From 6ccbbb90268b9a6b60b61c32aa4fb769066a049e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 14 May 2020 11:39:30 +0200 Subject: [PATCH 001/218] fix: resource_outscale_volume_link.go -> resource_outscale_volumes_link.go Signed-off-by: matthias.gatto --- ..._outscale_volume_link.go => resource_outscale_volumes_link.go} | 0 ...volume_link_test.go => resource_outscale_volumes_link_test.go} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename outscale/{resource_outscale_volume_link.go => resource_outscale_volumes_link.go} (100%) rename outscale/{resource_outscale_volume_link_test.go => resource_outscale_volumes_link_test.go} (100%) diff --git a/outscale/resource_outscale_volume_link.go b/outscale/resource_outscale_volumes_link.go similarity index 100% rename from outscale/resource_outscale_volume_link.go rename to outscale/resource_outscale_volumes_link.go diff --git a/outscale/resource_outscale_volume_link_test.go b/outscale/resource_outscale_volumes_link_test.go similarity index 100% rename from outscale/resource_outscale_volume_link_test.go rename to outscale/resource_outscale_volumes_link_test.go From 47345baeec714581d5abf21f119d9f50e3c2a300 Mon Sep 17 00:00:00 2001 From: PacoDw <__pm@outlook.com> Date: Tue, 7 Jul 2020 12:23:46 -0500 Subject: [PATCH 002/218] chore: fixed tags when the resource is imported --- outscale/data_source_outscale_vm.go | 6 ++--- outscale/data_source_outscale_vm_test.go | 22 ++++++++++------ outscale/resource_outscale_vm_test.go | 33 ++++++++++++++++++------ 3 files changed, 42 insertions(+), 19 deletions(-) diff --git a/outscale/data_source_outscale_vm.go b/outscale/data_source_outscale_vm.go index 665fe3c16..4400899d8 100644 --- a/outscale/data_source_outscale_vm.go +++ b/outscale/data_source_outscale_vm.go @@ -94,9 +94,6 @@ func dataSourceOutscaleOAPIVMRead(d *schema.ResourceData, meta interface{}) erro // Populate vm attribute fields with the returned vm return resourceDataAttrSetter(d, func(set AttributeSetter) error { d.SetId(vm.GetVmId()) - if err := set("tags", getOscAPITagSet(vm.GetTags())); err != nil { - return err - } return oapiVMDescriptionAttributes(set, &vm) }) } @@ -202,6 +199,9 @@ func oapiVMDescriptionAttributes(set AttributeSetter, vm *oscgo.Vm) error { if err := set("vm_initiated_shutdown_behavior", vm.GetVmInitiatedShutdownBehavior()); err != nil { return err } + if err := set("tags", getOscAPITagSet(vm.GetTags())); err != nil { + return err + } return set("vm_type", vm.GetVmType()) } diff --git a/outscale/data_source_outscale_vm_test.go b/outscale/data_source_outscale_vm_test.go index f72288047..ef114f3c5 100644 --- a/outscale/data_source_outscale_vm_test.go +++ b/outscale/data_source_outscale_vm_test.go @@ -10,6 +10,8 @@ import ( func TestAccOutscaleOAPIVMDataSource_basic(t *testing.T) { omi := os.Getenv("OUTSCALE_IMAGEID") + datasourcceName := "data.outscale_vm.basic_web" + resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, Providers: testAccProviders, @@ -17,10 +19,9 @@ func TestAccOutscaleOAPIVMDataSource_basic(t *testing.T) { { Config: testAccOAPIVMDataSourceConfig(omi, "tinav4.c2r2p2"), Check: resource.ComposeTestCheckFunc( - resource.TestCheckResourceAttr( - "outscale_vm.outscale_vm", "image_id", omi), - resource.TestCheckResourceAttr( - "outscale_vm.outscale_vm", "vm_type", "tinav4.c2r2p2"), + resource.TestCheckResourceAttr(datasourcceName, "image_id", omi), + resource.TestCheckResourceAttr(datasourcceName, "vm_type", "tinav4.c2r2p2"), + resource.TestCheckResourceAttr(datasourcceName, "tags.#", "1"), ), }, }, @@ -36,21 +37,26 @@ func testAccOAPIVMDataSourceConfig(omi, vmType string) string { key = "Name" value = "testacc-vm-ds" } - } - + } + resource "outscale_subnet" "outscale_subnet" { net_id = "${outscale_net.outscale_net.net_id}" ip_range = "10.0.0.0/24" subregion_name = "eu-west-2a" } - + resource "outscale_vm" "outscale_vm" { image_id = "%s" vm_type = "%s" keypair_name = "terraform-basic" subnet_id = "${outscale_subnet.outscale_subnet.subnet_id}" + + tags { + key = "name" + value = "Terraform-VM" + } } - + data "outscale_vm" "basic_web" { filter { name = "vm_ids" diff --git a/outscale/resource_outscale_vm_test.go b/outscale/resource_outscale_vm_test.go index de4a4bff1..b5eac0621 100644 --- a/outscale/resource_outscale_vm_test.go +++ b/outscale/resource_outscale_vm_test.go @@ -44,10 +44,13 @@ func TestAccOutscaleOAPIVM_Basic(t *testing.T) { } func TestAccOutscaleOAPIVM_importBasic(t *testing.T) { - omi := os.Getenv("OUTSCALE_IMAGEID") - region := os.Getenv("OUTSCALE_REGION") - keypair := os.Getenv("OUTSCALE_KEYPAIR") - resourceName := "outscale_vm.basic" + var ( + server oscgo.Vm + resourceName = "outscale_vm.basic" + omi = os.Getenv("OUTSCALE_IMAGEID") + region = fmt.Sprintf("%sa", os.Getenv("OUTSCALE_REGION")) + keypair = os.Getenv("OUTSCALE_KEYPAIR") + ) resource.ParallelTest(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, @@ -56,6 +59,15 @@ func TestAccOutscaleOAPIVM_importBasic(t *testing.T) { Steps: []resource.TestStep{ { Config: testAccCheckOutscaleOAPIVMConfigBasic(omi, "tinav4.c2r2p2", region, keypair), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPIVMExists(resourceName, &server), + resource.TestCheckResourceAttr(resourceName, "image_id", omi), + resource.TestCheckResourceAttr(resourceName, "vm_type", "tinav4.c2r2p2"), + resource.TestCheckResourceAttr(resourceName, "keypair_name", keypair), + resource.TestCheckResourceAttr(resourceName, "placement_subregion_name", region), + resource.TestCheckResourceAttr(resourceName, "private_ips.#", "1"), + resource.TestCheckResourceAttr(resourceName, "tags.#", "1"), + ), }, { ResourceName: resourceName, @@ -602,7 +614,7 @@ func testAccCheckOutscaleOAPIVMConfigBasic(omi, vmType, region, keypair string) ip_range = "10.0.0.0/16" tags { - key = "Name" + key = "Name" value = "testacc-vm-rs" } } @@ -614,12 +626,17 @@ func testAccCheckOutscaleOAPIVMConfigBasic(omi, vmType, region, keypair string) } resource "outscale_vm" "basic" { - image_id = "%[1]s" + image_id = "%[1]s" vm_type = "%[2]s" - keypair_name = "%[4]s" - placement_subregion_name = "%[3]sa" + keypair_name = "%[4]s" + placement_subregion_name = "%[3]s" subnet_id = "${outscale_subnet.outscale_subnet.subnet_id}" private_ips = ["10.0.0.12"] + + tags { + key = "name" + value = "Terraform-VM" + } }`, omi, vmType, region, keypair) } From 06e681a3940bba1038db9012a711ed57b321e1bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Tue, 7 Jul 2020 13:45:28 -0500 Subject: [PATCH 003/218] refactor: changed optional to required for image_id in resource vm --- outscale/resource_outscale_vm.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/outscale/resource_outscale_vm.go b/outscale/resource_outscale_vm.go index f9327301a..dd7f2eb57 100644 --- a/outscale/resource_outscale_vm.go +++ b/outscale/resource_outscale_vm.go @@ -109,9 +109,8 @@ func resourceOutscaleOApiVM() *schema.Resource { }, "image_id": { Type: schema.TypeString, + Required: true, ForceNew: true, - Optional: true, - Computed: true, }, "keypair_name": { Type: schema.TypeString, From 606712ec52598a6e3dbde7efe459c9801d6f83cc Mon Sep 17 00:00:00 2001 From: Marin Salinas Date: Tue, 15 Sep 2020 17:24:16 -0500 Subject: [PATCH 004/218] chore: add proxy configuration --- outscale/config.go | 1 + 1 file changed, 1 insertion(+) diff --git a/outscale/config.go b/outscale/config.go index 1f7ba177b..9ea73e25a 100644 --- a/outscale/config.go +++ b/outscale/config.go @@ -29,6 +29,7 @@ func (c *Config) Client() (*OutscaleClient, error) { skipClient := &http.Client{ Transport: &http.Transport{ TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, + Proxy: http.ProxyFromEnvironment, }, } From c1b295693bd520c0fa0bbc6c9c757fffea867bd0 Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Fri, 2 Oct 2020 14:33:59 +0000 Subject: [PATCH 005/218] Update for 0.1.1 - proxy support addition --- README.md | 58 +++++++++++++++++++++++++++++-------------------------- 1 file changed, 31 insertions(+), 27 deletions(-) diff --git a/README.md b/README.md index 048730cab..e25d45105 100644 --- a/README.md +++ b/README.md @@ -10,44 +10,46 @@ Requirements ------------ -- [Terraform](https://www.terraform.io/downloads.html) 0.12.x +- [Terraform](https://www.terraform.io/downloads.html) 0.13.x - [Go](https://golang.org/doc/install) 1.13 (to build the provider plugin) -Installing The Provider on Linux --------------------------------- +Using the Provider +------------------ -Download the binary and install it in ~/.terraform.d/plugins/linux_amd64/. +Add the following lines in the Terraform configuration to permit to get the provider from the Terrafom registry: ```sh -$ wget https://github.com/outscale-dev/terraform-provider-outscale/releases/download/release-0.1.0RC9/terraform-provider-outscale_linux_amd64_v0.1.0-rc9.zip -$ unzip terraform-provider-outscale_linux_amd64_v0.1.0-rc9.zip -$ mv terraform-provider-outscale_v0.1.0-rc9 ~/.terraform.d/plugins/linux_amd64/. +terraform { + required_providers { + outscale = { + source = "outscale-dev/outscale" + version = "0.1.1" + } + } +} + +provider "outscale" { + # Configuration options +} ``` -Installing The Provider on MacOs --------------------------------- - -Download the binary and install it in ~/.terraform/plugins/darwin_amd64/. +Configuring the proxy on Linux/MAC OS, if any +--------------------------------------------- ```sh -$ wget https://github.com/outscale-dev/terraform-provider-outscale/releases/download/release-0.1.0RC9/terraform-provider-outscale_darwin_amd64_v0.1.0-rc9.zip -$ unzip terraform-provider-outscale_darwin_amd64_v0.1.0-rc9.zip -$ mv terraform-provider-outscale_v0.1.0-rc9 ~/.terraform.d/plugins/darwin_amd64/. +$ export HTTPS_PROXY=http://192.168.1.24:3128 ``` -Installing The Provider on Windows ----------------------------------- - -Download the binary and install it in %APPDATA%\terraform.d\plugins +Configuring the proxy on Windows, if any +---------------------------------------- ```sh -$ download the plugin from https://github.com/outscale-dev/terraform-provider-outscale/releases/download/release-0.1.0RC9/terraform-provider-outscale_windows_386_v0.1.0-rc9.zip -$ unzip terraform-provider-outscale_windows_386_v0.1.0-rc9.zip -$ move terraform-provider-outscale_v0.1.0-rc9 %APPDATA%\terraform.d\plugins +$ set HTTPS_PROXY=http://192.168.1.24:3128 ``` + Building The Provider --------------------- @@ -55,27 +57,29 @@ Clone repository to: `$GOPATH/src/github.com/terraform-providers/terraform-provi ```sh $ mkdir -p $GOPATH/src/github.com/terraform-providers; cd $GOPATH/src/github.com/terraform-providers -$ git clone --branch release-0.1.0RC9 https://github.com/outscale-dev/terraform-provider-outscale +$ git clone --branch v0.1.1 https://github.com/outscale-dev/terraform-provider-outscale ``` Enter the provider directory and build the provider ```sh $ cd $GOPATH/src/github.com/terraform-providers/terraform-provider-outscale -$ go build -o terraform-provider-outscale_v0.1.0-rc9 +$ go build -o terraform-provider-outscale_v0.1.1 ``` Using the provider ---------------------- 1. Download and install [Terraform](https://www.terraform.io/downloads.html) -2. Move the plugin to the repository ~/.terraform.d/plugins/linux_amd64/. +2. Move the plugin to the repository ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.1.0/linux_amd64/. ```shell - $ mv terraform-provider-outscale_v0.1.0-rc9 ~/.terraform.d/plugins/linux_amd64/. + $ mv terraform-provider-outscale_v0.1.1 ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.1.0/linux_amd64/. ``` -3. Execute `terraform plan` -4. `terraform init` +3. Execute `terraform init` +4. Execute `terraform plan` + + Developing the Provider --------------------------- From 1679271520caa15a6f77ac46d9dab17e605d85db Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Fri, 2 Oct 2020 14:42:31 +0000 Subject: [PATCH 006/218] Update for 0.1.1 - proxy support addition --- CHANGELOG.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 269988323..299135618 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,19 @@ +0.1.1 (October 02, 2020) +======================== + +BUG FIXES: +---------- + +* Support proxy for Outscale Terraform provider (TPD-1924) + + +0.1.0 (August 07, 2020) +======================== + +NOTES: +Rename of the previous release + + 0.1.0RC9 (June 22, 2020) ======================== From b6a6e58b051e45e9fe00128f30744a3b365b2580 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Mon, 19 Oct 2020 10:54:56 -0600 Subject: [PATCH 007/218] chore:updated vendor --- go.mod | 3 +- go.sum | 10 + .../github.com/aws/aws-sdk-go/aws/config.go | 9 +- .../aws-sdk-go/aws/corehandlers/handlers.go | 2 + .../shared_credentials_provider.go | 5 +- .../stscreds/web_identity_provider.go | 21 +- .../aws/aws-sdk-go/aws/ec2metadata/api.go | 8 +- .../aws/aws-sdk-go/aws/ec2metadata/service.go | 19 +- .../aws/aws-sdk-go/aws/endpoints/defaults.go | 700 ++++++- .../aws/aws-sdk-go/aws/endpoints/v3model.go | 16 +- .../aws/request/connection_reset_error.go | 3 +- .../aws/aws-sdk-go/aws/session/doc.go | 17 + .../aws/aws-sdk-go/aws/session/env_config.go | 10 + .../aws/aws-sdk-go/aws/session/session.go | 61 +- .../github.com/aws/aws-sdk-go/aws/version.go | 2 +- .../eventstream/eventstreamapi/reader.go | 15 +- .../private/protocol/eventstream/header.go | 9 + .../private/protocol/eventstream/message.go | 14 + .../protocol/json/jsonutil/unmarshal.go | 36 +- .../aws-sdk-go/private/protocol/timestamp.go | 9 +- .../aws/aws-sdk-go/service/s3/api.go | 653 ++++++- .../aws/aws-sdk-go/service/s3/doc_custom.go | 13 - .../aws/aws-sdk-go/service/s3/sse.go | 2 +- .../outscale/osc-sdk-go/osc/.gitignore | 24 + .../osc-sdk-go/osc/.openapi-generator-ignore | 23 + .../outscale/osc-sdk-go/osc/.travis.yml | 8 + .../outscale/osc-sdk-go/osc/README.md | 728 ++++++++ .../outscale/osc-sdk-go/osc/api_access_key.go | 632 +++++++ .../outscale/osc-sdk-go/osc/api_account.go | 874 +++++++++ .../outscale/osc-sdk-go/osc/api_api_log.go | 148 ++ .../osc-sdk-go/osc/api_client_gateway.go | 390 ++++ .../osc-sdk-go/osc/api_dhcp_option.go | 390 ++++ .../osc-sdk-go/osc/api_direct_link.go | 390 ++++ .../osc/api_direct_link_interface.go | 390 ++++ .../osc-sdk-go/osc/api_flexible_gpu.go | 860 +++++++++ .../outscale/osc-sdk-go/osc/api_image.go | 869 +++++++++ .../osc-sdk-go/osc/api_internet_service.go | 777 ++++++++ .../outscale/osc-sdk-go/osc/api_keypair.go | 487 +++++ .../outscale/osc-sdk-go/osc/api_listener.go | 753 ++++++++ .../osc-sdk-go/osc/api_load_balancer.go | 1237 +++++++++++++ .../osc/api_load_balancer_policy.go | 269 +++ .../outscale/osc-sdk-go/osc/api_location.go | 134 ++ .../osc-sdk-go/osc/api_nat_service.go | 477 +++++ .../outscale/osc-sdk-go/osc/api_net.go | 637 +++++++ .../osc-sdk-go/osc/api_net_access_point.go | 618 +++++++ .../osc-sdk-go/osc/api_net_peering.go | 807 ++++++++ .../outscale/osc-sdk-go/osc/api_nic.go | 1227 +++++++++++++ .../osc-sdk-go/osc/api_product_type.go | 134 ++ .../outscale/osc-sdk-go/osc/api_public_ip.go | 884 +++++++++ .../outscale/osc-sdk-go/osc/api_quota.go | 148 ++ .../outscale/osc-sdk-go/osc/api_region.go | 148 ++ .../outscale/osc-sdk-go/osc/api_route.go | 477 +++++ .../osc-sdk-go/osc/api_route_table.go | 777 ++++++++ .../osc-sdk-go/osc/api_security_group.go | 477 +++++ .../osc-sdk-go/osc/api_security_group_rule.go | 327 ++++ .../osc-sdk-go/osc/api_server_certificate.go | 511 ++++++ .../outscale/osc-sdk-go/osc/api_snapshot.go | 869 +++++++++ .../outscale/osc-sdk-go/osc/api_subnet.go | 637 +++++++ .../outscale/osc-sdk-go/osc/api_subregion.go | 148 ++ .../outscale/osc-sdk-go/osc/api_tag.go | 477 +++++ .../outscale/osc-sdk-go/osc/api_task.go | 148 ++ .../osc-sdk-go/osc/api_virtual_gateway.go | 753 ++++++++ .../outscale/osc-sdk-go/osc/api_vm.go | 1634 +++++++++++++++++ .../outscale/osc-sdk-go/osc/api_volume.go | 777 ++++++++ .../osc-sdk-go/osc/api_vpn_connection.go | 632 +++++++ .../outscale/osc-sdk-go/osc/client.go | 664 +++++++ .../outscale/osc-sdk-go/osc/configuration.go | 266 +++ .../outscale/osc-sdk-go/osc/git_push.sh | 58 + .../github.com/outscale/osc-sdk-go/osc/go.mod | 8 + .../github.com/outscale/osc-sdk-go/osc/go.sum | 13 + .../osc/model_accept_net_peering_request.go | 147 ++ .../osc/model_accept_net_peering_response.go | 152 ++ .../osc-sdk-go/osc/model_accepter_net.go | 191 ++ .../osc-sdk-go/osc/model_access_key.go | 265 +++ .../osc/model_access_key_secret_key.go | 302 +++ .../osc-sdk-go/osc/model_access_log.go | 228 +++ .../outscale/osc-sdk-go/osc/model_account.go | 598 ++++++ .../model_application_sticky_cookie_policy.go | 154 ++ .../osc-sdk-go/osc/model_backend_vm_health.go | 228 +++ .../osc/model_block_device_mapping_created.go | 153 ++ .../osc/model_block_device_mapping_image.go | 190 ++ .../model_block_device_mapping_vm_creation.go | 227 +++ .../model_block_device_mapping_vm_update.go | 227 +++ .../osc-sdk-go/osc/model_bsu_created.go | 228 +++ .../osc-sdk-go/osc/model_bsu_to_create.go | 265 +++ .../osc-sdk-go/osc/model_bsu_to_update_vm.go | 154 ++ .../osc/model_check_authentication_request.go | 191 ++ .../model_check_authentication_response.go | 116 ++ .../osc-sdk-go/osc/model_client_gateway.go | 302 +++ .../osc-sdk-go/osc/model_consumption_entry.go | 376 ++++ .../osc/model_create_access_key_request.go | 154 ++ .../osc/model_create_access_key_response.go | 152 ++ .../osc/model_create_account_request.go | 542 ++++++ .../osc/model_create_account_response.go | 152 ++ .../model_create_client_gateway_request.go | 207 +++ .../model_create_client_gateway_response.go | 152 ++ .../osc/model_create_dhcp_options_request.go | 228 +++ .../osc/model_create_dhcp_options_response.go | 152 ++ ...el_create_direct_link_interface_request.go | 176 ++ ...l_create_direct_link_interface_response.go | 152 ++ .../osc/model_create_direct_link_request.go | 207 +++ .../osc/model_create_direct_link_response.go | 152 ++ .../osc/model_create_flexible_gpu_request.go | 255 +++ .../osc/model_create_flexible_gpu_response.go | 152 ++ .../model_create_image_export_task_request.go | 176 ++ ...model_create_image_export_task_response.go | 152 ++ .../osc/model_create_image_request.go | 487 +++++ .../osc/model_create_image_response.go | 152 ++ .../model_create_internet_service_request.go | 117 ++ .../model_create_internet_service_response.go | 152 ++ .../osc/model_create_keypair_request.go | 184 ++ .../osc/model_create_keypair_response.go | 152 ++ .../osc/model_create_listener_rule_request.go | 205 +++ .../model_create_listener_rule_response.go | 152 ++ ..._create_load_balancer_listeners_request.go | 177 ++ ...create_load_balancer_listeners_response.go | 152 ++ ...del_create_load_balancer_policy_request.go | 244 +++ ...el_create_load_balancer_policy_response.go | 152 ++ .../osc/model_create_load_balancer_request.go | 362 ++++ .../model_create_load_balancer_response.go | 152 ++ ...model_create_load_balancer_tags_request.go | 177 ++ ...odel_create_load_balancer_tags_response.go | 116 ++ .../osc/model_create_nat_service_request.go | 177 ++ .../osc/model_create_nat_service_response.go | 152 ++ .../model_create_net_access_point_request.go | 214 +++ .../model_create_net_access_point_response.go | 152 ++ .../osc/model_create_net_peering_request.go | 177 ++ .../osc/model_create_net_peering_response.go | 152 ++ .../osc/model_create_net_request.go | 184 ++ .../osc/model_create_net_response.go | 152 ++ .../osc/model_create_nic_request.go | 258 +++ .../osc/model_create_nic_response.go | 152 ++ .../osc/model_create_public_ip_request.go | 117 ++ .../osc/model_create_public_ip_response.go | 152 ++ .../osc/model_create_route_request.go | 362 ++++ .../osc/model_create_route_response.go | 152 ++ .../osc/model_create_route_table_request.go | 147 ++ .../osc/model_create_route_table_response.go | 152 ++ .../model_create_security_group_request.go | 214 +++ .../model_create_security_group_response.go | 152 ++ ...odel_create_security_group_rule_request.go | 436 +++++ ...del_create_security_group_rule_response.go | 152 ++ ...model_create_server_certificate_request.go | 281 +++ ...odel_create_server_certificate_response.go | 152 ++ ...del_create_snapshot_export_task_request.go | 176 ++ ...el_create_snapshot_export_task_response.go | 152 ++ .../osc/model_create_snapshot_request.go | 339 ++++ .../osc/model_create_snapshot_response.go | 152 ++ .../osc/model_create_subnet_request.go | 214 +++ .../osc/model_create_subnet_response.go | 152 ++ .../osc/model_create_tags_request.go | 177 ++ .../osc/model_create_tags_response.go | 116 ++ .../model_create_virtual_gateway_request.go | 147 ++ .../model_create_virtual_gateway_response.go | 152 ++ .../osc/model_create_vms_request.go | 816 ++++++++ .../osc/model_create_vms_response.go | 153 ++ .../osc/model_create_volume_request.go | 295 +++ .../osc/model_create_volume_response.go | 152 ++ .../model_create_vpn_connection_request.go | 244 +++ .../model_create_vpn_connection_response.go | 152 ++ ...del_create_vpn_connection_route_request.go | 177 ++ ...el_create_vpn_connection_route_response.go | 116 ++ .../osc/model_delete_access_key_request.go | 147 ++ .../osc/model_delete_access_key_response.go | 116 ++ .../model_delete_client_gateway_request.go | 147 ++ .../model_delete_client_gateway_response.go | 116 ++ .../osc/model_delete_dhcp_options_request.go | 147 ++ .../osc/model_delete_dhcp_options_response.go | 116 ++ ...el_delete_direct_link_interface_request.go | 147 ++ ...l_delete_direct_link_interface_response.go | 116 ++ .../osc/model_delete_direct_link_request.go | 147 ++ .../osc/model_delete_direct_link_response.go | 116 ++ .../osc/model_delete_export_task_request.go | 147 ++ .../osc/model_delete_export_task_response.go | 116 ++ .../osc/model_delete_flexible_gpu_request.go | 147 ++ .../osc/model_delete_flexible_gpu_response.go | 116 ++ .../osc/model_delete_image_request.go | 147 ++ .../osc/model_delete_image_response.go | 116 ++ .../model_delete_internet_service_request.go | 147 ++ .../model_delete_internet_service_response.go | 116 ++ .../osc/model_delete_keypair_request.go | 147 ++ .../osc/model_delete_keypair_response.go | 116 ++ .../osc/model_delete_listener_rule_request.go | 147 ++ .../model_delete_listener_rule_response.go | 116 ++ ..._delete_load_balancer_listeners_request.go | 177 ++ ...delete_load_balancer_listeners_response.go | 152 ++ ...del_delete_load_balancer_policy_request.go | 177 ++ ...el_delete_load_balancer_policy_response.go | 152 ++ .../osc/model_delete_load_balancer_request.go | 147 ++ .../model_delete_load_balancer_response.go | 116 ++ ...model_delete_load_balancer_tags_request.go | 177 ++ ...odel_delete_load_balancer_tags_response.go | 116 ++ .../osc/model_delete_nat_service_request.go | 147 ++ .../osc/model_delete_nat_service_response.go | 116 ++ .../model_delete_net_access_point_request.go | 147 ++ .../model_delete_net_access_point_response.go | 116 ++ .../osc/model_delete_net_peering_request.go | 147 ++ .../osc/model_delete_net_peering_response.go | 116 ++ .../osc/model_delete_net_request.go | 147 ++ .../osc/model_delete_net_response.go | 116 ++ .../osc/model_delete_nic_request.go | 147 ++ .../osc/model_delete_nic_response.go | 116 ++ .../osc/model_delete_public_ip_request.go | 191 ++ .../osc/model_delete_public_ip_response.go | 116 ++ .../osc/model_delete_route_request.go | 177 ++ .../osc/model_delete_route_response.go | 152 ++ .../osc/model_delete_route_table_request.go | 147 ++ .../osc/model_delete_route_table_response.go | 116 ++ .../model_delete_security_group_request.go | 191 ++ .../model_delete_security_group_response.go | 116 ++ ...odel_delete_security_group_rule_request.go | 436 +++++ ...del_delete_security_group_rule_response.go | 152 ++ ...model_delete_server_certificate_request.go | 147 ++ ...odel_delete_server_certificate_response.go | 116 ++ .../osc/model_delete_snapshot_request.go | 147 ++ .../osc/model_delete_snapshot_response.go | 116 ++ .../osc/model_delete_subnet_request.go | 147 ++ .../osc/model_delete_subnet_response.go | 116 ++ .../osc/model_delete_tags_request.go | 177 ++ .../osc/model_delete_tags_response.go | 116 ++ .../model_delete_virtual_gateway_request.go | 147 ++ .../model_delete_virtual_gateway_response.go | 116 ++ .../osc/model_delete_vms_request.go | 147 ++ .../osc/model_delete_vms_response.go | 153 ++ .../osc/model_delete_volume_request.go | 147 ++ .../osc/model_delete_volume_response.go | 116 ++ .../model_delete_vpn_connection_request.go | 147 ++ .../model_delete_vpn_connection_response.go | 116 ++ ...del_delete_vpn_connection_route_request.go | 177 ++ ...el_delete_vpn_connection_route_response.go | 116 ++ ...deregister_vms_in_load_balancer_request.go | 177 ++ ...eregister_vms_in_load_balancer_response.go | 116 ++ .../osc-sdk-go/osc/model_dhcp_options_set.go | 339 ++++ .../osc-sdk-go/osc/model_direct_link.go | 339 ++++ .../osc/model_direct_link_interface.go | 311 ++++ .../osc/model_direct_link_interfaces.go | 561 ++++++ .../osc-sdk-go/osc/model_error_response.go | 153 ++ .../outscale/osc-sdk-go/osc/model_errors.go | 191 ++ .../osc/model_filters_access_keys.go | 154 ++ .../osc-sdk-go/osc/model_filters_api_log.go | 413 +++++ .../osc/model_filters_client_gateway.go | 376 ++++ .../osc/model_filters_dhcp_options.go | 376 ++++ .../osc/model_filters_direct_link.go | 117 ++ .../model_filters_direct_link_interface.go | 154 ++ .../osc/model_filters_export_task.go | 117 ++ .../osc/model_filters_flexible_gpu.go | 339 ++++ .../osc-sdk-go/osc/model_filters_image.go | 857 +++++++++ .../osc/model_filters_internet_service.go | 302 +++ .../osc-sdk-go/osc/model_filters_keypair.go | 154 ++ .../osc/model_filters_listener_rule.go | 117 ++ .../osc/model_filters_load_balancer.go | 117 ++ .../osc/model_filters_nat_service.go | 339 ++++ .../osc-sdk-go/osc/model_filters_net.go | 376 ++++ .../osc/model_filters_net_access_point.go | 339 ++++ .../osc/model_filters_net_peering.go | 524 ++++++ .../osc-sdk-go/osc/model_filters_nic.go | 265 +++ .../osc/model_filters_product_type.go | 117 ++ .../osc-sdk-go/osc/model_filters_public_ip.go | 487 +++++ .../osc-sdk-go/osc/model_filters_quota.go | 228 +++ .../osc/model_filters_route_table.go | 709 +++++++ .../osc/model_filters_security_group.go | 339 ++++ .../osc/model_filters_server_certificate.go | 117 ++ .../osc-sdk-go/osc/model_filters_service.go | 154 ++ .../osc-sdk-go/osc/model_filters_snapshot.go | 561 ++++++ .../osc-sdk-go/osc/model_filters_subnet.go | 413 +++++ .../osc-sdk-go/osc/model_filters_subregion.go | 117 ++ .../osc-sdk-go/osc/model_filters_tag.go | 228 +++ .../osc/model_filters_virtual_gateway.go | 376 ++++ .../osc-sdk-go/osc/model_filters_vm.go | 228 +++ .../osc-sdk-go/osc/model_filters_vm_type.go | 302 +++ .../osc-sdk-go/osc/model_filters_vms_state.go | 191 ++ .../osc-sdk-go/osc/model_filters_volume.go | 635 +++++++ .../osc/model_filters_vpn_connection.go | 487 +++++ .../osc-sdk-go/osc/model_flexible_gpu.go | 339 ++++ .../osc/model_flexible_gpu_catalog.go | 265 +++ .../osc-sdk-go/osc/model_health_check.go | 297 +++ .../outscale/osc-sdk-go/osc/model_image.go | 707 +++++++ .../osc-sdk-go/osc/model_image_export_task.go | 338 ++++ .../osc-sdk-go/osc/model_internet_service.go | 228 +++ .../outscale/osc-sdk-go/osc/model_keypair.go | 154 ++ .../osc-sdk-go/osc/model_keypair_created.go | 191 ++ .../osc/model_link_flexible_gpu_request.go | 177 ++ .../osc/model_link_flexible_gpu_response.go | 116 ++ .../model_link_internet_service_request.go | 177 ++ .../model_link_internet_service_response.go | 116 ++ .../outscale/osc-sdk-go/osc/model_link_nic.go | 302 +++ .../osc-sdk-go/osc/model_link_nic_light.go | 228 +++ .../osc-sdk-go/osc/model_link_nic_request.go | 207 +++ .../osc-sdk-go/osc/model_link_nic_response.go | 153 ++ .../osc/model_link_nic_to_update.go | 154 ++ .../osc/model_link_private_ips_request.go | 258 +++ .../osc/model_link_private_ips_response.go | 116 ++ .../osc-sdk-go/osc/model_link_public_ip.go | 265 +++ .../osc/model_link_public_ip_light_for_vm.go | 191 ++ .../osc/model_link_public_ip_request.go | 339 ++++ .../osc/model_link_public_ip_response.go | 153 ++ .../osc-sdk-go/osc/model_link_route_table.go | 228 +++ .../osc/model_link_route_table_request.go | 177 ++ .../osc/model_link_route_table_response.go | 153 ++ .../osc/model_link_virtual_gateway_request.go | 177 ++ .../model_link_virtual_gateway_response.go | 152 ++ .../osc/model_link_volume_request.go | 207 +++ .../osc/model_link_volume_response.go | 116 ++ .../osc-sdk-go/osc/model_linked_volume.go | 265 +++ .../outscale/osc-sdk-go/osc/model_listener.go | 302 +++ .../osc/model_listener_for_creation.go | 244 +++ .../osc-sdk-go/osc/model_listener_rule.go | 376 ++++ .../osc/model_listener_rule_for_creation.go | 295 +++ .../osc-sdk-go/osc/model_load_balancer.go | 632 +++++++ .../osc/model_load_balancer_light.go | 140 ++ ...odel_load_balancer_sticky_cookie_policy.go | 117 ++ .../osc-sdk-go/osc/model_load_balancer_tag.go | 191 ++ .../outscale/osc-sdk-go/osc/model_location.go | 154 ++ .../outscale/osc-sdk-go/osc/model_log.go | 672 +++++++ .../osc-sdk-go/osc/model_maintenance_event.go | 228 +++ .../osc-sdk-go/osc/model_nat_service.go | 302 +++ .../outscale/osc-sdk-go/osc/model_net.go | 302 +++ .../osc-sdk-go/osc/model_net_access_point.go | 302 +++ .../osc-sdk-go/osc/model_net_peering.go | 262 +++ .../osc-sdk-go/osc/model_net_peering_state.go | 154 ++ .../osc/model_net_to_virtual_gateway_link.go | 154 ++ .../outscale/osc-sdk-go/osc/model_nic.go | 633 +++++++ .../osc/model_nic_for_vm_creation.go | 376 ++++ .../osc-sdk-go/osc/model_nic_light.go | 559 ++++++ .../osc-sdk-go/osc/model_osu_api_key.go | 154 ++ .../osc-sdk-go/osc/model_osu_export.go | 250 +++ .../osc/model_permissions_on_resource.go | 154 ++ .../model_permissions_on_resource_creation.go | 152 ++ .../osc-sdk-go/osc/model_placement.go | 154 ++ .../osc-sdk-go/osc/model_private_ip.go | 227 +++ .../osc-sdk-go/osc/model_private_ip_light.go | 154 ++ .../osc/model_private_ip_light_for_vm.go | 227 +++ .../osc-sdk-go/osc/model_product_type.go | 191 ++ .../osc-sdk-go/osc/model_public_ip.go | 376 ++++ .../osc-sdk-go/osc/model_public_ip_light.go | 154 ++ .../outscale/osc-sdk-go/osc/model_quota.go | 339 ++++ .../osc-sdk-go/osc/model_quota_types.go | 154 ++ .../osc/model_read_access_keys_request.go | 153 ++ .../osc/model_read_access_keys_response.go | 153 ++ .../osc/model_read_accounts_request.go | 117 ++ .../osc/model_read_accounts_response.go | 153 ++ .../osc/model_read_admin_password_request.go | 147 ++ .../osc/model_read_admin_password_response.go | 190 ++ .../osc/model_read_api_logs_request.go | 263 +++ .../osc/model_read_api_logs_response.go | 190 ++ .../osc/model_read_client_gateways_request.go | 153 ++ .../model_read_client_gateways_response.go | 153 ++ .../osc/model_read_console_output_request.go | 147 ++ .../osc/model_read_console_output_response.go | 190 ++ .../model_read_consumption_account_request.go | 177 ++ ...model_read_consumption_account_response.go | 153 ++ .../osc/model_read_dhcp_options_request.go | 153 ++ .../osc/model_read_dhcp_options_response.go | 153 ++ ...del_read_direct_link_interfaces_request.go | 153 ++ ...el_read_direct_link_interfaces_response.go | 153 ++ .../osc/model_read_direct_links_request.go | 153 ++ .../osc/model_read_direct_links_response.go | 153 ++ ...model_read_flexible_gpu_catalog_request.go | 117 ++ ...odel_read_flexible_gpu_catalog_response.go | 153 ++ .../osc/model_read_flexible_gpus_request.go | 153 ++ .../osc/model_read_flexible_gpus_response.go | 153 ++ .../model_read_image_export_tasks_request.go | 153 ++ .../model_read_image_export_tasks_response.go | 153 ++ .../osc/model_read_images_request.go | 153 ++ .../osc/model_read_images_response.go | 153 ++ .../model_read_internet_services_request.go | 153 ++ .../model_read_internet_services_response.go | 153 ++ .../osc/model_read_keypairs_request.go | 153 ++ .../osc/model_read_keypairs_response.go | 153 ++ .../osc/model_read_listener_rules_request.go | 153 ++ .../osc/model_read_listener_rules_response.go | 153 ++ .../model_read_load_balancer_tags_request.go | 147 ++ .../model_read_load_balancer_tags_response.go | 153 ++ .../osc/model_read_load_balancers_request.go | 153 ++ .../osc/model_read_load_balancers_response.go | 153 ++ .../osc/model_read_locations_request.go | 117 ++ .../osc/model_read_locations_response.go | 153 ++ .../osc/model_read_nat_services_request.go | 153 ++ .../osc/model_read_nat_services_response.go | 153 ++ ..._read_net_access_point_services_request.go | 153 ++ ...read_net_access_point_services_response.go | 153 ++ .../model_read_net_access_points_request.go | 153 ++ .../model_read_net_access_points_response.go | 153 ++ .../osc/model_read_net_peerings_request.go | 153 ++ .../osc/model_read_net_peerings_response.go | 153 ++ .../osc-sdk-go/osc/model_read_nets_request.go | 153 ++ .../osc/model_read_nets_response.go | 153 ++ .../osc-sdk-go/osc/model_read_nics_request.go | 153 ++ .../osc/model_read_nics_response.go | 153 ++ .../osc/model_read_product_types_request.go | 153 ++ .../osc/model_read_product_types_response.go | 153 ++ .../model_read_public_ip_ranges_request.go | 117 ++ .../model_read_public_ip_ranges_response.go | 153 ++ .../osc/model_read_public_ips_request.go | 153 ++ .../osc/model_read_public_ips_response.go | 153 ++ .../osc/model_read_quotas_request.go | 153 ++ .../osc/model_read_quotas_response.go | 153 ++ .../osc/model_read_regions_request.go | 117 ++ .../osc/model_read_regions_response.go | 153 ++ .../osc/model_read_route_tables_request.go | 153 ++ .../osc/model_read_route_tables_response.go | 153 ++ .../model_read_secret_access_key_request.go | 147 ++ .../model_read_secret_access_key_response.go | 152 ++ .../osc/model_read_security_groups_request.go | 153 ++ .../model_read_security_groups_response.go | 153 ++ .../model_read_server_certificates_request.go | 153 ++ ...model_read_server_certificates_response.go | 153 ++ ...odel_read_snapshot_export_tasks_request.go | 153 ++ ...del_read_snapshot_export_tasks_response.go | 153 ++ .../osc/model_read_snapshots_request.go | 153 ++ .../osc/model_read_snapshots_response.go | 153 ++ .../osc/model_read_subnets_request.go | 153 ++ .../osc/model_read_subnets_response.go | 153 ++ .../osc/model_read_subregions_request.go | 153 ++ .../osc/model_read_subregions_response.go | 153 ++ .../osc-sdk-go/osc/model_read_tags_request.go | 153 ++ .../osc/model_read_tags_response.go | 153 ++ .../model_read_virtual_gateways_request.go | 153 ++ .../model_read_virtual_gateways_response.go | 153 ++ .../osc/model_read_vm_types_request.go | 153 ++ .../osc/model_read_vm_types_response.go | 153 ++ .../osc/model_read_vms_health_request.go | 184 ++ .../osc/model_read_vms_health_response.go | 153 ++ .../osc-sdk-go/osc/model_read_vms_request.go | 153 ++ .../osc-sdk-go/osc/model_read_vms_response.go | 153 ++ .../osc/model_read_vms_state_request.go | 190 ++ .../osc/model_read_vms_state_response.go | 153 ++ .../osc/model_read_volumes_request.go | 153 ++ .../osc/model_read_volumes_response.go | 153 ++ .../osc/model_read_vpn_connections_request.go | 153 ++ .../model_read_vpn_connections_response.go | 153 ++ .../osc/model_reboot_vms_request.go | 147 ++ .../osc/model_reboot_vms_response.go | 116 ++ .../outscale/osc-sdk-go/osc/model_region.go | 154 ++ ...l_register_vms_in_load_balancer_request.go | 177 ++ ..._register_vms_in_load_balancer_response.go | 116 ++ .../osc/model_reject_net_peering_request.go | 147 ++ .../osc/model_reject_net_peering_response.go | 116 ++ .../model_reset_account_password_request.go | 177 ++ .../model_reset_account_password_response.go | 116 ++ .../osc/model_resource_load_balancer_tag.go | 117 ++ .../osc-sdk-go/osc/model_resource_tag.go | 140 ++ .../osc-sdk-go/osc/model_response_context.go | 117 ++ .../outscale/osc-sdk-go/osc/model_route.go | 487 +++++ .../osc-sdk-go/osc/model_route_light.go | 191 ++ ...model_route_propagating_virtual_gateway.go | 117 ++ .../osc-sdk-go/osc/model_route_table.go | 302 +++ .../osc-sdk-go/osc/model_security_group.go | 376 ++++ .../osc/model_security_group_light.go | 154 ++ .../osc/model_security_group_rule.go | 302 +++ .../osc/model_security_groups_member.go | 191 ++ ...model_send_reset_password_email_request.go | 147 ++ ...odel_send_reset_password_email_response.go | 116 ++ .../osc/model_server_certificate.go | 265 +++ .../outscale/osc-sdk-go/osc/model_service.go | 191 ++ .../outscale/osc-sdk-go/osc/model_snapshot.go | 449 +++++ .../osc/model_snapshot_export_task.go | 338 ++++ .../osc-sdk-go/osc/model_source_net.go | 191 ++ .../osc/model_source_security_group.go | 154 ++ .../osc-sdk-go/osc/model_start_vms_request.go | 147 ++ .../osc/model_start_vms_response.go | 153 ++ .../osc-sdk-go/osc/model_state_comment.go | 154 ++ .../osc-sdk-go/osc/model_stop_vms_request.go | 184 ++ .../osc-sdk-go/osc/model_stop_vms_response.go | 153 ++ .../outscale/osc-sdk-go/osc/model_subnet.go | 376 ++++ .../osc-sdk-go/osc/model_subregion.go | 191 ++ .../outscale/osc-sdk-go/osc/model_tag.go | 228 +++ .../osc/model_unlink_flexible_gpu_request.go | 147 ++ .../osc/model_unlink_flexible_gpu_response.go | 116 ++ .../model_unlink_internet_service_request.go | 177 ++ .../model_unlink_internet_service_response.go | 116 ++ .../osc/model_unlink_nic_request.go | 147 ++ .../osc/model_unlink_nic_response.go | 116 ++ .../osc/model_unlink_private_ips_request.go | 177 ++ .../osc/model_unlink_private_ips_response.go | 116 ++ .../osc/model_unlink_public_ip_request.go | 191 ++ .../osc/model_unlink_public_ip_response.go | 116 ++ .../osc/model_unlink_route_table_request.go | 147 ++ .../osc/model_unlink_route_table_response.go | 116 ++ .../model_unlink_virtual_gateway_request.go | 177 ++ .../model_unlink_virtual_gateway_response.go | 116 ++ .../osc/model_unlink_volume_request.go | 184 ++ .../osc/model_unlink_volume_response.go | 116 ++ .../osc/model_update_access_key_request.go | 177 ++ .../osc/model_update_access_key_response.go | 152 ++ .../osc/model_update_account_request.go | 561 ++++++ .../osc/model_update_account_response.go | 152 ++ .../osc/model_update_flexible_gpu_request.go | 184 ++ .../osc/model_update_flexible_gpu_response.go | 152 ++ .../osc/model_update_image_request.go | 176 ++ .../osc/model_update_image_response.go | 152 ++ .../osc/model_update_listener_rule_request.go | 221 +++ .../model_update_listener_rule_response.go | 152 ++ .../osc/model_update_load_balancer_request.go | 330 ++++ .../model_update_load_balancer_response.go | 152 ++ .../model_update_net_access_point_request.go | 221 +++ .../model_update_net_access_point_response.go | 152 ++ .../osc/model_update_net_request.go | 177 ++ .../osc/model_update_net_response.go | 152 ++ .../osc/model_update_nic_request.go | 257 +++ .../osc/model_update_nic_response.go | 152 ++ .../model_update_route_propagation_request.go | 207 +++ ...model_update_route_propagation_response.go | 152 ++ .../osc/model_update_route_request.go | 362 ++++ .../osc/model_update_route_response.go | 152 ++ ...model_update_server_certificate_request.go | 228 +++ ...odel_update_server_certificate_response.go | 152 ++ .../osc/model_update_snapshot_request.go | 176 ++ .../osc/model_update_snapshot_response.go | 152 ++ .../osc/model_update_subnet_request.go | 177 ++ .../osc/model_update_subnet_response.go | 152 ++ .../osc-sdk-go/osc/model_update_vm_request.go | 517 ++++++ .../osc/model_update_vm_response.go | 152 ++ .../osc-sdk-go/osc/model_virtual_gateway.go | 265 +++ .../outscale/osc-sdk-go/osc/model_vm.go | 1263 +++++++++++++ .../outscale/osc-sdk-go/osc/model_vm_state.go | 191 ++ .../osc-sdk-go/osc/model_vm_states.go | 228 +++ .../outscale/osc-sdk-go/osc/model_vm_type.go | 339 ++++ .../outscale/osc-sdk-go/osc/model_volume.go | 413 +++++ .../osc-sdk-go/osc/model_vpn_connection.go | 413 +++++ .../outscale/osc-sdk-go/osc/model_with.go | 672 +++++++ .../outscale/osc-sdk-go/osc/response.go | 48 + .../outscale/osc-sdk-go/osc/utils.go | 336 ++++ vendor/modules.txt | 4 +- 524 files changed, 118136 insertions(+), 130 deletions(-) create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/.gitignore create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/README.md create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_account.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_image.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_location.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_net.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_region.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_route.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_task.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/client.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/configuration.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/go.mod create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/go.sum create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_account.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_image.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_location.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_log.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_net.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_region.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_route.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_service.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/model_with.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/response.go create mode 100644 vendor/github.com/outscale/osc-sdk-go/osc/utils.go diff --git a/go.mod b/go.mod index 0d3b804e2..a4fdf47d8 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.12 require ( github.com/antihax/optional v1.0.0 - github.com/aws/aws-sdk-go v1.31.10 + github.com/aws/aws-sdk-go v1.34.14 github.com/davecgh/go-spew v1.1.1 github.com/go-test/deep v1.0.6 github.com/hashicorp/errwrap v1.0.0 @@ -12,5 +12,6 @@ require ( github.com/hashicorp/terraform-plugin-sdk v1.13.1 github.com/marinsalinas/osc-sdk-go v0.0.0-20200616160510-b775d5bdde1a github.com/openlyinc/pointy v1.1.2 + github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c github.com/spf13/cast v1.3.1 ) diff --git a/go.sum b/go.sum index 87b66fc83..f485a8b0f 100644 --- a/go.sum +++ b/go.sum @@ -59,9 +59,12 @@ github.com/armon/go-radix v1.0.0 h1:F4z6KzEeeQIMeLFa97iZU6vupzoecKdU5TX24SNppXI= github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aws/aws-sdk-go v1.15.78/go.mod h1:E3/ieXAlvM0XWO57iftYVDLLvQ824smPP3ATZkfNZeM= github.com/aws/aws-sdk-go v1.25.3/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= +github.com/aws/aws-sdk-go v1.26.3/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.30.12/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/aws/aws-sdk-go v1.31.10 h1:33jOMifUSdOP9pvNEOj+PGwljzunc8bJvKKNF/JuGzo= github.com/aws/aws-sdk-go v1.31.10/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= +github.com/aws/aws-sdk-go v1.34.14 h1:G0jUdSDSp63P0oo/N3c/ldo7s8mYW3Kh/GPIJ+oESVQ= +github.com/aws/aws-sdk-go v1.34.14/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/baiyubin/aliyun-sts-go-sdk v0.0.0-20180326062324-cfa1a18b161f/go.mod h1:AuiFmCCPBSrqvVMvuqFuk0qogytodnVFVSN5CeJB8Gc= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= @@ -293,6 +296,13 @@ github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/openlyinc/pointy v1.1.2 h1:LywVV2BWC5Sp5v7FoP4bUD+2Yn5k0VNeRbU5vq9jUMY= github.com/openlyinc/pointy v1.1.2/go.mod h1:w2Sytx+0FVuMKn37xpXIAyBNhFNBIJGR/v2m7ik1WtM= +github.com/outscale/osc-sdk-go v1.3.0 h1:M3moUrGrwsK5XYk82zhWuypRKwnpBwzuX89YMIzx/IA= +github.com/outscale/osc-sdk-go v1.3.1-0.20201014193009-10509d4e084c h1:+20TjLxqtIVO18OPrpHh6sniXshSxJJntiRYdnmiK2g= +github.com/outscale/osc-sdk-go v1.3.1-0.20201014193009-10509d4e084c/go.mod h1:R2qnfXaSxnGSNgyCQ6VRV3sqFPjkjupMDOiKbqs5cAI= +github.com/outscale/osc-sdk-go/osc v0.0.0-20200902152503-f3b2a0227815 h1:iW3PlDOm545CGaMkZv5s1k6r5/j3JTll/FCLjasVPko= +github.com/outscale/osc-sdk-go/osc v0.0.0-20200902152503-f3b2a0227815/go.mod h1:5AqqNH1X8zCHescKVlpSHRzrat1KCKDXqZoQPe8fY3A= +github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c h1:/XVdGvgImVYxABbV4BttnO02tA45jpVXT/A5TWDRBuk= +github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c/go.mod h1:bq0k5osdMFbx7TKlbTFCSFwudIDJqp5VYf4hD1iQCl0= github.com/packer-community/winrmcp v0.0.0-20180102160824-81144009af58/go.mod h1:f6Izs6JvFTdnRbziASagjZ2vmf55NSIkC/weStxCHqk= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= diff --git a/vendor/github.com/aws/aws-sdk-go/aws/config.go b/vendor/github.com/aws/aws-sdk-go/aws/config.go index 2def23fa1..3b809e847 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/config.go @@ -43,7 +43,7 @@ type Config struct { // An optional endpoint URL (hostname only or fully qualified URI) // that overrides the default generated endpoint for a client. Set this - // to `""` to use the default generated endpoint. + // to `nil` or the value to `""` to use the default generated endpoint. // // Note: You must still provide a `Region` value when specifying an // endpoint for a client. @@ -138,7 +138,7 @@ type Config struct { // `ExpectContinueTimeout` for information on adjusting the continue wait // timeout. https://golang.org/pkg/net/http/#Transport // - // You should use this flag to disble 100-Continue if you experience issues + // You should use this flag to disable 100-Continue if you experience issues // with proxies or third party S3 compatible services. S3Disable100Continue *bool @@ -183,7 +183,7 @@ type Config struct { // // Example: // sess := session.Must(session.NewSession(aws.NewConfig() - // .WithEC2MetadataDiableTimeoutOverride(true))) + // .WithEC2MetadataDisableTimeoutOverride(true))) // // svc := s3.New(sess) // @@ -194,7 +194,7 @@ type Config struct { // both IPv4 and IPv6 addressing. // // Setting this for a service which does not support dual stack will fail - // to make requets. It is not recommended to set this value on the session + // to make requests. It is not recommended to set this value on the session // as it will apply to all service clients created with the session. Even // services which don't support dual stack endpoints. // @@ -238,6 +238,7 @@ type Config struct { // EnableEndpointDiscovery will allow for endpoint discovery on operations that // have the definition in its model. By default, endpoint discovery is off. + // To use EndpointDiscovery, Endpoint should be unset or set to an empty string. // // Example: // sess := session.Must(session.NewSession(&aws.Config{ diff --git a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go index aa902d708..d95a5eb54 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go @@ -225,6 +225,8 @@ var ValidateEndpointHandler = request.NamedHandler{Name: "core.ValidateEndpointH if r.ClientInfo.SigningRegion == "" && aws.StringValue(r.Config.Region) == "" { r.Error = aws.ErrMissingRegion } else if r.ClientInfo.Endpoint == "" { + // Was any endpoint provided by the user, or one was derived by the + // SDK's endpoint resolver? r.Error = aws.ErrMissingEndpoint } }} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go index e15514958..22b5c5d9f 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/shared_credentials_provider.go @@ -17,8 +17,9 @@ var ( ErrSharedCredentialsHomeNotFound = awserr.New("UserHomeNotFound", "user home directory not found.", nil) ) -// A SharedCredentialsProvider retrieves credentials from the current user's home -// directory, and keeps track if those credentials are expired. +// A SharedCredentialsProvider retrieves access key pair (access key ID, +// secret access key, and session token if present) credentials from the current +// user's home directory, and keeps track if those credentials are expired. // // Profile ini file example: $HOME/.aws/credentials type SharedCredentialsProvider struct { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go index 6feb262b2..cefe2a76d 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/credentials/stscreds/web_identity_provider.go @@ -52,9 +52,21 @@ type WebIdentityRoleProvider struct { credentials.Expiry PolicyArns []*sts.PolicyDescriptorType - client stsiface.STSAPI + // Duration the STS credentials will be valid for. Truncated to seconds. + // If unset, the assumed role will use AssumeRoleWithWebIdentity's default + // expiry duration. See + // https://docs.aws.amazon.com/sdk-for-go/api/service/sts/#STS.AssumeRoleWithWebIdentity + // for more information. + Duration time.Duration + + // The amount of time the credentials will be refreshed before they expire. + // This is useful refresh credentials before they expire to reduce risk of + // using credentials as they expire. If unset, will default to no expiry + // window. ExpiryWindow time.Duration + client stsiface.STSAPI + tokenFetcher TokenFetcher roleARN string roleSessionName string @@ -107,11 +119,18 @@ func (p *WebIdentityRoleProvider) RetrieveWithContext(ctx credentials.Context) ( // uses unix time in nanoseconds to uniquely identify sessions. sessionName = strconv.FormatInt(now().UnixNano(), 10) } + + var duration *int64 + if p.Duration != 0 { + duration = aws.Int64(int64(p.Duration / time.Second)) + } + req, resp := p.client.AssumeRoleWithWebIdentityRequest(&sts.AssumeRoleWithWebIdentityInput{ PolicyArns: p.PolicyArns, RoleArn: &p.roleARN, RoleSessionName: &sessionName, WebIdentityToken: aws.String(string(b)), + DurationSeconds: duration, }) req.SetContext(ctx) diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go index a716c021c..69fa63dc0 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go @@ -20,7 +20,7 @@ func (c *EC2Metadata) getToken(ctx aws.Context, duration time.Duration) (tokenOu op := &request.Operation{ Name: "GetToken", HTTPMethod: "PUT", - HTTPPath: "/api/token", + HTTPPath: "/latest/api/token", } var output tokenOutput @@ -62,7 +62,7 @@ func (c *EC2Metadata) GetMetadataWithContext(ctx aws.Context, p string) (string, op := &request.Operation{ Name: "GetMetadata", HTTPMethod: "GET", - HTTPPath: sdkuri.PathJoin("/meta-data", p), + HTTPPath: sdkuri.PathJoin("/latest/meta-data", p), } output := &metadataOutput{} @@ -88,7 +88,7 @@ func (c *EC2Metadata) GetUserDataWithContext(ctx aws.Context) (string, error) { op := &request.Operation{ Name: "GetUserData", HTTPMethod: "GET", - HTTPPath: "/user-data", + HTTPPath: "/latest/user-data", } output := &metadataOutput{} @@ -113,7 +113,7 @@ func (c *EC2Metadata) GetDynamicDataWithContext(ctx aws.Context, p string) (stri op := &request.Operation{ Name: "GetDynamicData", HTTPMethod: "GET", - HTTPPath: sdkuri.PathJoin("/dynamic", p), + HTTPPath: sdkuri.PathJoin("/latest/dynamic", p), } output := &metadataOutput{} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go index b8b2940d7..8f35b3464 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go @@ -5,6 +5,10 @@ // variable "AWS_EC2_METADATA_DISABLED=true". This environment variable set to // true instructs the SDK to disable the EC2 Metadata client. The client cannot // be used while the environment variable is set to true, (case insensitive). +// +// The endpoint of the EC2 IMDS client can be configured via the environment +// variable, AWS_EC2_METADATA_SERVICE_ENDPOINT when creating the client with a +// Session. See aws/session#Options.EC2IMDSEndpoint for more details. package ec2metadata import ( @@ -12,6 +16,7 @@ import ( "errors" "io" "net/http" + "net/url" "os" "strconv" "strings" @@ -41,7 +46,7 @@ const ( enableTokenProviderHandlerName = "enableTokenProviderHandler" // TTL constants - defaultTTL = 21600 * time.Second + defaultTTL = 21600 * time.Second ttlExpirationWindow = 30 * time.Second ) @@ -69,6 +74,9 @@ func New(p client.ConfigProvider, cfgs ...*aws.Config) *EC2Metadata { // a client when not using a session. Generally using just New with a session // is preferred. // +// Will remove the URL path from the endpoint provided to ensure the EC2 IMDS +// client is able to communicate with the EC2 IMDS API. +// // If an unmodified HTTP client is provided from the stdlib default, or no client // the EC2RoleProvider's EC2Metadata HTTP client's timeout will be shortened. // To disable this set Config.EC2MetadataDisableTimeoutOverride to false. Enabled by default. @@ -86,6 +94,15 @@ func NewClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegio cfg.MaxRetries = aws.Int(2) } + if u, err := url.Parse(endpoint); err == nil { + // Remove path from the endpoint since it will be added by requests. + // This is an artifact of the SDK adding `/latest` to the endpoint for + // EC2 IMDS, but this is now moved to the operation definition. + u.Path = "" + u.RawPath = "" + endpoint = u.String() + } + svc := &EC2Metadata{ Client: client.New( cfg, diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go index 34d3702e2..a496df484 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go @@ -194,12 +194,42 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "me-south-1": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips-ca-central-1": endpoint{ + Hostname: "access-analyzer-fips.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "fips-us-east-1": endpoint{ + Hostname: "access-analyzer-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "access-analyzer-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-1": endpoint{ + Hostname: "access-analyzer-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "access-analyzer-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "acm": service{ @@ -262,6 +292,7 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -271,6 +302,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -422,6 +454,30 @@ var awsPartition = partition{ Region: "eu-west-3", }, }, + "fips-dkr-us-east-1": endpoint{ + Hostname: "ecr-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-dkr-us-east-2": endpoint{ + Hostname: "ecr-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-dkr-us-west-1": endpoint{ + Hostname: "ecr-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-dkr-us-west-2": endpoint{ + Hostname: "ecr-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, "fips-us-east-1": endpoint{ Hostname: "ecr-fips.us-east-1.amazonaws.com", CredentialScope: credentialScope{ @@ -602,6 +658,26 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "appflow": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "application-autoscaling": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -662,6 +738,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -684,11 +761,17 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -802,6 +885,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -892,6 +976,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1002,6 +1087,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -1011,6 +1097,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1086,6 +1173,21 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "codeartifact": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "codebuild": service{ Endpoints: endpoints{ @@ -1538,6 +1640,7 @@ var awsPartition = partition{ "datasync": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -1547,6 +1650,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1667,6 +1771,8 @@ var awsPartition = partition{ "ap-northeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-west-2": endpoint{}, }, @@ -1788,6 +1894,7 @@ var awsPartition = partition{ "ds": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -1797,6 +1904,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2024,6 +2132,7 @@ var awsPartition = partition{ Protocols: []string{"http", "https"}, }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -2033,6 +2142,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2516,6 +2626,7 @@ var awsPartition = partition{ "firehose": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -2525,6 +2636,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2565,6 +2677,7 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ + "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, @@ -2666,11 +2779,12 @@ var awsPartition = partition{ Region: "us-west-2", }, }, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "forecast": service{ @@ -2712,10 +2826,13 @@ var awsPartition = partition{ "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -2870,9 +2987,21 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, - "me-south-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "fips-us-east-2": endpoint{ + Hostname: "groundstation-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "groundstation-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "me-south-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, }, }, "guardduty": service{ @@ -2881,6 +3010,7 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -2890,6 +3020,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2931,6 +3062,12 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, + "honeycode": service{ + + Endpoints: endpoints{ + "us-west-2": endpoint{}, + }, + }, "iam": service{ PartitionEndpoint: "aws-global", IsRegionalized: boxedFalse, @@ -2950,6 +3087,21 @@ var awsPartition = partition{ }, }, }, + "identitystore": service{ + + Endpoints: endpoints{ + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "importexport": service{ PartitionEndpoint: "aws-global", IsRegionalized: boxedFalse, @@ -3037,6 +3189,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, @@ -3174,6 +3327,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3374,6 +3528,7 @@ var awsPartition = partition{ "license-manager": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -3383,6 +3538,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -3453,12 +3609,36 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "me-south-1": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips-us-east-1": endpoint{ + Hostname: "logs-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "logs-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-1": endpoint{ + Hostname: "logs-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "logs-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "machinelearning": service{ @@ -3487,6 +3667,52 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "macie2": service{ + + Endpoints: endpoints{ + "ap-east-1": endpoint{}, + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "fips-us-east-1": endpoint{ + Hostname: "macie2-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "macie2-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-1": endpoint{ + Hostname: "macie2-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "macie2-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "managedblockchain": service{ Endpoints: endpoints{ @@ -3588,10 +3814,28 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-2": endpoint{}, + "fips-us-east-1": endpoint{ + Hostname: "medialive-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "medialive-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "medialive-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, }, }, "mediapackage": service{ @@ -3662,6 +3906,8 @@ var awsPartition = partition{ "ap-northeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-west-2": endpoint{}, }, @@ -3679,6 +3925,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -3799,6 +4046,12 @@ var awsPartition = partition{ "neptune": service{ Endpoints: endpoints{ + "ap-east-1": endpoint{ + Hostname: "rds.ap-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-east-1", + }, + }, "ap-northeast-1": endpoint{ Hostname: "rds.ap-northeast-1.amazonaws.com", CredentialScope: credentialScope{ @@ -3871,6 +4124,12 @@ var awsPartition = partition{ Region: "me-south-1", }, }, + "sa-east-1": endpoint{ + Hostname: "rds.sa-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "sa-east-1", + }, + }, "us-east-1": endpoint{ Hostname: "rds.us-east-1.amazonaws.com", CredentialScope: credentialScope{ @@ -3883,6 +4142,12 @@ var awsPartition = partition{ Region: "us-east-2", }, }, + "us-west-1": endpoint{ + Hostname: "rds.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, "us-west-2": endpoint{ Hostname: "rds.us-west-2.amazonaws.com", CredentialScope: credentialScope{ @@ -3918,6 +4183,12 @@ var awsPartition = partition{ Region: "eu-central-1", }, }, + "eu-north-1": endpoint{ + Hostname: "oidc.eu-north-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-north-1", + }, + }, "eu-west-1": endpoint{ Hostname: "oidc.eu-west-1.amazonaws.com", CredentialScope: credentialScope{ @@ -4006,14 +4277,17 @@ var awsPartition = partition{ "outposts": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -4048,6 +4322,7 @@ var awsPartition = partition{ }, }, "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -4061,6 +4336,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -4226,6 +4502,7 @@ var awsPartition = partition{ "ram": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -4235,6 +4512,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -4369,10 +4647,34 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "rekognition-fips.us-east-1": endpoint{ + Hostname: "rekognition-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "rekognition-fips.us-east-2": endpoint{ + Hostname: "rekognition-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "rekognition-fips.us-west-1": endpoint{ + Hostname: "rekognition-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "rekognition-fips.us-west-2": endpoint{ + Hostname: "rekognition-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "resource-groups": service{ @@ -4460,6 +4762,7 @@ var awsPartition = partition{ Protocols: []string{"https"}, }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -4469,6 +4772,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -4487,6 +4791,7 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -4884,12 +5189,36 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "me-south-1": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips-us-east-1": endpoint{ + Hostname: "securityhub-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "securityhub-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-1": endpoint{ + Hostname: "securityhub-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "securityhub-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "serverlessrepo": service{ @@ -4956,6 +5285,7 @@ var awsPartition = partition{ "servicecatalog": service{ Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -4965,6 +5295,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -5000,9 +5331,35 @@ var awsPartition = partition{ }, }, }, - "servicediscovery": service{ - + "servicediscovery": service{ + + Endpoints: endpoints{ + "ap-east-1": endpoint{}, + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "servicequotas": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, Endpoints: endpoints{ + "af-south-1": endpoint{}, "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, @@ -5012,6 +5369,7 @@ var awsPartition = partition{ "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-north-1": endpoint{}, + "eu-south-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -5462,12 +5820,18 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "me-south-1": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips": endpoint{ + Hostname: "storagegateway-fips.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "me-south-1": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "streams.dynamodb": service{ @@ -5749,11 +6113,41 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips-ca-central-1": endpoint{ + Hostname: "transfer-fips.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "fips-us-east-1": endpoint{ + Hostname: "transfer-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "fips-us-east-2": endpoint{ + Hostname: "transfer-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "fips-us-west-1": endpoint{ + Hostname: "transfer-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "fips-us-west-2": endpoint{ + Hostname: "transfer-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "translate": service{ @@ -6143,6 +6537,13 @@ var awscnPartition = partition{ }, }, Services: services{ + "access-analyzer": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "acm": service{ Endpoints: endpoints{ @@ -6212,6 +6613,15 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "autoscaling-plans": service{ + Defaults: endpoint{ + Protocols: []string{"http", "https"}, + }, + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "backup": service{ Endpoints: endpoints{ @@ -6226,6 +6636,32 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "budgets": service{ + PartitionEndpoint: "aws-cn-global", + IsRegionalized: boxedFalse, + + Endpoints: endpoints{ + "aws-cn-global": endpoint{ + Hostname: "budgets.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + }, + }, + "ce": service{ + PartitionEndpoint: "aws-cn-global", + IsRegionalized: boxedFalse, + + Endpoints: endpoints{ + "aws-cn-global": endpoint{ + Hostname: "ce.cn-northwest-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + }, + }, "cloudformation": service{ Endpoints: endpoints{ @@ -6288,6 +6724,12 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "cur": service{ + + Endpoints: endpoints{ + "cn-northwest-1": endpoint{}, + }, + }, "dax": service{ Endpoints: endpoints{ @@ -6515,6 +6957,13 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "kinesisanalytics": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "kms": service{ Endpoints: endpoints{ @@ -6574,6 +7023,25 @@ var awscnPartition = partition{ }, }, }, + "organizations": service{ + PartitionEndpoint: "aws-cn-global", + IsRegionalized: boxedFalse, + + Endpoints: endpoints{ + "aws-cn-global": endpoint{ + Hostname: "organizations.cn-northwest-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + "fips-aws-cn-global": endpoint{ + Hostname: "organizations.cn-northwest-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + }, + }, "polly": service{ Endpoints: endpoints{ @@ -6682,13 +7150,20 @@ var awscnPartition = partition{ "snowball": service{ Endpoints: endpoints{ - "cn-north-1": endpoint{}, + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, "fips-cn-north-1": endpoint{ Hostname: "snowball-fips.cn-north-1.amazonaws.com.cn", CredentialScope: credentialScope{ Region: "cn-north-1", }, }, + "fips-cn-northwest-1": endpoint{ + Hostname: "snowball-fips.cn-northwest-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, }, }, "sns": service{ @@ -6843,8 +7318,18 @@ var awsusgovPartition = partition{ "access-analyzer": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, + "us-gov-east-1": endpoint{ + Hostname: "access-analyzer.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "us-gov-west-1": endpoint{ + Hostname: "access-analyzer.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, }, }, "acm": service{ @@ -6878,6 +7363,18 @@ var awsusgovPartition = partition{ "api.ecr": service{ Endpoints: endpoints{ + "fips-dkr-us-gov-east-1": endpoint{ + Hostname: "ecr-fips.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "fips-dkr-us-gov-west-1": endpoint{ + Hostname: "ecr-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, "fips-us-gov-east-1": endpoint{ Hostname: "ecr-fips.us-gov-east-1.amazonaws.com", CredentialScope: credentialScope{ @@ -6908,6 +7405,18 @@ var awsusgovPartition = partition{ Endpoints: endpoints{ "us-gov-west-1": endpoint{}, + "us-gov-west-1-fips": endpoint{ + Hostname: "api-fips.sagemaker.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + "us-gov-west-1-fips-secondary": endpoint{ + Hostname: "api.sagemaker.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, }, }, "apigateway": service{ @@ -6986,6 +7495,13 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, + "backup": service{ + + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, "batch": service{ Endpoints: endpoints{ @@ -7160,6 +7676,12 @@ var awsusgovPartition = partition{ "comprehendmedical": service{ Endpoints: endpoints{ + "fips-us-gov-west-1": endpoint{ + Hostname: "comprehendmedical-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, "us-gov-west-1": endpoint{}, }, }, @@ -7219,6 +7741,17 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, + "docdb": service{ + + Endpoints: endpoints{ + "us-gov-west-1": endpoint{ + Hostname: "rds.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + }, + }, "ds": service{ Endpoints: endpoints{ @@ -7317,7 +7850,7 @@ var awsusgovPartition = partition{ Endpoints: endpoints{ "fips": endpoint{ - Hostname: "elasticache-fips.us-gov-west-1.amazonaws.com", + Hostname: "elasticache.us-gov-west-1.amazonaws.com", CredentialScope: credentialScope{ Region: "us-gov-west-1", }, @@ -7366,13 +7899,13 @@ var awsusgovPartition = partition{ Endpoints: endpoints{ "fips-us-gov-east-1": endpoint{ - Hostname: "elasticloadbalancing-fips.us-gov-east-1.amazonaws.com", + Hostname: "elasticloadbalancing.us-gov-east-1.amazonaws.com", CredentialScope: credentialScope{ Region: "us-gov-east-1", }, }, "fips-us-gov-west-1": endpoint{ - Hostname: "elasticloadbalancing-fips.us-gov-west-1.amazonaws.com", + Hostname: "elasticloadbalancing.us-gov-west-1.amazonaws.com", CredentialScope: credentialScope{ Region: "us-gov-west-1", }, @@ -7582,12 +8115,14 @@ var awsusgovPartition = partition{ }, }, Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "iotsecuredtunneling": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -7617,6 +8152,13 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, + "kinesisanalytics": service{ + + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, "kms": service{ Endpoints: endpoints{ @@ -7671,8 +8213,18 @@ var awsusgovPartition = partition{ "logs": service{ Endpoints: endpoints{ - "us-gov-east-1": endpoint{}, - "us-gov-west-1": endpoint{}, + "us-gov-east-1": endpoint{ + Hostname: "logs.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "us-gov-west-1": endpoint{ + Hostname: "logs.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, }, }, "mediaconvert": service{ @@ -7837,6 +8389,12 @@ var awsusgovPartition = partition{ "rekognition": service{ Endpoints: endpoints{ + "rekognition-fips.us-gov-west-1": endpoint{ + Hostname: "rekognition-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, "us-gov-west-1": endpoint{}, }, }, @@ -7970,6 +8528,18 @@ var awsusgovPartition = partition{ "securityhub": service{ Endpoints: endpoints{ + "fips-us-gov-east-1": endpoint{ + Hostname: "securityhub-fips.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "fips-us-gov-west-1": endpoint{ + Hostname: "securityhub-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, @@ -8666,6 +9236,20 @@ var awsisoPartition = partition{ "us-iso-east-1": endpoint{}, }, }, + "transcribe": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "us-iso-east-1": endpoint{}, + }, + }, + "transcribestreaming": service{ + + Endpoints: endpoints{ + "us-iso-east-1": endpoint{}, + }, + }, "workspaces": service{ Endpoints: endpoints{ @@ -8849,6 +9433,12 @@ var awsisobPartition = partition{ "us-isob-east-1": endpoint{}, }, }, + "lambda": service{ + + Endpoints: endpoints{ + "us-isob-east-1": endpoint{}, + }, + }, "license-manager": service{ Endpoints: endpoints{ diff --git a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go index eb2ac83c9..773613722 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model.go @@ -7,6 +7,8 @@ import ( "strings" ) +var regionValidationRegex = regexp.MustCompile(`^[[:alnum:]]([[:alnum:]\-]*[[:alnum:]])?$`) + type partitions []partition func (ps partitions) EndpointFor(service, region string, opts ...func(*Options)) (ResolvedEndpoint, error) { @@ -124,7 +126,7 @@ func (p partition) EndpointFor(service, region string, opts ...func(*Options)) ( defs := []endpoint{p.Defaults, s.Defaults} - return e.resolve(service, p.ID, region, p.DNSSuffix, defs, opt), nil + return e.resolve(service, p.ID, region, p.DNSSuffix, defs, opt) } func serviceList(ss services) []string { @@ -233,7 +235,7 @@ func getByPriority(s []string, p []string, def string) string { return s[0] } -func (e endpoint) resolve(service, partitionID, region, dnsSuffix string, defs []endpoint, opts Options) ResolvedEndpoint { +func (e endpoint) resolve(service, partitionID, region, dnsSuffix string, defs []endpoint, opts Options) (ResolvedEndpoint, error) { var merged endpoint for _, def := range defs { merged.mergeIn(def) @@ -260,6 +262,10 @@ func (e endpoint) resolve(service, partitionID, region, dnsSuffix string, defs [ region = signingRegion } + if !validateInputRegion(region) { + return ResolvedEndpoint{}, fmt.Errorf("invalid region identifier format provided") + } + u := strings.Replace(hostname, "{service}", service, 1) u = strings.Replace(u, "{region}", region, 1) u = strings.Replace(u, "{dnsSuffix}", dnsSuffix, 1) @@ -274,7 +280,7 @@ func (e endpoint) resolve(service, partitionID, region, dnsSuffix string, defs [ SigningName: signingName, SigningNameDerived: signingNameDerived, SigningMethod: getByPriority(e.SignatureVersions, signerPriority, defaultSigner), - } + }, nil } func getEndpointScheme(protocols []string, disableSSL bool) string { @@ -339,3 +345,7 @@ const ( boxedFalse boxedTrue ) + +func validateInputRegion(region string) bool { + return regionValidationRegex.MatchString(region) +} diff --git a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go index d9b37f4d3..2ba3c56c1 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/request/connection_reset_error.go @@ -9,7 +9,8 @@ func isErrConnectionReset(err error) bool { return false } - if strings.Contains(err.Error(), "connection reset") || + if strings.Contains(err.Error(), "use of closed network connection") || + strings.Contains(err.Error(), "connection reset") || strings.Contains(err.Error(), "broken pipe") { return true } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go b/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go index 7ec66e7e5..cc461bd32 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go @@ -241,5 +241,22 @@ over the AWS_CA_BUNDLE environment variable, and will be used if both are set. Setting a custom HTTPClient in the aws.Config options will override this setting. To use this option and custom HTTP client, the HTTP client needs to be provided when creating the session. Not the service client. + +The endpoint of the EC2 IMDS client can be configured via the environment +variable, AWS_EC2_METADATA_SERVICE_ENDPOINT when creating the client with a +Session. See Options.EC2IMDSEndpoint for more details. + + AWS_EC2_METADATA_SERVICE_ENDPOINT=http://169.254.169.254 + +If using an URL with an IPv6 address literal, the IPv6 address +component must be enclosed in square brackets. + + AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1] + +The custom EC2 IMDS endpoint can also be specified via the Session options. + + sess, err := session.NewSessionWithOptions(session.Options{ + EC2IMDSEndpoint: "http://[::1]", + }) */ package session diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go index c1e0e9c95..d67c261d7 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go @@ -148,6 +148,11 @@ type envConfig struct { // // AWS_S3_USE_ARN_REGION=true S3UseARNRegion bool + + // Specifies the alternative endpoint to use for EC2 IMDS. + // + // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1] + EC2IMDSEndpoint string } var ( @@ -211,6 +216,9 @@ var ( s3UseARNRegionEnvKey = []string{ "AWS_S3_USE_ARN_REGION", } + ec2IMDSEndpointEnvKey = []string{ + "AWS_EC2_METADATA_SERVICE_ENDPOINT", + } ) // loadEnvConfig retrieves the SDK's environment configuration. @@ -332,6 +340,8 @@ func envConfigLoad(enableSharedConfig bool) (envConfig, error) { } } + setFromEnvVal(&cfg.EC2IMDSEndpoint, ec2IMDSEndpointEnvKey) + return cfg, nil } diff --git a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go index 0ff499605..6430a7f15 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/session/session.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/session/session.go @@ -48,6 +48,8 @@ var ErrSharedConfigInvalidCredSource = awserr.New(ErrCodeSharedConfig, "credenti type Session struct { Config *aws.Config Handlers request.Handlers + + options Options } // New creates a new instance of the handlers merging in the provided configs @@ -99,7 +101,7 @@ func New(cfgs ...*aws.Config) *Session { return s } - s := deprecatedNewSession(cfgs...) + s := deprecatedNewSession(envCfg, cfgs...) if envErr != nil { msg := "failed to load env config" s.logDeprecatedNewSessionError(msg, envErr, cfgs) @@ -243,6 +245,23 @@ type Options struct { // function to initialize this value before changing the handlers to be // used by the SDK. Handlers request.Handlers + + // Allows specifying a custom endpoint to be used by the EC2 IMDS client + // when making requests to the EC2 IMDS API. The must endpoint value must + // include protocol prefix. + // + // If unset, will the EC2 IMDS client will use its default endpoint. + // + // Can also be specified via the environment variable, + // AWS_EC2_METADATA_SERVICE_ENDPOINT. + // + // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://169.254.169.254 + // + // If using an URL with an IPv6 address literal, the IPv6 address + // component must be enclosed in square brackets. + // + // AWS_EC2_METADATA_SERVICE_ENDPOINT=http://[::1] + EC2IMDSEndpoint string } // NewSessionWithOptions returns a new Session created from SDK defaults, config files, @@ -329,7 +348,25 @@ func Must(sess *Session, err error) *Session { return sess } -func deprecatedNewSession(cfgs ...*aws.Config) *Session { +// Wraps the endpoint resolver with a resolver that will return a custom +// endpoint for EC2 IMDS. +func wrapEC2IMDSEndpoint(resolver endpoints.Resolver, endpoint string) endpoints.Resolver { + return endpoints.ResolverFunc( + func(service, region string, opts ...func(*endpoints.Options)) ( + endpoints.ResolvedEndpoint, error, + ) { + if service == ec2MetadataServiceID { + return endpoints.ResolvedEndpoint{ + URL: endpoint, + SigningName: ec2MetadataServiceID, + SigningRegion: region, + }, nil + } + return resolver.EndpointFor(service, region) + }) +} + +func deprecatedNewSession(envCfg envConfig, cfgs ...*aws.Config) *Session { cfg := defaults.Config() handlers := defaults.Handlers() @@ -341,6 +378,11 @@ func deprecatedNewSession(cfgs ...*aws.Config) *Session { // endpoints for service client configurations. cfg.EndpointResolver = endpoints.DefaultResolver() } + + if len(envCfg.EC2IMDSEndpoint) != 0 { + cfg.EndpointResolver = wrapEC2IMDSEndpoint(cfg.EndpointResolver, envCfg.EC2IMDSEndpoint) + } + cfg.Credentials = defaults.CredChain(cfg, handlers) // Reapply any passed in configs to override credentials if set @@ -349,6 +391,9 @@ func deprecatedNewSession(cfgs ...*aws.Config) *Session { s := &Session{ Config: cfg, Handlers: handlers, + options: Options{ + EC2IMDSEndpoint: envCfg.EC2IMDSEndpoint, + }, } initHandlers(s) @@ -418,6 +463,7 @@ func newSession(opts Options, envCfg envConfig, cfgs ...*aws.Config) (*Session, s := &Session{ Config: cfg, Handlers: handlers, + options: opts, } initHandlers(s) @@ -570,6 +616,14 @@ func mergeConfigSrcs(cfg, userCfg *aws.Config, endpoints.LegacyS3UsEast1Endpoint, }) + ec2IMDSEndpoint := sessOpts.EC2IMDSEndpoint + if len(ec2IMDSEndpoint) == 0 { + ec2IMDSEndpoint = envCfg.EC2IMDSEndpoint + } + if len(ec2IMDSEndpoint) != 0 { + cfg.EndpointResolver = wrapEC2IMDSEndpoint(cfg.EndpointResolver, ec2IMDSEndpoint) + } + // Configure credentials if not already set by the user when creating the // Session. if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil { @@ -627,6 +681,7 @@ func (s *Session) Copy(cfgs ...*aws.Config) *Session { newSession := &Session{ Config: s.Config.Copy(cfgs...), Handlers: s.Handlers.Copy(), + options: s.options, } initHandlers(newSession) @@ -665,6 +720,8 @@ func (s *Session) ClientConfig(service string, cfgs ...*aws.Config) client.Confi } } +const ec2MetadataServiceID = "ec2metadata" + func (s *Session) resolveEndpoint(service, region string, cfg *aws.Config) (endpoints.ResolvedEndpoint, error) { if ep := aws.StringValue(cfg.Endpoint); len(ep) != 0 { diff --git a/vendor/github.com/aws/aws-sdk-go/aws/version.go b/vendor/github.com/aws/aws-sdk-go/aws/version.go index f1b9ec4db..1d19f8ad3 100644 --- a/vendor/github.com/aws/aws-sdk-go/aws/version.go +++ b/vendor/github.com/aws/aws-sdk-go/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.31.10" +const SDKVersion = "1.34.14" diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/eventstreamapi/reader.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/eventstreamapi/reader.go index bb8ea5da1..0e4aa42f3 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/eventstreamapi/reader.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/eventstreamapi/reader.go @@ -69,10 +69,23 @@ func (r *EventReader) ReadEvent() (event interface{}, err error) { case ErrorMessageType: return nil, r.unmarshalErrorMessage(msg) default: - return nil, fmt.Errorf("unknown eventstream message type, %v", typ) + return nil, &UnknownMessageTypeError{ + Type: typ, Message: msg.Clone(), + } } } +// UnknownMessageTypeError provides an error when a message is received from +// the stream, but the reader is unable to determine what kind of message it is. +type UnknownMessageTypeError struct { + Type string + Message eventstream.Message +} + +func (e *UnknownMessageTypeError) Error() string { + return "unknown eventstream message type, " + e.Type +} + func (r *EventReader) unmarshalEventMessage( msg eventstream.Message, ) (event interface{}, err error) { diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/header.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/header.go index 3b44dde2f..f6f8c5674 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/header.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/header.go @@ -52,6 +52,15 @@ func (hs *Headers) Del(name string) { } } +// Clone returns a deep copy of the headers +func (hs Headers) Clone() Headers { + o := make(Headers, 0, len(hs)) + for _, h := range hs { + o.Set(h.Name, h.Value) + } + return o +} + func decodeHeaders(r io.Reader) (Headers, error) { hs := Headers{} diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/message.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/message.go index 25c9783cd..f7427da03 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/message.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/eventstream/message.go @@ -57,6 +57,20 @@ func (m *Message) rawMessage() (rawMessage, error) { return raw, nil } +// Clone returns a deep copy of the message. +func (m Message) Clone() Message { + var payload []byte + if m.Payload != nil { + payload = make([]byte, len(m.Payload)) + copy(payload, m.Payload) + } + + return Message{ + Headers: m.Headers.Clone(), + Payload: payload, + } +} + type messagePrelude struct { Length uint32 HeadersLen uint32 diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go index 5e9499699..8b2c9bbeb 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/json/jsonutil/unmarshal.go @@ -6,6 +6,7 @@ import ( "encoding/json" "fmt" "io" + "math/big" "reflect" "strings" "time" @@ -15,6 +16,8 @@ import ( "github.com/aws/aws-sdk-go/private/protocol" ) +var millisecondsFloat = new(big.Float).SetInt64(1e3) + // UnmarshalJSONError unmarshal's the reader's JSON document into the passed in // type. The value to unmarshal the json document into must be a pointer to the // type. @@ -39,7 +42,9 @@ func UnmarshalJSONError(v interface{}, stream io.Reader) error { func UnmarshalJSON(v interface{}, stream io.Reader) error { var out interface{} - err := json.NewDecoder(stream).Decode(&out) + decoder := json.NewDecoder(stream) + decoder.UseNumber() + err := decoder.Decode(&out) if err == io.EOF { return nil } else if err != nil { @@ -54,7 +59,9 @@ func UnmarshalJSON(v interface{}, stream io.Reader) error { func UnmarshalJSONCaseInsensitive(v interface{}, stream io.Reader) error { var out interface{} - err := json.NewDecoder(stream).Decode(&out) + decoder := json.NewDecoder(stream) + decoder.UseNumber() + err := decoder.Decode(&out) if err == io.EOF { return nil } else if err != nil { @@ -254,16 +261,31 @@ func (u unmarshaler) unmarshalScalar(value reflect.Value, data interface{}, tag default: return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type()) } - case float64: + case json.Number: switch value.Interface().(type) { case *int64: - di := int64(d) + // Retain the old behavior where we would just truncate the float64 + // calling d.Int64() here could cause an invalid syntax error due to the usage of strconv.ParseInt + f, err := d.Float64() + if err != nil { + return err + } + di := int64(f) value.Set(reflect.ValueOf(&di)) case *float64: - value.Set(reflect.ValueOf(&d)) + f, err := d.Float64() + if err != nil { + return err + } + value.Set(reflect.ValueOf(&f)) case *time.Time: - // Time unmarshaled from a float64 can only be epoch seconds - t := time.Unix(int64(d), 0).UTC() + float, ok := new(big.Float).SetString(d.String()) + if !ok { + return fmt.Errorf("unsupported float time representation: %v", d.String()) + } + float = float.Mul(float, millisecondsFloat) + ms, _ := float.Int64() + t := time.Unix(0, ms*1e6).UTC() value.Set(reflect.ValueOf(&t)) default: return fmt.Errorf("unsupported value: %v (%s)", value.Interface(), value.Type()) diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go index 05d4ff519..98f4caed9 100644 --- a/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go +++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/timestamp.go @@ -27,8 +27,8 @@ const ( // RFC3339 a subset of the ISO8601 timestamp format. e.g 2014-04-29T18:30:38Z ISO8601TimeFormat = "2006-01-02T15:04:05.999999999Z" - // This format is used for output time without seconds precision - ISO8601OutputTimeFormat = "2006-01-02T15:04:05Z" + // This format is used for output time with fractional second precision up to milliseconds + ISO8601OutputTimeFormat = "2006-01-02T15:04:05.999999999Z" ) // IsKnownTimestampFormat returns if the timestamp format name @@ -48,7 +48,7 @@ func IsKnownTimestampFormat(name string) bool { // FormatTime returns a string value of the time. func FormatTime(name string, t time.Time) string { - t = t.UTC() + t = t.UTC().Truncate(time.Millisecond) switch name { case RFC822TimeFormatName: @@ -56,7 +56,8 @@ func FormatTime(name string, t time.Time) string { case ISO8601TimeFormatName: return t.Format(ISO8601OutputTimeFormat) case UnixTimeFormatName: - return strconv.FormatInt(t.Unix(), 10) + ms := t.UnixNano() / int64(time.Millisecond) + return strconv.FormatFloat(float64(ms)/1e3, 'f', -1, 64) default: panic("unknown timestamp format name, " + name) } diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/api.go b/vendor/github.com/aws/aws-sdk-go/service/s3/api.go index 228cd3cfe..8b14d6f7b 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/api.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/api.go @@ -200,7 +200,7 @@ func (c *S3) CompleteMultipartUploadRequest(input *CompleteMultipartUploadInput) // For information about permissions required to use the multipart upload API, // see Multipart Upload API and Permissions (https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html). // -// GetBucketLifecycle has the following special errors: +// CompleteMultipartUpload has the following special errors: // // * Error code: EntityTooSmall Description: Your proposed upload is smaller // than the minimum allowed object size. Each part must be at least 5 MB @@ -7883,6 +7883,13 @@ func (c *S3) PutBucketReplicationRequest(input *PutBucketReplicationInput) (req // When you add the Filter element in the configuration, you must also add the // following elements: DeleteMarkerReplication, Status, and Priority. // +// The latest version of the replication configuration XML is V2. XML V2 replication +// configurations are those that contain the Filter element for rules, and rules +// that specify S3 Replication Time Control (S3 RTC). In XML V2 replication +// configurations, Amazon S3 doesn't replicate delete markers. Therefore, you +// must set the DeleteMarkerReplication element to Disabled. For backward compatibility, +// Amazon S3 continues to support the XML V1 replication configuration. +// // For information about enabling versioning on a bucket, see Using Versioning // (https://docs.aws.amazon.com/AmazonS3/latest/dev/Versioning.html). // @@ -9474,7 +9481,7 @@ func (c *S3) SelectObjectContentRequest(input *SelectObjectContentInput) (req *r output = &SelectObjectContentOutput{} req = c.newRequest(op, input, output) - es := newSelectObjectContentEventStream() + es := NewSelectObjectContentEventStream() req.Handlers.Unmarshal.PushBack(es.setStreamCloser) output.EventStream = es @@ -9599,7 +9606,13 @@ func (c *S3) SelectObjectContentWithContext(ctx aws.Context, input *SelectObject return out, req.Send() } +var _ awserr.Error + // SelectObjectContentEventStream provides the event stream handling for the SelectObjectContent. +// +// For testing and mocking the event stream this type should be initialized via +// the NewSelectObjectContentEventStream constructor function. Using the functional options +// to pass in nested mock behavior. type SelectObjectContentEventStream struct { // Reader is the EventStream reader for the SelectObjectContentEventStream @@ -9622,11 +9635,31 @@ type SelectObjectContentEventStream struct { err *eventstreamapi.OnceError } -func newSelectObjectContentEventStream() *SelectObjectContentEventStream { - return &SelectObjectContentEventStream{ +// NewSelectObjectContentEventStream initializes an SelectObjectContentEventStream. +// This function should only be used for testing and mocking the SelectObjectContentEventStream +// stream within your application. +// +// The Reader member must be set before reading events from the stream. +// +// The StreamCloser member should be set to the underlying io.Closer, +// (e.g. http.Response.Body), that will be closed when the stream Close method +// is called. +// +// es := NewSelectObjectContentEventStream(func(o *SelectObjectContentEventStream{ +// es.Reader = myMockStreamReader +// es.StreamCloser = myMockStreamCloser +// }) +func NewSelectObjectContentEventStream(opts ...func(*SelectObjectContentEventStream)) *SelectObjectContentEventStream { + es := &SelectObjectContentEventStream{ done: make(chan struct{}), err: eventstreamapi.NewOnceError(), } + + for _, fn := range opts { + fn(es) + } + + return es } func (es *SelectObjectContentEventStream) setStreamCloser(r *request.Request) { @@ -9673,6 +9706,7 @@ func (es *SelectObjectContentEventStream) waitStreamPartClose() { // * ProgressEvent // * RecordsEvent // * StatsEvent +// * SelectObjectContentEventStreamUnknownEvent func (es *SelectObjectContentEventStream) Events() <-chan SelectObjectContentEventStreamEvent { return es.Reader.Events() } @@ -11558,6 +11592,8 @@ func (s *ContinuationEvent) UnmarshalEvent( return nil } +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. func (s *ContinuationEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) return msg, err @@ -14113,7 +14149,7 @@ type DeleteObjectTaggingInput struct { // Bucket is a required field Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"` - // Name of the tag. + // Name of the object key. // // Key is a required field Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"` @@ -14774,6 +14810,8 @@ func (s *EndEvent) UnmarshalEvent( return nil } +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. func (s *EndEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) return msg, err @@ -21467,7 +21505,7 @@ type ListObjectsOutput struct { // is true), you can use the key name in this field as marker in the subsequent // request to get next set of objects. Amazon S3 lists objects in alphabetical // order Note: This element is returned only if you have delimiter request parameter - // specified. If response does not include the NextMaker and it is truncated, + // specified. If response does not include the NextMarker and it is truncated, // you can use the value of the last Key in the response as the marker in the // subsequent request to get the next set of object keys. NextMarker *string `type:"string"` @@ -22947,8 +22985,22 @@ func (s *NotificationConfigurationFilter) SetKey(v *KeyFilter) *NotificationConf type Object struct { _ struct{} `type:"structure"` - // The entity tag is an MD5 hash of the object. ETag reflects only changes to - // the contents of an object, not its metadata. + // The entity tag is a hash of the object. The ETag reflects changes only to + // the contents of an object, not its metadata. The ETag may or may not be an + // MD5 digest of the object data. Whether or not it is depends on how the object + // was created and how it is encrypted as described below: + // + // * Objects created by the PUT Object, POST Object, or Copy operation, or + // through the AWS Management Console, and are encrypted by SSE-S3 or plaintext, + // have ETags that are an MD5 digest of their object data. + // + // * Objects created by the PUT Object, POST Object, or Copy operation, or + // through the AWS Management Console, and are encrypted by SSE-C or SSE-KMS, + // have ETags that are not an MD5 digest of their object data. + // + // * If an object is created by either the Multipart Upload or Part Copy + // operation, the ETag is not an MD5 digest, regardless of the method of + // encryption. ETag *string `type:"string"` // The name that you assign to an object. You use the object key to retrieve @@ -23548,6 +23600,8 @@ func (s *ProgressEvent) UnmarshalEvent( return nil } +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. func (s *ProgressEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) var buf bytes.Buffer @@ -26593,7 +26647,7 @@ type PutObjectTaggingInput struct { // Bucket is a required field Bucket *string `location:"uri" locationName:"Bucket" type:"string" required:"true"` - // Name of the tag. + // Name of the object key. // // Key is a required field Key *string `location:"uri" locationName:"Key" min:"1" type:"string" required:"true"` @@ -26984,6 +27038,8 @@ func (s *RecordsEvent) UnmarshalEvent( return nil } +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. func (s *RecordsEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) msg.Headers.Set(":content-type", eventstream.StringValue("application/octet-stream")) @@ -28204,6 +28260,7 @@ type SelectObjectContentEventStreamEvent interface { // * ProgressEvent // * RecordsEvent // * StatsEvent +// * SelectObjectContentEventStreamUnknownEvent type SelectObjectContentEventStreamReader interface { // Returns a channel of events as they are read from the event stream. Events() <-chan SelectObjectContentEventStreamEvent @@ -28278,6 +28335,9 @@ func (r *readSelectObjectContentEventStream) readEventStream() { return default: } + if _, ok := err.(*eventstreamapi.UnknownMessageTypeError); ok { + continue + } r.err.SetError(err) return } @@ -28307,14 +28367,39 @@ func (u unmarshalerForSelectObjectContentEventStreamEvent) UnmarshalerForEventNa case "Stats": return &StatsEvent{}, nil default: - return nil, awserr.New( - request.ErrCodeSerialization, - fmt.Sprintf("unknown event type name, %s, for SelectObjectContentEventStream", eventType), - nil, - ) + return &SelectObjectContentEventStreamUnknownEvent{Type: eventType}, nil } } +// SelectObjectContentEventStreamUnknownEvent provides a failsafe event for the +// SelectObjectContentEventStream group of events when an unknown event is received. +type SelectObjectContentEventStreamUnknownEvent struct { + Type string + Message eventstream.Message +} + +// The SelectObjectContentEventStreamUnknownEvent is and event in the SelectObjectContentEventStream +// group of events. +func (s *SelectObjectContentEventStreamUnknownEvent) eventSelectObjectContentEventStream() {} + +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. +func (e *SelectObjectContentEventStreamUnknownEvent) MarshalEvent(pm protocol.PayloadMarshaler) ( + msg eventstream.Message, err error, +) { + return e.Message.Clone(), nil +} + +// UnmarshalEvent unmarshals the EventStream Message into the SelectObjectContentEventStreamData value. +// This method is only used internally within the SDK's EventStream handling. +func (e *SelectObjectContentEventStreamUnknownEvent) UnmarshalEvent( + payloadUnmarshaler protocol.PayloadUnmarshaler, + msg eventstream.Message, +) error { + e.Message = msg.Clone() + return nil +} + // Request to filter the contents of an Amazon S3 object based on a simple Structured // Query Language (SQL) statement. In the request, along with the SQL expression, // you must specify a data serialization format (JSON or CSV) of the object. @@ -28966,6 +29051,8 @@ func (s *StatsEvent) UnmarshalEvent( return nil } +// MarshalEvent marshals the type into an stream event value. This method +// should only used internally within the SDK's EventStream handling. func (s *StatsEvent) MarshalEvent(pm protocol.PayloadMarshaler) (msg eventstream.Message, err error) { msg.Headers.Set(eventstreamapi.MessageTypeHeader, eventstream.StringValue(eventstreamapi.EventMessageType)) var buf bytes.Buffer @@ -29081,7 +29168,7 @@ func (s *StorageClassAnalysisDataExport) SetOutputSchemaVersion(v string) *Stora type Tag struct { _ struct{} `type:"structure"` - // Name of the tag. + // Name of the object key. // // Key is a required field Key *string `min:"1" type:"string" required:"true"` @@ -30165,6 +30252,13 @@ const ( AnalyticsS3ExportFileFormatCsv = "CSV" ) +// AnalyticsS3ExportFileFormat_Values returns all elements of the AnalyticsS3ExportFileFormat enum +func AnalyticsS3ExportFileFormat_Values() []string { + return []string{ + AnalyticsS3ExportFileFormatCsv, + } +} + const ( // BucketAccelerateStatusEnabled is a BucketAccelerateStatus enum value BucketAccelerateStatusEnabled = "Enabled" @@ -30173,6 +30267,14 @@ const ( BucketAccelerateStatusSuspended = "Suspended" ) +// BucketAccelerateStatus_Values returns all elements of the BucketAccelerateStatus enum +func BucketAccelerateStatus_Values() []string { + return []string{ + BucketAccelerateStatusEnabled, + BucketAccelerateStatusSuspended, + } +} + const ( // BucketCannedACLPrivate is a BucketCannedACL enum value BucketCannedACLPrivate = "private" @@ -30187,18 +30289,31 @@ const ( BucketCannedACLAuthenticatedRead = "authenticated-read" ) +// BucketCannedACL_Values returns all elements of the BucketCannedACL enum +func BucketCannedACL_Values() []string { + return []string{ + BucketCannedACLPrivate, + BucketCannedACLPublicRead, + BucketCannedACLPublicReadWrite, + BucketCannedACLAuthenticatedRead, + } +} + const ( - // BucketLocationConstraintEu is a BucketLocationConstraint enum value - BucketLocationConstraintEu = "EU" + // BucketLocationConstraintAfSouth1 is a BucketLocationConstraint enum value + BucketLocationConstraintAfSouth1 = "af-south-1" - // BucketLocationConstraintEuWest1 is a BucketLocationConstraint enum value - BucketLocationConstraintEuWest1 = "eu-west-1" + // BucketLocationConstraintApEast1 is a BucketLocationConstraint enum value + BucketLocationConstraintApEast1 = "ap-east-1" - // BucketLocationConstraintUsWest1 is a BucketLocationConstraint enum value - BucketLocationConstraintUsWest1 = "us-west-1" + // BucketLocationConstraintApNortheast1 is a BucketLocationConstraint enum value + BucketLocationConstraintApNortheast1 = "ap-northeast-1" - // BucketLocationConstraintUsWest2 is a BucketLocationConstraint enum value - BucketLocationConstraintUsWest2 = "us-west-2" + // BucketLocationConstraintApNortheast2 is a BucketLocationConstraint enum value + BucketLocationConstraintApNortheast2 = "ap-northeast-2" + + // BucketLocationConstraintApNortheast3 is a BucketLocationConstraint enum value + BucketLocationConstraintApNortheast3 = "ap-northeast-3" // BucketLocationConstraintApSouth1 is a BucketLocationConstraint enum value BucketLocationConstraintApSouth1 = "ap-south-1" @@ -30209,19 +30324,89 @@ const ( // BucketLocationConstraintApSoutheast2 is a BucketLocationConstraint enum value BucketLocationConstraintApSoutheast2 = "ap-southeast-2" - // BucketLocationConstraintApNortheast1 is a BucketLocationConstraint enum value - BucketLocationConstraintApNortheast1 = "ap-northeast-1" - - // BucketLocationConstraintSaEast1 is a BucketLocationConstraint enum value - BucketLocationConstraintSaEast1 = "sa-east-1" + // BucketLocationConstraintCaCentral1 is a BucketLocationConstraint enum value + BucketLocationConstraintCaCentral1 = "ca-central-1" // BucketLocationConstraintCnNorth1 is a BucketLocationConstraint enum value BucketLocationConstraintCnNorth1 = "cn-north-1" + // BucketLocationConstraintCnNorthwest1 is a BucketLocationConstraint enum value + BucketLocationConstraintCnNorthwest1 = "cn-northwest-1" + + // BucketLocationConstraintEu is a BucketLocationConstraint enum value + BucketLocationConstraintEu = "EU" + // BucketLocationConstraintEuCentral1 is a BucketLocationConstraint enum value BucketLocationConstraintEuCentral1 = "eu-central-1" + + // BucketLocationConstraintEuNorth1 is a BucketLocationConstraint enum value + BucketLocationConstraintEuNorth1 = "eu-north-1" + + // BucketLocationConstraintEuSouth1 is a BucketLocationConstraint enum value + BucketLocationConstraintEuSouth1 = "eu-south-1" + + // BucketLocationConstraintEuWest1 is a BucketLocationConstraint enum value + BucketLocationConstraintEuWest1 = "eu-west-1" + + // BucketLocationConstraintEuWest2 is a BucketLocationConstraint enum value + BucketLocationConstraintEuWest2 = "eu-west-2" + + // BucketLocationConstraintEuWest3 is a BucketLocationConstraint enum value + BucketLocationConstraintEuWest3 = "eu-west-3" + + // BucketLocationConstraintMeSouth1 is a BucketLocationConstraint enum value + BucketLocationConstraintMeSouth1 = "me-south-1" + + // BucketLocationConstraintSaEast1 is a BucketLocationConstraint enum value + BucketLocationConstraintSaEast1 = "sa-east-1" + + // BucketLocationConstraintUsEast2 is a BucketLocationConstraint enum value + BucketLocationConstraintUsEast2 = "us-east-2" + + // BucketLocationConstraintUsGovEast1 is a BucketLocationConstraint enum value + BucketLocationConstraintUsGovEast1 = "us-gov-east-1" + + // BucketLocationConstraintUsGovWest1 is a BucketLocationConstraint enum value + BucketLocationConstraintUsGovWest1 = "us-gov-west-1" + + // BucketLocationConstraintUsWest1 is a BucketLocationConstraint enum value + BucketLocationConstraintUsWest1 = "us-west-1" + + // BucketLocationConstraintUsWest2 is a BucketLocationConstraint enum value + BucketLocationConstraintUsWest2 = "us-west-2" ) +// BucketLocationConstraint_Values returns all elements of the BucketLocationConstraint enum +func BucketLocationConstraint_Values() []string { + return []string{ + BucketLocationConstraintAfSouth1, + BucketLocationConstraintApEast1, + BucketLocationConstraintApNortheast1, + BucketLocationConstraintApNortheast2, + BucketLocationConstraintApNortheast3, + BucketLocationConstraintApSouth1, + BucketLocationConstraintApSoutheast1, + BucketLocationConstraintApSoutheast2, + BucketLocationConstraintCaCentral1, + BucketLocationConstraintCnNorth1, + BucketLocationConstraintCnNorthwest1, + BucketLocationConstraintEu, + BucketLocationConstraintEuCentral1, + BucketLocationConstraintEuNorth1, + BucketLocationConstraintEuSouth1, + BucketLocationConstraintEuWest1, + BucketLocationConstraintEuWest2, + BucketLocationConstraintEuWest3, + BucketLocationConstraintMeSouth1, + BucketLocationConstraintSaEast1, + BucketLocationConstraintUsEast2, + BucketLocationConstraintUsGovEast1, + BucketLocationConstraintUsGovWest1, + BucketLocationConstraintUsWest1, + BucketLocationConstraintUsWest2, + } +} + const ( // BucketLogsPermissionFullControl is a BucketLogsPermission enum value BucketLogsPermissionFullControl = "FULL_CONTROL" @@ -30233,6 +30418,15 @@ const ( BucketLogsPermissionWrite = "WRITE" ) +// BucketLogsPermission_Values returns all elements of the BucketLogsPermission enum +func BucketLogsPermission_Values() []string { + return []string{ + BucketLogsPermissionFullControl, + BucketLogsPermissionRead, + BucketLogsPermissionWrite, + } +} + const ( // BucketVersioningStatusEnabled is a BucketVersioningStatus enum value BucketVersioningStatusEnabled = "Enabled" @@ -30241,6 +30435,14 @@ const ( BucketVersioningStatusSuspended = "Suspended" ) +// BucketVersioningStatus_Values returns all elements of the BucketVersioningStatus enum +func BucketVersioningStatus_Values() []string { + return []string{ + BucketVersioningStatusEnabled, + BucketVersioningStatusSuspended, + } +} + const ( // CompressionTypeNone is a CompressionType enum value CompressionTypeNone = "NONE" @@ -30252,6 +30454,15 @@ const ( CompressionTypeBzip2 = "BZIP2" ) +// CompressionType_Values returns all elements of the CompressionType enum +func CompressionType_Values() []string { + return []string{ + CompressionTypeNone, + CompressionTypeGzip, + CompressionTypeBzip2, + } +} + const ( // DeleteMarkerReplicationStatusEnabled is a DeleteMarkerReplicationStatus enum value DeleteMarkerReplicationStatusEnabled = "Enabled" @@ -30260,6 +30471,14 @@ const ( DeleteMarkerReplicationStatusDisabled = "Disabled" ) +// DeleteMarkerReplicationStatus_Values returns all elements of the DeleteMarkerReplicationStatus enum +func DeleteMarkerReplicationStatus_Values() []string { + return []string{ + DeleteMarkerReplicationStatusEnabled, + DeleteMarkerReplicationStatusDisabled, + } +} + // Requests Amazon S3 to encode the object keys in the response and specifies // the encoding method to use. An object key may contain any Unicode character; // however, XML 1.0 parser cannot parse some characters, such as characters @@ -30271,6 +30490,13 @@ const ( EncodingTypeUrl = "url" ) +// EncodingType_Values returns all elements of the EncodingType enum +func EncodingType_Values() []string { + return []string{ + EncodingTypeUrl, + } +} + // The bucket event for which to send notifications. const ( // EventS3ReducedRedundancyLostObject is a Event enum value @@ -30325,6 +30551,29 @@ const ( EventS3ReplicationOperationReplicatedAfterThreshold = "s3:Replication:OperationReplicatedAfterThreshold" ) +// Event_Values returns all elements of the Event enum +func Event_Values() []string { + return []string{ + EventS3ReducedRedundancyLostObject, + EventS3ObjectCreated, + EventS3ObjectCreatedPut, + EventS3ObjectCreatedPost, + EventS3ObjectCreatedCopy, + EventS3ObjectCreatedCompleteMultipartUpload, + EventS3ObjectRemoved, + EventS3ObjectRemovedDelete, + EventS3ObjectRemovedDeleteMarkerCreated, + EventS3ObjectRestore, + EventS3ObjectRestorePost, + EventS3ObjectRestoreCompleted, + EventS3Replication, + EventS3ReplicationOperationFailedReplication, + EventS3ReplicationOperationNotTracked, + EventS3ReplicationOperationMissedThreshold, + EventS3ReplicationOperationReplicatedAfterThreshold, + } +} + const ( // ExistingObjectReplicationStatusEnabled is a ExistingObjectReplicationStatus enum value ExistingObjectReplicationStatusEnabled = "Enabled" @@ -30333,6 +30582,14 @@ const ( ExistingObjectReplicationStatusDisabled = "Disabled" ) +// ExistingObjectReplicationStatus_Values returns all elements of the ExistingObjectReplicationStatus enum +func ExistingObjectReplicationStatus_Values() []string { + return []string{ + ExistingObjectReplicationStatusEnabled, + ExistingObjectReplicationStatusDisabled, + } +} + const ( // ExpirationStatusEnabled is a ExpirationStatus enum value ExpirationStatusEnabled = "Enabled" @@ -30341,11 +30598,26 @@ const ( ExpirationStatusDisabled = "Disabled" ) +// ExpirationStatus_Values returns all elements of the ExpirationStatus enum +func ExpirationStatus_Values() []string { + return []string{ + ExpirationStatusEnabled, + ExpirationStatusDisabled, + } +} + const ( // ExpressionTypeSql is a ExpressionType enum value ExpressionTypeSql = "SQL" ) +// ExpressionType_Values returns all elements of the ExpressionType enum +func ExpressionType_Values() []string { + return []string{ + ExpressionTypeSql, + } +} + const ( // FileHeaderInfoUse is a FileHeaderInfo enum value FileHeaderInfoUse = "USE" @@ -30357,6 +30629,15 @@ const ( FileHeaderInfoNone = "NONE" ) +// FileHeaderInfo_Values returns all elements of the FileHeaderInfo enum +func FileHeaderInfo_Values() []string { + return []string{ + FileHeaderInfoUse, + FileHeaderInfoIgnore, + FileHeaderInfoNone, + } +} + const ( // FilterRuleNamePrefix is a FilterRuleName enum value FilterRuleNamePrefix = "prefix" @@ -30365,6 +30646,14 @@ const ( FilterRuleNameSuffix = "suffix" ) +// FilterRuleName_Values returns all elements of the FilterRuleName enum +func FilterRuleName_Values() []string { + return []string{ + FilterRuleNamePrefix, + FilterRuleNameSuffix, + } +} + const ( // InventoryFormatCsv is a InventoryFormat enum value InventoryFormatCsv = "CSV" @@ -30376,6 +30665,15 @@ const ( InventoryFormatParquet = "Parquet" ) +// InventoryFormat_Values returns all elements of the InventoryFormat enum +func InventoryFormat_Values() []string { + return []string{ + InventoryFormatCsv, + InventoryFormatOrc, + InventoryFormatParquet, + } +} + const ( // InventoryFrequencyDaily is a InventoryFrequency enum value InventoryFrequencyDaily = "Daily" @@ -30384,6 +30682,14 @@ const ( InventoryFrequencyWeekly = "Weekly" ) +// InventoryFrequency_Values returns all elements of the InventoryFrequency enum +func InventoryFrequency_Values() []string { + return []string{ + InventoryFrequencyDaily, + InventoryFrequencyWeekly, + } +} + const ( // InventoryIncludedObjectVersionsAll is a InventoryIncludedObjectVersions enum value InventoryIncludedObjectVersionsAll = "All" @@ -30392,6 +30698,14 @@ const ( InventoryIncludedObjectVersionsCurrent = "Current" ) +// InventoryIncludedObjectVersions_Values returns all elements of the InventoryIncludedObjectVersions enum +func InventoryIncludedObjectVersions_Values() []string { + return []string{ + InventoryIncludedObjectVersionsAll, + InventoryIncludedObjectVersionsCurrent, + } +} + const ( // InventoryOptionalFieldSize is a InventoryOptionalField enum value InventoryOptionalFieldSize = "Size" @@ -30427,6 +30741,23 @@ const ( InventoryOptionalFieldIntelligentTieringAccessTier = "IntelligentTieringAccessTier" ) +// InventoryOptionalField_Values returns all elements of the InventoryOptionalField enum +func InventoryOptionalField_Values() []string { + return []string{ + InventoryOptionalFieldSize, + InventoryOptionalFieldLastModifiedDate, + InventoryOptionalFieldStorageClass, + InventoryOptionalFieldEtag, + InventoryOptionalFieldIsMultipartUploaded, + InventoryOptionalFieldReplicationStatus, + InventoryOptionalFieldEncryptionStatus, + InventoryOptionalFieldObjectLockRetainUntilDate, + InventoryOptionalFieldObjectLockMode, + InventoryOptionalFieldObjectLockLegalHoldStatus, + InventoryOptionalFieldIntelligentTieringAccessTier, + } +} + const ( // JSONTypeDocument is a JSONType enum value JSONTypeDocument = "DOCUMENT" @@ -30435,6 +30766,14 @@ const ( JSONTypeLines = "LINES" ) +// JSONType_Values returns all elements of the JSONType enum +func JSONType_Values() []string { + return []string{ + JSONTypeDocument, + JSONTypeLines, + } +} + const ( // MFADeleteEnabled is a MFADelete enum value MFADeleteEnabled = "Enabled" @@ -30443,6 +30782,14 @@ const ( MFADeleteDisabled = "Disabled" ) +// MFADelete_Values returns all elements of the MFADelete enum +func MFADelete_Values() []string { + return []string{ + MFADeleteEnabled, + MFADeleteDisabled, + } +} + const ( // MFADeleteStatusEnabled is a MFADeleteStatus enum value MFADeleteStatusEnabled = "Enabled" @@ -30451,6 +30798,14 @@ const ( MFADeleteStatusDisabled = "Disabled" ) +// MFADeleteStatus_Values returns all elements of the MFADeleteStatus enum +func MFADeleteStatus_Values() []string { + return []string{ + MFADeleteStatusEnabled, + MFADeleteStatusDisabled, + } +} + const ( // MetadataDirectiveCopy is a MetadataDirective enum value MetadataDirectiveCopy = "COPY" @@ -30459,6 +30814,14 @@ const ( MetadataDirectiveReplace = "REPLACE" ) +// MetadataDirective_Values returns all elements of the MetadataDirective enum +func MetadataDirective_Values() []string { + return []string{ + MetadataDirectiveCopy, + MetadataDirectiveReplace, + } +} + const ( // MetricsStatusEnabled is a MetricsStatus enum value MetricsStatusEnabled = "Enabled" @@ -30467,6 +30830,14 @@ const ( MetricsStatusDisabled = "Disabled" ) +// MetricsStatus_Values returns all elements of the MetricsStatus enum +func MetricsStatus_Values() []string { + return []string{ + MetricsStatusEnabled, + MetricsStatusDisabled, + } +} + const ( // ObjectCannedACLPrivate is a ObjectCannedACL enum value ObjectCannedACLPrivate = "private" @@ -30490,11 +30861,31 @@ const ( ObjectCannedACLBucketOwnerFullControl = "bucket-owner-full-control" ) +// ObjectCannedACL_Values returns all elements of the ObjectCannedACL enum +func ObjectCannedACL_Values() []string { + return []string{ + ObjectCannedACLPrivate, + ObjectCannedACLPublicRead, + ObjectCannedACLPublicReadWrite, + ObjectCannedACLAuthenticatedRead, + ObjectCannedACLAwsExecRead, + ObjectCannedACLBucketOwnerRead, + ObjectCannedACLBucketOwnerFullControl, + } +} + const ( // ObjectLockEnabledEnabled is a ObjectLockEnabled enum value ObjectLockEnabledEnabled = "Enabled" ) +// ObjectLockEnabled_Values returns all elements of the ObjectLockEnabled enum +func ObjectLockEnabled_Values() []string { + return []string{ + ObjectLockEnabledEnabled, + } +} + const ( // ObjectLockLegalHoldStatusOn is a ObjectLockLegalHoldStatus enum value ObjectLockLegalHoldStatusOn = "ON" @@ -30503,6 +30894,14 @@ const ( ObjectLockLegalHoldStatusOff = "OFF" ) +// ObjectLockLegalHoldStatus_Values returns all elements of the ObjectLockLegalHoldStatus enum +func ObjectLockLegalHoldStatus_Values() []string { + return []string{ + ObjectLockLegalHoldStatusOn, + ObjectLockLegalHoldStatusOff, + } +} + const ( // ObjectLockModeGovernance is a ObjectLockMode enum value ObjectLockModeGovernance = "GOVERNANCE" @@ -30511,6 +30910,14 @@ const ( ObjectLockModeCompliance = "COMPLIANCE" ) +// ObjectLockMode_Values returns all elements of the ObjectLockMode enum +func ObjectLockMode_Values() []string { + return []string{ + ObjectLockModeGovernance, + ObjectLockModeCompliance, + } +} + const ( // ObjectLockRetentionModeGovernance is a ObjectLockRetentionMode enum value ObjectLockRetentionModeGovernance = "GOVERNANCE" @@ -30519,6 +30926,14 @@ const ( ObjectLockRetentionModeCompliance = "COMPLIANCE" ) +// ObjectLockRetentionMode_Values returns all elements of the ObjectLockRetentionMode enum +func ObjectLockRetentionMode_Values() []string { + return []string{ + ObjectLockRetentionModeGovernance, + ObjectLockRetentionModeCompliance, + } +} + const ( // ObjectStorageClassStandard is a ObjectStorageClass enum value ObjectStorageClassStandard = "STANDARD" @@ -30542,16 +30957,43 @@ const ( ObjectStorageClassDeepArchive = "DEEP_ARCHIVE" ) +// ObjectStorageClass_Values returns all elements of the ObjectStorageClass enum +func ObjectStorageClass_Values() []string { + return []string{ + ObjectStorageClassStandard, + ObjectStorageClassReducedRedundancy, + ObjectStorageClassGlacier, + ObjectStorageClassStandardIa, + ObjectStorageClassOnezoneIa, + ObjectStorageClassIntelligentTiering, + ObjectStorageClassDeepArchive, + } +} + const ( // ObjectVersionStorageClassStandard is a ObjectVersionStorageClass enum value ObjectVersionStorageClassStandard = "STANDARD" ) +// ObjectVersionStorageClass_Values returns all elements of the ObjectVersionStorageClass enum +func ObjectVersionStorageClass_Values() []string { + return []string{ + ObjectVersionStorageClassStandard, + } +} + const ( // OwnerOverrideDestination is a OwnerOverride enum value OwnerOverrideDestination = "Destination" ) +// OwnerOverride_Values returns all elements of the OwnerOverride enum +func OwnerOverride_Values() []string { + return []string{ + OwnerOverrideDestination, + } +} + const ( // PayerRequester is a Payer enum value PayerRequester = "Requester" @@ -30560,6 +31002,14 @@ const ( PayerBucketOwner = "BucketOwner" ) +// Payer_Values returns all elements of the Payer enum +func Payer_Values() []string { + return []string{ + PayerRequester, + PayerBucketOwner, + } +} + const ( // PermissionFullControl is a Permission enum value PermissionFullControl = "FULL_CONTROL" @@ -30577,6 +31027,17 @@ const ( PermissionReadAcp = "READ_ACP" ) +// Permission_Values returns all elements of the Permission enum +func Permission_Values() []string { + return []string{ + PermissionFullControl, + PermissionWrite, + PermissionWriteAcp, + PermissionRead, + PermissionReadAcp, + } +} + const ( // ProtocolHttp is a Protocol enum value ProtocolHttp = "http" @@ -30585,6 +31046,14 @@ const ( ProtocolHttps = "https" ) +// Protocol_Values returns all elements of the Protocol enum +func Protocol_Values() []string { + return []string{ + ProtocolHttp, + ProtocolHttps, + } +} + const ( // QuoteFieldsAlways is a QuoteFields enum value QuoteFieldsAlways = "ALWAYS" @@ -30593,6 +31062,14 @@ const ( QuoteFieldsAsneeded = "ASNEEDED" ) +// QuoteFields_Values returns all elements of the QuoteFields enum +func QuoteFields_Values() []string { + return []string{ + QuoteFieldsAlways, + QuoteFieldsAsneeded, + } +} + const ( // ReplicationRuleStatusEnabled is a ReplicationRuleStatus enum value ReplicationRuleStatusEnabled = "Enabled" @@ -30601,6 +31078,14 @@ const ( ReplicationRuleStatusDisabled = "Disabled" ) +// ReplicationRuleStatus_Values returns all elements of the ReplicationRuleStatus enum +func ReplicationRuleStatus_Values() []string { + return []string{ + ReplicationRuleStatusEnabled, + ReplicationRuleStatusDisabled, + } +} + const ( // ReplicationStatusComplete is a ReplicationStatus enum value ReplicationStatusComplete = "COMPLETE" @@ -30615,6 +31100,16 @@ const ( ReplicationStatusReplica = "REPLICA" ) +// ReplicationStatus_Values returns all elements of the ReplicationStatus enum +func ReplicationStatus_Values() []string { + return []string{ + ReplicationStatusComplete, + ReplicationStatusPending, + ReplicationStatusFailed, + ReplicationStatusReplica, + } +} + const ( // ReplicationTimeStatusEnabled is a ReplicationTimeStatus enum value ReplicationTimeStatusEnabled = "Enabled" @@ -30623,6 +31118,14 @@ const ( ReplicationTimeStatusDisabled = "Disabled" ) +// ReplicationTimeStatus_Values returns all elements of the ReplicationTimeStatus enum +func ReplicationTimeStatus_Values() []string { + return []string{ + ReplicationTimeStatusEnabled, + ReplicationTimeStatusDisabled, + } +} + // If present, indicates that the requester was successfully charged for the // request. const ( @@ -30630,6 +31133,13 @@ const ( RequestChargedRequester = "requester" ) +// RequestCharged_Values returns all elements of the RequestCharged enum +func RequestCharged_Values() []string { + return []string{ + RequestChargedRequester, + } +} + // Confirms that the requester knows that they will be charged for the request. // Bucket owners need not specify this parameter in their requests. For information // about downloading objects from requester pays buckets, see Downloading Objects @@ -30640,11 +31150,25 @@ const ( RequestPayerRequester = "requester" ) +// RequestPayer_Values returns all elements of the RequestPayer enum +func RequestPayer_Values() []string { + return []string{ + RequestPayerRequester, + } +} + const ( // RestoreRequestTypeSelect is a RestoreRequestType enum value RestoreRequestTypeSelect = "SELECT" ) +// RestoreRequestType_Values returns all elements of the RestoreRequestType enum +func RestoreRequestType_Values() []string { + return []string{ + RestoreRequestTypeSelect, + } +} + const ( // ServerSideEncryptionAes256 is a ServerSideEncryption enum value ServerSideEncryptionAes256 = "AES256" @@ -30653,6 +31177,14 @@ const ( ServerSideEncryptionAwsKms = "aws:kms" ) +// ServerSideEncryption_Values returns all elements of the ServerSideEncryption enum +func ServerSideEncryption_Values() []string { + return []string{ + ServerSideEncryptionAes256, + ServerSideEncryptionAwsKms, + } +} + const ( // SseKmsEncryptedObjectsStatusEnabled is a SseKmsEncryptedObjectsStatus enum value SseKmsEncryptedObjectsStatusEnabled = "Enabled" @@ -30661,6 +31193,14 @@ const ( SseKmsEncryptedObjectsStatusDisabled = "Disabled" ) +// SseKmsEncryptedObjectsStatus_Values returns all elements of the SseKmsEncryptedObjectsStatus enum +func SseKmsEncryptedObjectsStatus_Values() []string { + return []string{ + SseKmsEncryptedObjectsStatusEnabled, + SseKmsEncryptedObjectsStatusDisabled, + } +} + const ( // StorageClassStandard is a StorageClass enum value StorageClassStandard = "STANDARD" @@ -30684,11 +31224,31 @@ const ( StorageClassDeepArchive = "DEEP_ARCHIVE" ) +// StorageClass_Values returns all elements of the StorageClass enum +func StorageClass_Values() []string { + return []string{ + StorageClassStandard, + StorageClassReducedRedundancy, + StorageClassStandardIa, + StorageClassOnezoneIa, + StorageClassIntelligentTiering, + StorageClassGlacier, + StorageClassDeepArchive, + } +} + const ( // StorageClassAnalysisSchemaVersionV1 is a StorageClassAnalysisSchemaVersion enum value StorageClassAnalysisSchemaVersionV1 = "V_1" ) +// StorageClassAnalysisSchemaVersion_Values returns all elements of the StorageClassAnalysisSchemaVersion enum +func StorageClassAnalysisSchemaVersion_Values() []string { + return []string{ + StorageClassAnalysisSchemaVersionV1, + } +} + const ( // TaggingDirectiveCopy is a TaggingDirective enum value TaggingDirectiveCopy = "COPY" @@ -30697,6 +31257,14 @@ const ( TaggingDirectiveReplace = "REPLACE" ) +// TaggingDirective_Values returns all elements of the TaggingDirective enum +func TaggingDirective_Values() []string { + return []string{ + TaggingDirectiveCopy, + TaggingDirectiveReplace, + } +} + const ( // TierStandard is a Tier enum value TierStandard = "Standard" @@ -30708,6 +31276,15 @@ const ( TierExpedited = "Expedited" ) +// Tier_Values returns all elements of the Tier enum +func Tier_Values() []string { + return []string{ + TierStandard, + TierBulk, + TierExpedited, + } +} + const ( // TransitionStorageClassGlacier is a TransitionStorageClass enum value TransitionStorageClassGlacier = "GLACIER" @@ -30725,6 +31302,17 @@ const ( TransitionStorageClassDeepArchive = "DEEP_ARCHIVE" ) +// TransitionStorageClass_Values returns all elements of the TransitionStorageClass enum +func TransitionStorageClass_Values() []string { + return []string{ + TransitionStorageClassGlacier, + TransitionStorageClassStandardIa, + TransitionStorageClassOnezoneIa, + TransitionStorageClassIntelligentTiering, + TransitionStorageClassDeepArchive, + } +} + const ( // TypeCanonicalUser is a Type enum value TypeCanonicalUser = "CanonicalUser" @@ -30735,3 +31323,12 @@ const ( // TypeGroup is a Type enum value TypeGroup = "Group" ) + +// Type_Values returns all elements of the Type enum +func Type_Values() []string { + return []string{ + TypeCanonicalUser, + TypeAmazonCustomerByEmail, + TypeGroup, + } +} diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/doc_custom.go b/vendor/github.com/aws/aws-sdk-go/service/s3/doc_custom.go index 4b65f7153..7f7aca208 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/doc_custom.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/doc_custom.go @@ -104,19 +104,6 @@ // content from S3. The Encryption and Decryption clients can be used concurrently // once the client is created. // -// sess := session.Must(session.NewSession()) -// -// // Create the decryption client. -// svc := s3crypto.NewDecryptionClient(sess) -// -// // The object will be downloaded from S3 and decrypted locally. By metadata -// // about the object's encryption will instruct the decryption client how -// // decrypt the content of the object. By default KMS is used for keys. -// result, err := svc.GetObject(&s3.GetObjectInput { -// Bucket: aws.String(myBucket), -// Key: aws.String(myKey), -// }) -// // See the s3crypto package documentation for more information. // https://docs.aws.amazon.com/sdk-for-go/api/service/s3/s3crypto/ // diff --git a/vendor/github.com/aws/aws-sdk-go/service/s3/sse.go b/vendor/github.com/aws/aws-sdk-go/service/s3/sse.go index b71c835de..57a0bd92c 100644 --- a/vendor/github.com/aws/aws-sdk-go/service/s3/sse.go +++ b/vendor/github.com/aws/aws-sdk-go/service/s3/sse.go @@ -69,7 +69,7 @@ func computeKeyMD5(keyHeader, keyMD5Header, key string, r *http.Request) { return } - // In backwards compatiable, the header's value is not base64 encoded, + // In backwards compatible, the header's value is not base64 encoded, // and needs to be encoded and updated by the SDK's customizations. b64Key := base64.StdEncoding.EncodeToString([]byte(key)) r.Header.Set(keyHeader, b64Key) diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.gitignore b/vendor/github.com/outscale/osc-sdk-go/osc/.gitignore new file mode 100644 index 000000000..daf913b1b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/.gitignore @@ -0,0 +1,24 @@ +# Compiled Object files, Static and Dynamic libs (Shared Objects) +*.o +*.a +*.so + +# Folders +_obj +_test + +# Architecture specific extensions/prefixes +*.[568vq] +[568vq].out + +*.cgo1.go +*.cgo2.c +_cgo_defun.c +_cgo_gotypes.go +_cgo_export.* + +_testmain.go + +*.exe +*.test +*.prof diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore b/vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore new file mode 100644 index 000000000..7484ee590 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore @@ -0,0 +1,23 @@ +# OpenAPI Generator Ignore +# Generated by openapi-generator https://github.com/openapitools/openapi-generator + +# Use this file to prevent files from being overwritten by the generator. +# The patterns follow closely to .gitignore or .dockerignore. + +# As an example, the C# client generator defines ApiClient.cs. +# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: +#ApiClient.cs + +# You can match any string of characters against a directory, file or extension with a single asterisk (*): +#foo/*/qux +# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux + +# You can recursively match patterns against a directory, file or extension with a double asterisk (**): +#foo/**/qux +# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux + +# You can also negate patterns with an exclamation (!). +# For example, you can ignore all files in a docs folder with the file extension .md: +#docs/*.md +# Then explicitly reverse the ignore rule for a single file: +#!docs/README.md diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml b/vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml new file mode 100644 index 000000000..f5cb2ce9a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml @@ -0,0 +1,8 @@ +language: go + +install: + - go get -d -v . + +script: + - go build -v ./ + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/README.md b/vendor/github.com/outscale/osc-sdk-go/osc/README.md new file mode 100644 index 000000000..3fb0f2728 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/README.md @@ -0,0 +1,728 @@ +# Go API client for osc + +Welcome to the 3DS OUTSCALE's API documentation.

+ +The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

+ +Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

+ +You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + +## Overview +This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. + +- API version: 1.4 +- Package version: 1.0.0 +- Build package: org.openapitools.codegen.languages.GoClientCodegen + +## Installation + +Install the following dependencies: + +```shell +go get github.com/stretchr/testify/assert +go get golang.org/x/oauth2 +go get golang.org/x/net/context +``` + +Put the package under your project folder and add the following in import: + +```golang +import sw "./osc" +``` + +## Configuration of Server URL + +Default configuration comes with `Servers` field that contains server objects as defined in the OpenAPI specification. + +### Select Server Configuration + +For using other server than the one defined on index 0 set context value `sw.ContextServerIndex` of type `int`. + +```golang +ctx := context.WithValue(context.Background(), sw.ContextServerIndex, 1) +``` + +### Templated Server URL + +Templated server URL is formatted using default variables from configuration or from context value `sw.ContextServerVariables` of type `map[string]string`. + +```golang +ctx := context.WithValue(context.Background(), sw.ContextServerVariables, map[string]string{ + "basePath": "v2", +}) +``` + +Note, enum values are always validated and all unused variables are silently ignored. + +### URLs Configuration per Operation + +Each operation can use different server URL defined using `OperationServers` map in the `Configuration`. +An operation is uniquely identifield by `"{classname}Service.{nickname}"` string. +Similar rules for overriding default operation server index and variables applies by using `sw.ContextOperationServerIndices` and `sw.ContextOperationServerVariables` context maps. + +``` +ctx := context.WithValue(context.Background(), sw.ContextOperationServerIndices, map[string]int{ + "{classname}Service.{nickname}": 2, +}) +ctx = context.WithValue(context.Background(), sw.ContextOperationServerVariables, map[string]map[string]string{ + "{classname}Service.{nickname}": { + "port": "8443", + }, +}) +``` + +## Documentation for API Endpoints + +All URIs are relative to *https://api.eu-west-2.outscale.com/api/v1* + +Class | Method | HTTP request | Description +------------ | ------------- | ------------- | ------------- +*AccessKeyApi* | [**CreateAccessKey**](docs/AccessKeyApi.md#createaccesskey) | **Post** /CreateAccessKey | +*AccessKeyApi* | [**DeleteAccessKey**](docs/AccessKeyApi.md#deleteaccesskey) | **Post** /DeleteAccessKey | +*AccessKeyApi* | [**ReadAccessKeys**](docs/AccessKeyApi.md#readaccesskeys) | **Post** /ReadAccessKeys | +*AccessKeyApi* | [**ReadSecretAccessKey**](docs/AccessKeyApi.md#readsecretaccesskey) | **Post** /ReadSecretAccessKey | +*AccessKeyApi* | [**UpdateAccessKey**](docs/AccessKeyApi.md#updateaccesskey) | **Post** /UpdateAccessKey | +*AccountApi* | [**CheckAuthentication**](docs/AccountApi.md#checkauthentication) | **Post** /CheckAuthentication | +*AccountApi* | [**CreateAccount**](docs/AccountApi.md#createaccount) | **Post** /CreateAccount | +*AccountApi* | [**ReadAccounts**](docs/AccountApi.md#readaccounts) | **Post** /ReadAccounts | +*AccountApi* | [**ReadConsumptionAccount**](docs/AccountApi.md#readconsumptionaccount) | **Post** /ReadConsumptionAccount | +*AccountApi* | [**ResetAccountPassword**](docs/AccountApi.md#resetaccountpassword) | **Post** /ResetAccountPassword | +*AccountApi* | [**SendResetPasswordEmail**](docs/AccountApi.md#sendresetpasswordemail) | **Post** /SendResetPasswordEmail | +*AccountApi* | [**UpdateAccount**](docs/AccountApi.md#updateaccount) | **Post** /UpdateAccount | +*ApiLogApi* | [**ReadApiLogs**](docs/ApiLogApi.md#readapilogs) | **Post** /ReadApiLogs | +*ClientGatewayApi* | [**CreateClientGateway**](docs/ClientGatewayApi.md#createclientgateway) | **Post** /CreateClientGateway | +*ClientGatewayApi* | [**DeleteClientGateway**](docs/ClientGatewayApi.md#deleteclientgateway) | **Post** /DeleteClientGateway | +*ClientGatewayApi* | [**ReadClientGateways**](docs/ClientGatewayApi.md#readclientgateways) | **Post** /ReadClientGateways | +*DhcpOptionApi* | [**CreateDhcpOptions**](docs/DhcpOptionApi.md#createdhcpoptions) | **Post** /CreateDhcpOptions | +*DhcpOptionApi* | [**DeleteDhcpOptions**](docs/DhcpOptionApi.md#deletedhcpoptions) | **Post** /DeleteDhcpOptions | +*DhcpOptionApi* | [**ReadDhcpOptions**](docs/DhcpOptionApi.md#readdhcpoptions) | **Post** /ReadDhcpOptions | +*DirectLinkApi* | [**CreateDirectLink**](docs/DirectLinkApi.md#createdirectlink) | **Post** /CreateDirectLink | +*DirectLinkApi* | [**DeleteDirectLink**](docs/DirectLinkApi.md#deletedirectlink) | **Post** /DeleteDirectLink | +*DirectLinkApi* | [**ReadDirectLinks**](docs/DirectLinkApi.md#readdirectlinks) | **Post** /ReadDirectLinks | +*DirectLinkInterfaceApi* | [**CreateDirectLinkInterface**](docs/DirectLinkInterfaceApi.md#createdirectlinkinterface) | **Post** /CreateDirectLinkInterface | +*DirectLinkInterfaceApi* | [**DeleteDirectLinkInterface**](docs/DirectLinkInterfaceApi.md#deletedirectlinkinterface) | **Post** /DeleteDirectLinkInterface | +*DirectLinkInterfaceApi* | [**ReadDirectLinkInterfaces**](docs/DirectLinkInterfaceApi.md#readdirectlinkinterfaces) | **Post** /ReadDirectLinkInterfaces | +*FlexibleGpuApi* | [**CreateFlexibleGpu**](docs/FlexibleGpuApi.md#createflexiblegpu) | **Post** /CreateFlexibleGpu | +*FlexibleGpuApi* | [**DeleteFlexibleGpu**](docs/FlexibleGpuApi.md#deleteflexiblegpu) | **Post** /DeleteFlexibleGpu | +*FlexibleGpuApi* | [**LinkFlexibleGpu**](docs/FlexibleGpuApi.md#linkflexiblegpu) | **Post** /LinkFlexibleGpu | +*FlexibleGpuApi* | [**ReadFlexibleGpuCatalog**](docs/FlexibleGpuApi.md#readflexiblegpucatalog) | **Post** /ReadFlexibleGpuCatalog | +*FlexibleGpuApi* | [**ReadFlexibleGpus**](docs/FlexibleGpuApi.md#readflexiblegpus) | **Post** /ReadFlexibleGpus | +*FlexibleGpuApi* | [**UnlinkFlexibleGpu**](docs/FlexibleGpuApi.md#unlinkflexiblegpu) | **Post** /UnlinkFlexibleGpu | +*FlexibleGpuApi* | [**UpdateFlexibleGpu**](docs/FlexibleGpuApi.md#updateflexiblegpu) | **Post** /UpdateFlexibleGpu | +*ImageApi* | [**CreateImage**](docs/ImageApi.md#createimage) | **Post** /CreateImage | +*ImageApi* | [**CreateImageExportTask**](docs/ImageApi.md#createimageexporttask) | **Post** /CreateImageExportTask | +*ImageApi* | [**DeleteImage**](docs/ImageApi.md#deleteimage) | **Post** /DeleteImage | +*ImageApi* | [**ReadImageExportTasks**](docs/ImageApi.md#readimageexporttasks) | **Post** /ReadImageExportTasks | +*ImageApi* | [**ReadImages**](docs/ImageApi.md#readimages) | **Post** /ReadImages | +*ImageApi* | [**UpdateImage**](docs/ImageApi.md#updateimage) | **Post** /UpdateImage | +*InternetServiceApi* | [**CreateInternetService**](docs/InternetServiceApi.md#createinternetservice) | **Post** /CreateInternetService | +*InternetServiceApi* | [**DeleteInternetService**](docs/InternetServiceApi.md#deleteinternetservice) | **Post** /DeleteInternetService | +*InternetServiceApi* | [**LinkInternetService**](docs/InternetServiceApi.md#linkinternetservice) | **Post** /LinkInternetService | +*InternetServiceApi* | [**ReadInternetServices**](docs/InternetServiceApi.md#readinternetservices) | **Post** /ReadInternetServices | +*InternetServiceApi* | [**UnlinkInternetService**](docs/InternetServiceApi.md#unlinkinternetservice) | **Post** /UnlinkInternetService | +*KeypairApi* | [**CreateKeypair**](docs/KeypairApi.md#createkeypair) | **Post** /CreateKeypair | +*KeypairApi* | [**DeleteKeypair**](docs/KeypairApi.md#deletekeypair) | **Post** /DeleteKeypair | +*KeypairApi* | [**ReadKeypairs**](docs/KeypairApi.md#readkeypairs) | **Post** /ReadKeypairs | +*ListenerApi* | [**CreateListenerRule**](docs/ListenerApi.md#createlistenerrule) | **Post** /CreateListenerRule | +*ListenerApi* | [**CreateLoadBalancerListeners**](docs/ListenerApi.md#createloadbalancerlisteners) | **Post** /CreateLoadBalancerListeners | +*ListenerApi* | [**DeleteListenerRule**](docs/ListenerApi.md#deletelistenerrule) | **Post** /DeleteListenerRule | +*ListenerApi* | [**DeleteLoadBalancerListeners**](docs/ListenerApi.md#deleteloadbalancerlisteners) | **Post** /DeleteLoadBalancerListeners | +*ListenerApi* | [**ReadListenerRules**](docs/ListenerApi.md#readlistenerrules) | **Post** /ReadListenerRules | +*ListenerApi* | [**UpdateListenerRule**](docs/ListenerApi.md#updatelistenerrule) | **Post** /UpdateListenerRule | +*LoadBalancerApi* | [**CreateLoadBalancer**](docs/LoadBalancerApi.md#createloadbalancer) | **Post** /CreateLoadBalancer | +*LoadBalancerApi* | [**CreateLoadBalancerTags**](docs/LoadBalancerApi.md#createloadbalancertags) | **Post** /CreateLoadBalancerTags | +*LoadBalancerApi* | [**DeleteLoadBalancer**](docs/LoadBalancerApi.md#deleteloadbalancer) | **Post** /DeleteLoadBalancer | +*LoadBalancerApi* | [**DeleteLoadBalancerTags**](docs/LoadBalancerApi.md#deleteloadbalancertags) | **Post** /DeleteLoadBalancerTags | +*LoadBalancerApi* | [**DeregisterVmsInLoadBalancer**](docs/LoadBalancerApi.md#deregistervmsinloadbalancer) | **Post** /DeregisterVmsInLoadBalancer | +*LoadBalancerApi* | [**ReadLoadBalancerTags**](docs/LoadBalancerApi.md#readloadbalancertags) | **Post** /ReadLoadBalancerTags | +*LoadBalancerApi* | [**ReadLoadBalancers**](docs/LoadBalancerApi.md#readloadbalancers) | **Post** /ReadLoadBalancers | +*LoadBalancerApi* | [**ReadVmsHealth**](docs/LoadBalancerApi.md#readvmshealth) | **Post** /ReadVmsHealth | +*LoadBalancerApi* | [**RegisterVmsInLoadBalancer**](docs/LoadBalancerApi.md#registervmsinloadbalancer) | **Post** /RegisterVmsInLoadBalancer | +*LoadBalancerApi* | [**UpdateLoadBalancer**](docs/LoadBalancerApi.md#updateloadbalancer) | **Post** /UpdateLoadBalancer | +*LoadBalancerPolicyApi* | [**CreateLoadBalancerPolicy**](docs/LoadBalancerPolicyApi.md#createloadbalancerpolicy) | **Post** /CreateLoadBalancerPolicy | +*LoadBalancerPolicyApi* | [**DeleteLoadBalancerPolicy**](docs/LoadBalancerPolicyApi.md#deleteloadbalancerpolicy) | **Post** /DeleteLoadBalancerPolicy | +*LocationApi* | [**ReadLocations**](docs/LocationApi.md#readlocations) | **Post** /ReadLocations | +*NatServiceApi* | [**CreateNatService**](docs/NatServiceApi.md#createnatservice) | **Post** /CreateNatService | +*NatServiceApi* | [**DeleteNatService**](docs/NatServiceApi.md#deletenatservice) | **Post** /DeleteNatService | +*NatServiceApi* | [**ReadNatServices**](docs/NatServiceApi.md#readnatservices) | **Post** /ReadNatServices | +*NetApi* | [**CreateNet**](docs/NetApi.md#createnet) | **Post** /CreateNet | +*NetApi* | [**DeleteNet**](docs/NetApi.md#deletenet) | **Post** /DeleteNet | +*NetApi* | [**ReadNets**](docs/NetApi.md#readnets) | **Post** /ReadNets | +*NetApi* | [**UpdateNet**](docs/NetApi.md#updatenet) | **Post** /UpdateNet | +*NetAccessPointApi* | [**CreateNetAccessPoint**](docs/NetAccessPointApi.md#createnetaccesspoint) | **Post** /CreateNetAccessPoint | +*NetAccessPointApi* | [**DeleteNetAccessPoint**](docs/NetAccessPointApi.md#deletenetaccesspoint) | **Post** /DeleteNetAccessPoint | +*NetAccessPointApi* | [**ReadNetAccessPointServices**](docs/NetAccessPointApi.md#readnetaccesspointservices) | **Post** /ReadNetAccessPointServices | +*NetAccessPointApi* | [**ReadNetAccessPoints**](docs/NetAccessPointApi.md#readnetaccesspoints) | **Post** /ReadNetAccessPoints | +*NetAccessPointApi* | [**UpdateNetAccessPoint**](docs/NetAccessPointApi.md#updatenetaccesspoint) | **Post** /UpdateNetAccessPoint | +*NetPeeringApi* | [**AcceptNetPeering**](docs/NetPeeringApi.md#acceptnetpeering) | **Post** /AcceptNetPeering | +*NetPeeringApi* | [**CreateNetPeering**](docs/NetPeeringApi.md#createnetpeering) | **Post** /CreateNetPeering | +*NetPeeringApi* | [**DeleteNetPeering**](docs/NetPeeringApi.md#deletenetpeering) | **Post** /DeleteNetPeering | +*NetPeeringApi* | [**ReadNetPeerings**](docs/NetPeeringApi.md#readnetpeerings) | **Post** /ReadNetPeerings | +*NetPeeringApi* | [**RejectNetPeering**](docs/NetPeeringApi.md#rejectnetpeering) | **Post** /RejectNetPeering | +*NicApi* | [**CreateNic**](docs/NicApi.md#createnic) | **Post** /CreateNic | +*NicApi* | [**DeleteNic**](docs/NicApi.md#deletenic) | **Post** /DeleteNic | +*NicApi* | [**LinkNic**](docs/NicApi.md#linknic) | **Post** /LinkNic | +*NicApi* | [**LinkPrivateIps**](docs/NicApi.md#linkprivateips) | **Post** /LinkPrivateIps | +*NicApi* | [**ReadNics**](docs/NicApi.md#readnics) | **Post** /ReadNics | +*NicApi* | [**UnlinkNic**](docs/NicApi.md#unlinknic) | **Post** /UnlinkNic | +*NicApi* | [**UnlinkPrivateIps**](docs/NicApi.md#unlinkprivateips) | **Post** /UnlinkPrivateIps | +*NicApi* | [**UpdateNic**](docs/NicApi.md#updatenic) | **Post** /UpdateNic | +*ProductTypeApi* | [**ReadProductTypes**](docs/ProductTypeApi.md#readproducttypes) | **Post** /ReadProductTypes | +*PublicIpApi* | [**CreatePublicIp**](docs/PublicIpApi.md#createpublicip) | **Post** /CreatePublicIp | +*PublicIpApi* | [**DeletePublicIp**](docs/PublicIpApi.md#deletepublicip) | **Post** /DeletePublicIp | +*PublicIpApi* | [**LinkPublicIp**](docs/PublicIpApi.md#linkpublicip) | **Post** /LinkPublicIp | +*PublicIpApi* | [**ReadPublicIpRanges**](docs/PublicIpApi.md#readpublicipranges) | **Post** /ReadPublicIpRanges | +*PublicIpApi* | [**ReadPublicIps**](docs/PublicIpApi.md#readpublicips) | **Post** /ReadPublicIps | +*PublicIpApi* | [**UnlinkPublicIp**](docs/PublicIpApi.md#unlinkpublicip) | **Post** /UnlinkPublicIp | +*QuotaApi* | [**ReadQuotas**](docs/QuotaApi.md#readquotas) | **Post** /ReadQuotas | +*RegionApi* | [**ReadRegions**](docs/RegionApi.md#readregions) | **Post** /ReadRegions | +*RouteApi* | [**CreateRoute**](docs/RouteApi.md#createroute) | **Post** /CreateRoute | +*RouteApi* | [**DeleteRoute**](docs/RouteApi.md#deleteroute) | **Post** /DeleteRoute | +*RouteApi* | [**UpdateRoute**](docs/RouteApi.md#updateroute) | **Post** /UpdateRoute | +*RouteTableApi* | [**CreateRouteTable**](docs/RouteTableApi.md#createroutetable) | **Post** /CreateRouteTable | +*RouteTableApi* | [**DeleteRouteTable**](docs/RouteTableApi.md#deleteroutetable) | **Post** /DeleteRouteTable | +*RouteTableApi* | [**LinkRouteTable**](docs/RouteTableApi.md#linkroutetable) | **Post** /LinkRouteTable | +*RouteTableApi* | [**ReadRouteTables**](docs/RouteTableApi.md#readroutetables) | **Post** /ReadRouteTables | +*RouteTableApi* | [**UnlinkRouteTable**](docs/RouteTableApi.md#unlinkroutetable) | **Post** /UnlinkRouteTable | +*SecurityGroupApi* | [**CreateSecurityGroup**](docs/SecurityGroupApi.md#createsecuritygroup) | **Post** /CreateSecurityGroup | +*SecurityGroupApi* | [**DeleteSecurityGroup**](docs/SecurityGroupApi.md#deletesecuritygroup) | **Post** /DeleteSecurityGroup | +*SecurityGroupApi* | [**ReadSecurityGroups**](docs/SecurityGroupApi.md#readsecuritygroups) | **Post** /ReadSecurityGroups | +*SecurityGroupRuleApi* | [**CreateSecurityGroupRule**](docs/SecurityGroupRuleApi.md#createsecuritygrouprule) | **Post** /CreateSecurityGroupRule | +*SecurityGroupRuleApi* | [**DeleteSecurityGroupRule**](docs/SecurityGroupRuleApi.md#deletesecuritygrouprule) | **Post** /DeleteSecurityGroupRule | +*ServerCertificateApi* | [**CreateServerCertificate**](docs/ServerCertificateApi.md#createservercertificate) | **Post** /CreateServerCertificate | +*ServerCertificateApi* | [**DeleteServerCertificate**](docs/ServerCertificateApi.md#deleteservercertificate) | **Post** /DeleteServerCertificate | +*ServerCertificateApi* | [**ReadServerCertificates**](docs/ServerCertificateApi.md#readservercertificates) | **Post** /ReadServerCertificates | +*ServerCertificateApi* | [**UpdateServerCertificate**](docs/ServerCertificateApi.md#updateservercertificate) | **Post** /UpdateServerCertificate | +*SnapshotApi* | [**CreateSnapshot**](docs/SnapshotApi.md#createsnapshot) | **Post** /CreateSnapshot | +*SnapshotApi* | [**CreateSnapshotExportTask**](docs/SnapshotApi.md#createsnapshotexporttask) | **Post** /CreateSnapshotExportTask | +*SnapshotApi* | [**DeleteSnapshot**](docs/SnapshotApi.md#deletesnapshot) | **Post** /DeleteSnapshot | +*SnapshotApi* | [**ReadSnapshotExportTasks**](docs/SnapshotApi.md#readsnapshotexporttasks) | **Post** /ReadSnapshotExportTasks | +*SnapshotApi* | [**ReadSnapshots**](docs/SnapshotApi.md#readsnapshots) | **Post** /ReadSnapshots | +*SnapshotApi* | [**UpdateSnapshot**](docs/SnapshotApi.md#updatesnapshot) | **Post** /UpdateSnapshot | +*SubnetApi* | [**CreateSubnet**](docs/SubnetApi.md#createsubnet) | **Post** /CreateSubnet | +*SubnetApi* | [**DeleteSubnet**](docs/SubnetApi.md#deletesubnet) | **Post** /DeleteSubnet | +*SubnetApi* | [**ReadSubnets**](docs/SubnetApi.md#readsubnets) | **Post** /ReadSubnets | +*SubnetApi* | [**UpdateSubnet**](docs/SubnetApi.md#updatesubnet) | **Post** /UpdateSubnet | +*SubregionApi* | [**ReadSubregions**](docs/SubregionApi.md#readsubregions) | **Post** /ReadSubregions | +*TagApi* | [**CreateTags**](docs/TagApi.md#createtags) | **Post** /CreateTags | +*TagApi* | [**DeleteTags**](docs/TagApi.md#deletetags) | **Post** /DeleteTags | +*TagApi* | [**ReadTags**](docs/TagApi.md#readtags) | **Post** /ReadTags | +*TaskApi* | [**DeleteExportTask**](docs/TaskApi.md#deleteexporttask) | **Post** /DeleteExportTask | +*VirtualGatewayApi* | [**CreateVirtualGateway**](docs/VirtualGatewayApi.md#createvirtualgateway) | **Post** /CreateVirtualGateway | +*VirtualGatewayApi* | [**DeleteVirtualGateway**](docs/VirtualGatewayApi.md#deletevirtualgateway) | **Post** /DeleteVirtualGateway | +*VirtualGatewayApi* | [**LinkVirtualGateway**](docs/VirtualGatewayApi.md#linkvirtualgateway) | **Post** /LinkVirtualGateway | +*VirtualGatewayApi* | [**ReadVirtualGateways**](docs/VirtualGatewayApi.md#readvirtualgateways) | **Post** /ReadVirtualGateways | +*VirtualGatewayApi* | [**UnlinkVirtualGateway**](docs/VirtualGatewayApi.md#unlinkvirtualgateway) | **Post** /UnlinkVirtualGateway | +*VirtualGatewayApi* | [**UpdateRoutePropagation**](docs/VirtualGatewayApi.md#updateroutepropagation) | **Post** /UpdateRoutePropagation | +*VmApi* | [**CreateVms**](docs/VmApi.md#createvms) | **Post** /CreateVms | +*VmApi* | [**DeleteVms**](docs/VmApi.md#deletevms) | **Post** /DeleteVms | +*VmApi* | [**ReadAdminPassword**](docs/VmApi.md#readadminpassword) | **Post** /ReadAdminPassword | +*VmApi* | [**ReadConsoleOutput**](docs/VmApi.md#readconsoleoutput) | **Post** /ReadConsoleOutput | +*VmApi* | [**ReadVmTypes**](docs/VmApi.md#readvmtypes) | **Post** /ReadVmTypes | +*VmApi* | [**ReadVms**](docs/VmApi.md#readvms) | **Post** /ReadVms | +*VmApi* | [**ReadVmsState**](docs/VmApi.md#readvmsstate) | **Post** /ReadVmsState | +*VmApi* | [**RebootVms**](docs/VmApi.md#rebootvms) | **Post** /RebootVms | +*VmApi* | [**StartVms**](docs/VmApi.md#startvms) | **Post** /StartVms | +*VmApi* | [**StopVms**](docs/VmApi.md#stopvms) | **Post** /StopVms | +*VmApi* | [**UpdateVm**](docs/VmApi.md#updatevm) | **Post** /UpdateVm | +*VolumeApi* | [**CreateVolume**](docs/VolumeApi.md#createvolume) | **Post** /CreateVolume | +*VolumeApi* | [**DeleteVolume**](docs/VolumeApi.md#deletevolume) | **Post** /DeleteVolume | +*VolumeApi* | [**LinkVolume**](docs/VolumeApi.md#linkvolume) | **Post** /LinkVolume | +*VolumeApi* | [**ReadVolumes**](docs/VolumeApi.md#readvolumes) | **Post** /ReadVolumes | +*VolumeApi* | [**UnlinkVolume**](docs/VolumeApi.md#unlinkvolume) | **Post** /UnlinkVolume | +*VpnConnectionApi* | [**CreateVpnConnection**](docs/VpnConnectionApi.md#createvpnconnection) | **Post** /CreateVpnConnection | +*VpnConnectionApi* | [**CreateVpnConnectionRoute**](docs/VpnConnectionApi.md#createvpnconnectionroute) | **Post** /CreateVpnConnectionRoute | +*VpnConnectionApi* | [**DeleteVpnConnection**](docs/VpnConnectionApi.md#deletevpnconnection) | **Post** /DeleteVpnConnection | +*VpnConnectionApi* | [**DeleteVpnConnectionRoute**](docs/VpnConnectionApi.md#deletevpnconnectionroute) | **Post** /DeleteVpnConnectionRoute | +*VpnConnectionApi* | [**ReadVpnConnections**](docs/VpnConnectionApi.md#readvpnconnections) | **Post** /ReadVpnConnections | + + +## Documentation For Models + + - [AcceptNetPeeringRequest](docs/AcceptNetPeeringRequest.md) + - [AcceptNetPeeringResponse](docs/AcceptNetPeeringResponse.md) + - [AccepterNet](docs/AccepterNet.md) + - [AccessKey](docs/AccessKey.md) + - [AccessKeySecretKey](docs/AccessKeySecretKey.md) + - [AccessLog](docs/AccessLog.md) + - [Account](docs/Account.md) + - [ApplicationStickyCookiePolicy](docs/ApplicationStickyCookiePolicy.md) + - [BackendVmHealth](docs/BackendVmHealth.md) + - [BlockDeviceMappingCreated](docs/BlockDeviceMappingCreated.md) + - [BlockDeviceMappingImage](docs/BlockDeviceMappingImage.md) + - [BlockDeviceMappingVmCreation](docs/BlockDeviceMappingVmCreation.md) + - [BlockDeviceMappingVmUpdate](docs/BlockDeviceMappingVmUpdate.md) + - [BsuCreated](docs/BsuCreated.md) + - [BsuToCreate](docs/BsuToCreate.md) + - [BsuToUpdateVm](docs/BsuToUpdateVm.md) + - [CheckAuthenticationRequest](docs/CheckAuthenticationRequest.md) + - [CheckAuthenticationResponse](docs/CheckAuthenticationResponse.md) + - [ClientGateway](docs/ClientGateway.md) + - [ConsumptionEntry](docs/ConsumptionEntry.md) + - [CreateAccessKeyRequest](docs/CreateAccessKeyRequest.md) + - [CreateAccessKeyResponse](docs/CreateAccessKeyResponse.md) + - [CreateAccountRequest](docs/CreateAccountRequest.md) + - [CreateAccountResponse](docs/CreateAccountResponse.md) + - [CreateClientGatewayRequest](docs/CreateClientGatewayRequest.md) + - [CreateClientGatewayResponse](docs/CreateClientGatewayResponse.md) + - [CreateDhcpOptionsRequest](docs/CreateDhcpOptionsRequest.md) + - [CreateDhcpOptionsResponse](docs/CreateDhcpOptionsResponse.md) + - [CreateDirectLinkInterfaceRequest](docs/CreateDirectLinkInterfaceRequest.md) + - [CreateDirectLinkInterfaceResponse](docs/CreateDirectLinkInterfaceResponse.md) + - [CreateDirectLinkRequest](docs/CreateDirectLinkRequest.md) + - [CreateDirectLinkResponse](docs/CreateDirectLinkResponse.md) + - [CreateFlexibleGpuRequest](docs/CreateFlexibleGpuRequest.md) + - [CreateFlexibleGpuResponse](docs/CreateFlexibleGpuResponse.md) + - [CreateImageExportTaskRequest](docs/CreateImageExportTaskRequest.md) + - [CreateImageExportTaskResponse](docs/CreateImageExportTaskResponse.md) + - [CreateImageRequest](docs/CreateImageRequest.md) + - [CreateImageResponse](docs/CreateImageResponse.md) + - [CreateInternetServiceRequest](docs/CreateInternetServiceRequest.md) + - [CreateInternetServiceResponse](docs/CreateInternetServiceResponse.md) + - [CreateKeypairRequest](docs/CreateKeypairRequest.md) + - [CreateKeypairResponse](docs/CreateKeypairResponse.md) + - [CreateListenerRuleRequest](docs/CreateListenerRuleRequest.md) + - [CreateListenerRuleResponse](docs/CreateListenerRuleResponse.md) + - [CreateLoadBalancerListenersRequest](docs/CreateLoadBalancerListenersRequest.md) + - [CreateLoadBalancerListenersResponse](docs/CreateLoadBalancerListenersResponse.md) + - [CreateLoadBalancerPolicyRequest](docs/CreateLoadBalancerPolicyRequest.md) + - [CreateLoadBalancerPolicyResponse](docs/CreateLoadBalancerPolicyResponse.md) + - [CreateLoadBalancerRequest](docs/CreateLoadBalancerRequest.md) + - [CreateLoadBalancerResponse](docs/CreateLoadBalancerResponse.md) + - [CreateLoadBalancerTagsRequest](docs/CreateLoadBalancerTagsRequest.md) + - [CreateLoadBalancerTagsResponse](docs/CreateLoadBalancerTagsResponse.md) + - [CreateNatServiceRequest](docs/CreateNatServiceRequest.md) + - [CreateNatServiceResponse](docs/CreateNatServiceResponse.md) + - [CreateNetAccessPointRequest](docs/CreateNetAccessPointRequest.md) + - [CreateNetAccessPointResponse](docs/CreateNetAccessPointResponse.md) + - [CreateNetPeeringRequest](docs/CreateNetPeeringRequest.md) + - [CreateNetPeeringResponse](docs/CreateNetPeeringResponse.md) + - [CreateNetRequest](docs/CreateNetRequest.md) + - [CreateNetResponse](docs/CreateNetResponse.md) + - [CreateNicRequest](docs/CreateNicRequest.md) + - [CreateNicResponse](docs/CreateNicResponse.md) + - [CreatePublicIpRequest](docs/CreatePublicIpRequest.md) + - [CreatePublicIpResponse](docs/CreatePublicIpResponse.md) + - [CreateRouteRequest](docs/CreateRouteRequest.md) + - [CreateRouteResponse](docs/CreateRouteResponse.md) + - [CreateRouteTableRequest](docs/CreateRouteTableRequest.md) + - [CreateRouteTableResponse](docs/CreateRouteTableResponse.md) + - [CreateSecurityGroupRequest](docs/CreateSecurityGroupRequest.md) + - [CreateSecurityGroupResponse](docs/CreateSecurityGroupResponse.md) + - [CreateSecurityGroupRuleRequest](docs/CreateSecurityGroupRuleRequest.md) + - [CreateSecurityGroupRuleResponse](docs/CreateSecurityGroupRuleResponse.md) + - [CreateServerCertificateRequest](docs/CreateServerCertificateRequest.md) + - [CreateServerCertificateResponse](docs/CreateServerCertificateResponse.md) + - [CreateSnapshotExportTaskRequest](docs/CreateSnapshotExportTaskRequest.md) + - [CreateSnapshotExportTaskResponse](docs/CreateSnapshotExportTaskResponse.md) + - [CreateSnapshotRequest](docs/CreateSnapshotRequest.md) + - [CreateSnapshotResponse](docs/CreateSnapshotResponse.md) + - [CreateSubnetRequest](docs/CreateSubnetRequest.md) + - [CreateSubnetResponse](docs/CreateSubnetResponse.md) + - [CreateTagsRequest](docs/CreateTagsRequest.md) + - [CreateTagsResponse](docs/CreateTagsResponse.md) + - [CreateVirtualGatewayRequest](docs/CreateVirtualGatewayRequest.md) + - [CreateVirtualGatewayResponse](docs/CreateVirtualGatewayResponse.md) + - [CreateVmsRequest](docs/CreateVmsRequest.md) + - [CreateVmsResponse](docs/CreateVmsResponse.md) + - [CreateVolumeRequest](docs/CreateVolumeRequest.md) + - [CreateVolumeResponse](docs/CreateVolumeResponse.md) + - [CreateVpnConnectionRequest](docs/CreateVpnConnectionRequest.md) + - [CreateVpnConnectionResponse](docs/CreateVpnConnectionResponse.md) + - [CreateVpnConnectionRouteRequest](docs/CreateVpnConnectionRouteRequest.md) + - [CreateVpnConnectionRouteResponse](docs/CreateVpnConnectionRouteResponse.md) + - [DeleteAccessKeyRequest](docs/DeleteAccessKeyRequest.md) + - [DeleteAccessKeyResponse](docs/DeleteAccessKeyResponse.md) + - [DeleteClientGatewayRequest](docs/DeleteClientGatewayRequest.md) + - [DeleteClientGatewayResponse](docs/DeleteClientGatewayResponse.md) + - [DeleteDhcpOptionsRequest](docs/DeleteDhcpOptionsRequest.md) + - [DeleteDhcpOptionsResponse](docs/DeleteDhcpOptionsResponse.md) + - [DeleteDirectLinkInterfaceRequest](docs/DeleteDirectLinkInterfaceRequest.md) + - [DeleteDirectLinkInterfaceResponse](docs/DeleteDirectLinkInterfaceResponse.md) + - [DeleteDirectLinkRequest](docs/DeleteDirectLinkRequest.md) + - [DeleteDirectLinkResponse](docs/DeleteDirectLinkResponse.md) + - [DeleteExportTaskRequest](docs/DeleteExportTaskRequest.md) + - [DeleteExportTaskResponse](docs/DeleteExportTaskResponse.md) + - [DeleteFlexibleGpuRequest](docs/DeleteFlexibleGpuRequest.md) + - [DeleteFlexibleGpuResponse](docs/DeleteFlexibleGpuResponse.md) + - [DeleteImageRequest](docs/DeleteImageRequest.md) + - [DeleteImageResponse](docs/DeleteImageResponse.md) + - [DeleteInternetServiceRequest](docs/DeleteInternetServiceRequest.md) + - [DeleteInternetServiceResponse](docs/DeleteInternetServiceResponse.md) + - [DeleteKeypairRequest](docs/DeleteKeypairRequest.md) + - [DeleteKeypairResponse](docs/DeleteKeypairResponse.md) + - [DeleteListenerRuleRequest](docs/DeleteListenerRuleRequest.md) + - [DeleteListenerRuleResponse](docs/DeleteListenerRuleResponse.md) + - [DeleteLoadBalancerListenersRequest](docs/DeleteLoadBalancerListenersRequest.md) + - [DeleteLoadBalancerListenersResponse](docs/DeleteLoadBalancerListenersResponse.md) + - [DeleteLoadBalancerPolicyRequest](docs/DeleteLoadBalancerPolicyRequest.md) + - [DeleteLoadBalancerPolicyResponse](docs/DeleteLoadBalancerPolicyResponse.md) + - [DeleteLoadBalancerRequest](docs/DeleteLoadBalancerRequest.md) + - [DeleteLoadBalancerResponse](docs/DeleteLoadBalancerResponse.md) + - [DeleteLoadBalancerTagsRequest](docs/DeleteLoadBalancerTagsRequest.md) + - [DeleteLoadBalancerTagsResponse](docs/DeleteLoadBalancerTagsResponse.md) + - [DeleteNatServiceRequest](docs/DeleteNatServiceRequest.md) + - [DeleteNatServiceResponse](docs/DeleteNatServiceResponse.md) + - [DeleteNetAccessPointRequest](docs/DeleteNetAccessPointRequest.md) + - [DeleteNetAccessPointResponse](docs/DeleteNetAccessPointResponse.md) + - [DeleteNetPeeringRequest](docs/DeleteNetPeeringRequest.md) + - [DeleteNetPeeringResponse](docs/DeleteNetPeeringResponse.md) + - [DeleteNetRequest](docs/DeleteNetRequest.md) + - [DeleteNetResponse](docs/DeleteNetResponse.md) + - [DeleteNicRequest](docs/DeleteNicRequest.md) + - [DeleteNicResponse](docs/DeleteNicResponse.md) + - [DeletePublicIpRequest](docs/DeletePublicIpRequest.md) + - [DeletePublicIpResponse](docs/DeletePublicIpResponse.md) + - [DeleteRouteRequest](docs/DeleteRouteRequest.md) + - [DeleteRouteResponse](docs/DeleteRouteResponse.md) + - [DeleteRouteTableRequest](docs/DeleteRouteTableRequest.md) + - [DeleteRouteTableResponse](docs/DeleteRouteTableResponse.md) + - [DeleteSecurityGroupRequest](docs/DeleteSecurityGroupRequest.md) + - [DeleteSecurityGroupResponse](docs/DeleteSecurityGroupResponse.md) + - [DeleteSecurityGroupRuleRequest](docs/DeleteSecurityGroupRuleRequest.md) + - [DeleteSecurityGroupRuleResponse](docs/DeleteSecurityGroupRuleResponse.md) + - [DeleteServerCertificateRequest](docs/DeleteServerCertificateRequest.md) + - [DeleteServerCertificateResponse](docs/DeleteServerCertificateResponse.md) + - [DeleteSnapshotRequest](docs/DeleteSnapshotRequest.md) + - [DeleteSnapshotResponse](docs/DeleteSnapshotResponse.md) + - [DeleteSubnetRequest](docs/DeleteSubnetRequest.md) + - [DeleteSubnetResponse](docs/DeleteSubnetResponse.md) + - [DeleteTagsRequest](docs/DeleteTagsRequest.md) + - [DeleteTagsResponse](docs/DeleteTagsResponse.md) + - [DeleteVirtualGatewayRequest](docs/DeleteVirtualGatewayRequest.md) + - [DeleteVirtualGatewayResponse](docs/DeleteVirtualGatewayResponse.md) + - [DeleteVmsRequest](docs/DeleteVmsRequest.md) + - [DeleteVmsResponse](docs/DeleteVmsResponse.md) + - [DeleteVolumeRequest](docs/DeleteVolumeRequest.md) + - [DeleteVolumeResponse](docs/DeleteVolumeResponse.md) + - [DeleteVpnConnectionRequest](docs/DeleteVpnConnectionRequest.md) + - [DeleteVpnConnectionResponse](docs/DeleteVpnConnectionResponse.md) + - [DeleteVpnConnectionRouteRequest](docs/DeleteVpnConnectionRouteRequest.md) + - [DeleteVpnConnectionRouteResponse](docs/DeleteVpnConnectionRouteResponse.md) + - [DeregisterVmsInLoadBalancerRequest](docs/DeregisterVmsInLoadBalancerRequest.md) + - [DeregisterVmsInLoadBalancerResponse](docs/DeregisterVmsInLoadBalancerResponse.md) + - [DhcpOptionsSet](docs/DhcpOptionsSet.md) + - [DirectLink](docs/DirectLink.md) + - [DirectLinkInterface](docs/DirectLinkInterface.md) + - [DirectLinkInterfaces](docs/DirectLinkInterfaces.md) + - [ErrorResponse](docs/ErrorResponse.md) + - [Errors](docs/Errors.md) + - [FiltersAccessKeys](docs/FiltersAccessKeys.md) + - [FiltersApiLog](docs/FiltersApiLog.md) + - [FiltersClientGateway](docs/FiltersClientGateway.md) + - [FiltersDhcpOptions](docs/FiltersDhcpOptions.md) + - [FiltersDirectLink](docs/FiltersDirectLink.md) + - [FiltersDirectLinkInterface](docs/FiltersDirectLinkInterface.md) + - [FiltersExportTask](docs/FiltersExportTask.md) + - [FiltersFlexibleGpu](docs/FiltersFlexibleGpu.md) + - [FiltersImage](docs/FiltersImage.md) + - [FiltersInternetService](docs/FiltersInternetService.md) + - [FiltersKeypair](docs/FiltersKeypair.md) + - [FiltersListenerRule](docs/FiltersListenerRule.md) + - [FiltersLoadBalancer](docs/FiltersLoadBalancer.md) + - [FiltersNatService](docs/FiltersNatService.md) + - [FiltersNet](docs/FiltersNet.md) + - [FiltersNetAccessPoint](docs/FiltersNetAccessPoint.md) + - [FiltersNetPeering](docs/FiltersNetPeering.md) + - [FiltersNic](docs/FiltersNic.md) + - [FiltersProductType](docs/FiltersProductType.md) + - [FiltersPublicIp](docs/FiltersPublicIp.md) + - [FiltersQuota](docs/FiltersQuota.md) + - [FiltersRouteTable](docs/FiltersRouteTable.md) + - [FiltersSecurityGroup](docs/FiltersSecurityGroup.md) + - [FiltersServerCertificate](docs/FiltersServerCertificate.md) + - [FiltersService](docs/FiltersService.md) + - [FiltersSnapshot](docs/FiltersSnapshot.md) + - [FiltersSubnet](docs/FiltersSubnet.md) + - [FiltersSubregion](docs/FiltersSubregion.md) + - [FiltersTag](docs/FiltersTag.md) + - [FiltersVirtualGateway](docs/FiltersVirtualGateway.md) + - [FiltersVm](docs/FiltersVm.md) + - [FiltersVmType](docs/FiltersVmType.md) + - [FiltersVmsState](docs/FiltersVmsState.md) + - [FiltersVolume](docs/FiltersVolume.md) + - [FiltersVpnConnection](docs/FiltersVpnConnection.md) + - [FlexibleGpu](docs/FlexibleGpu.md) + - [FlexibleGpuCatalog](docs/FlexibleGpuCatalog.md) + - [HealthCheck](docs/HealthCheck.md) + - [Image](docs/Image.md) + - [ImageExportTask](docs/ImageExportTask.md) + - [InternetService](docs/InternetService.md) + - [Keypair](docs/Keypair.md) + - [KeypairCreated](docs/KeypairCreated.md) + - [LinkFlexibleGpuRequest](docs/LinkFlexibleGpuRequest.md) + - [LinkFlexibleGpuResponse](docs/LinkFlexibleGpuResponse.md) + - [LinkInternetServiceRequest](docs/LinkInternetServiceRequest.md) + - [LinkInternetServiceResponse](docs/LinkInternetServiceResponse.md) + - [LinkNic](docs/LinkNic.md) + - [LinkNicLight](docs/LinkNicLight.md) + - [LinkNicRequest](docs/LinkNicRequest.md) + - [LinkNicResponse](docs/LinkNicResponse.md) + - [LinkNicToUpdate](docs/LinkNicToUpdate.md) + - [LinkPrivateIpsRequest](docs/LinkPrivateIpsRequest.md) + - [LinkPrivateIpsResponse](docs/LinkPrivateIpsResponse.md) + - [LinkPublicIp](docs/LinkPublicIp.md) + - [LinkPublicIpLightForVm](docs/LinkPublicIpLightForVm.md) + - [LinkPublicIpRequest](docs/LinkPublicIpRequest.md) + - [LinkPublicIpResponse](docs/LinkPublicIpResponse.md) + - [LinkRouteTable](docs/LinkRouteTable.md) + - [LinkRouteTableRequest](docs/LinkRouteTableRequest.md) + - [LinkRouteTableResponse](docs/LinkRouteTableResponse.md) + - [LinkVirtualGatewayRequest](docs/LinkVirtualGatewayRequest.md) + - [LinkVirtualGatewayResponse](docs/LinkVirtualGatewayResponse.md) + - [LinkVolumeRequest](docs/LinkVolumeRequest.md) + - [LinkVolumeResponse](docs/LinkVolumeResponse.md) + - [LinkedVolume](docs/LinkedVolume.md) + - [Listener](docs/Listener.md) + - [ListenerForCreation](docs/ListenerForCreation.md) + - [ListenerRule](docs/ListenerRule.md) + - [ListenerRuleForCreation](docs/ListenerRuleForCreation.md) + - [LoadBalancer](docs/LoadBalancer.md) + - [LoadBalancerLight](docs/LoadBalancerLight.md) + - [LoadBalancerStickyCookiePolicy](docs/LoadBalancerStickyCookiePolicy.md) + - [LoadBalancerTag](docs/LoadBalancerTag.md) + - [Location](docs/Location.md) + - [Log](docs/Log.md) + - [MaintenanceEvent](docs/MaintenanceEvent.md) + - [NatService](docs/NatService.md) + - [Net](docs/Net.md) + - [NetAccessPoint](docs/NetAccessPoint.md) + - [NetPeering](docs/NetPeering.md) + - [NetPeeringState](docs/NetPeeringState.md) + - [NetToVirtualGatewayLink](docs/NetToVirtualGatewayLink.md) + - [Nic](docs/Nic.md) + - [NicForVmCreation](docs/NicForVmCreation.md) + - [NicLight](docs/NicLight.md) + - [OsuApiKey](docs/OsuApiKey.md) + - [OsuExport](docs/OsuExport.md) + - [PermissionsOnResource](docs/PermissionsOnResource.md) + - [PermissionsOnResourceCreation](docs/PermissionsOnResourceCreation.md) + - [Placement](docs/Placement.md) + - [PrivateIp](docs/PrivateIp.md) + - [PrivateIpLight](docs/PrivateIpLight.md) + - [PrivateIpLightForVm](docs/PrivateIpLightForVm.md) + - [ProductType](docs/ProductType.md) + - [PublicIp](docs/PublicIp.md) + - [PublicIpLight](docs/PublicIpLight.md) + - [Quota](docs/Quota.md) + - [QuotaTypes](docs/QuotaTypes.md) + - [ReadAccessKeysRequest](docs/ReadAccessKeysRequest.md) + - [ReadAccessKeysResponse](docs/ReadAccessKeysResponse.md) + - [ReadAccountsRequest](docs/ReadAccountsRequest.md) + - [ReadAccountsResponse](docs/ReadAccountsResponse.md) + - [ReadAdminPasswordRequest](docs/ReadAdminPasswordRequest.md) + - [ReadAdminPasswordResponse](docs/ReadAdminPasswordResponse.md) + - [ReadApiLogsRequest](docs/ReadApiLogsRequest.md) + - [ReadApiLogsResponse](docs/ReadApiLogsResponse.md) + - [ReadClientGatewaysRequest](docs/ReadClientGatewaysRequest.md) + - [ReadClientGatewaysResponse](docs/ReadClientGatewaysResponse.md) + - [ReadConsoleOutputRequest](docs/ReadConsoleOutputRequest.md) + - [ReadConsoleOutputResponse](docs/ReadConsoleOutputResponse.md) + - [ReadConsumptionAccountRequest](docs/ReadConsumptionAccountRequest.md) + - [ReadConsumptionAccountResponse](docs/ReadConsumptionAccountResponse.md) + - [ReadDhcpOptionsRequest](docs/ReadDhcpOptionsRequest.md) + - [ReadDhcpOptionsResponse](docs/ReadDhcpOptionsResponse.md) + - [ReadDirectLinkInterfacesRequest](docs/ReadDirectLinkInterfacesRequest.md) + - [ReadDirectLinkInterfacesResponse](docs/ReadDirectLinkInterfacesResponse.md) + - [ReadDirectLinksRequest](docs/ReadDirectLinksRequest.md) + - [ReadDirectLinksResponse](docs/ReadDirectLinksResponse.md) + - [ReadFlexibleGpuCatalogRequest](docs/ReadFlexibleGpuCatalogRequest.md) + - [ReadFlexibleGpuCatalogResponse](docs/ReadFlexibleGpuCatalogResponse.md) + - [ReadFlexibleGpusRequest](docs/ReadFlexibleGpusRequest.md) + - [ReadFlexibleGpusResponse](docs/ReadFlexibleGpusResponse.md) + - [ReadImageExportTasksRequest](docs/ReadImageExportTasksRequest.md) + - [ReadImageExportTasksResponse](docs/ReadImageExportTasksResponse.md) + - [ReadImagesRequest](docs/ReadImagesRequest.md) + - [ReadImagesResponse](docs/ReadImagesResponse.md) + - [ReadInternetServicesRequest](docs/ReadInternetServicesRequest.md) + - [ReadInternetServicesResponse](docs/ReadInternetServicesResponse.md) + - [ReadKeypairsRequest](docs/ReadKeypairsRequest.md) + - [ReadKeypairsResponse](docs/ReadKeypairsResponse.md) + - [ReadListenerRulesRequest](docs/ReadListenerRulesRequest.md) + - [ReadListenerRulesResponse](docs/ReadListenerRulesResponse.md) + - [ReadLoadBalancerTagsRequest](docs/ReadLoadBalancerTagsRequest.md) + - [ReadLoadBalancerTagsResponse](docs/ReadLoadBalancerTagsResponse.md) + - [ReadLoadBalancersRequest](docs/ReadLoadBalancersRequest.md) + - [ReadLoadBalancersResponse](docs/ReadLoadBalancersResponse.md) + - [ReadLocationsRequest](docs/ReadLocationsRequest.md) + - [ReadLocationsResponse](docs/ReadLocationsResponse.md) + - [ReadNatServicesRequest](docs/ReadNatServicesRequest.md) + - [ReadNatServicesResponse](docs/ReadNatServicesResponse.md) + - [ReadNetAccessPointServicesRequest](docs/ReadNetAccessPointServicesRequest.md) + - [ReadNetAccessPointServicesResponse](docs/ReadNetAccessPointServicesResponse.md) + - [ReadNetAccessPointsRequest](docs/ReadNetAccessPointsRequest.md) + - [ReadNetAccessPointsResponse](docs/ReadNetAccessPointsResponse.md) + - [ReadNetPeeringsRequest](docs/ReadNetPeeringsRequest.md) + - [ReadNetPeeringsResponse](docs/ReadNetPeeringsResponse.md) + - [ReadNetsRequest](docs/ReadNetsRequest.md) + - [ReadNetsResponse](docs/ReadNetsResponse.md) + - [ReadNicsRequest](docs/ReadNicsRequest.md) + - [ReadNicsResponse](docs/ReadNicsResponse.md) + - [ReadProductTypesRequest](docs/ReadProductTypesRequest.md) + - [ReadProductTypesResponse](docs/ReadProductTypesResponse.md) + - [ReadPublicIpRangesRequest](docs/ReadPublicIpRangesRequest.md) + - [ReadPublicIpRangesResponse](docs/ReadPublicIpRangesResponse.md) + - [ReadPublicIpsRequest](docs/ReadPublicIpsRequest.md) + - [ReadPublicIpsResponse](docs/ReadPublicIpsResponse.md) + - [ReadQuotasRequest](docs/ReadQuotasRequest.md) + - [ReadQuotasResponse](docs/ReadQuotasResponse.md) + - [ReadRegionsRequest](docs/ReadRegionsRequest.md) + - [ReadRegionsResponse](docs/ReadRegionsResponse.md) + - [ReadRouteTablesRequest](docs/ReadRouteTablesRequest.md) + - [ReadRouteTablesResponse](docs/ReadRouteTablesResponse.md) + - [ReadSecretAccessKeyRequest](docs/ReadSecretAccessKeyRequest.md) + - [ReadSecretAccessKeyResponse](docs/ReadSecretAccessKeyResponse.md) + - [ReadSecurityGroupsRequest](docs/ReadSecurityGroupsRequest.md) + - [ReadSecurityGroupsResponse](docs/ReadSecurityGroupsResponse.md) + - [ReadServerCertificatesRequest](docs/ReadServerCertificatesRequest.md) + - [ReadServerCertificatesResponse](docs/ReadServerCertificatesResponse.md) + - [ReadSnapshotExportTasksRequest](docs/ReadSnapshotExportTasksRequest.md) + - [ReadSnapshotExportTasksResponse](docs/ReadSnapshotExportTasksResponse.md) + - [ReadSnapshotsRequest](docs/ReadSnapshotsRequest.md) + - [ReadSnapshotsResponse](docs/ReadSnapshotsResponse.md) + - [ReadSubnetsRequest](docs/ReadSubnetsRequest.md) + - [ReadSubnetsResponse](docs/ReadSubnetsResponse.md) + - [ReadSubregionsRequest](docs/ReadSubregionsRequest.md) + - [ReadSubregionsResponse](docs/ReadSubregionsResponse.md) + - [ReadTagsRequest](docs/ReadTagsRequest.md) + - [ReadTagsResponse](docs/ReadTagsResponse.md) + - [ReadVirtualGatewaysRequest](docs/ReadVirtualGatewaysRequest.md) + - [ReadVirtualGatewaysResponse](docs/ReadVirtualGatewaysResponse.md) + - [ReadVmTypesRequest](docs/ReadVmTypesRequest.md) + - [ReadVmTypesResponse](docs/ReadVmTypesResponse.md) + - [ReadVmsHealthRequest](docs/ReadVmsHealthRequest.md) + - [ReadVmsHealthResponse](docs/ReadVmsHealthResponse.md) + - [ReadVmsRequest](docs/ReadVmsRequest.md) + - [ReadVmsResponse](docs/ReadVmsResponse.md) + - [ReadVmsStateRequest](docs/ReadVmsStateRequest.md) + - [ReadVmsStateResponse](docs/ReadVmsStateResponse.md) + - [ReadVolumesRequest](docs/ReadVolumesRequest.md) + - [ReadVolumesResponse](docs/ReadVolumesResponse.md) + - [ReadVpnConnectionsRequest](docs/ReadVpnConnectionsRequest.md) + - [ReadVpnConnectionsResponse](docs/ReadVpnConnectionsResponse.md) + - [RebootVmsRequest](docs/RebootVmsRequest.md) + - [RebootVmsResponse](docs/RebootVmsResponse.md) + - [Region](docs/Region.md) + - [RegisterVmsInLoadBalancerRequest](docs/RegisterVmsInLoadBalancerRequest.md) + - [RegisterVmsInLoadBalancerResponse](docs/RegisterVmsInLoadBalancerResponse.md) + - [RejectNetPeeringRequest](docs/RejectNetPeeringRequest.md) + - [RejectNetPeeringResponse](docs/RejectNetPeeringResponse.md) + - [ResetAccountPasswordRequest](docs/ResetAccountPasswordRequest.md) + - [ResetAccountPasswordResponse](docs/ResetAccountPasswordResponse.md) + - [ResourceLoadBalancerTag](docs/ResourceLoadBalancerTag.md) + - [ResourceTag](docs/ResourceTag.md) + - [ResponseContext](docs/ResponseContext.md) + - [Route](docs/Route.md) + - [RouteLight](docs/RouteLight.md) + - [RoutePropagatingVirtualGateway](docs/RoutePropagatingVirtualGateway.md) + - [RouteTable](docs/RouteTable.md) + - [SecurityGroup](docs/SecurityGroup.md) + - [SecurityGroupLight](docs/SecurityGroupLight.md) + - [SecurityGroupRule](docs/SecurityGroupRule.md) + - [SecurityGroupsMember](docs/SecurityGroupsMember.md) + - [SendResetPasswordEmailRequest](docs/SendResetPasswordEmailRequest.md) + - [SendResetPasswordEmailResponse](docs/SendResetPasswordEmailResponse.md) + - [ServerCertificate](docs/ServerCertificate.md) + - [Service](docs/Service.md) + - [Snapshot](docs/Snapshot.md) + - [SnapshotExportTask](docs/SnapshotExportTask.md) + - [SourceNet](docs/SourceNet.md) + - [SourceSecurityGroup](docs/SourceSecurityGroup.md) + - [StartVmsRequest](docs/StartVmsRequest.md) + - [StartVmsResponse](docs/StartVmsResponse.md) + - [StateComment](docs/StateComment.md) + - [StopVmsRequest](docs/StopVmsRequest.md) + - [StopVmsResponse](docs/StopVmsResponse.md) + - [Subnet](docs/Subnet.md) + - [Subregion](docs/Subregion.md) + - [Tag](docs/Tag.md) + - [UnlinkFlexibleGpuRequest](docs/UnlinkFlexibleGpuRequest.md) + - [UnlinkFlexibleGpuResponse](docs/UnlinkFlexibleGpuResponse.md) + - [UnlinkInternetServiceRequest](docs/UnlinkInternetServiceRequest.md) + - [UnlinkInternetServiceResponse](docs/UnlinkInternetServiceResponse.md) + - [UnlinkNicRequest](docs/UnlinkNicRequest.md) + - [UnlinkNicResponse](docs/UnlinkNicResponse.md) + - [UnlinkPrivateIpsRequest](docs/UnlinkPrivateIpsRequest.md) + - [UnlinkPrivateIpsResponse](docs/UnlinkPrivateIpsResponse.md) + - [UnlinkPublicIpRequest](docs/UnlinkPublicIpRequest.md) + - [UnlinkPublicIpResponse](docs/UnlinkPublicIpResponse.md) + - [UnlinkRouteTableRequest](docs/UnlinkRouteTableRequest.md) + - [UnlinkRouteTableResponse](docs/UnlinkRouteTableResponse.md) + - [UnlinkVirtualGatewayRequest](docs/UnlinkVirtualGatewayRequest.md) + - [UnlinkVirtualGatewayResponse](docs/UnlinkVirtualGatewayResponse.md) + - [UnlinkVolumeRequest](docs/UnlinkVolumeRequest.md) + - [UnlinkVolumeResponse](docs/UnlinkVolumeResponse.md) + - [UpdateAccessKeyRequest](docs/UpdateAccessKeyRequest.md) + - [UpdateAccessKeyResponse](docs/UpdateAccessKeyResponse.md) + - [UpdateAccountRequest](docs/UpdateAccountRequest.md) + - [UpdateAccountResponse](docs/UpdateAccountResponse.md) + - [UpdateFlexibleGpuRequest](docs/UpdateFlexibleGpuRequest.md) + - [UpdateFlexibleGpuResponse](docs/UpdateFlexibleGpuResponse.md) + - [UpdateImageRequest](docs/UpdateImageRequest.md) + - [UpdateImageResponse](docs/UpdateImageResponse.md) + - [UpdateListenerRuleRequest](docs/UpdateListenerRuleRequest.md) + - [UpdateListenerRuleResponse](docs/UpdateListenerRuleResponse.md) + - [UpdateLoadBalancerRequest](docs/UpdateLoadBalancerRequest.md) + - [UpdateLoadBalancerResponse](docs/UpdateLoadBalancerResponse.md) + - [UpdateNetAccessPointRequest](docs/UpdateNetAccessPointRequest.md) + - [UpdateNetAccessPointResponse](docs/UpdateNetAccessPointResponse.md) + - [UpdateNetRequest](docs/UpdateNetRequest.md) + - [UpdateNetResponse](docs/UpdateNetResponse.md) + - [UpdateNicRequest](docs/UpdateNicRequest.md) + - [UpdateNicResponse](docs/UpdateNicResponse.md) + - [UpdateRoutePropagationRequest](docs/UpdateRoutePropagationRequest.md) + - [UpdateRoutePropagationResponse](docs/UpdateRoutePropagationResponse.md) + - [UpdateRouteRequest](docs/UpdateRouteRequest.md) + - [UpdateRouteResponse](docs/UpdateRouteResponse.md) + - [UpdateServerCertificateRequest](docs/UpdateServerCertificateRequest.md) + - [UpdateServerCertificateResponse](docs/UpdateServerCertificateResponse.md) + - [UpdateSnapshotRequest](docs/UpdateSnapshotRequest.md) + - [UpdateSnapshotResponse](docs/UpdateSnapshotResponse.md) + - [UpdateSubnetRequest](docs/UpdateSubnetRequest.md) + - [UpdateSubnetResponse](docs/UpdateSubnetResponse.md) + - [UpdateVmRequest](docs/UpdateVmRequest.md) + - [UpdateVmResponse](docs/UpdateVmResponse.md) + - [VirtualGateway](docs/VirtualGateway.md) + - [Vm](docs/Vm.md) + - [VmState](docs/VmState.md) + - [VmStates](docs/VmStates.md) + - [VmType](docs/VmType.md) + - [Volume](docs/Volume.md) + - [VpnConnection](docs/VpnConnection.md) + - [With](docs/With.md) + + +## Documentation For Authorization + + + +### ApiKeyAuth + +- **Type**: API key +- **API key parameter name**: Authorization +- **Location**: HTTP header + +Note, each API key must be added to a map of `map[string]APIKey` where the key is: Authorization and passed in as the auth context for each request. + + +## Documentation for Utility Methods + +Due to the fact that model structure members are all pointers, this package contains +a number of utility functions to easily obtain pointers to values of basic types. +Each of these functions takes a value of the given basic type and returns a pointer to it: + +* `PtrBool` +* `PtrInt` +* `PtrInt32` +* `PtrInt64` +* `PtrFloat` +* `PtrFloat32` +* `PtrFloat64` +* `PtrString` +* `PtrTime` + +## Author + +support@outscale.com + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go new file mode 100644 index 000000000..c24c5c90f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go @@ -0,0 +1,632 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// AccessKeyApiService AccessKeyApi service +type AccessKeyApiService service + +type ApiCreateAccessKeyRequest struct { + ctx _context.Context + ApiService *AccessKeyApiService + createAccessKeyRequest *CreateAccessKeyRequest +} + +func (r ApiCreateAccessKeyRequest) CreateAccessKeyRequest(createAccessKeyRequest CreateAccessKeyRequest) ApiCreateAccessKeyRequest { + r.createAccessKeyRequest = &createAccessKeyRequest + return r +} + +func (r ApiCreateAccessKeyRequest) Execute() (CreateAccessKeyResponse, *_nethttp.Response, error) { + return r.ApiService.CreateAccessKeyExecute(r) +} + +/* + * CreateAccessKey Method for CreateAccessKey + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateAccessKeyRequest + */ +func (a *AccessKeyApiService) CreateAccessKey(ctx _context.Context) ApiCreateAccessKeyRequest { + return ApiCreateAccessKeyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateAccessKeyResponse + */ +func (a *AccessKeyApiService) CreateAccessKeyExecute(r ApiCreateAccessKeyRequest) (CreateAccessKeyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateAccessKeyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccessKeyApiService.CreateAccessKey") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateAccessKey" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createAccessKeyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteAccessKeyRequest struct { + ctx _context.Context + ApiService *AccessKeyApiService + deleteAccessKeyRequest *DeleteAccessKeyRequest +} + +func (r ApiDeleteAccessKeyRequest) DeleteAccessKeyRequest(deleteAccessKeyRequest DeleteAccessKeyRequest) ApiDeleteAccessKeyRequest { + r.deleteAccessKeyRequest = &deleteAccessKeyRequest + return r +} + +func (r ApiDeleteAccessKeyRequest) Execute() (DeleteAccessKeyResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteAccessKeyExecute(r) +} + +/* + * DeleteAccessKey Method for DeleteAccessKey + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteAccessKeyRequest + */ +func (a *AccessKeyApiService) DeleteAccessKey(ctx _context.Context) ApiDeleteAccessKeyRequest { + return ApiDeleteAccessKeyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteAccessKeyResponse + */ +func (a *AccessKeyApiService) DeleteAccessKeyExecute(r ApiDeleteAccessKeyRequest) (DeleteAccessKeyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteAccessKeyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccessKeyApiService.DeleteAccessKey") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteAccessKey" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteAccessKeyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadAccessKeysRequest struct { + ctx _context.Context + ApiService *AccessKeyApiService + readAccessKeysRequest *ReadAccessKeysRequest +} + +func (r ApiReadAccessKeysRequest) ReadAccessKeysRequest(readAccessKeysRequest ReadAccessKeysRequest) ApiReadAccessKeysRequest { + r.readAccessKeysRequest = &readAccessKeysRequest + return r +} + +func (r ApiReadAccessKeysRequest) Execute() (ReadAccessKeysResponse, *_nethttp.Response, error) { + return r.ApiService.ReadAccessKeysExecute(r) +} + +/* + * ReadAccessKeys Method for ReadAccessKeys + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadAccessKeysRequest + */ +func (a *AccessKeyApiService) ReadAccessKeys(ctx _context.Context) ApiReadAccessKeysRequest { + return ApiReadAccessKeysRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadAccessKeysResponse + */ +func (a *AccessKeyApiService) ReadAccessKeysExecute(r ApiReadAccessKeysRequest) (ReadAccessKeysResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadAccessKeysResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccessKeyApiService.ReadAccessKeys") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadAccessKeys" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readAccessKeysRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadSecretAccessKeyRequest struct { + ctx _context.Context + ApiService *AccessKeyApiService + readSecretAccessKeyRequest *ReadSecretAccessKeyRequest +} + +func (r ApiReadSecretAccessKeyRequest) ReadSecretAccessKeyRequest(readSecretAccessKeyRequest ReadSecretAccessKeyRequest) ApiReadSecretAccessKeyRequest { + r.readSecretAccessKeyRequest = &readSecretAccessKeyRequest + return r +} + +func (r ApiReadSecretAccessKeyRequest) Execute() (ReadSecretAccessKeyResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSecretAccessKeyExecute(r) +} + +/* + * ReadSecretAccessKey Method for ReadSecretAccessKey + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSecretAccessKeyRequest + */ +func (a *AccessKeyApiService) ReadSecretAccessKey(ctx _context.Context) ApiReadSecretAccessKeyRequest { + return ApiReadSecretAccessKeyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSecretAccessKeyResponse + */ +func (a *AccessKeyApiService) ReadSecretAccessKeyExecute(r ApiReadSecretAccessKeyRequest) (ReadSecretAccessKeyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSecretAccessKeyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccessKeyApiService.ReadSecretAccessKey") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSecretAccessKey" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSecretAccessKeyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateAccessKeyRequest struct { + ctx _context.Context + ApiService *AccessKeyApiService + updateAccessKeyRequest *UpdateAccessKeyRequest +} + +func (r ApiUpdateAccessKeyRequest) UpdateAccessKeyRequest(updateAccessKeyRequest UpdateAccessKeyRequest) ApiUpdateAccessKeyRequest { + r.updateAccessKeyRequest = &updateAccessKeyRequest + return r +} + +func (r ApiUpdateAccessKeyRequest) Execute() (UpdateAccessKeyResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateAccessKeyExecute(r) +} + +/* + * UpdateAccessKey Method for UpdateAccessKey + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateAccessKeyRequest + */ +func (a *AccessKeyApiService) UpdateAccessKey(ctx _context.Context) ApiUpdateAccessKeyRequest { + return ApiUpdateAccessKeyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateAccessKeyResponse + */ +func (a *AccessKeyApiService) UpdateAccessKeyExecute(r ApiUpdateAccessKeyRequest) (UpdateAccessKeyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateAccessKeyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccessKeyApiService.UpdateAccessKey") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateAccessKey" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateAccessKeyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_account.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_account.go new file mode 100644 index 000000000..d95f9f42d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_account.go @@ -0,0 +1,874 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// AccountApiService AccountApi service +type AccountApiService service + +type ApiCheckAuthenticationRequest struct { + ctx _context.Context + ApiService *AccountApiService + checkAuthenticationRequest *CheckAuthenticationRequest +} + +func (r ApiCheckAuthenticationRequest) CheckAuthenticationRequest(checkAuthenticationRequest CheckAuthenticationRequest) ApiCheckAuthenticationRequest { + r.checkAuthenticationRequest = &checkAuthenticationRequest + return r +} + +func (r ApiCheckAuthenticationRequest) Execute() (CheckAuthenticationResponse, *_nethttp.Response, error) { + return r.ApiService.CheckAuthenticationExecute(r) +} + +/* + * CheckAuthentication Method for CheckAuthentication + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCheckAuthenticationRequest + */ +func (a *AccountApiService) CheckAuthentication(ctx _context.Context) ApiCheckAuthenticationRequest { + return ApiCheckAuthenticationRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CheckAuthenticationResponse + */ +func (a *AccountApiService) CheckAuthenticationExecute(r ApiCheckAuthenticationRequest) (CheckAuthenticationResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CheckAuthenticationResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.CheckAuthentication") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CheckAuthentication" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.checkAuthenticationRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateAccountRequest struct { + ctx _context.Context + ApiService *AccountApiService + createAccountRequest *CreateAccountRequest +} + +func (r ApiCreateAccountRequest) CreateAccountRequest(createAccountRequest CreateAccountRequest) ApiCreateAccountRequest { + r.createAccountRequest = &createAccountRequest + return r +} + +func (r ApiCreateAccountRequest) Execute() (CreateAccountResponse, *_nethttp.Response, error) { + return r.ApiService.CreateAccountExecute(r) +} + +/* + * CreateAccount Method for CreateAccount + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateAccountRequest + */ +func (a *AccountApiService) CreateAccount(ctx _context.Context) ApiCreateAccountRequest { + return ApiCreateAccountRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateAccountResponse + */ +func (a *AccountApiService) CreateAccountExecute(r ApiCreateAccountRequest) (CreateAccountResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateAccountResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.CreateAccount") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateAccount" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createAccountRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadAccountsRequest struct { + ctx _context.Context + ApiService *AccountApiService + readAccountsRequest *ReadAccountsRequest +} + +func (r ApiReadAccountsRequest) ReadAccountsRequest(readAccountsRequest ReadAccountsRequest) ApiReadAccountsRequest { + r.readAccountsRequest = &readAccountsRequest + return r +} + +func (r ApiReadAccountsRequest) Execute() (ReadAccountsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadAccountsExecute(r) +} + +/* + * ReadAccounts Method for ReadAccounts + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadAccountsRequest + */ +func (a *AccountApiService) ReadAccounts(ctx _context.Context) ApiReadAccountsRequest { + return ApiReadAccountsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadAccountsResponse + */ +func (a *AccountApiService) ReadAccountsExecute(r ApiReadAccountsRequest) (ReadAccountsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadAccountsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.ReadAccounts") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadAccounts" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readAccountsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadConsumptionAccountRequest struct { + ctx _context.Context + ApiService *AccountApiService + readConsumptionAccountRequest *ReadConsumptionAccountRequest +} + +func (r ApiReadConsumptionAccountRequest) ReadConsumptionAccountRequest(readConsumptionAccountRequest ReadConsumptionAccountRequest) ApiReadConsumptionAccountRequest { + r.readConsumptionAccountRequest = &readConsumptionAccountRequest + return r +} + +func (r ApiReadConsumptionAccountRequest) Execute() (ReadConsumptionAccountResponse, *_nethttp.Response, error) { + return r.ApiService.ReadConsumptionAccountExecute(r) +} + +/* + * ReadConsumptionAccount Method for ReadConsumptionAccount + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadConsumptionAccountRequest + */ +func (a *AccountApiService) ReadConsumptionAccount(ctx _context.Context) ApiReadConsumptionAccountRequest { + return ApiReadConsumptionAccountRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadConsumptionAccountResponse + */ +func (a *AccountApiService) ReadConsumptionAccountExecute(r ApiReadConsumptionAccountRequest) (ReadConsumptionAccountResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadConsumptionAccountResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.ReadConsumptionAccount") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadConsumptionAccount" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readConsumptionAccountRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiResetAccountPasswordRequest struct { + ctx _context.Context + ApiService *AccountApiService + resetAccountPasswordRequest *ResetAccountPasswordRequest +} + +func (r ApiResetAccountPasswordRequest) ResetAccountPasswordRequest(resetAccountPasswordRequest ResetAccountPasswordRequest) ApiResetAccountPasswordRequest { + r.resetAccountPasswordRequest = &resetAccountPasswordRequest + return r +} + +func (r ApiResetAccountPasswordRequest) Execute() (ResetAccountPasswordResponse, *_nethttp.Response, error) { + return r.ApiService.ResetAccountPasswordExecute(r) +} + +/* + * ResetAccountPassword Method for ResetAccountPassword + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiResetAccountPasswordRequest + */ +func (a *AccountApiService) ResetAccountPassword(ctx _context.Context) ApiResetAccountPasswordRequest { + return ApiResetAccountPasswordRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ResetAccountPasswordResponse + */ +func (a *AccountApiService) ResetAccountPasswordExecute(r ApiResetAccountPasswordRequest) (ResetAccountPasswordResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResetAccountPasswordResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.ResetAccountPassword") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ResetAccountPassword" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.resetAccountPasswordRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiSendResetPasswordEmailRequest struct { + ctx _context.Context + ApiService *AccountApiService + sendResetPasswordEmailRequest *SendResetPasswordEmailRequest +} + +func (r ApiSendResetPasswordEmailRequest) SendResetPasswordEmailRequest(sendResetPasswordEmailRequest SendResetPasswordEmailRequest) ApiSendResetPasswordEmailRequest { + r.sendResetPasswordEmailRequest = &sendResetPasswordEmailRequest + return r +} + +func (r ApiSendResetPasswordEmailRequest) Execute() (SendResetPasswordEmailResponse, *_nethttp.Response, error) { + return r.ApiService.SendResetPasswordEmailExecute(r) +} + +/* + * SendResetPasswordEmail Method for SendResetPasswordEmail + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiSendResetPasswordEmailRequest + */ +func (a *AccountApiService) SendResetPasswordEmail(ctx _context.Context) ApiSendResetPasswordEmailRequest { + return ApiSendResetPasswordEmailRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return SendResetPasswordEmailResponse + */ +func (a *AccountApiService) SendResetPasswordEmailExecute(r ApiSendResetPasswordEmailRequest) (SendResetPasswordEmailResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue SendResetPasswordEmailResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.SendResetPasswordEmail") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/SendResetPasswordEmail" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.sendResetPasswordEmailRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateAccountRequest struct { + ctx _context.Context + ApiService *AccountApiService + updateAccountRequest *UpdateAccountRequest +} + +func (r ApiUpdateAccountRequest) UpdateAccountRequest(updateAccountRequest UpdateAccountRequest) ApiUpdateAccountRequest { + r.updateAccountRequest = &updateAccountRequest + return r +} + +func (r ApiUpdateAccountRequest) Execute() (UpdateAccountResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateAccountExecute(r) +} + +/* + * UpdateAccount Method for UpdateAccount + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateAccountRequest + */ +func (a *AccountApiService) UpdateAccount(ctx _context.Context) ApiUpdateAccountRequest { + return ApiUpdateAccountRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateAccountResponse + */ +func (a *AccountApiService) UpdateAccountExecute(r ApiUpdateAccountRequest) (UpdateAccountResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateAccountResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "AccountApiService.UpdateAccount") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateAccount" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateAccountRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go new file mode 100644 index 000000000..3063e09c5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go @@ -0,0 +1,148 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ApiLogApiService ApiLogApi service +type ApiLogApiService service + +type ApiReadApiLogsRequest struct { + ctx _context.Context + ApiService *ApiLogApiService + readApiLogsRequest *ReadApiLogsRequest +} + +func (r ApiReadApiLogsRequest) ReadApiLogsRequest(readApiLogsRequest ReadApiLogsRequest) ApiReadApiLogsRequest { + r.readApiLogsRequest = &readApiLogsRequest + return r +} + +func (r ApiReadApiLogsRequest) Execute() (ReadApiLogsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadApiLogsExecute(r) +} + +/* + * ReadApiLogs Method for ReadApiLogs + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadApiLogsRequest + */ +func (a *ApiLogApiService) ReadApiLogs(ctx _context.Context) ApiReadApiLogsRequest { + return ApiReadApiLogsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadApiLogsResponse + */ +func (a *ApiLogApiService) ReadApiLogsExecute(r ApiReadApiLogsRequest) (ReadApiLogsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadApiLogsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ApiLogApiService.ReadApiLogs") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadApiLogs" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readApiLogsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go new file mode 100644 index 000000000..9ae6384fe --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go @@ -0,0 +1,390 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ClientGatewayApiService ClientGatewayApi service +type ClientGatewayApiService service + +type ApiCreateClientGatewayRequest struct { + ctx _context.Context + ApiService *ClientGatewayApiService + createClientGatewayRequest *CreateClientGatewayRequest +} + +func (r ApiCreateClientGatewayRequest) CreateClientGatewayRequest(createClientGatewayRequest CreateClientGatewayRequest) ApiCreateClientGatewayRequest { + r.createClientGatewayRequest = &createClientGatewayRequest + return r +} + +func (r ApiCreateClientGatewayRequest) Execute() (CreateClientGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.CreateClientGatewayExecute(r) +} + +/* + * CreateClientGateway Method for CreateClientGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateClientGatewayRequest + */ +func (a *ClientGatewayApiService) CreateClientGateway(ctx _context.Context) ApiCreateClientGatewayRequest { + return ApiCreateClientGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateClientGatewayResponse + */ +func (a *ClientGatewayApiService) CreateClientGatewayExecute(r ApiCreateClientGatewayRequest) (CreateClientGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateClientGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ClientGatewayApiService.CreateClientGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateClientGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createClientGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteClientGatewayRequest struct { + ctx _context.Context + ApiService *ClientGatewayApiService + deleteClientGatewayRequest *DeleteClientGatewayRequest +} + +func (r ApiDeleteClientGatewayRequest) DeleteClientGatewayRequest(deleteClientGatewayRequest DeleteClientGatewayRequest) ApiDeleteClientGatewayRequest { + r.deleteClientGatewayRequest = &deleteClientGatewayRequest + return r +} + +func (r ApiDeleteClientGatewayRequest) Execute() (DeleteClientGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteClientGatewayExecute(r) +} + +/* + * DeleteClientGateway Method for DeleteClientGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteClientGatewayRequest + */ +func (a *ClientGatewayApiService) DeleteClientGateway(ctx _context.Context) ApiDeleteClientGatewayRequest { + return ApiDeleteClientGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteClientGatewayResponse + */ +func (a *ClientGatewayApiService) DeleteClientGatewayExecute(r ApiDeleteClientGatewayRequest) (DeleteClientGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteClientGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ClientGatewayApiService.DeleteClientGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteClientGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteClientGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadClientGatewaysRequest struct { + ctx _context.Context + ApiService *ClientGatewayApiService + readClientGatewaysRequest *ReadClientGatewaysRequest +} + +func (r ApiReadClientGatewaysRequest) ReadClientGatewaysRequest(readClientGatewaysRequest ReadClientGatewaysRequest) ApiReadClientGatewaysRequest { + r.readClientGatewaysRequest = &readClientGatewaysRequest + return r +} + +func (r ApiReadClientGatewaysRequest) Execute() (ReadClientGatewaysResponse, *_nethttp.Response, error) { + return r.ApiService.ReadClientGatewaysExecute(r) +} + +/* + * ReadClientGateways Method for ReadClientGateways + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadClientGatewaysRequest + */ +func (a *ClientGatewayApiService) ReadClientGateways(ctx _context.Context) ApiReadClientGatewaysRequest { + return ApiReadClientGatewaysRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadClientGatewaysResponse + */ +func (a *ClientGatewayApiService) ReadClientGatewaysExecute(r ApiReadClientGatewaysRequest) (ReadClientGatewaysResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadClientGatewaysResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ClientGatewayApiService.ReadClientGateways") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadClientGateways" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readClientGatewaysRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go new file mode 100644 index 000000000..438e2c01e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go @@ -0,0 +1,390 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// DhcpOptionApiService DhcpOptionApi service +type DhcpOptionApiService service + +type ApiCreateDhcpOptionsRequest struct { + ctx _context.Context + ApiService *DhcpOptionApiService + createDhcpOptionsRequest *CreateDhcpOptionsRequest +} + +func (r ApiCreateDhcpOptionsRequest) CreateDhcpOptionsRequest(createDhcpOptionsRequest CreateDhcpOptionsRequest) ApiCreateDhcpOptionsRequest { + r.createDhcpOptionsRequest = &createDhcpOptionsRequest + return r +} + +func (r ApiCreateDhcpOptionsRequest) Execute() (CreateDhcpOptionsResponse, *_nethttp.Response, error) { + return r.ApiService.CreateDhcpOptionsExecute(r) +} + +/* + * CreateDhcpOptions Method for CreateDhcpOptions + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateDhcpOptionsRequest + */ +func (a *DhcpOptionApiService) CreateDhcpOptions(ctx _context.Context) ApiCreateDhcpOptionsRequest { + return ApiCreateDhcpOptionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateDhcpOptionsResponse + */ +func (a *DhcpOptionApiService) CreateDhcpOptionsExecute(r ApiCreateDhcpOptionsRequest) (CreateDhcpOptionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateDhcpOptionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DhcpOptionApiService.CreateDhcpOptions") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateDhcpOptions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createDhcpOptionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteDhcpOptionsRequest struct { + ctx _context.Context + ApiService *DhcpOptionApiService + deleteDhcpOptionsRequest *DeleteDhcpOptionsRequest +} + +func (r ApiDeleteDhcpOptionsRequest) DeleteDhcpOptionsRequest(deleteDhcpOptionsRequest DeleteDhcpOptionsRequest) ApiDeleteDhcpOptionsRequest { + r.deleteDhcpOptionsRequest = &deleteDhcpOptionsRequest + return r +} + +func (r ApiDeleteDhcpOptionsRequest) Execute() (DeleteDhcpOptionsResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteDhcpOptionsExecute(r) +} + +/* + * DeleteDhcpOptions Method for DeleteDhcpOptions + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteDhcpOptionsRequest + */ +func (a *DhcpOptionApiService) DeleteDhcpOptions(ctx _context.Context) ApiDeleteDhcpOptionsRequest { + return ApiDeleteDhcpOptionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteDhcpOptionsResponse + */ +func (a *DhcpOptionApiService) DeleteDhcpOptionsExecute(r ApiDeleteDhcpOptionsRequest) (DeleteDhcpOptionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteDhcpOptionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DhcpOptionApiService.DeleteDhcpOptions") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteDhcpOptions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteDhcpOptionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadDhcpOptionsRequest struct { + ctx _context.Context + ApiService *DhcpOptionApiService + readDhcpOptionsRequest *ReadDhcpOptionsRequest +} + +func (r ApiReadDhcpOptionsRequest) ReadDhcpOptionsRequest(readDhcpOptionsRequest ReadDhcpOptionsRequest) ApiReadDhcpOptionsRequest { + r.readDhcpOptionsRequest = &readDhcpOptionsRequest + return r +} + +func (r ApiReadDhcpOptionsRequest) Execute() (ReadDhcpOptionsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadDhcpOptionsExecute(r) +} + +/* + * ReadDhcpOptions Method for ReadDhcpOptions + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadDhcpOptionsRequest + */ +func (a *DhcpOptionApiService) ReadDhcpOptions(ctx _context.Context) ApiReadDhcpOptionsRequest { + return ApiReadDhcpOptionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadDhcpOptionsResponse + */ +func (a *DhcpOptionApiService) ReadDhcpOptionsExecute(r ApiReadDhcpOptionsRequest) (ReadDhcpOptionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadDhcpOptionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DhcpOptionApiService.ReadDhcpOptions") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadDhcpOptions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readDhcpOptionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go new file mode 100644 index 000000000..0f6c58605 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go @@ -0,0 +1,390 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// DirectLinkApiService DirectLinkApi service +type DirectLinkApiService service + +type ApiCreateDirectLinkRequest struct { + ctx _context.Context + ApiService *DirectLinkApiService + createDirectLinkRequest *CreateDirectLinkRequest +} + +func (r ApiCreateDirectLinkRequest) CreateDirectLinkRequest(createDirectLinkRequest CreateDirectLinkRequest) ApiCreateDirectLinkRequest { + r.createDirectLinkRequest = &createDirectLinkRequest + return r +} + +func (r ApiCreateDirectLinkRequest) Execute() (CreateDirectLinkResponse, *_nethttp.Response, error) { + return r.ApiService.CreateDirectLinkExecute(r) +} + +/* + * CreateDirectLink Method for CreateDirectLink + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateDirectLinkRequest + */ +func (a *DirectLinkApiService) CreateDirectLink(ctx _context.Context) ApiCreateDirectLinkRequest { + return ApiCreateDirectLinkRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateDirectLinkResponse + */ +func (a *DirectLinkApiService) CreateDirectLinkExecute(r ApiCreateDirectLinkRequest) (CreateDirectLinkResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateDirectLinkResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkApiService.CreateDirectLink") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateDirectLink" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createDirectLinkRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteDirectLinkRequest struct { + ctx _context.Context + ApiService *DirectLinkApiService + deleteDirectLinkRequest *DeleteDirectLinkRequest +} + +func (r ApiDeleteDirectLinkRequest) DeleteDirectLinkRequest(deleteDirectLinkRequest DeleteDirectLinkRequest) ApiDeleteDirectLinkRequest { + r.deleteDirectLinkRequest = &deleteDirectLinkRequest + return r +} + +func (r ApiDeleteDirectLinkRequest) Execute() (DeleteDirectLinkResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteDirectLinkExecute(r) +} + +/* + * DeleteDirectLink Method for DeleteDirectLink + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteDirectLinkRequest + */ +func (a *DirectLinkApiService) DeleteDirectLink(ctx _context.Context) ApiDeleteDirectLinkRequest { + return ApiDeleteDirectLinkRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteDirectLinkResponse + */ +func (a *DirectLinkApiService) DeleteDirectLinkExecute(r ApiDeleteDirectLinkRequest) (DeleteDirectLinkResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteDirectLinkResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkApiService.DeleteDirectLink") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteDirectLink" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteDirectLinkRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadDirectLinksRequest struct { + ctx _context.Context + ApiService *DirectLinkApiService + readDirectLinksRequest *ReadDirectLinksRequest +} + +func (r ApiReadDirectLinksRequest) ReadDirectLinksRequest(readDirectLinksRequest ReadDirectLinksRequest) ApiReadDirectLinksRequest { + r.readDirectLinksRequest = &readDirectLinksRequest + return r +} + +func (r ApiReadDirectLinksRequest) Execute() (ReadDirectLinksResponse, *_nethttp.Response, error) { + return r.ApiService.ReadDirectLinksExecute(r) +} + +/* + * ReadDirectLinks Method for ReadDirectLinks + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadDirectLinksRequest + */ +func (a *DirectLinkApiService) ReadDirectLinks(ctx _context.Context) ApiReadDirectLinksRequest { + return ApiReadDirectLinksRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadDirectLinksResponse + */ +func (a *DirectLinkApiService) ReadDirectLinksExecute(r ApiReadDirectLinksRequest) (ReadDirectLinksResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadDirectLinksResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkApiService.ReadDirectLinks") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadDirectLinks" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readDirectLinksRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go new file mode 100644 index 000000000..d3eb2655e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go @@ -0,0 +1,390 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// DirectLinkInterfaceApiService DirectLinkInterfaceApi service +type DirectLinkInterfaceApiService service + +type ApiCreateDirectLinkInterfaceRequest struct { + ctx _context.Context + ApiService *DirectLinkInterfaceApiService + createDirectLinkInterfaceRequest *CreateDirectLinkInterfaceRequest +} + +func (r ApiCreateDirectLinkInterfaceRequest) CreateDirectLinkInterfaceRequest(createDirectLinkInterfaceRequest CreateDirectLinkInterfaceRequest) ApiCreateDirectLinkInterfaceRequest { + r.createDirectLinkInterfaceRequest = &createDirectLinkInterfaceRequest + return r +} + +func (r ApiCreateDirectLinkInterfaceRequest) Execute() (CreateDirectLinkInterfaceResponse, *_nethttp.Response, error) { + return r.ApiService.CreateDirectLinkInterfaceExecute(r) +} + +/* + * CreateDirectLinkInterface Method for CreateDirectLinkInterface + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateDirectLinkInterfaceRequest + */ +func (a *DirectLinkInterfaceApiService) CreateDirectLinkInterface(ctx _context.Context) ApiCreateDirectLinkInterfaceRequest { + return ApiCreateDirectLinkInterfaceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateDirectLinkInterfaceResponse + */ +func (a *DirectLinkInterfaceApiService) CreateDirectLinkInterfaceExecute(r ApiCreateDirectLinkInterfaceRequest) (CreateDirectLinkInterfaceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateDirectLinkInterfaceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkInterfaceApiService.CreateDirectLinkInterface") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateDirectLinkInterface" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createDirectLinkInterfaceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteDirectLinkInterfaceRequest struct { + ctx _context.Context + ApiService *DirectLinkInterfaceApiService + deleteDirectLinkInterfaceRequest *DeleteDirectLinkInterfaceRequest +} + +func (r ApiDeleteDirectLinkInterfaceRequest) DeleteDirectLinkInterfaceRequest(deleteDirectLinkInterfaceRequest DeleteDirectLinkInterfaceRequest) ApiDeleteDirectLinkInterfaceRequest { + r.deleteDirectLinkInterfaceRequest = &deleteDirectLinkInterfaceRequest + return r +} + +func (r ApiDeleteDirectLinkInterfaceRequest) Execute() (DeleteDirectLinkInterfaceResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteDirectLinkInterfaceExecute(r) +} + +/* + * DeleteDirectLinkInterface Method for DeleteDirectLinkInterface + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteDirectLinkInterfaceRequest + */ +func (a *DirectLinkInterfaceApiService) DeleteDirectLinkInterface(ctx _context.Context) ApiDeleteDirectLinkInterfaceRequest { + return ApiDeleteDirectLinkInterfaceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteDirectLinkInterfaceResponse + */ +func (a *DirectLinkInterfaceApiService) DeleteDirectLinkInterfaceExecute(r ApiDeleteDirectLinkInterfaceRequest) (DeleteDirectLinkInterfaceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteDirectLinkInterfaceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkInterfaceApiService.DeleteDirectLinkInterface") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteDirectLinkInterface" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteDirectLinkInterfaceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadDirectLinkInterfacesRequest struct { + ctx _context.Context + ApiService *DirectLinkInterfaceApiService + readDirectLinkInterfacesRequest *ReadDirectLinkInterfacesRequest +} + +func (r ApiReadDirectLinkInterfacesRequest) ReadDirectLinkInterfacesRequest(readDirectLinkInterfacesRequest ReadDirectLinkInterfacesRequest) ApiReadDirectLinkInterfacesRequest { + r.readDirectLinkInterfacesRequest = &readDirectLinkInterfacesRequest + return r +} + +func (r ApiReadDirectLinkInterfacesRequest) Execute() (ReadDirectLinkInterfacesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadDirectLinkInterfacesExecute(r) +} + +/* + * ReadDirectLinkInterfaces Method for ReadDirectLinkInterfaces + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadDirectLinkInterfacesRequest + */ +func (a *DirectLinkInterfaceApiService) ReadDirectLinkInterfaces(ctx _context.Context) ApiReadDirectLinkInterfacesRequest { + return ApiReadDirectLinkInterfacesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadDirectLinkInterfacesResponse + */ +func (a *DirectLinkInterfaceApiService) ReadDirectLinkInterfacesExecute(r ApiReadDirectLinkInterfacesRequest) (ReadDirectLinkInterfacesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadDirectLinkInterfacesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "DirectLinkInterfaceApiService.ReadDirectLinkInterfaces") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadDirectLinkInterfaces" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readDirectLinkInterfacesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go new file mode 100644 index 000000000..6f323c121 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go @@ -0,0 +1,860 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// FlexibleGpuApiService FlexibleGpuApi service +type FlexibleGpuApiService service + +type ApiCreateFlexibleGpuRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + createFlexibleGpuRequest *CreateFlexibleGpuRequest +} + +func (r ApiCreateFlexibleGpuRequest) CreateFlexibleGpuRequest(createFlexibleGpuRequest CreateFlexibleGpuRequest) ApiCreateFlexibleGpuRequest { + r.createFlexibleGpuRequest = &createFlexibleGpuRequest + return r +} + +func (r ApiCreateFlexibleGpuRequest) Execute() (CreateFlexibleGpuResponse, *_nethttp.Response, error) { + return r.ApiService.CreateFlexibleGpuExecute(r) +} + +/* + * CreateFlexibleGpu Method for CreateFlexibleGpu + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateFlexibleGpuRequest + */ +func (a *FlexibleGpuApiService) CreateFlexibleGpu(ctx _context.Context) ApiCreateFlexibleGpuRequest { + return ApiCreateFlexibleGpuRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateFlexibleGpuResponse + */ +func (a *FlexibleGpuApiService) CreateFlexibleGpuExecute(r ApiCreateFlexibleGpuRequest) (CreateFlexibleGpuResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateFlexibleGpuResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.CreateFlexibleGpu") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateFlexibleGpu" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createFlexibleGpuRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteFlexibleGpuRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + deleteFlexibleGpuRequest *DeleteFlexibleGpuRequest +} + +func (r ApiDeleteFlexibleGpuRequest) DeleteFlexibleGpuRequest(deleteFlexibleGpuRequest DeleteFlexibleGpuRequest) ApiDeleteFlexibleGpuRequest { + r.deleteFlexibleGpuRequest = &deleteFlexibleGpuRequest + return r +} + +func (r ApiDeleteFlexibleGpuRequest) Execute() (DeleteFlexibleGpuResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteFlexibleGpuExecute(r) +} + +/* + * DeleteFlexibleGpu Method for DeleteFlexibleGpu + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteFlexibleGpuRequest + */ +func (a *FlexibleGpuApiService) DeleteFlexibleGpu(ctx _context.Context) ApiDeleteFlexibleGpuRequest { + return ApiDeleteFlexibleGpuRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteFlexibleGpuResponse + */ +func (a *FlexibleGpuApiService) DeleteFlexibleGpuExecute(r ApiDeleteFlexibleGpuRequest) (DeleteFlexibleGpuResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteFlexibleGpuResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.DeleteFlexibleGpu") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteFlexibleGpu" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteFlexibleGpuRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkFlexibleGpuRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + linkFlexibleGpuRequest *LinkFlexibleGpuRequest +} + +func (r ApiLinkFlexibleGpuRequest) LinkFlexibleGpuRequest(linkFlexibleGpuRequest LinkFlexibleGpuRequest) ApiLinkFlexibleGpuRequest { + r.linkFlexibleGpuRequest = &linkFlexibleGpuRequest + return r +} + +func (r ApiLinkFlexibleGpuRequest) Execute() (LinkFlexibleGpuResponse, *_nethttp.Response, error) { + return r.ApiService.LinkFlexibleGpuExecute(r) +} + +/* + * LinkFlexibleGpu Method for LinkFlexibleGpu + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkFlexibleGpuRequest + */ +func (a *FlexibleGpuApiService) LinkFlexibleGpu(ctx _context.Context) ApiLinkFlexibleGpuRequest { + return ApiLinkFlexibleGpuRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkFlexibleGpuResponse + */ +func (a *FlexibleGpuApiService) LinkFlexibleGpuExecute(r ApiLinkFlexibleGpuRequest) (LinkFlexibleGpuResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkFlexibleGpuResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.LinkFlexibleGpu") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkFlexibleGpu" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkFlexibleGpuRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadFlexibleGpuCatalogRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + readFlexibleGpuCatalogRequest *ReadFlexibleGpuCatalogRequest +} + +func (r ApiReadFlexibleGpuCatalogRequest) ReadFlexibleGpuCatalogRequest(readFlexibleGpuCatalogRequest ReadFlexibleGpuCatalogRequest) ApiReadFlexibleGpuCatalogRequest { + r.readFlexibleGpuCatalogRequest = &readFlexibleGpuCatalogRequest + return r +} + +func (r ApiReadFlexibleGpuCatalogRequest) Execute() (ReadFlexibleGpuCatalogResponse, *_nethttp.Response, error) { + return r.ApiService.ReadFlexibleGpuCatalogExecute(r) +} + +/* + * ReadFlexibleGpuCatalog Method for ReadFlexibleGpuCatalog + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadFlexibleGpuCatalogRequest + */ +func (a *FlexibleGpuApiService) ReadFlexibleGpuCatalog(ctx _context.Context) ApiReadFlexibleGpuCatalogRequest { + return ApiReadFlexibleGpuCatalogRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadFlexibleGpuCatalogResponse + */ +func (a *FlexibleGpuApiService) ReadFlexibleGpuCatalogExecute(r ApiReadFlexibleGpuCatalogRequest) (ReadFlexibleGpuCatalogResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadFlexibleGpuCatalogResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.ReadFlexibleGpuCatalog") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadFlexibleGpuCatalog" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readFlexibleGpuCatalogRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadFlexibleGpusRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + readFlexibleGpusRequest *ReadFlexibleGpusRequest +} + +func (r ApiReadFlexibleGpusRequest) ReadFlexibleGpusRequest(readFlexibleGpusRequest ReadFlexibleGpusRequest) ApiReadFlexibleGpusRequest { + r.readFlexibleGpusRequest = &readFlexibleGpusRequest + return r +} + +func (r ApiReadFlexibleGpusRequest) Execute() (ReadFlexibleGpusResponse, *_nethttp.Response, error) { + return r.ApiService.ReadFlexibleGpusExecute(r) +} + +/* + * ReadFlexibleGpus Method for ReadFlexibleGpus + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadFlexibleGpusRequest + */ +func (a *FlexibleGpuApiService) ReadFlexibleGpus(ctx _context.Context) ApiReadFlexibleGpusRequest { + return ApiReadFlexibleGpusRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadFlexibleGpusResponse + */ +func (a *FlexibleGpuApiService) ReadFlexibleGpusExecute(r ApiReadFlexibleGpusRequest) (ReadFlexibleGpusResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadFlexibleGpusResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.ReadFlexibleGpus") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadFlexibleGpus" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readFlexibleGpusRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkFlexibleGpuRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + unlinkFlexibleGpuRequest *UnlinkFlexibleGpuRequest +} + +func (r ApiUnlinkFlexibleGpuRequest) UnlinkFlexibleGpuRequest(unlinkFlexibleGpuRequest UnlinkFlexibleGpuRequest) ApiUnlinkFlexibleGpuRequest { + r.unlinkFlexibleGpuRequest = &unlinkFlexibleGpuRequest + return r +} + +func (r ApiUnlinkFlexibleGpuRequest) Execute() (UnlinkFlexibleGpuResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkFlexibleGpuExecute(r) +} + +/* + * UnlinkFlexibleGpu Method for UnlinkFlexibleGpu + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkFlexibleGpuRequest + */ +func (a *FlexibleGpuApiService) UnlinkFlexibleGpu(ctx _context.Context) ApiUnlinkFlexibleGpuRequest { + return ApiUnlinkFlexibleGpuRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkFlexibleGpuResponse + */ +func (a *FlexibleGpuApiService) UnlinkFlexibleGpuExecute(r ApiUnlinkFlexibleGpuRequest) (UnlinkFlexibleGpuResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkFlexibleGpuResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.UnlinkFlexibleGpu") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkFlexibleGpu" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkFlexibleGpuRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateFlexibleGpuRequest struct { + ctx _context.Context + ApiService *FlexibleGpuApiService + updateFlexibleGpuRequest *UpdateFlexibleGpuRequest +} + +func (r ApiUpdateFlexibleGpuRequest) UpdateFlexibleGpuRequest(updateFlexibleGpuRequest UpdateFlexibleGpuRequest) ApiUpdateFlexibleGpuRequest { + r.updateFlexibleGpuRequest = &updateFlexibleGpuRequest + return r +} + +func (r ApiUpdateFlexibleGpuRequest) Execute() (UpdateFlexibleGpuResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateFlexibleGpuExecute(r) +} + +/* + * UpdateFlexibleGpu Method for UpdateFlexibleGpu + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateFlexibleGpuRequest + */ +func (a *FlexibleGpuApiService) UpdateFlexibleGpu(ctx _context.Context) ApiUpdateFlexibleGpuRequest { + return ApiUpdateFlexibleGpuRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateFlexibleGpuResponse + */ +func (a *FlexibleGpuApiService) UpdateFlexibleGpuExecute(r ApiUpdateFlexibleGpuRequest) (UpdateFlexibleGpuResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateFlexibleGpuResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "FlexibleGpuApiService.UpdateFlexibleGpu") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateFlexibleGpu" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateFlexibleGpuRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_image.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_image.go new file mode 100644 index 000000000..832ffa208 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_image.go @@ -0,0 +1,869 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ImageApiService ImageApi service +type ImageApiService service + +type ApiCreateImageRequest struct { + ctx _context.Context + ApiService *ImageApiService + createImageRequest *CreateImageRequest +} + +func (r ApiCreateImageRequest) CreateImageRequest(createImageRequest CreateImageRequest) ApiCreateImageRequest { + r.createImageRequest = &createImageRequest + return r +} + +func (r ApiCreateImageRequest) Execute() (CreateImageResponse, *_nethttp.Response, error) { + return r.ApiService.CreateImageExecute(r) +} + +/* + * CreateImage Method for CreateImage + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateImageRequest + */ +func (a *ImageApiService) CreateImage(ctx _context.Context) ApiCreateImageRequest { + return ApiCreateImageRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateImageResponse + */ +func (a *ImageApiService) CreateImageExecute(r ApiCreateImageRequest) (CreateImageResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateImageResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.CreateImage") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateImage" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createImageRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateImageExportTaskRequest struct { + ctx _context.Context + ApiService *ImageApiService + createImageExportTaskRequest *CreateImageExportTaskRequest +} + +func (r ApiCreateImageExportTaskRequest) CreateImageExportTaskRequest(createImageExportTaskRequest CreateImageExportTaskRequest) ApiCreateImageExportTaskRequest { + r.createImageExportTaskRequest = &createImageExportTaskRequest + return r +} + +func (r ApiCreateImageExportTaskRequest) Execute() (CreateImageExportTaskResponse, *_nethttp.Response, error) { + return r.ApiService.CreateImageExportTaskExecute(r) +} + +/* + * CreateImageExportTask Method for CreateImageExportTask + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateImageExportTaskRequest + */ +func (a *ImageApiService) CreateImageExportTask(ctx _context.Context) ApiCreateImageExportTaskRequest { + return ApiCreateImageExportTaskRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateImageExportTaskResponse + */ +func (a *ImageApiService) CreateImageExportTaskExecute(r ApiCreateImageExportTaskRequest) (CreateImageExportTaskResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateImageExportTaskResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.CreateImageExportTask") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateImageExportTask" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createImageExportTaskRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteImageRequest struct { + ctx _context.Context + ApiService *ImageApiService + deleteImageRequest *DeleteImageRequest +} + +func (r ApiDeleteImageRequest) DeleteImageRequest(deleteImageRequest DeleteImageRequest) ApiDeleteImageRequest { + r.deleteImageRequest = &deleteImageRequest + return r +} + +func (r ApiDeleteImageRequest) Execute() (DeleteImageResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteImageExecute(r) +} + +/* + * DeleteImage Method for DeleteImage + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteImageRequest + */ +func (a *ImageApiService) DeleteImage(ctx _context.Context) ApiDeleteImageRequest { + return ApiDeleteImageRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteImageResponse + */ +func (a *ImageApiService) DeleteImageExecute(r ApiDeleteImageRequest) (DeleteImageResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteImageResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.DeleteImage") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteImage" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteImageRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadImageExportTasksRequest struct { + ctx _context.Context + ApiService *ImageApiService + readImageExportTasksRequest *ReadImageExportTasksRequest +} + +func (r ApiReadImageExportTasksRequest) ReadImageExportTasksRequest(readImageExportTasksRequest ReadImageExportTasksRequest) ApiReadImageExportTasksRequest { + r.readImageExportTasksRequest = &readImageExportTasksRequest + return r +} + +func (r ApiReadImageExportTasksRequest) Execute() (ReadImageExportTasksResponse, *_nethttp.Response, error) { + return r.ApiService.ReadImageExportTasksExecute(r) +} + +/* + * ReadImageExportTasks Method for ReadImageExportTasks + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadImageExportTasksRequest + */ +func (a *ImageApiService) ReadImageExportTasks(ctx _context.Context) ApiReadImageExportTasksRequest { + return ApiReadImageExportTasksRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadImageExportTasksResponse + */ +func (a *ImageApiService) ReadImageExportTasksExecute(r ApiReadImageExportTasksRequest) (ReadImageExportTasksResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadImageExportTasksResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.ReadImageExportTasks") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadImageExportTasks" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readImageExportTasksRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadImagesRequest struct { + ctx _context.Context + ApiService *ImageApiService + readImagesRequest *ReadImagesRequest +} + +func (r ApiReadImagesRequest) ReadImagesRequest(readImagesRequest ReadImagesRequest) ApiReadImagesRequest { + r.readImagesRequest = &readImagesRequest + return r +} + +func (r ApiReadImagesRequest) Execute() (ReadImagesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadImagesExecute(r) +} + +/* + * ReadImages Method for ReadImages + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadImagesRequest + */ +func (a *ImageApiService) ReadImages(ctx _context.Context) ApiReadImagesRequest { + return ApiReadImagesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadImagesResponse + */ +func (a *ImageApiService) ReadImagesExecute(r ApiReadImagesRequest) (ReadImagesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadImagesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.ReadImages") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadImages" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readImagesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateImageRequest struct { + ctx _context.Context + ApiService *ImageApiService + updateImageRequest *UpdateImageRequest +} + +func (r ApiUpdateImageRequest) UpdateImageRequest(updateImageRequest UpdateImageRequest) ApiUpdateImageRequest { + r.updateImageRequest = &updateImageRequest + return r +} + +func (r ApiUpdateImageRequest) Execute() (UpdateImageResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateImageExecute(r) +} + +/* + * UpdateImage Method for UpdateImage + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateImageRequest + */ +func (a *ImageApiService) UpdateImage(ctx _context.Context) ApiUpdateImageRequest { + return ApiUpdateImageRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateImageResponse + */ +func (a *ImageApiService) UpdateImageExecute(r ApiUpdateImageRequest) (UpdateImageResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateImageResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ImageApiService.UpdateImage") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateImage" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateImageRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go new file mode 100644 index 000000000..3f7dff4f5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go @@ -0,0 +1,777 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// InternetServiceApiService InternetServiceApi service +type InternetServiceApiService service + +type ApiCreateInternetServiceRequest struct { + ctx _context.Context + ApiService *InternetServiceApiService + createInternetServiceRequest *CreateInternetServiceRequest +} + +func (r ApiCreateInternetServiceRequest) CreateInternetServiceRequest(createInternetServiceRequest CreateInternetServiceRequest) ApiCreateInternetServiceRequest { + r.createInternetServiceRequest = &createInternetServiceRequest + return r +} + +func (r ApiCreateInternetServiceRequest) Execute() (CreateInternetServiceResponse, *_nethttp.Response, error) { + return r.ApiService.CreateInternetServiceExecute(r) +} + +/* + * CreateInternetService Method for CreateInternetService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateInternetServiceRequest + */ +func (a *InternetServiceApiService) CreateInternetService(ctx _context.Context) ApiCreateInternetServiceRequest { + return ApiCreateInternetServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateInternetServiceResponse + */ +func (a *InternetServiceApiService) CreateInternetServiceExecute(r ApiCreateInternetServiceRequest) (CreateInternetServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateInternetServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "InternetServiceApiService.CreateInternetService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateInternetService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createInternetServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteInternetServiceRequest struct { + ctx _context.Context + ApiService *InternetServiceApiService + deleteInternetServiceRequest *DeleteInternetServiceRequest +} + +func (r ApiDeleteInternetServiceRequest) DeleteInternetServiceRequest(deleteInternetServiceRequest DeleteInternetServiceRequest) ApiDeleteInternetServiceRequest { + r.deleteInternetServiceRequest = &deleteInternetServiceRequest + return r +} + +func (r ApiDeleteInternetServiceRequest) Execute() (DeleteInternetServiceResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteInternetServiceExecute(r) +} + +/* + * DeleteInternetService Method for DeleteInternetService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteInternetServiceRequest + */ +func (a *InternetServiceApiService) DeleteInternetService(ctx _context.Context) ApiDeleteInternetServiceRequest { + return ApiDeleteInternetServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteInternetServiceResponse + */ +func (a *InternetServiceApiService) DeleteInternetServiceExecute(r ApiDeleteInternetServiceRequest) (DeleteInternetServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteInternetServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "InternetServiceApiService.DeleteInternetService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteInternetService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteInternetServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkInternetServiceRequest struct { + ctx _context.Context + ApiService *InternetServiceApiService + linkInternetServiceRequest *LinkInternetServiceRequest +} + +func (r ApiLinkInternetServiceRequest) LinkInternetServiceRequest(linkInternetServiceRequest LinkInternetServiceRequest) ApiLinkInternetServiceRequest { + r.linkInternetServiceRequest = &linkInternetServiceRequest + return r +} + +func (r ApiLinkInternetServiceRequest) Execute() (LinkInternetServiceResponse, *_nethttp.Response, error) { + return r.ApiService.LinkInternetServiceExecute(r) +} + +/* + * LinkInternetService Method for LinkInternetService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkInternetServiceRequest + */ +func (a *InternetServiceApiService) LinkInternetService(ctx _context.Context) ApiLinkInternetServiceRequest { + return ApiLinkInternetServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkInternetServiceResponse + */ +func (a *InternetServiceApiService) LinkInternetServiceExecute(r ApiLinkInternetServiceRequest) (LinkInternetServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkInternetServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "InternetServiceApiService.LinkInternetService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkInternetService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkInternetServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadInternetServicesRequest struct { + ctx _context.Context + ApiService *InternetServiceApiService + readInternetServicesRequest *ReadInternetServicesRequest +} + +func (r ApiReadInternetServicesRequest) ReadInternetServicesRequest(readInternetServicesRequest ReadInternetServicesRequest) ApiReadInternetServicesRequest { + r.readInternetServicesRequest = &readInternetServicesRequest + return r +} + +func (r ApiReadInternetServicesRequest) Execute() (ReadInternetServicesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadInternetServicesExecute(r) +} + +/* + * ReadInternetServices Method for ReadInternetServices + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadInternetServicesRequest + */ +func (a *InternetServiceApiService) ReadInternetServices(ctx _context.Context) ApiReadInternetServicesRequest { + return ApiReadInternetServicesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadInternetServicesResponse + */ +func (a *InternetServiceApiService) ReadInternetServicesExecute(r ApiReadInternetServicesRequest) (ReadInternetServicesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadInternetServicesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "InternetServiceApiService.ReadInternetServices") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadInternetServices" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readInternetServicesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkInternetServiceRequest struct { + ctx _context.Context + ApiService *InternetServiceApiService + unlinkInternetServiceRequest *UnlinkInternetServiceRequest +} + +func (r ApiUnlinkInternetServiceRequest) UnlinkInternetServiceRequest(unlinkInternetServiceRequest UnlinkInternetServiceRequest) ApiUnlinkInternetServiceRequest { + r.unlinkInternetServiceRequest = &unlinkInternetServiceRequest + return r +} + +func (r ApiUnlinkInternetServiceRequest) Execute() (UnlinkInternetServiceResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkInternetServiceExecute(r) +} + +/* + * UnlinkInternetService Method for UnlinkInternetService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkInternetServiceRequest + */ +func (a *InternetServiceApiService) UnlinkInternetService(ctx _context.Context) ApiUnlinkInternetServiceRequest { + return ApiUnlinkInternetServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkInternetServiceResponse + */ +func (a *InternetServiceApiService) UnlinkInternetServiceExecute(r ApiUnlinkInternetServiceRequest) (UnlinkInternetServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkInternetServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "InternetServiceApiService.UnlinkInternetService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkInternetService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkInternetServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go new file mode 100644 index 000000000..b2307db8f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go @@ -0,0 +1,487 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// KeypairApiService KeypairApi service +type KeypairApiService service + +type ApiCreateKeypairRequest struct { + ctx _context.Context + ApiService *KeypairApiService + createKeypairRequest *CreateKeypairRequest +} + +func (r ApiCreateKeypairRequest) CreateKeypairRequest(createKeypairRequest CreateKeypairRequest) ApiCreateKeypairRequest { + r.createKeypairRequest = &createKeypairRequest + return r +} + +func (r ApiCreateKeypairRequest) Execute() (CreateKeypairResponse, *_nethttp.Response, error) { + return r.ApiService.CreateKeypairExecute(r) +} + +/* + * CreateKeypair Method for CreateKeypair + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateKeypairRequest + */ +func (a *KeypairApiService) CreateKeypair(ctx _context.Context) ApiCreateKeypairRequest { + return ApiCreateKeypairRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateKeypairResponse + */ +func (a *KeypairApiService) CreateKeypairExecute(r ApiCreateKeypairRequest) (CreateKeypairResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateKeypairResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "KeypairApiService.CreateKeypair") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateKeypair" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createKeypairRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteKeypairRequest struct { + ctx _context.Context + ApiService *KeypairApiService + deleteKeypairRequest *DeleteKeypairRequest +} + +func (r ApiDeleteKeypairRequest) DeleteKeypairRequest(deleteKeypairRequest DeleteKeypairRequest) ApiDeleteKeypairRequest { + r.deleteKeypairRequest = &deleteKeypairRequest + return r +} + +func (r ApiDeleteKeypairRequest) Execute() (DeleteKeypairResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteKeypairExecute(r) +} + +/* + * DeleteKeypair Method for DeleteKeypair + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteKeypairRequest + */ +func (a *KeypairApiService) DeleteKeypair(ctx _context.Context) ApiDeleteKeypairRequest { + return ApiDeleteKeypairRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteKeypairResponse + */ +func (a *KeypairApiService) DeleteKeypairExecute(r ApiDeleteKeypairRequest) (DeleteKeypairResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteKeypairResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "KeypairApiService.DeleteKeypair") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteKeypair" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteKeypairRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadKeypairsRequest struct { + ctx _context.Context + ApiService *KeypairApiService + readKeypairsRequest *ReadKeypairsRequest +} + +func (r ApiReadKeypairsRequest) ReadKeypairsRequest(readKeypairsRequest ReadKeypairsRequest) ApiReadKeypairsRequest { + r.readKeypairsRequest = &readKeypairsRequest + return r +} + +func (r ApiReadKeypairsRequest) Execute() (ReadKeypairsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadKeypairsExecute(r) +} + +/* + * ReadKeypairs Method for ReadKeypairs + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadKeypairsRequest + */ +func (a *KeypairApiService) ReadKeypairs(ctx _context.Context) ApiReadKeypairsRequest { + return ApiReadKeypairsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadKeypairsResponse + */ +func (a *KeypairApiService) ReadKeypairsExecute(r ApiReadKeypairsRequest) (ReadKeypairsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadKeypairsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "KeypairApiService.ReadKeypairs") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadKeypairs" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readKeypairsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go new file mode 100644 index 000000000..12440cfdf --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go @@ -0,0 +1,753 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ListenerApiService ListenerApi service +type ListenerApiService service + +type ApiCreateListenerRuleRequest struct { + ctx _context.Context + ApiService *ListenerApiService + createListenerRuleRequest *CreateListenerRuleRequest +} + +func (r ApiCreateListenerRuleRequest) CreateListenerRuleRequest(createListenerRuleRequest CreateListenerRuleRequest) ApiCreateListenerRuleRequest { + r.createListenerRuleRequest = &createListenerRuleRequest + return r +} + +func (r ApiCreateListenerRuleRequest) Execute() (CreateListenerRuleResponse, *_nethttp.Response, error) { + return r.ApiService.CreateListenerRuleExecute(r) +} + +/* + * CreateListenerRule Method for CreateListenerRule + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateListenerRuleRequest + */ +func (a *ListenerApiService) CreateListenerRule(ctx _context.Context) ApiCreateListenerRuleRequest { + return ApiCreateListenerRuleRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateListenerRuleResponse + */ +func (a *ListenerApiService) CreateListenerRuleExecute(r ApiCreateListenerRuleRequest) (CreateListenerRuleResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateListenerRuleResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.CreateListenerRule") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateListenerRule" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createListenerRuleRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateLoadBalancerListenersRequest struct { + ctx _context.Context + ApiService *ListenerApiService + createLoadBalancerListenersRequest *CreateLoadBalancerListenersRequest +} + +func (r ApiCreateLoadBalancerListenersRequest) CreateLoadBalancerListenersRequest(createLoadBalancerListenersRequest CreateLoadBalancerListenersRequest) ApiCreateLoadBalancerListenersRequest { + r.createLoadBalancerListenersRequest = &createLoadBalancerListenersRequest + return r +} + +func (r ApiCreateLoadBalancerListenersRequest) Execute() (CreateLoadBalancerListenersResponse, *_nethttp.Response, error) { + return r.ApiService.CreateLoadBalancerListenersExecute(r) +} + +/* + * CreateLoadBalancerListeners Method for CreateLoadBalancerListeners + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateLoadBalancerListenersRequest + */ +func (a *ListenerApiService) CreateLoadBalancerListeners(ctx _context.Context) ApiCreateLoadBalancerListenersRequest { + return ApiCreateLoadBalancerListenersRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateLoadBalancerListenersResponse + */ +func (a *ListenerApiService) CreateLoadBalancerListenersExecute(r ApiCreateLoadBalancerListenersRequest) (CreateLoadBalancerListenersResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateLoadBalancerListenersResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.CreateLoadBalancerListeners") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateLoadBalancerListeners" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createLoadBalancerListenersRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteListenerRuleRequest struct { + ctx _context.Context + ApiService *ListenerApiService + deleteListenerRuleRequest *DeleteListenerRuleRequest +} + +func (r ApiDeleteListenerRuleRequest) DeleteListenerRuleRequest(deleteListenerRuleRequest DeleteListenerRuleRequest) ApiDeleteListenerRuleRequest { + r.deleteListenerRuleRequest = &deleteListenerRuleRequest + return r +} + +func (r ApiDeleteListenerRuleRequest) Execute() (DeleteListenerRuleResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteListenerRuleExecute(r) +} + +/* + * DeleteListenerRule Method for DeleteListenerRule + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteListenerRuleRequest + */ +func (a *ListenerApiService) DeleteListenerRule(ctx _context.Context) ApiDeleteListenerRuleRequest { + return ApiDeleteListenerRuleRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteListenerRuleResponse + */ +func (a *ListenerApiService) DeleteListenerRuleExecute(r ApiDeleteListenerRuleRequest) (DeleteListenerRuleResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteListenerRuleResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.DeleteListenerRule") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteListenerRule" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteListenerRuleRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteLoadBalancerListenersRequest struct { + ctx _context.Context + ApiService *ListenerApiService + deleteLoadBalancerListenersRequest *DeleteLoadBalancerListenersRequest +} + +func (r ApiDeleteLoadBalancerListenersRequest) DeleteLoadBalancerListenersRequest(deleteLoadBalancerListenersRequest DeleteLoadBalancerListenersRequest) ApiDeleteLoadBalancerListenersRequest { + r.deleteLoadBalancerListenersRequest = &deleteLoadBalancerListenersRequest + return r +} + +func (r ApiDeleteLoadBalancerListenersRequest) Execute() (DeleteLoadBalancerListenersResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteLoadBalancerListenersExecute(r) +} + +/* + * DeleteLoadBalancerListeners Method for DeleteLoadBalancerListeners + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteLoadBalancerListenersRequest + */ +func (a *ListenerApiService) DeleteLoadBalancerListeners(ctx _context.Context) ApiDeleteLoadBalancerListenersRequest { + return ApiDeleteLoadBalancerListenersRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteLoadBalancerListenersResponse + */ +func (a *ListenerApiService) DeleteLoadBalancerListenersExecute(r ApiDeleteLoadBalancerListenersRequest) (DeleteLoadBalancerListenersResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteLoadBalancerListenersResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.DeleteLoadBalancerListeners") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteLoadBalancerListeners" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteLoadBalancerListenersRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadListenerRulesRequest struct { + ctx _context.Context + ApiService *ListenerApiService + readListenerRulesRequest *ReadListenerRulesRequest +} + +func (r ApiReadListenerRulesRequest) ReadListenerRulesRequest(readListenerRulesRequest ReadListenerRulesRequest) ApiReadListenerRulesRequest { + r.readListenerRulesRequest = &readListenerRulesRequest + return r +} + +func (r ApiReadListenerRulesRequest) Execute() (ReadListenerRulesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadListenerRulesExecute(r) +} + +/* + * ReadListenerRules Method for ReadListenerRules + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadListenerRulesRequest + */ +func (a *ListenerApiService) ReadListenerRules(ctx _context.Context) ApiReadListenerRulesRequest { + return ApiReadListenerRulesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadListenerRulesResponse + */ +func (a *ListenerApiService) ReadListenerRulesExecute(r ApiReadListenerRulesRequest) (ReadListenerRulesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadListenerRulesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.ReadListenerRules") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadListenerRules" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readListenerRulesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateListenerRuleRequest struct { + ctx _context.Context + ApiService *ListenerApiService + updateListenerRuleRequest *UpdateListenerRuleRequest +} + +func (r ApiUpdateListenerRuleRequest) UpdateListenerRuleRequest(updateListenerRuleRequest UpdateListenerRuleRequest) ApiUpdateListenerRuleRequest { + r.updateListenerRuleRequest = &updateListenerRuleRequest + return r +} + +func (r ApiUpdateListenerRuleRequest) Execute() (UpdateListenerRuleResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateListenerRuleExecute(r) +} + +/* + * UpdateListenerRule Method for UpdateListenerRule + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateListenerRuleRequest + */ +func (a *ListenerApiService) UpdateListenerRule(ctx _context.Context) ApiUpdateListenerRuleRequest { + return ApiUpdateListenerRuleRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateListenerRuleResponse + */ +func (a *ListenerApiService) UpdateListenerRuleExecute(r ApiUpdateListenerRuleRequest) (UpdateListenerRuleResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateListenerRuleResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ListenerApiService.UpdateListenerRule") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateListenerRule" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateListenerRuleRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go new file mode 100644 index 000000000..25bbc0633 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go @@ -0,0 +1,1237 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// LoadBalancerApiService LoadBalancerApi service +type LoadBalancerApiService service + +type ApiCreateLoadBalancerRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + createLoadBalancerRequest *CreateLoadBalancerRequest +} + +func (r ApiCreateLoadBalancerRequest) CreateLoadBalancerRequest(createLoadBalancerRequest CreateLoadBalancerRequest) ApiCreateLoadBalancerRequest { + r.createLoadBalancerRequest = &createLoadBalancerRequest + return r +} + +func (r ApiCreateLoadBalancerRequest) Execute() (CreateLoadBalancerResponse, *_nethttp.Response, error) { + return r.ApiService.CreateLoadBalancerExecute(r) +} + +/* + * CreateLoadBalancer Method for CreateLoadBalancer + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateLoadBalancerRequest + */ +func (a *LoadBalancerApiService) CreateLoadBalancer(ctx _context.Context) ApiCreateLoadBalancerRequest { + return ApiCreateLoadBalancerRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateLoadBalancerResponse + */ +func (a *LoadBalancerApiService) CreateLoadBalancerExecute(r ApiCreateLoadBalancerRequest) (CreateLoadBalancerResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateLoadBalancerResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.CreateLoadBalancer") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateLoadBalancer" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createLoadBalancerRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateLoadBalancerTagsRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + createLoadBalancerTagsRequest *CreateLoadBalancerTagsRequest +} + +func (r ApiCreateLoadBalancerTagsRequest) CreateLoadBalancerTagsRequest(createLoadBalancerTagsRequest CreateLoadBalancerTagsRequest) ApiCreateLoadBalancerTagsRequest { + r.createLoadBalancerTagsRequest = &createLoadBalancerTagsRequest + return r +} + +func (r ApiCreateLoadBalancerTagsRequest) Execute() (CreateLoadBalancerTagsResponse, *_nethttp.Response, error) { + return r.ApiService.CreateLoadBalancerTagsExecute(r) +} + +/* + * CreateLoadBalancerTags Method for CreateLoadBalancerTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateLoadBalancerTagsRequest + */ +func (a *LoadBalancerApiService) CreateLoadBalancerTags(ctx _context.Context) ApiCreateLoadBalancerTagsRequest { + return ApiCreateLoadBalancerTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateLoadBalancerTagsResponse + */ +func (a *LoadBalancerApiService) CreateLoadBalancerTagsExecute(r ApiCreateLoadBalancerTagsRequest) (CreateLoadBalancerTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateLoadBalancerTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.CreateLoadBalancerTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateLoadBalancerTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createLoadBalancerTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteLoadBalancerRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + deleteLoadBalancerRequest *DeleteLoadBalancerRequest +} + +func (r ApiDeleteLoadBalancerRequest) DeleteLoadBalancerRequest(deleteLoadBalancerRequest DeleteLoadBalancerRequest) ApiDeleteLoadBalancerRequest { + r.deleteLoadBalancerRequest = &deleteLoadBalancerRequest + return r +} + +func (r ApiDeleteLoadBalancerRequest) Execute() (DeleteLoadBalancerResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteLoadBalancerExecute(r) +} + +/* + * DeleteLoadBalancer Method for DeleteLoadBalancer + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteLoadBalancerRequest + */ +func (a *LoadBalancerApiService) DeleteLoadBalancer(ctx _context.Context) ApiDeleteLoadBalancerRequest { + return ApiDeleteLoadBalancerRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteLoadBalancerResponse + */ +func (a *LoadBalancerApiService) DeleteLoadBalancerExecute(r ApiDeleteLoadBalancerRequest) (DeleteLoadBalancerResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteLoadBalancerResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.DeleteLoadBalancer") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteLoadBalancer" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteLoadBalancerRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteLoadBalancerTagsRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + deleteLoadBalancerTagsRequest *DeleteLoadBalancerTagsRequest +} + +func (r ApiDeleteLoadBalancerTagsRequest) DeleteLoadBalancerTagsRequest(deleteLoadBalancerTagsRequest DeleteLoadBalancerTagsRequest) ApiDeleteLoadBalancerTagsRequest { + r.deleteLoadBalancerTagsRequest = &deleteLoadBalancerTagsRequest + return r +} + +func (r ApiDeleteLoadBalancerTagsRequest) Execute() (DeleteLoadBalancerTagsResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteLoadBalancerTagsExecute(r) +} + +/* + * DeleteLoadBalancerTags Method for DeleteLoadBalancerTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteLoadBalancerTagsRequest + */ +func (a *LoadBalancerApiService) DeleteLoadBalancerTags(ctx _context.Context) ApiDeleteLoadBalancerTagsRequest { + return ApiDeleteLoadBalancerTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteLoadBalancerTagsResponse + */ +func (a *LoadBalancerApiService) DeleteLoadBalancerTagsExecute(r ApiDeleteLoadBalancerTagsRequest) (DeleteLoadBalancerTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteLoadBalancerTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.DeleteLoadBalancerTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteLoadBalancerTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteLoadBalancerTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeregisterVmsInLoadBalancerRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + deregisterVmsInLoadBalancerRequest *DeregisterVmsInLoadBalancerRequest +} + +func (r ApiDeregisterVmsInLoadBalancerRequest) DeregisterVmsInLoadBalancerRequest(deregisterVmsInLoadBalancerRequest DeregisterVmsInLoadBalancerRequest) ApiDeregisterVmsInLoadBalancerRequest { + r.deregisterVmsInLoadBalancerRequest = &deregisterVmsInLoadBalancerRequest + return r +} + +func (r ApiDeregisterVmsInLoadBalancerRequest) Execute() (DeregisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { + return r.ApiService.DeregisterVmsInLoadBalancerExecute(r) +} + +/* + * DeregisterVmsInLoadBalancer Method for DeregisterVmsInLoadBalancer + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeregisterVmsInLoadBalancerRequest + */ +func (a *LoadBalancerApiService) DeregisterVmsInLoadBalancer(ctx _context.Context) ApiDeregisterVmsInLoadBalancerRequest { + return ApiDeregisterVmsInLoadBalancerRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeregisterVmsInLoadBalancerResponse + */ +func (a *LoadBalancerApiService) DeregisterVmsInLoadBalancerExecute(r ApiDeregisterVmsInLoadBalancerRequest) (DeregisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeregisterVmsInLoadBalancerResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.DeregisterVmsInLoadBalancer") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeregisterVmsInLoadBalancer" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deregisterVmsInLoadBalancerRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadLoadBalancerTagsRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + readLoadBalancerTagsRequest *ReadLoadBalancerTagsRequest +} + +func (r ApiReadLoadBalancerTagsRequest) ReadLoadBalancerTagsRequest(readLoadBalancerTagsRequest ReadLoadBalancerTagsRequest) ApiReadLoadBalancerTagsRequest { + r.readLoadBalancerTagsRequest = &readLoadBalancerTagsRequest + return r +} + +func (r ApiReadLoadBalancerTagsRequest) Execute() (ReadLoadBalancerTagsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadLoadBalancerTagsExecute(r) +} + +/* + * ReadLoadBalancerTags Method for ReadLoadBalancerTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadLoadBalancerTagsRequest + */ +func (a *LoadBalancerApiService) ReadLoadBalancerTags(ctx _context.Context) ApiReadLoadBalancerTagsRequest { + return ApiReadLoadBalancerTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadLoadBalancerTagsResponse + */ +func (a *LoadBalancerApiService) ReadLoadBalancerTagsExecute(r ApiReadLoadBalancerTagsRequest) (ReadLoadBalancerTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadLoadBalancerTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.ReadLoadBalancerTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadLoadBalancerTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readLoadBalancerTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadLoadBalancersRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + readLoadBalancersRequest *ReadLoadBalancersRequest +} + +func (r ApiReadLoadBalancersRequest) ReadLoadBalancersRequest(readLoadBalancersRequest ReadLoadBalancersRequest) ApiReadLoadBalancersRequest { + r.readLoadBalancersRequest = &readLoadBalancersRequest + return r +} + +func (r ApiReadLoadBalancersRequest) Execute() (ReadLoadBalancersResponse, *_nethttp.Response, error) { + return r.ApiService.ReadLoadBalancersExecute(r) +} + +/* + * ReadLoadBalancers Method for ReadLoadBalancers + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadLoadBalancersRequest + */ +func (a *LoadBalancerApiService) ReadLoadBalancers(ctx _context.Context) ApiReadLoadBalancersRequest { + return ApiReadLoadBalancersRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadLoadBalancersResponse + */ +func (a *LoadBalancerApiService) ReadLoadBalancersExecute(r ApiReadLoadBalancersRequest) (ReadLoadBalancersResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadLoadBalancersResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.ReadLoadBalancers") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadLoadBalancers" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readLoadBalancersRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVmsHealthRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + readVmsHealthRequest *ReadVmsHealthRequest +} + +func (r ApiReadVmsHealthRequest) ReadVmsHealthRequest(readVmsHealthRequest ReadVmsHealthRequest) ApiReadVmsHealthRequest { + r.readVmsHealthRequest = &readVmsHealthRequest + return r +} + +func (r ApiReadVmsHealthRequest) Execute() (ReadVmsHealthResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVmsHealthExecute(r) +} + +/* + * ReadVmsHealth Method for ReadVmsHealth + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVmsHealthRequest + */ +func (a *LoadBalancerApiService) ReadVmsHealth(ctx _context.Context) ApiReadVmsHealthRequest { + return ApiReadVmsHealthRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVmsHealthResponse + */ +func (a *LoadBalancerApiService) ReadVmsHealthExecute(r ApiReadVmsHealthRequest) (ReadVmsHealthResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVmsHealthResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.ReadVmsHealth") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVmsHealth" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVmsHealthRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiRegisterVmsInLoadBalancerRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + registerVmsInLoadBalancerRequest *RegisterVmsInLoadBalancerRequest +} + +func (r ApiRegisterVmsInLoadBalancerRequest) RegisterVmsInLoadBalancerRequest(registerVmsInLoadBalancerRequest RegisterVmsInLoadBalancerRequest) ApiRegisterVmsInLoadBalancerRequest { + r.registerVmsInLoadBalancerRequest = ®isterVmsInLoadBalancerRequest + return r +} + +func (r ApiRegisterVmsInLoadBalancerRequest) Execute() (RegisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { + return r.ApiService.RegisterVmsInLoadBalancerExecute(r) +} + +/* + * RegisterVmsInLoadBalancer Method for RegisterVmsInLoadBalancer + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiRegisterVmsInLoadBalancerRequest + */ +func (a *LoadBalancerApiService) RegisterVmsInLoadBalancer(ctx _context.Context) ApiRegisterVmsInLoadBalancerRequest { + return ApiRegisterVmsInLoadBalancerRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return RegisterVmsInLoadBalancerResponse + */ +func (a *LoadBalancerApiService) RegisterVmsInLoadBalancerExecute(r ApiRegisterVmsInLoadBalancerRequest) (RegisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue RegisterVmsInLoadBalancerResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.RegisterVmsInLoadBalancer") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/RegisterVmsInLoadBalancer" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.registerVmsInLoadBalancerRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateLoadBalancerRequest struct { + ctx _context.Context + ApiService *LoadBalancerApiService + updateLoadBalancerRequest *UpdateLoadBalancerRequest +} + +func (r ApiUpdateLoadBalancerRequest) UpdateLoadBalancerRequest(updateLoadBalancerRequest UpdateLoadBalancerRequest) ApiUpdateLoadBalancerRequest { + r.updateLoadBalancerRequest = &updateLoadBalancerRequest + return r +} + +func (r ApiUpdateLoadBalancerRequest) Execute() (UpdateLoadBalancerResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateLoadBalancerExecute(r) +} + +/* + * UpdateLoadBalancer Method for UpdateLoadBalancer + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateLoadBalancerRequest + */ +func (a *LoadBalancerApiService) UpdateLoadBalancer(ctx _context.Context) ApiUpdateLoadBalancerRequest { + return ApiUpdateLoadBalancerRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateLoadBalancerResponse + */ +func (a *LoadBalancerApiService) UpdateLoadBalancerExecute(r ApiUpdateLoadBalancerRequest) (UpdateLoadBalancerResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateLoadBalancerResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerApiService.UpdateLoadBalancer") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateLoadBalancer" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateLoadBalancerRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go new file mode 100644 index 000000000..443422f4c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go @@ -0,0 +1,269 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// LoadBalancerPolicyApiService LoadBalancerPolicyApi service +type LoadBalancerPolicyApiService service + +type ApiCreateLoadBalancerPolicyRequest struct { + ctx _context.Context + ApiService *LoadBalancerPolicyApiService + createLoadBalancerPolicyRequest *CreateLoadBalancerPolicyRequest +} + +func (r ApiCreateLoadBalancerPolicyRequest) CreateLoadBalancerPolicyRequest(createLoadBalancerPolicyRequest CreateLoadBalancerPolicyRequest) ApiCreateLoadBalancerPolicyRequest { + r.createLoadBalancerPolicyRequest = &createLoadBalancerPolicyRequest + return r +} + +func (r ApiCreateLoadBalancerPolicyRequest) Execute() (CreateLoadBalancerPolicyResponse, *_nethttp.Response, error) { + return r.ApiService.CreateLoadBalancerPolicyExecute(r) +} + +/* + * CreateLoadBalancerPolicy Method for CreateLoadBalancerPolicy + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateLoadBalancerPolicyRequest + */ +func (a *LoadBalancerPolicyApiService) CreateLoadBalancerPolicy(ctx _context.Context) ApiCreateLoadBalancerPolicyRequest { + return ApiCreateLoadBalancerPolicyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateLoadBalancerPolicyResponse + */ +func (a *LoadBalancerPolicyApiService) CreateLoadBalancerPolicyExecute(r ApiCreateLoadBalancerPolicyRequest) (CreateLoadBalancerPolicyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateLoadBalancerPolicyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerPolicyApiService.CreateLoadBalancerPolicy") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateLoadBalancerPolicy" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createLoadBalancerPolicyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteLoadBalancerPolicyRequest struct { + ctx _context.Context + ApiService *LoadBalancerPolicyApiService + deleteLoadBalancerPolicyRequest *DeleteLoadBalancerPolicyRequest +} + +func (r ApiDeleteLoadBalancerPolicyRequest) DeleteLoadBalancerPolicyRequest(deleteLoadBalancerPolicyRequest DeleteLoadBalancerPolicyRequest) ApiDeleteLoadBalancerPolicyRequest { + r.deleteLoadBalancerPolicyRequest = &deleteLoadBalancerPolicyRequest + return r +} + +func (r ApiDeleteLoadBalancerPolicyRequest) Execute() (DeleteLoadBalancerPolicyResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteLoadBalancerPolicyExecute(r) +} + +/* + * DeleteLoadBalancerPolicy Method for DeleteLoadBalancerPolicy + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteLoadBalancerPolicyRequest + */ +func (a *LoadBalancerPolicyApiService) DeleteLoadBalancerPolicy(ctx _context.Context) ApiDeleteLoadBalancerPolicyRequest { + return ApiDeleteLoadBalancerPolicyRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteLoadBalancerPolicyResponse + */ +func (a *LoadBalancerPolicyApiService) DeleteLoadBalancerPolicyExecute(r ApiDeleteLoadBalancerPolicyRequest) (DeleteLoadBalancerPolicyResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteLoadBalancerPolicyResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LoadBalancerPolicyApiService.DeleteLoadBalancerPolicy") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteLoadBalancerPolicy" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteLoadBalancerPolicyRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_location.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_location.go new file mode 100644 index 000000000..e4ab8fbe8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_location.go @@ -0,0 +1,134 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// LocationApiService LocationApi service +type LocationApiService service + +type ApiReadLocationsRequest struct { + ctx _context.Context + ApiService *LocationApiService + readLocationsRequest *ReadLocationsRequest +} + +func (r ApiReadLocationsRequest) ReadLocationsRequest(readLocationsRequest ReadLocationsRequest) ApiReadLocationsRequest { + r.readLocationsRequest = &readLocationsRequest + return r +} + +func (r ApiReadLocationsRequest) Execute() (ReadLocationsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadLocationsExecute(r) +} + +/* + * ReadLocations Method for ReadLocations + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadLocationsRequest + */ +func (a *LocationApiService) ReadLocations(ctx _context.Context) ApiReadLocationsRequest { + return ApiReadLocationsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadLocationsResponse + */ +func (a *LocationApiService) ReadLocationsExecute(r ApiReadLocationsRequest) (ReadLocationsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadLocationsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LocationApiService.ReadLocations") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadLocations" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readLocationsRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go new file mode 100644 index 000000000..a3aa9a89f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go @@ -0,0 +1,477 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// NatServiceApiService NatServiceApi service +type NatServiceApiService service + +type ApiCreateNatServiceRequest struct { + ctx _context.Context + ApiService *NatServiceApiService + createNatServiceRequest *CreateNatServiceRequest +} + +func (r ApiCreateNatServiceRequest) CreateNatServiceRequest(createNatServiceRequest CreateNatServiceRequest) ApiCreateNatServiceRequest { + r.createNatServiceRequest = &createNatServiceRequest + return r +} + +func (r ApiCreateNatServiceRequest) Execute() (CreateNatServiceResponse, *_nethttp.Response, error) { + return r.ApiService.CreateNatServiceExecute(r) +} + +/* + * CreateNatService Method for CreateNatService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateNatServiceRequest + */ +func (a *NatServiceApiService) CreateNatService(ctx _context.Context) ApiCreateNatServiceRequest { + return ApiCreateNatServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateNatServiceResponse + */ +func (a *NatServiceApiService) CreateNatServiceExecute(r ApiCreateNatServiceRequest) (CreateNatServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateNatServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NatServiceApiService.CreateNatService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateNatService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createNatServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteNatServiceRequest struct { + ctx _context.Context + ApiService *NatServiceApiService + deleteNatServiceRequest *DeleteNatServiceRequest +} + +func (r ApiDeleteNatServiceRequest) DeleteNatServiceRequest(deleteNatServiceRequest DeleteNatServiceRequest) ApiDeleteNatServiceRequest { + r.deleteNatServiceRequest = &deleteNatServiceRequest + return r +} + +func (r ApiDeleteNatServiceRequest) Execute() (DeleteNatServiceResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteNatServiceExecute(r) +} + +/* + * DeleteNatService Method for DeleteNatService + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteNatServiceRequest + */ +func (a *NatServiceApiService) DeleteNatService(ctx _context.Context) ApiDeleteNatServiceRequest { + return ApiDeleteNatServiceRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteNatServiceResponse + */ +func (a *NatServiceApiService) DeleteNatServiceExecute(r ApiDeleteNatServiceRequest) (DeleteNatServiceResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteNatServiceResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NatServiceApiService.DeleteNatService") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteNatService" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteNatServiceRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNatServicesRequest struct { + ctx _context.Context + ApiService *NatServiceApiService + readNatServicesRequest *ReadNatServicesRequest +} + +func (r ApiReadNatServicesRequest) ReadNatServicesRequest(readNatServicesRequest ReadNatServicesRequest) ApiReadNatServicesRequest { + r.readNatServicesRequest = &readNatServicesRequest + return r +} + +func (r ApiReadNatServicesRequest) Execute() (ReadNatServicesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNatServicesExecute(r) +} + +/* + * ReadNatServices Method for ReadNatServices + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNatServicesRequest + */ +func (a *NatServiceApiService) ReadNatServices(ctx _context.Context) ApiReadNatServicesRequest { + return ApiReadNatServicesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNatServicesResponse + */ +func (a *NatServiceApiService) ReadNatServicesExecute(r ApiReadNatServicesRequest) (ReadNatServicesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNatServicesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NatServiceApiService.ReadNatServices") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNatServices" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNatServicesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_net.go new file mode 100644 index 000000000..a6720b59b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_net.go @@ -0,0 +1,637 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// NetApiService NetApi service +type NetApiService service + +type ApiCreateNetRequest struct { + ctx _context.Context + ApiService *NetApiService + createNetRequest *CreateNetRequest +} + +func (r ApiCreateNetRequest) CreateNetRequest(createNetRequest CreateNetRequest) ApiCreateNetRequest { + r.createNetRequest = &createNetRequest + return r +} + +func (r ApiCreateNetRequest) Execute() (CreateNetResponse, *_nethttp.Response, error) { + return r.ApiService.CreateNetExecute(r) +} + +/* + * CreateNet Method for CreateNet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateNetRequest + */ +func (a *NetApiService) CreateNet(ctx _context.Context) ApiCreateNetRequest { + return ApiCreateNetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateNetResponse + */ +func (a *NetApiService) CreateNetExecute(r ApiCreateNetRequest) (CreateNetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateNetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetApiService.CreateNet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateNet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createNetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteNetRequest struct { + ctx _context.Context + ApiService *NetApiService + deleteNetRequest *DeleteNetRequest +} + +func (r ApiDeleteNetRequest) DeleteNetRequest(deleteNetRequest DeleteNetRequest) ApiDeleteNetRequest { + r.deleteNetRequest = &deleteNetRequest + return r +} + +func (r ApiDeleteNetRequest) Execute() (DeleteNetResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteNetExecute(r) +} + +/* + * DeleteNet Method for DeleteNet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteNetRequest + */ +func (a *NetApiService) DeleteNet(ctx _context.Context) ApiDeleteNetRequest { + return ApiDeleteNetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteNetResponse + */ +func (a *NetApiService) DeleteNetExecute(r ApiDeleteNetRequest) (DeleteNetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteNetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetApiService.DeleteNet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteNet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteNetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNetsRequest struct { + ctx _context.Context + ApiService *NetApiService + readNetsRequest *ReadNetsRequest +} + +func (r ApiReadNetsRequest) ReadNetsRequest(readNetsRequest ReadNetsRequest) ApiReadNetsRequest { + r.readNetsRequest = &readNetsRequest + return r +} + +func (r ApiReadNetsRequest) Execute() (ReadNetsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNetsExecute(r) +} + +/* + * ReadNets Method for ReadNets + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNetsRequest + */ +func (a *NetApiService) ReadNets(ctx _context.Context) ApiReadNetsRequest { + return ApiReadNetsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNetsResponse + */ +func (a *NetApiService) ReadNetsExecute(r ApiReadNetsRequest) (ReadNetsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNetsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetApiService.ReadNets") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNets" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNetsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateNetRequest struct { + ctx _context.Context + ApiService *NetApiService + updateNetRequest *UpdateNetRequest +} + +func (r ApiUpdateNetRequest) UpdateNetRequest(updateNetRequest UpdateNetRequest) ApiUpdateNetRequest { + r.updateNetRequest = &updateNetRequest + return r +} + +func (r ApiUpdateNetRequest) Execute() (UpdateNetResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateNetExecute(r) +} + +/* + * UpdateNet Method for UpdateNet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateNetRequest + */ +func (a *NetApiService) UpdateNet(ctx _context.Context) ApiUpdateNetRequest { + return ApiUpdateNetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateNetResponse + */ +func (a *NetApiService) UpdateNetExecute(r ApiUpdateNetRequest) (UpdateNetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateNetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetApiService.UpdateNet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateNet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateNetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go new file mode 100644 index 000000000..9aff2d9e1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go @@ -0,0 +1,618 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// NetAccessPointApiService NetAccessPointApi service +type NetAccessPointApiService service + +type ApiCreateNetAccessPointRequest struct { + ctx _context.Context + ApiService *NetAccessPointApiService + createNetAccessPointRequest *CreateNetAccessPointRequest +} + +func (r ApiCreateNetAccessPointRequest) CreateNetAccessPointRequest(createNetAccessPointRequest CreateNetAccessPointRequest) ApiCreateNetAccessPointRequest { + r.createNetAccessPointRequest = &createNetAccessPointRequest + return r +} + +func (r ApiCreateNetAccessPointRequest) Execute() (CreateNetAccessPointResponse, *_nethttp.Response, error) { + return r.ApiService.CreateNetAccessPointExecute(r) +} + +/* + * CreateNetAccessPoint Method for CreateNetAccessPoint + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateNetAccessPointRequest + */ +func (a *NetAccessPointApiService) CreateNetAccessPoint(ctx _context.Context) ApiCreateNetAccessPointRequest { + return ApiCreateNetAccessPointRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateNetAccessPointResponse + */ +func (a *NetAccessPointApiService) CreateNetAccessPointExecute(r ApiCreateNetAccessPointRequest) (CreateNetAccessPointResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateNetAccessPointResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetAccessPointApiService.CreateNetAccessPoint") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateNetAccessPoint" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createNetAccessPointRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteNetAccessPointRequest struct { + ctx _context.Context + ApiService *NetAccessPointApiService + deleteNetAccessPointRequest *DeleteNetAccessPointRequest +} + +func (r ApiDeleteNetAccessPointRequest) DeleteNetAccessPointRequest(deleteNetAccessPointRequest DeleteNetAccessPointRequest) ApiDeleteNetAccessPointRequest { + r.deleteNetAccessPointRequest = &deleteNetAccessPointRequest + return r +} + +func (r ApiDeleteNetAccessPointRequest) Execute() (DeleteNetAccessPointResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteNetAccessPointExecute(r) +} + +/* + * DeleteNetAccessPoint Method for DeleteNetAccessPoint + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteNetAccessPointRequest + */ +func (a *NetAccessPointApiService) DeleteNetAccessPoint(ctx _context.Context) ApiDeleteNetAccessPointRequest { + return ApiDeleteNetAccessPointRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteNetAccessPointResponse + */ +func (a *NetAccessPointApiService) DeleteNetAccessPointExecute(r ApiDeleteNetAccessPointRequest) (DeleteNetAccessPointResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteNetAccessPointResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetAccessPointApiService.DeleteNetAccessPoint") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteNetAccessPoint" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteNetAccessPointRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNetAccessPointServicesRequest struct { + ctx _context.Context + ApiService *NetAccessPointApiService + readNetAccessPointServicesRequest *ReadNetAccessPointServicesRequest +} + +func (r ApiReadNetAccessPointServicesRequest) ReadNetAccessPointServicesRequest(readNetAccessPointServicesRequest ReadNetAccessPointServicesRequest) ApiReadNetAccessPointServicesRequest { + r.readNetAccessPointServicesRequest = &readNetAccessPointServicesRequest + return r +} + +func (r ApiReadNetAccessPointServicesRequest) Execute() (ReadNetAccessPointServicesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNetAccessPointServicesExecute(r) +} + +/* + * ReadNetAccessPointServices Method for ReadNetAccessPointServices + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNetAccessPointServicesRequest + */ +func (a *NetAccessPointApiService) ReadNetAccessPointServices(ctx _context.Context) ApiReadNetAccessPointServicesRequest { + return ApiReadNetAccessPointServicesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNetAccessPointServicesResponse + */ +func (a *NetAccessPointApiService) ReadNetAccessPointServicesExecute(r ApiReadNetAccessPointServicesRequest) (ReadNetAccessPointServicesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNetAccessPointServicesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetAccessPointApiService.ReadNetAccessPointServices") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNetAccessPointServices" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNetAccessPointServicesRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNetAccessPointsRequest struct { + ctx _context.Context + ApiService *NetAccessPointApiService + readNetAccessPointsRequest *ReadNetAccessPointsRequest +} + +func (r ApiReadNetAccessPointsRequest) ReadNetAccessPointsRequest(readNetAccessPointsRequest ReadNetAccessPointsRequest) ApiReadNetAccessPointsRequest { + r.readNetAccessPointsRequest = &readNetAccessPointsRequest + return r +} + +func (r ApiReadNetAccessPointsRequest) Execute() (ReadNetAccessPointsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNetAccessPointsExecute(r) +} + +/* + * ReadNetAccessPoints Method for ReadNetAccessPoints + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNetAccessPointsRequest + */ +func (a *NetAccessPointApiService) ReadNetAccessPoints(ctx _context.Context) ApiReadNetAccessPointsRequest { + return ApiReadNetAccessPointsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNetAccessPointsResponse + */ +func (a *NetAccessPointApiService) ReadNetAccessPointsExecute(r ApiReadNetAccessPointsRequest) (ReadNetAccessPointsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNetAccessPointsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetAccessPointApiService.ReadNetAccessPoints") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNetAccessPoints" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNetAccessPointsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateNetAccessPointRequest struct { + ctx _context.Context + ApiService *NetAccessPointApiService + updateNetAccessPointRequest *UpdateNetAccessPointRequest +} + +func (r ApiUpdateNetAccessPointRequest) UpdateNetAccessPointRequest(updateNetAccessPointRequest UpdateNetAccessPointRequest) ApiUpdateNetAccessPointRequest { + r.updateNetAccessPointRequest = &updateNetAccessPointRequest + return r +} + +func (r ApiUpdateNetAccessPointRequest) Execute() (UpdateNetAccessPointResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateNetAccessPointExecute(r) +} + +/* + * UpdateNetAccessPoint Method for UpdateNetAccessPoint + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateNetAccessPointRequest + */ +func (a *NetAccessPointApiService) UpdateNetAccessPoint(ctx _context.Context) ApiUpdateNetAccessPointRequest { + return ApiUpdateNetAccessPointRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateNetAccessPointResponse + */ +func (a *NetAccessPointApiService) UpdateNetAccessPointExecute(r ApiUpdateNetAccessPointRequest) (UpdateNetAccessPointResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateNetAccessPointResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetAccessPointApiService.UpdateNetAccessPoint") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateNetAccessPoint" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateNetAccessPointRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go new file mode 100644 index 000000000..22f71f51c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go @@ -0,0 +1,807 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// NetPeeringApiService NetPeeringApi service +type NetPeeringApiService service + +type ApiAcceptNetPeeringRequest struct { + ctx _context.Context + ApiService *NetPeeringApiService + acceptNetPeeringRequest *AcceptNetPeeringRequest +} + +func (r ApiAcceptNetPeeringRequest) AcceptNetPeeringRequest(acceptNetPeeringRequest AcceptNetPeeringRequest) ApiAcceptNetPeeringRequest { + r.acceptNetPeeringRequest = &acceptNetPeeringRequest + return r +} + +func (r ApiAcceptNetPeeringRequest) Execute() (AcceptNetPeeringResponse, *_nethttp.Response, error) { + return r.ApiService.AcceptNetPeeringExecute(r) +} + +/* + * AcceptNetPeering Method for AcceptNetPeering + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiAcceptNetPeeringRequest + */ +func (a *NetPeeringApiService) AcceptNetPeering(ctx _context.Context) ApiAcceptNetPeeringRequest { + return ApiAcceptNetPeeringRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return AcceptNetPeeringResponse + */ +func (a *NetPeeringApiService) AcceptNetPeeringExecute(r ApiAcceptNetPeeringRequest) (AcceptNetPeeringResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue AcceptNetPeeringResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetPeeringApiService.AcceptNetPeering") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/AcceptNetPeering" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.acceptNetPeeringRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateNetPeeringRequest struct { + ctx _context.Context + ApiService *NetPeeringApiService + createNetPeeringRequest *CreateNetPeeringRequest +} + +func (r ApiCreateNetPeeringRequest) CreateNetPeeringRequest(createNetPeeringRequest CreateNetPeeringRequest) ApiCreateNetPeeringRequest { + r.createNetPeeringRequest = &createNetPeeringRequest + return r +} + +func (r ApiCreateNetPeeringRequest) Execute() (CreateNetPeeringResponse, *_nethttp.Response, error) { + return r.ApiService.CreateNetPeeringExecute(r) +} + +/* + * CreateNetPeering Method for CreateNetPeering + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateNetPeeringRequest + */ +func (a *NetPeeringApiService) CreateNetPeering(ctx _context.Context) ApiCreateNetPeeringRequest { + return ApiCreateNetPeeringRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateNetPeeringResponse + */ +func (a *NetPeeringApiService) CreateNetPeeringExecute(r ApiCreateNetPeeringRequest) (CreateNetPeeringResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateNetPeeringResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetPeeringApiService.CreateNetPeering") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateNetPeering" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createNetPeeringRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteNetPeeringRequest struct { + ctx _context.Context + ApiService *NetPeeringApiService + deleteNetPeeringRequest *DeleteNetPeeringRequest +} + +func (r ApiDeleteNetPeeringRequest) DeleteNetPeeringRequest(deleteNetPeeringRequest DeleteNetPeeringRequest) ApiDeleteNetPeeringRequest { + r.deleteNetPeeringRequest = &deleteNetPeeringRequest + return r +} + +func (r ApiDeleteNetPeeringRequest) Execute() (DeleteNetPeeringResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteNetPeeringExecute(r) +} + +/* + * DeleteNetPeering Method for DeleteNetPeering + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteNetPeeringRequest + */ +func (a *NetPeeringApiService) DeleteNetPeering(ctx _context.Context) ApiDeleteNetPeeringRequest { + return ApiDeleteNetPeeringRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteNetPeeringResponse + */ +func (a *NetPeeringApiService) DeleteNetPeeringExecute(r ApiDeleteNetPeeringRequest) (DeleteNetPeeringResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteNetPeeringResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetPeeringApiService.DeleteNetPeering") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteNetPeering" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteNetPeeringRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNetPeeringsRequest struct { + ctx _context.Context + ApiService *NetPeeringApiService + readNetPeeringsRequest *ReadNetPeeringsRequest +} + +func (r ApiReadNetPeeringsRequest) ReadNetPeeringsRequest(readNetPeeringsRequest ReadNetPeeringsRequest) ApiReadNetPeeringsRequest { + r.readNetPeeringsRequest = &readNetPeeringsRequest + return r +} + +func (r ApiReadNetPeeringsRequest) Execute() (ReadNetPeeringsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNetPeeringsExecute(r) +} + +/* + * ReadNetPeerings Method for ReadNetPeerings + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNetPeeringsRequest + */ +func (a *NetPeeringApiService) ReadNetPeerings(ctx _context.Context) ApiReadNetPeeringsRequest { + return ApiReadNetPeeringsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNetPeeringsResponse + */ +func (a *NetPeeringApiService) ReadNetPeeringsExecute(r ApiReadNetPeeringsRequest) (ReadNetPeeringsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNetPeeringsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetPeeringApiService.ReadNetPeerings") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNetPeerings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNetPeeringsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiRejectNetPeeringRequest struct { + ctx _context.Context + ApiService *NetPeeringApiService + rejectNetPeeringRequest *RejectNetPeeringRequest +} + +func (r ApiRejectNetPeeringRequest) RejectNetPeeringRequest(rejectNetPeeringRequest RejectNetPeeringRequest) ApiRejectNetPeeringRequest { + r.rejectNetPeeringRequest = &rejectNetPeeringRequest + return r +} + +func (r ApiRejectNetPeeringRequest) Execute() (RejectNetPeeringResponse, *_nethttp.Response, error) { + return r.ApiService.RejectNetPeeringExecute(r) +} + +/* + * RejectNetPeering Method for RejectNetPeering + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiRejectNetPeeringRequest + */ +func (a *NetPeeringApiService) RejectNetPeering(ctx _context.Context) ApiRejectNetPeeringRequest { + return ApiRejectNetPeeringRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return RejectNetPeeringResponse + */ +func (a *NetPeeringApiService) RejectNetPeeringExecute(r ApiRejectNetPeeringRequest) (RejectNetPeeringResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue RejectNetPeeringResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NetPeeringApiService.RejectNetPeering") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/RejectNetPeering" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.rejectNetPeeringRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go new file mode 100644 index 000000000..d9920922a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go @@ -0,0 +1,1227 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// NicApiService NicApi service +type NicApiService service + +type ApiCreateNicRequest struct { + ctx _context.Context + ApiService *NicApiService + createNicRequest *CreateNicRequest +} + +func (r ApiCreateNicRequest) CreateNicRequest(createNicRequest CreateNicRequest) ApiCreateNicRequest { + r.createNicRequest = &createNicRequest + return r +} + +func (r ApiCreateNicRequest) Execute() (CreateNicResponse, *_nethttp.Response, error) { + return r.ApiService.CreateNicExecute(r) +} + +/* + * CreateNic Method for CreateNic + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateNicRequest + */ +func (a *NicApiService) CreateNic(ctx _context.Context) ApiCreateNicRequest { + return ApiCreateNicRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateNicResponse + */ +func (a *NicApiService) CreateNicExecute(r ApiCreateNicRequest) (CreateNicResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateNicResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.CreateNic") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateNic" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createNicRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteNicRequest struct { + ctx _context.Context + ApiService *NicApiService + deleteNicRequest *DeleteNicRequest +} + +func (r ApiDeleteNicRequest) DeleteNicRequest(deleteNicRequest DeleteNicRequest) ApiDeleteNicRequest { + r.deleteNicRequest = &deleteNicRequest + return r +} + +func (r ApiDeleteNicRequest) Execute() (DeleteNicResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteNicExecute(r) +} + +/* + * DeleteNic Method for DeleteNic + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteNicRequest + */ +func (a *NicApiService) DeleteNic(ctx _context.Context) ApiDeleteNicRequest { + return ApiDeleteNicRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteNicResponse + */ +func (a *NicApiService) DeleteNicExecute(r ApiDeleteNicRequest) (DeleteNicResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteNicResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.DeleteNic") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteNic" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteNicRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkNicRequest struct { + ctx _context.Context + ApiService *NicApiService + linkNicRequest *LinkNicRequest +} + +func (r ApiLinkNicRequest) LinkNicRequest(linkNicRequest LinkNicRequest) ApiLinkNicRequest { + r.linkNicRequest = &linkNicRequest + return r +} + +func (r ApiLinkNicRequest) Execute() (LinkNicResponse, *_nethttp.Response, error) { + return r.ApiService.LinkNicExecute(r) +} + +/* + * LinkNic Method for LinkNic + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkNicRequest + */ +func (a *NicApiService) LinkNic(ctx _context.Context) ApiLinkNicRequest { + return ApiLinkNicRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkNicResponse + */ +func (a *NicApiService) LinkNicExecute(r ApiLinkNicRequest) (LinkNicResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkNicResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.LinkNic") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkNic" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkNicRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkPrivateIpsRequest struct { + ctx _context.Context + ApiService *NicApiService + linkPrivateIpsRequest *LinkPrivateIpsRequest +} + +func (r ApiLinkPrivateIpsRequest) LinkPrivateIpsRequest(linkPrivateIpsRequest LinkPrivateIpsRequest) ApiLinkPrivateIpsRequest { + r.linkPrivateIpsRequest = &linkPrivateIpsRequest + return r +} + +func (r ApiLinkPrivateIpsRequest) Execute() (LinkPrivateIpsResponse, *_nethttp.Response, error) { + return r.ApiService.LinkPrivateIpsExecute(r) +} + +/* + * LinkPrivateIps Method for LinkPrivateIps + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkPrivateIpsRequest + */ +func (a *NicApiService) LinkPrivateIps(ctx _context.Context) ApiLinkPrivateIpsRequest { + return ApiLinkPrivateIpsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkPrivateIpsResponse + */ +func (a *NicApiService) LinkPrivateIpsExecute(r ApiLinkPrivateIpsRequest) (LinkPrivateIpsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkPrivateIpsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.LinkPrivateIps") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkPrivateIps" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkPrivateIpsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadNicsRequest struct { + ctx _context.Context + ApiService *NicApiService + readNicsRequest *ReadNicsRequest +} + +func (r ApiReadNicsRequest) ReadNicsRequest(readNicsRequest ReadNicsRequest) ApiReadNicsRequest { + r.readNicsRequest = &readNicsRequest + return r +} + +func (r ApiReadNicsRequest) Execute() (ReadNicsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadNicsExecute(r) +} + +/* + * ReadNics Method for ReadNics + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadNicsRequest + */ +func (a *NicApiService) ReadNics(ctx _context.Context) ApiReadNicsRequest { + return ApiReadNicsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadNicsResponse + */ +func (a *NicApiService) ReadNicsExecute(r ApiReadNicsRequest) (ReadNicsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadNicsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.ReadNics") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadNics" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readNicsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkNicRequest struct { + ctx _context.Context + ApiService *NicApiService + unlinkNicRequest *UnlinkNicRequest +} + +func (r ApiUnlinkNicRequest) UnlinkNicRequest(unlinkNicRequest UnlinkNicRequest) ApiUnlinkNicRequest { + r.unlinkNicRequest = &unlinkNicRequest + return r +} + +func (r ApiUnlinkNicRequest) Execute() (UnlinkNicResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkNicExecute(r) +} + +/* + * UnlinkNic Method for UnlinkNic + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkNicRequest + */ +func (a *NicApiService) UnlinkNic(ctx _context.Context) ApiUnlinkNicRequest { + return ApiUnlinkNicRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkNicResponse + */ +func (a *NicApiService) UnlinkNicExecute(r ApiUnlinkNicRequest) (UnlinkNicResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkNicResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.UnlinkNic") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkNic" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkNicRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkPrivateIpsRequest struct { + ctx _context.Context + ApiService *NicApiService + unlinkPrivateIpsRequest *UnlinkPrivateIpsRequest +} + +func (r ApiUnlinkPrivateIpsRequest) UnlinkPrivateIpsRequest(unlinkPrivateIpsRequest UnlinkPrivateIpsRequest) ApiUnlinkPrivateIpsRequest { + r.unlinkPrivateIpsRequest = &unlinkPrivateIpsRequest + return r +} + +func (r ApiUnlinkPrivateIpsRequest) Execute() (UnlinkPrivateIpsResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkPrivateIpsExecute(r) +} + +/* + * UnlinkPrivateIps Method for UnlinkPrivateIps + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkPrivateIpsRequest + */ +func (a *NicApiService) UnlinkPrivateIps(ctx _context.Context) ApiUnlinkPrivateIpsRequest { + return ApiUnlinkPrivateIpsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkPrivateIpsResponse + */ +func (a *NicApiService) UnlinkPrivateIpsExecute(r ApiUnlinkPrivateIpsRequest) (UnlinkPrivateIpsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkPrivateIpsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.UnlinkPrivateIps") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkPrivateIps" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkPrivateIpsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateNicRequest struct { + ctx _context.Context + ApiService *NicApiService + updateNicRequest *UpdateNicRequest +} + +func (r ApiUpdateNicRequest) UpdateNicRequest(updateNicRequest UpdateNicRequest) ApiUpdateNicRequest { + r.updateNicRequest = &updateNicRequest + return r +} + +func (r ApiUpdateNicRequest) Execute() (UpdateNicResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateNicExecute(r) +} + +/* + * UpdateNic Method for UpdateNic + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateNicRequest + */ +func (a *NicApiService) UpdateNic(ctx _context.Context) ApiUpdateNicRequest { + return ApiUpdateNicRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateNicResponse + */ +func (a *NicApiService) UpdateNicExecute(r ApiUpdateNicRequest) (UpdateNicResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateNicResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "NicApiService.UpdateNic") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateNic" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateNicRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go new file mode 100644 index 000000000..1eace1edc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go @@ -0,0 +1,134 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ProductTypeApiService ProductTypeApi service +type ProductTypeApiService service + +type ApiReadProductTypesRequest struct { + ctx _context.Context + ApiService *ProductTypeApiService + readProductTypesRequest *ReadProductTypesRequest +} + +func (r ApiReadProductTypesRequest) ReadProductTypesRequest(readProductTypesRequest ReadProductTypesRequest) ApiReadProductTypesRequest { + r.readProductTypesRequest = &readProductTypesRequest + return r +} + +func (r ApiReadProductTypesRequest) Execute() (ReadProductTypesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadProductTypesExecute(r) +} + +/* + * ReadProductTypes Method for ReadProductTypes + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadProductTypesRequest + */ +func (a *ProductTypeApiService) ReadProductTypes(ctx _context.Context) ApiReadProductTypesRequest { + return ApiReadProductTypesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadProductTypesResponse + */ +func (a *ProductTypeApiService) ReadProductTypesExecute(r ApiReadProductTypesRequest) (ReadProductTypesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadProductTypesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ProductTypeApiService.ReadProductTypes") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadProductTypes" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readProductTypesRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go new file mode 100644 index 000000000..439097902 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go @@ -0,0 +1,884 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// PublicIpApiService PublicIpApi service +type PublicIpApiService service + +type ApiCreatePublicIpRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + createPublicIpRequest *CreatePublicIpRequest +} + +func (r ApiCreatePublicIpRequest) CreatePublicIpRequest(createPublicIpRequest CreatePublicIpRequest) ApiCreatePublicIpRequest { + r.createPublicIpRequest = &createPublicIpRequest + return r +} + +func (r ApiCreatePublicIpRequest) Execute() (CreatePublicIpResponse, *_nethttp.Response, error) { + return r.ApiService.CreatePublicIpExecute(r) +} + +/* + * CreatePublicIp Method for CreatePublicIp + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreatePublicIpRequest + */ +func (a *PublicIpApiService) CreatePublicIp(ctx _context.Context) ApiCreatePublicIpRequest { + return ApiCreatePublicIpRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreatePublicIpResponse + */ +func (a *PublicIpApiService) CreatePublicIpExecute(r ApiCreatePublicIpRequest) (CreatePublicIpResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreatePublicIpResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.CreatePublicIp") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreatePublicIp" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createPublicIpRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeletePublicIpRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + deletePublicIpRequest *DeletePublicIpRequest +} + +func (r ApiDeletePublicIpRequest) DeletePublicIpRequest(deletePublicIpRequest DeletePublicIpRequest) ApiDeletePublicIpRequest { + r.deletePublicIpRequest = &deletePublicIpRequest + return r +} + +func (r ApiDeletePublicIpRequest) Execute() (DeletePublicIpResponse, *_nethttp.Response, error) { + return r.ApiService.DeletePublicIpExecute(r) +} + +/* + * DeletePublicIp Method for DeletePublicIp + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeletePublicIpRequest + */ +func (a *PublicIpApiService) DeletePublicIp(ctx _context.Context) ApiDeletePublicIpRequest { + return ApiDeletePublicIpRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeletePublicIpResponse + */ +func (a *PublicIpApiService) DeletePublicIpExecute(r ApiDeletePublicIpRequest) (DeletePublicIpResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeletePublicIpResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.DeletePublicIp") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeletePublicIp" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deletePublicIpRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkPublicIpRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + linkPublicIpRequest *LinkPublicIpRequest +} + +func (r ApiLinkPublicIpRequest) LinkPublicIpRequest(linkPublicIpRequest LinkPublicIpRequest) ApiLinkPublicIpRequest { + r.linkPublicIpRequest = &linkPublicIpRequest + return r +} + +func (r ApiLinkPublicIpRequest) Execute() (LinkPublicIpResponse, *_nethttp.Response, error) { + return r.ApiService.LinkPublicIpExecute(r) +} + +/* + * LinkPublicIp Method for LinkPublicIp + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkPublicIpRequest + */ +func (a *PublicIpApiService) LinkPublicIp(ctx _context.Context) ApiLinkPublicIpRequest { + return ApiLinkPublicIpRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkPublicIpResponse + */ +func (a *PublicIpApiService) LinkPublicIpExecute(r ApiLinkPublicIpRequest) (LinkPublicIpResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkPublicIpResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.LinkPublicIp") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkPublicIp" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkPublicIpRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadPublicIpRangesRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + readPublicIpRangesRequest *ReadPublicIpRangesRequest +} + +func (r ApiReadPublicIpRangesRequest) ReadPublicIpRangesRequest(readPublicIpRangesRequest ReadPublicIpRangesRequest) ApiReadPublicIpRangesRequest { + r.readPublicIpRangesRequest = &readPublicIpRangesRequest + return r +} + +func (r ApiReadPublicIpRangesRequest) Execute() (ReadPublicIpRangesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadPublicIpRangesExecute(r) +} + +/* + * ReadPublicIpRanges Method for ReadPublicIpRanges + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadPublicIpRangesRequest + */ +func (a *PublicIpApiService) ReadPublicIpRanges(ctx _context.Context) ApiReadPublicIpRangesRequest { + return ApiReadPublicIpRangesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadPublicIpRangesResponse + */ +func (a *PublicIpApiService) ReadPublicIpRangesExecute(r ApiReadPublicIpRangesRequest) (ReadPublicIpRangesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadPublicIpRangesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.ReadPublicIpRanges") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadPublicIpRanges" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readPublicIpRangesRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadPublicIpsRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + readPublicIpsRequest *ReadPublicIpsRequest +} + +func (r ApiReadPublicIpsRequest) ReadPublicIpsRequest(readPublicIpsRequest ReadPublicIpsRequest) ApiReadPublicIpsRequest { + r.readPublicIpsRequest = &readPublicIpsRequest + return r +} + +func (r ApiReadPublicIpsRequest) Execute() (ReadPublicIpsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadPublicIpsExecute(r) +} + +/* + * ReadPublicIps Method for ReadPublicIps + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadPublicIpsRequest + */ +func (a *PublicIpApiService) ReadPublicIps(ctx _context.Context) ApiReadPublicIpsRequest { + return ApiReadPublicIpsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadPublicIpsResponse + */ +func (a *PublicIpApiService) ReadPublicIpsExecute(r ApiReadPublicIpsRequest) (ReadPublicIpsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadPublicIpsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.ReadPublicIps") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadPublicIps" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readPublicIpsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkPublicIpRequest struct { + ctx _context.Context + ApiService *PublicIpApiService + unlinkPublicIpRequest *UnlinkPublicIpRequest +} + +func (r ApiUnlinkPublicIpRequest) UnlinkPublicIpRequest(unlinkPublicIpRequest UnlinkPublicIpRequest) ApiUnlinkPublicIpRequest { + r.unlinkPublicIpRequest = &unlinkPublicIpRequest + return r +} + +func (r ApiUnlinkPublicIpRequest) Execute() (UnlinkPublicIpResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkPublicIpExecute(r) +} + +/* + * UnlinkPublicIp Method for UnlinkPublicIp + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkPublicIpRequest + */ +func (a *PublicIpApiService) UnlinkPublicIp(ctx _context.Context) ApiUnlinkPublicIpRequest { + return ApiUnlinkPublicIpRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkPublicIpResponse + */ +func (a *PublicIpApiService) UnlinkPublicIpExecute(r ApiUnlinkPublicIpRequest) (UnlinkPublicIpResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkPublicIpResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "PublicIpApiService.UnlinkPublicIp") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkPublicIp" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkPublicIpRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go new file mode 100644 index 000000000..f2697ebe6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go @@ -0,0 +1,148 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// QuotaApiService QuotaApi service +type QuotaApiService service + +type ApiReadQuotasRequest struct { + ctx _context.Context + ApiService *QuotaApiService + readQuotasRequest *ReadQuotasRequest +} + +func (r ApiReadQuotasRequest) ReadQuotasRequest(readQuotasRequest ReadQuotasRequest) ApiReadQuotasRequest { + r.readQuotasRequest = &readQuotasRequest + return r +} + +func (r ApiReadQuotasRequest) Execute() (ReadQuotasResponse, *_nethttp.Response, error) { + return r.ApiService.ReadQuotasExecute(r) +} + +/* + * ReadQuotas Method for ReadQuotas + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadQuotasRequest + */ +func (a *QuotaApiService) ReadQuotas(ctx _context.Context) ApiReadQuotasRequest { + return ApiReadQuotasRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadQuotasResponse + */ +func (a *QuotaApiService) ReadQuotasExecute(r ApiReadQuotasRequest) (ReadQuotasResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadQuotasResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "QuotaApiService.ReadQuotas") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadQuotas" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readQuotasRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_region.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_region.go new file mode 100644 index 000000000..9e5234204 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_region.go @@ -0,0 +1,148 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// RegionApiService RegionApi service +type RegionApiService service + +type ApiReadRegionsRequest struct { + ctx _context.Context + ApiService *RegionApiService + readRegionsRequest *ReadRegionsRequest +} + +func (r ApiReadRegionsRequest) ReadRegionsRequest(readRegionsRequest ReadRegionsRequest) ApiReadRegionsRequest { + r.readRegionsRequest = &readRegionsRequest + return r +} + +func (r ApiReadRegionsRequest) Execute() (ReadRegionsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadRegionsExecute(r) +} + +/* + * ReadRegions Method for ReadRegions + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadRegionsRequest + */ +func (a *RegionApiService) ReadRegions(ctx _context.Context) ApiReadRegionsRequest { + return ApiReadRegionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadRegionsResponse + */ +func (a *RegionApiService) ReadRegionsExecute(r ApiReadRegionsRequest) (ReadRegionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadRegionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RegionApiService.ReadRegions") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadRegions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readRegionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_route.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_route.go new file mode 100644 index 000000000..8104e3975 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_route.go @@ -0,0 +1,477 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// RouteApiService RouteApi service +type RouteApiService service + +type ApiCreateRouteRequest struct { + ctx _context.Context + ApiService *RouteApiService + createRouteRequest *CreateRouteRequest +} + +func (r ApiCreateRouteRequest) CreateRouteRequest(createRouteRequest CreateRouteRequest) ApiCreateRouteRequest { + r.createRouteRequest = &createRouteRequest + return r +} + +func (r ApiCreateRouteRequest) Execute() (CreateRouteResponse, *_nethttp.Response, error) { + return r.ApiService.CreateRouteExecute(r) +} + +/* + * CreateRoute Method for CreateRoute + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateRouteRequest + */ +func (a *RouteApiService) CreateRoute(ctx _context.Context) ApiCreateRouteRequest { + return ApiCreateRouteRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateRouteResponse + */ +func (a *RouteApiService) CreateRouteExecute(r ApiCreateRouteRequest) (CreateRouteResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateRouteResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteApiService.CreateRoute") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateRoute" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createRouteRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteRouteRequest struct { + ctx _context.Context + ApiService *RouteApiService + deleteRouteRequest *DeleteRouteRequest +} + +func (r ApiDeleteRouteRequest) DeleteRouteRequest(deleteRouteRequest DeleteRouteRequest) ApiDeleteRouteRequest { + r.deleteRouteRequest = &deleteRouteRequest + return r +} + +func (r ApiDeleteRouteRequest) Execute() (DeleteRouteResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteRouteExecute(r) +} + +/* + * DeleteRoute Method for DeleteRoute + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteRouteRequest + */ +func (a *RouteApiService) DeleteRoute(ctx _context.Context) ApiDeleteRouteRequest { + return ApiDeleteRouteRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteRouteResponse + */ +func (a *RouteApiService) DeleteRouteExecute(r ApiDeleteRouteRequest) (DeleteRouteResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteRouteResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteApiService.DeleteRoute") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteRoute" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteRouteRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateRouteRequest struct { + ctx _context.Context + ApiService *RouteApiService + updateRouteRequest *UpdateRouteRequest +} + +func (r ApiUpdateRouteRequest) UpdateRouteRequest(updateRouteRequest UpdateRouteRequest) ApiUpdateRouteRequest { + r.updateRouteRequest = &updateRouteRequest + return r +} + +func (r ApiUpdateRouteRequest) Execute() (UpdateRouteResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateRouteExecute(r) +} + +/* + * UpdateRoute Method for UpdateRoute + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateRouteRequest + */ +func (a *RouteApiService) UpdateRoute(ctx _context.Context) ApiUpdateRouteRequest { + return ApiUpdateRouteRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateRouteResponse + */ +func (a *RouteApiService) UpdateRouteExecute(r ApiUpdateRouteRequest) (UpdateRouteResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateRouteResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteApiService.UpdateRoute") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateRoute" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateRouteRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go new file mode 100644 index 000000000..d09651524 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go @@ -0,0 +1,777 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// RouteTableApiService RouteTableApi service +type RouteTableApiService service + +type ApiCreateRouteTableRequest struct { + ctx _context.Context + ApiService *RouteTableApiService + createRouteTableRequest *CreateRouteTableRequest +} + +func (r ApiCreateRouteTableRequest) CreateRouteTableRequest(createRouteTableRequest CreateRouteTableRequest) ApiCreateRouteTableRequest { + r.createRouteTableRequest = &createRouteTableRequest + return r +} + +func (r ApiCreateRouteTableRequest) Execute() (CreateRouteTableResponse, *_nethttp.Response, error) { + return r.ApiService.CreateRouteTableExecute(r) +} + +/* + * CreateRouteTable Method for CreateRouteTable + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateRouteTableRequest + */ +func (a *RouteTableApiService) CreateRouteTable(ctx _context.Context) ApiCreateRouteTableRequest { + return ApiCreateRouteTableRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateRouteTableResponse + */ +func (a *RouteTableApiService) CreateRouteTableExecute(r ApiCreateRouteTableRequest) (CreateRouteTableResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateRouteTableResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteTableApiService.CreateRouteTable") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateRouteTable" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createRouteTableRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteRouteTableRequest struct { + ctx _context.Context + ApiService *RouteTableApiService + deleteRouteTableRequest *DeleteRouteTableRequest +} + +func (r ApiDeleteRouteTableRequest) DeleteRouteTableRequest(deleteRouteTableRequest DeleteRouteTableRequest) ApiDeleteRouteTableRequest { + r.deleteRouteTableRequest = &deleteRouteTableRequest + return r +} + +func (r ApiDeleteRouteTableRequest) Execute() (DeleteRouteTableResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteRouteTableExecute(r) +} + +/* + * DeleteRouteTable Method for DeleteRouteTable + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteRouteTableRequest + */ +func (a *RouteTableApiService) DeleteRouteTable(ctx _context.Context) ApiDeleteRouteTableRequest { + return ApiDeleteRouteTableRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteRouteTableResponse + */ +func (a *RouteTableApiService) DeleteRouteTableExecute(r ApiDeleteRouteTableRequest) (DeleteRouteTableResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteRouteTableResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteTableApiService.DeleteRouteTable") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteRouteTable" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteRouteTableRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkRouteTableRequest struct { + ctx _context.Context + ApiService *RouteTableApiService + linkRouteTableRequest *LinkRouteTableRequest +} + +func (r ApiLinkRouteTableRequest) LinkRouteTableRequest(linkRouteTableRequest LinkRouteTableRequest) ApiLinkRouteTableRequest { + r.linkRouteTableRequest = &linkRouteTableRequest + return r +} + +func (r ApiLinkRouteTableRequest) Execute() (LinkRouteTableResponse, *_nethttp.Response, error) { + return r.ApiService.LinkRouteTableExecute(r) +} + +/* + * LinkRouteTable Method for LinkRouteTable + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkRouteTableRequest + */ +func (a *RouteTableApiService) LinkRouteTable(ctx _context.Context) ApiLinkRouteTableRequest { + return ApiLinkRouteTableRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkRouteTableResponse + */ +func (a *RouteTableApiService) LinkRouteTableExecute(r ApiLinkRouteTableRequest) (LinkRouteTableResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkRouteTableResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteTableApiService.LinkRouteTable") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkRouteTable" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkRouteTableRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadRouteTablesRequest struct { + ctx _context.Context + ApiService *RouteTableApiService + readRouteTablesRequest *ReadRouteTablesRequest +} + +func (r ApiReadRouteTablesRequest) ReadRouteTablesRequest(readRouteTablesRequest ReadRouteTablesRequest) ApiReadRouteTablesRequest { + r.readRouteTablesRequest = &readRouteTablesRequest + return r +} + +func (r ApiReadRouteTablesRequest) Execute() (ReadRouteTablesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadRouteTablesExecute(r) +} + +/* + * ReadRouteTables Method for ReadRouteTables + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadRouteTablesRequest + */ +func (a *RouteTableApiService) ReadRouteTables(ctx _context.Context) ApiReadRouteTablesRequest { + return ApiReadRouteTablesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadRouteTablesResponse + */ +func (a *RouteTableApiService) ReadRouteTablesExecute(r ApiReadRouteTablesRequest) (ReadRouteTablesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadRouteTablesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteTableApiService.ReadRouteTables") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadRouteTables" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readRouteTablesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkRouteTableRequest struct { + ctx _context.Context + ApiService *RouteTableApiService + unlinkRouteTableRequest *UnlinkRouteTableRequest +} + +func (r ApiUnlinkRouteTableRequest) UnlinkRouteTableRequest(unlinkRouteTableRequest UnlinkRouteTableRequest) ApiUnlinkRouteTableRequest { + r.unlinkRouteTableRequest = &unlinkRouteTableRequest + return r +} + +func (r ApiUnlinkRouteTableRequest) Execute() (UnlinkRouteTableResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkRouteTableExecute(r) +} + +/* + * UnlinkRouteTable Method for UnlinkRouteTable + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkRouteTableRequest + */ +func (a *RouteTableApiService) UnlinkRouteTable(ctx _context.Context) ApiUnlinkRouteTableRequest { + return ApiUnlinkRouteTableRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkRouteTableResponse + */ +func (a *RouteTableApiService) UnlinkRouteTableExecute(r ApiUnlinkRouteTableRequest) (UnlinkRouteTableResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkRouteTableResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RouteTableApiService.UnlinkRouteTable") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkRouteTable" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkRouteTableRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go new file mode 100644 index 000000000..cbc2d0306 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go @@ -0,0 +1,477 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// SecurityGroupApiService SecurityGroupApi service +type SecurityGroupApiService service + +type ApiCreateSecurityGroupRequest struct { + ctx _context.Context + ApiService *SecurityGroupApiService + createSecurityGroupRequest *CreateSecurityGroupRequest +} + +func (r ApiCreateSecurityGroupRequest) CreateSecurityGroupRequest(createSecurityGroupRequest CreateSecurityGroupRequest) ApiCreateSecurityGroupRequest { + r.createSecurityGroupRequest = &createSecurityGroupRequest + return r +} + +func (r ApiCreateSecurityGroupRequest) Execute() (CreateSecurityGroupResponse, *_nethttp.Response, error) { + return r.ApiService.CreateSecurityGroupExecute(r) +} + +/* + * CreateSecurityGroup Method for CreateSecurityGroup + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateSecurityGroupRequest + */ +func (a *SecurityGroupApiService) CreateSecurityGroup(ctx _context.Context) ApiCreateSecurityGroupRequest { + return ApiCreateSecurityGroupRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateSecurityGroupResponse + */ +func (a *SecurityGroupApiService) CreateSecurityGroupExecute(r ApiCreateSecurityGroupRequest) (CreateSecurityGroupResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateSecurityGroupResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SecurityGroupApiService.CreateSecurityGroup") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateSecurityGroup" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createSecurityGroupRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteSecurityGroupRequest struct { + ctx _context.Context + ApiService *SecurityGroupApiService + deleteSecurityGroupRequest *DeleteSecurityGroupRequest +} + +func (r ApiDeleteSecurityGroupRequest) DeleteSecurityGroupRequest(deleteSecurityGroupRequest DeleteSecurityGroupRequest) ApiDeleteSecurityGroupRequest { + r.deleteSecurityGroupRequest = &deleteSecurityGroupRequest + return r +} + +func (r ApiDeleteSecurityGroupRequest) Execute() (DeleteSecurityGroupResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteSecurityGroupExecute(r) +} + +/* + * DeleteSecurityGroup Method for DeleteSecurityGroup + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteSecurityGroupRequest + */ +func (a *SecurityGroupApiService) DeleteSecurityGroup(ctx _context.Context) ApiDeleteSecurityGroupRequest { + return ApiDeleteSecurityGroupRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteSecurityGroupResponse + */ +func (a *SecurityGroupApiService) DeleteSecurityGroupExecute(r ApiDeleteSecurityGroupRequest) (DeleteSecurityGroupResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteSecurityGroupResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SecurityGroupApiService.DeleteSecurityGroup") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteSecurityGroup" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteSecurityGroupRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadSecurityGroupsRequest struct { + ctx _context.Context + ApiService *SecurityGroupApiService + readSecurityGroupsRequest *ReadSecurityGroupsRequest +} + +func (r ApiReadSecurityGroupsRequest) ReadSecurityGroupsRequest(readSecurityGroupsRequest ReadSecurityGroupsRequest) ApiReadSecurityGroupsRequest { + r.readSecurityGroupsRequest = &readSecurityGroupsRequest + return r +} + +func (r ApiReadSecurityGroupsRequest) Execute() (ReadSecurityGroupsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSecurityGroupsExecute(r) +} + +/* + * ReadSecurityGroups Method for ReadSecurityGroups + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSecurityGroupsRequest + */ +func (a *SecurityGroupApiService) ReadSecurityGroups(ctx _context.Context) ApiReadSecurityGroupsRequest { + return ApiReadSecurityGroupsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSecurityGroupsResponse + */ +func (a *SecurityGroupApiService) ReadSecurityGroupsExecute(r ApiReadSecurityGroupsRequest) (ReadSecurityGroupsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSecurityGroupsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SecurityGroupApiService.ReadSecurityGroups") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSecurityGroups" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSecurityGroupsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go new file mode 100644 index 000000000..c0b4235df --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go @@ -0,0 +1,327 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// SecurityGroupRuleApiService SecurityGroupRuleApi service +type SecurityGroupRuleApiService service + +type ApiCreateSecurityGroupRuleRequest struct { + ctx _context.Context + ApiService *SecurityGroupRuleApiService + createSecurityGroupRuleRequest *CreateSecurityGroupRuleRequest +} + +func (r ApiCreateSecurityGroupRuleRequest) CreateSecurityGroupRuleRequest(createSecurityGroupRuleRequest CreateSecurityGroupRuleRequest) ApiCreateSecurityGroupRuleRequest { + r.createSecurityGroupRuleRequest = &createSecurityGroupRuleRequest + return r +} + +func (r ApiCreateSecurityGroupRuleRequest) Execute() (CreateSecurityGroupRuleResponse, *_nethttp.Response, error) { + return r.ApiService.CreateSecurityGroupRuleExecute(r) +} + +/* + * CreateSecurityGroupRule Method for CreateSecurityGroupRule + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateSecurityGroupRuleRequest + */ +func (a *SecurityGroupRuleApiService) CreateSecurityGroupRule(ctx _context.Context) ApiCreateSecurityGroupRuleRequest { + return ApiCreateSecurityGroupRuleRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateSecurityGroupRuleResponse + */ +func (a *SecurityGroupRuleApiService) CreateSecurityGroupRuleExecute(r ApiCreateSecurityGroupRuleRequest) (CreateSecurityGroupRuleResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateSecurityGroupRuleResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SecurityGroupRuleApiService.CreateSecurityGroupRule") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateSecurityGroupRule" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createSecurityGroupRuleRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteSecurityGroupRuleRequest struct { + ctx _context.Context + ApiService *SecurityGroupRuleApiService + deleteSecurityGroupRuleRequest *DeleteSecurityGroupRuleRequest +} + +func (r ApiDeleteSecurityGroupRuleRequest) DeleteSecurityGroupRuleRequest(deleteSecurityGroupRuleRequest DeleteSecurityGroupRuleRequest) ApiDeleteSecurityGroupRuleRequest { + r.deleteSecurityGroupRuleRequest = &deleteSecurityGroupRuleRequest + return r +} + +func (r ApiDeleteSecurityGroupRuleRequest) Execute() (DeleteSecurityGroupRuleResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteSecurityGroupRuleExecute(r) +} + +/* + * DeleteSecurityGroupRule Method for DeleteSecurityGroupRule + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteSecurityGroupRuleRequest + */ +func (a *SecurityGroupRuleApiService) DeleteSecurityGroupRule(ctx _context.Context) ApiDeleteSecurityGroupRuleRequest { + return ApiDeleteSecurityGroupRuleRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteSecurityGroupRuleResponse + */ +func (a *SecurityGroupRuleApiService) DeleteSecurityGroupRuleExecute(r ApiDeleteSecurityGroupRuleRequest) (DeleteSecurityGroupRuleResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteSecurityGroupRuleResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SecurityGroupRuleApiService.DeleteSecurityGroupRule") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteSecurityGroupRule" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteSecurityGroupRuleRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go new file mode 100644 index 000000000..2bf45f4ca --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go @@ -0,0 +1,511 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// ServerCertificateApiService ServerCertificateApi service +type ServerCertificateApiService service + +type ApiCreateServerCertificateRequest struct { + ctx _context.Context + ApiService *ServerCertificateApiService + createServerCertificateRequest *CreateServerCertificateRequest +} + +func (r ApiCreateServerCertificateRequest) CreateServerCertificateRequest(createServerCertificateRequest CreateServerCertificateRequest) ApiCreateServerCertificateRequest { + r.createServerCertificateRequest = &createServerCertificateRequest + return r +} + +func (r ApiCreateServerCertificateRequest) Execute() (CreateServerCertificateResponse, *_nethttp.Response, error) { + return r.ApiService.CreateServerCertificateExecute(r) +} + +/* + * CreateServerCertificate Method for CreateServerCertificate + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateServerCertificateRequest + */ +func (a *ServerCertificateApiService) CreateServerCertificate(ctx _context.Context) ApiCreateServerCertificateRequest { + return ApiCreateServerCertificateRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateServerCertificateResponse + */ +func (a *ServerCertificateApiService) CreateServerCertificateExecute(r ApiCreateServerCertificateRequest) (CreateServerCertificateResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateServerCertificateResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ServerCertificateApiService.CreateServerCertificate") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateServerCertificate" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createServerCertificateRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteServerCertificateRequest struct { + ctx _context.Context + ApiService *ServerCertificateApiService + deleteServerCertificateRequest *DeleteServerCertificateRequest +} + +func (r ApiDeleteServerCertificateRequest) DeleteServerCertificateRequest(deleteServerCertificateRequest DeleteServerCertificateRequest) ApiDeleteServerCertificateRequest { + r.deleteServerCertificateRequest = &deleteServerCertificateRequest + return r +} + +func (r ApiDeleteServerCertificateRequest) Execute() (DeleteServerCertificateResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteServerCertificateExecute(r) +} + +/* + * DeleteServerCertificate Method for DeleteServerCertificate + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteServerCertificateRequest + */ +func (a *ServerCertificateApiService) DeleteServerCertificate(ctx _context.Context) ApiDeleteServerCertificateRequest { + return ApiDeleteServerCertificateRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteServerCertificateResponse + */ +func (a *ServerCertificateApiService) DeleteServerCertificateExecute(r ApiDeleteServerCertificateRequest) (DeleteServerCertificateResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteServerCertificateResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ServerCertificateApiService.DeleteServerCertificate") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteServerCertificate" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteServerCertificateRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadServerCertificatesRequest struct { + ctx _context.Context + ApiService *ServerCertificateApiService + readServerCertificatesRequest *ReadServerCertificatesRequest +} + +func (r ApiReadServerCertificatesRequest) ReadServerCertificatesRequest(readServerCertificatesRequest ReadServerCertificatesRequest) ApiReadServerCertificatesRequest { + r.readServerCertificatesRequest = &readServerCertificatesRequest + return r +} + +func (r ApiReadServerCertificatesRequest) Execute() (ReadServerCertificatesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadServerCertificatesExecute(r) +} + +/* + * ReadServerCertificates Method for ReadServerCertificates + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadServerCertificatesRequest + */ +func (a *ServerCertificateApiService) ReadServerCertificates(ctx _context.Context) ApiReadServerCertificatesRequest { + return ApiReadServerCertificatesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadServerCertificatesResponse + */ +func (a *ServerCertificateApiService) ReadServerCertificatesExecute(r ApiReadServerCertificatesRequest) (ReadServerCertificatesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadServerCertificatesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ServerCertificateApiService.ReadServerCertificates") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadServerCertificates" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readServerCertificatesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateServerCertificateRequest struct { + ctx _context.Context + ApiService *ServerCertificateApiService + updateServerCertificateRequest *UpdateServerCertificateRequest +} + +func (r ApiUpdateServerCertificateRequest) UpdateServerCertificateRequest(updateServerCertificateRequest UpdateServerCertificateRequest) ApiUpdateServerCertificateRequest { + r.updateServerCertificateRequest = &updateServerCertificateRequest + return r +} + +func (r ApiUpdateServerCertificateRequest) Execute() (UpdateServerCertificateResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateServerCertificateExecute(r) +} + +/* + * UpdateServerCertificate Method for UpdateServerCertificate + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateServerCertificateRequest + */ +func (a *ServerCertificateApiService) UpdateServerCertificate(ctx _context.Context) ApiUpdateServerCertificateRequest { + return ApiUpdateServerCertificateRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateServerCertificateResponse + */ +func (a *ServerCertificateApiService) UpdateServerCertificateExecute(r ApiUpdateServerCertificateRequest) (UpdateServerCertificateResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateServerCertificateResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "ServerCertificateApiService.UpdateServerCertificate") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateServerCertificate" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateServerCertificateRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go new file mode 100644 index 000000000..b70b87f10 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go @@ -0,0 +1,869 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// SnapshotApiService SnapshotApi service +type SnapshotApiService service + +type ApiCreateSnapshotRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + createSnapshotRequest *CreateSnapshotRequest +} + +func (r ApiCreateSnapshotRequest) CreateSnapshotRequest(createSnapshotRequest CreateSnapshotRequest) ApiCreateSnapshotRequest { + r.createSnapshotRequest = &createSnapshotRequest + return r +} + +func (r ApiCreateSnapshotRequest) Execute() (CreateSnapshotResponse, *_nethttp.Response, error) { + return r.ApiService.CreateSnapshotExecute(r) +} + +/* + * CreateSnapshot Method for CreateSnapshot + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateSnapshotRequest + */ +func (a *SnapshotApiService) CreateSnapshot(ctx _context.Context) ApiCreateSnapshotRequest { + return ApiCreateSnapshotRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateSnapshotResponse + */ +func (a *SnapshotApiService) CreateSnapshotExecute(r ApiCreateSnapshotRequest) (CreateSnapshotResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateSnapshotResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.CreateSnapshot") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateSnapshot" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createSnapshotRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateSnapshotExportTaskRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + createSnapshotExportTaskRequest *CreateSnapshotExportTaskRequest +} + +func (r ApiCreateSnapshotExportTaskRequest) CreateSnapshotExportTaskRequest(createSnapshotExportTaskRequest CreateSnapshotExportTaskRequest) ApiCreateSnapshotExportTaskRequest { + r.createSnapshotExportTaskRequest = &createSnapshotExportTaskRequest + return r +} + +func (r ApiCreateSnapshotExportTaskRequest) Execute() (CreateSnapshotExportTaskResponse, *_nethttp.Response, error) { + return r.ApiService.CreateSnapshotExportTaskExecute(r) +} + +/* + * CreateSnapshotExportTask Method for CreateSnapshotExportTask + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateSnapshotExportTaskRequest + */ +func (a *SnapshotApiService) CreateSnapshotExportTask(ctx _context.Context) ApiCreateSnapshotExportTaskRequest { + return ApiCreateSnapshotExportTaskRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateSnapshotExportTaskResponse + */ +func (a *SnapshotApiService) CreateSnapshotExportTaskExecute(r ApiCreateSnapshotExportTaskRequest) (CreateSnapshotExportTaskResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateSnapshotExportTaskResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.CreateSnapshotExportTask") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateSnapshotExportTask" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createSnapshotExportTaskRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteSnapshotRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + deleteSnapshotRequest *DeleteSnapshotRequest +} + +func (r ApiDeleteSnapshotRequest) DeleteSnapshotRequest(deleteSnapshotRequest DeleteSnapshotRequest) ApiDeleteSnapshotRequest { + r.deleteSnapshotRequest = &deleteSnapshotRequest + return r +} + +func (r ApiDeleteSnapshotRequest) Execute() (DeleteSnapshotResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteSnapshotExecute(r) +} + +/* + * DeleteSnapshot Method for DeleteSnapshot + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteSnapshotRequest + */ +func (a *SnapshotApiService) DeleteSnapshot(ctx _context.Context) ApiDeleteSnapshotRequest { + return ApiDeleteSnapshotRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteSnapshotResponse + */ +func (a *SnapshotApiService) DeleteSnapshotExecute(r ApiDeleteSnapshotRequest) (DeleteSnapshotResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteSnapshotResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.DeleteSnapshot") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteSnapshot" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteSnapshotRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadSnapshotExportTasksRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + readSnapshotExportTasksRequest *ReadSnapshotExportTasksRequest +} + +func (r ApiReadSnapshotExportTasksRequest) ReadSnapshotExportTasksRequest(readSnapshotExportTasksRequest ReadSnapshotExportTasksRequest) ApiReadSnapshotExportTasksRequest { + r.readSnapshotExportTasksRequest = &readSnapshotExportTasksRequest + return r +} + +func (r ApiReadSnapshotExportTasksRequest) Execute() (ReadSnapshotExportTasksResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSnapshotExportTasksExecute(r) +} + +/* + * ReadSnapshotExportTasks Method for ReadSnapshotExportTasks + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSnapshotExportTasksRequest + */ +func (a *SnapshotApiService) ReadSnapshotExportTasks(ctx _context.Context) ApiReadSnapshotExportTasksRequest { + return ApiReadSnapshotExportTasksRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSnapshotExportTasksResponse + */ +func (a *SnapshotApiService) ReadSnapshotExportTasksExecute(r ApiReadSnapshotExportTasksRequest) (ReadSnapshotExportTasksResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSnapshotExportTasksResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.ReadSnapshotExportTasks") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSnapshotExportTasks" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSnapshotExportTasksRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadSnapshotsRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + readSnapshotsRequest *ReadSnapshotsRequest +} + +func (r ApiReadSnapshotsRequest) ReadSnapshotsRequest(readSnapshotsRequest ReadSnapshotsRequest) ApiReadSnapshotsRequest { + r.readSnapshotsRequest = &readSnapshotsRequest + return r +} + +func (r ApiReadSnapshotsRequest) Execute() (ReadSnapshotsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSnapshotsExecute(r) +} + +/* + * ReadSnapshots Method for ReadSnapshots + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSnapshotsRequest + */ +func (a *SnapshotApiService) ReadSnapshots(ctx _context.Context) ApiReadSnapshotsRequest { + return ApiReadSnapshotsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSnapshotsResponse + */ +func (a *SnapshotApiService) ReadSnapshotsExecute(r ApiReadSnapshotsRequest) (ReadSnapshotsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSnapshotsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.ReadSnapshots") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSnapshots" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSnapshotsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateSnapshotRequest struct { + ctx _context.Context + ApiService *SnapshotApiService + updateSnapshotRequest *UpdateSnapshotRequest +} + +func (r ApiUpdateSnapshotRequest) UpdateSnapshotRequest(updateSnapshotRequest UpdateSnapshotRequest) ApiUpdateSnapshotRequest { + r.updateSnapshotRequest = &updateSnapshotRequest + return r +} + +func (r ApiUpdateSnapshotRequest) Execute() (UpdateSnapshotResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateSnapshotExecute(r) +} + +/* + * UpdateSnapshot Method for UpdateSnapshot + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateSnapshotRequest + */ +func (a *SnapshotApiService) UpdateSnapshot(ctx _context.Context) ApiUpdateSnapshotRequest { + return ApiUpdateSnapshotRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateSnapshotResponse + */ +func (a *SnapshotApiService) UpdateSnapshotExecute(r ApiUpdateSnapshotRequest) (UpdateSnapshotResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateSnapshotResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SnapshotApiService.UpdateSnapshot") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateSnapshot" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateSnapshotRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go new file mode 100644 index 000000000..75cc8896f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go @@ -0,0 +1,637 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// SubnetApiService SubnetApi service +type SubnetApiService service + +type ApiCreateSubnetRequest struct { + ctx _context.Context + ApiService *SubnetApiService + createSubnetRequest *CreateSubnetRequest +} + +func (r ApiCreateSubnetRequest) CreateSubnetRequest(createSubnetRequest CreateSubnetRequest) ApiCreateSubnetRequest { + r.createSubnetRequest = &createSubnetRequest + return r +} + +func (r ApiCreateSubnetRequest) Execute() (CreateSubnetResponse, *_nethttp.Response, error) { + return r.ApiService.CreateSubnetExecute(r) +} + +/* + * CreateSubnet Method for CreateSubnet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateSubnetRequest + */ +func (a *SubnetApiService) CreateSubnet(ctx _context.Context) ApiCreateSubnetRequest { + return ApiCreateSubnetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateSubnetResponse + */ +func (a *SubnetApiService) CreateSubnetExecute(r ApiCreateSubnetRequest) (CreateSubnetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateSubnetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SubnetApiService.CreateSubnet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateSubnet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createSubnetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 409 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteSubnetRequest struct { + ctx _context.Context + ApiService *SubnetApiService + deleteSubnetRequest *DeleteSubnetRequest +} + +func (r ApiDeleteSubnetRequest) DeleteSubnetRequest(deleteSubnetRequest DeleteSubnetRequest) ApiDeleteSubnetRequest { + r.deleteSubnetRequest = &deleteSubnetRequest + return r +} + +func (r ApiDeleteSubnetRequest) Execute() (DeleteSubnetResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteSubnetExecute(r) +} + +/* + * DeleteSubnet Method for DeleteSubnet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteSubnetRequest + */ +func (a *SubnetApiService) DeleteSubnet(ctx _context.Context) ApiDeleteSubnetRequest { + return ApiDeleteSubnetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteSubnetResponse + */ +func (a *SubnetApiService) DeleteSubnetExecute(r ApiDeleteSubnetRequest) (DeleteSubnetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteSubnetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SubnetApiService.DeleteSubnet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteSubnet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteSubnetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadSubnetsRequest struct { + ctx _context.Context + ApiService *SubnetApiService + readSubnetsRequest *ReadSubnetsRequest +} + +func (r ApiReadSubnetsRequest) ReadSubnetsRequest(readSubnetsRequest ReadSubnetsRequest) ApiReadSubnetsRequest { + r.readSubnetsRequest = &readSubnetsRequest + return r +} + +func (r ApiReadSubnetsRequest) Execute() (ReadSubnetsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSubnetsExecute(r) +} + +/* + * ReadSubnets Method for ReadSubnets + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSubnetsRequest + */ +func (a *SubnetApiService) ReadSubnets(ctx _context.Context) ApiReadSubnetsRequest { + return ApiReadSubnetsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSubnetsResponse + */ +func (a *SubnetApiService) ReadSubnetsExecute(r ApiReadSubnetsRequest) (ReadSubnetsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSubnetsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SubnetApiService.ReadSubnets") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSubnets" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSubnetsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateSubnetRequest struct { + ctx _context.Context + ApiService *SubnetApiService + updateSubnetRequest *UpdateSubnetRequest +} + +func (r ApiUpdateSubnetRequest) UpdateSubnetRequest(updateSubnetRequest UpdateSubnetRequest) ApiUpdateSubnetRequest { + r.updateSubnetRequest = &updateSubnetRequest + return r +} + +func (r ApiUpdateSubnetRequest) Execute() (UpdateSubnetResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateSubnetExecute(r) +} + +/* + * UpdateSubnet Method for UpdateSubnet + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateSubnetRequest + */ +func (a *SubnetApiService) UpdateSubnet(ctx _context.Context) ApiUpdateSubnetRequest { + return ApiUpdateSubnetRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateSubnetResponse + */ +func (a *SubnetApiService) UpdateSubnetExecute(r ApiUpdateSubnetRequest) (UpdateSubnetResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateSubnetResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SubnetApiService.UpdateSubnet") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateSubnet" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateSubnetRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go new file mode 100644 index 000000000..7a5d4162e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go @@ -0,0 +1,148 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// SubregionApiService SubregionApi service +type SubregionApiService service + +type ApiReadSubregionsRequest struct { + ctx _context.Context + ApiService *SubregionApiService + readSubregionsRequest *ReadSubregionsRequest +} + +func (r ApiReadSubregionsRequest) ReadSubregionsRequest(readSubregionsRequest ReadSubregionsRequest) ApiReadSubregionsRequest { + r.readSubregionsRequest = &readSubregionsRequest + return r +} + +func (r ApiReadSubregionsRequest) Execute() (ReadSubregionsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadSubregionsExecute(r) +} + +/* + * ReadSubregions Method for ReadSubregions + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadSubregionsRequest + */ +func (a *SubregionApiService) ReadSubregions(ctx _context.Context) ApiReadSubregionsRequest { + return ApiReadSubregionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadSubregionsResponse + */ +func (a *SubregionApiService) ReadSubregionsExecute(r ApiReadSubregionsRequest) (ReadSubregionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadSubregionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "SubregionApiService.ReadSubregions") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadSubregions" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readSubregionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go new file mode 100644 index 000000000..8d3aa813d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go @@ -0,0 +1,477 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// TagApiService TagApi service +type TagApiService service + +type ApiCreateTagsRequest struct { + ctx _context.Context + ApiService *TagApiService + createTagsRequest *CreateTagsRequest +} + +func (r ApiCreateTagsRequest) CreateTagsRequest(createTagsRequest CreateTagsRequest) ApiCreateTagsRequest { + r.createTagsRequest = &createTagsRequest + return r +} + +func (r ApiCreateTagsRequest) Execute() (CreateTagsResponse, *_nethttp.Response, error) { + return r.ApiService.CreateTagsExecute(r) +} + +/* + * CreateTags Method for CreateTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateTagsRequest + */ +func (a *TagApiService) CreateTags(ctx _context.Context) ApiCreateTagsRequest { + return ApiCreateTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateTagsResponse + */ +func (a *TagApiService) CreateTagsExecute(r ApiCreateTagsRequest) (CreateTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "TagApiService.CreateTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteTagsRequest struct { + ctx _context.Context + ApiService *TagApiService + deleteTagsRequest *DeleteTagsRequest +} + +func (r ApiDeleteTagsRequest) DeleteTagsRequest(deleteTagsRequest DeleteTagsRequest) ApiDeleteTagsRequest { + r.deleteTagsRequest = &deleteTagsRequest + return r +} + +func (r ApiDeleteTagsRequest) Execute() (DeleteTagsResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteTagsExecute(r) +} + +/* + * DeleteTags Method for DeleteTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteTagsRequest + */ +func (a *TagApiService) DeleteTags(ctx _context.Context) ApiDeleteTagsRequest { + return ApiDeleteTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteTagsResponse + */ +func (a *TagApiService) DeleteTagsExecute(r ApiDeleteTagsRequest) (DeleteTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "TagApiService.DeleteTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadTagsRequest struct { + ctx _context.Context + ApiService *TagApiService + readTagsRequest *ReadTagsRequest +} + +func (r ApiReadTagsRequest) ReadTagsRequest(readTagsRequest ReadTagsRequest) ApiReadTagsRequest { + r.readTagsRequest = &readTagsRequest + return r +} + +func (r ApiReadTagsRequest) Execute() (ReadTagsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadTagsExecute(r) +} + +/* + * ReadTags Method for ReadTags + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadTagsRequest + */ +func (a *TagApiService) ReadTags(ctx _context.Context) ApiReadTagsRequest { + return ApiReadTagsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadTagsResponse + */ +func (a *TagApiService) ReadTagsExecute(r ApiReadTagsRequest) (ReadTagsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadTagsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "TagApiService.ReadTags") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadTags" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readTagsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_task.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_task.go new file mode 100644 index 000000000..7a396f0f2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_task.go @@ -0,0 +1,148 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// TaskApiService TaskApi service +type TaskApiService service + +type ApiDeleteExportTaskRequest struct { + ctx _context.Context + ApiService *TaskApiService + deleteExportTaskRequest *DeleteExportTaskRequest +} + +func (r ApiDeleteExportTaskRequest) DeleteExportTaskRequest(deleteExportTaskRequest DeleteExportTaskRequest) ApiDeleteExportTaskRequest { + r.deleteExportTaskRequest = &deleteExportTaskRequest + return r +} + +func (r ApiDeleteExportTaskRequest) Execute() (DeleteExportTaskResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteExportTaskExecute(r) +} + +/* + * DeleteExportTask Method for DeleteExportTask + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteExportTaskRequest + */ +func (a *TaskApiService) DeleteExportTask(ctx _context.Context) ApiDeleteExportTaskRequest { + return ApiDeleteExportTaskRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteExportTaskResponse + */ +func (a *TaskApiService) DeleteExportTaskExecute(r ApiDeleteExportTaskRequest) (DeleteExportTaskResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteExportTaskResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "TaskApiService.DeleteExportTask") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteExportTask" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteExportTaskRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go new file mode 100644 index 000000000..ae41536a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go @@ -0,0 +1,753 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// VirtualGatewayApiService VirtualGatewayApi service +type VirtualGatewayApiService service + +type ApiCreateVirtualGatewayRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + createVirtualGatewayRequest *CreateVirtualGatewayRequest +} + +func (r ApiCreateVirtualGatewayRequest) CreateVirtualGatewayRequest(createVirtualGatewayRequest CreateVirtualGatewayRequest) ApiCreateVirtualGatewayRequest { + r.createVirtualGatewayRequest = &createVirtualGatewayRequest + return r +} + +func (r ApiCreateVirtualGatewayRequest) Execute() (CreateVirtualGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.CreateVirtualGatewayExecute(r) +} + +/* + * CreateVirtualGateway Method for CreateVirtualGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateVirtualGatewayRequest + */ +func (a *VirtualGatewayApiService) CreateVirtualGateway(ctx _context.Context) ApiCreateVirtualGatewayRequest { + return ApiCreateVirtualGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateVirtualGatewayResponse + */ +func (a *VirtualGatewayApiService) CreateVirtualGatewayExecute(r ApiCreateVirtualGatewayRequest) (CreateVirtualGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateVirtualGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.CreateVirtualGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateVirtualGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createVirtualGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteVirtualGatewayRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + deleteVirtualGatewayRequest *DeleteVirtualGatewayRequest +} + +func (r ApiDeleteVirtualGatewayRequest) DeleteVirtualGatewayRequest(deleteVirtualGatewayRequest DeleteVirtualGatewayRequest) ApiDeleteVirtualGatewayRequest { + r.deleteVirtualGatewayRequest = &deleteVirtualGatewayRequest + return r +} + +func (r ApiDeleteVirtualGatewayRequest) Execute() (DeleteVirtualGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteVirtualGatewayExecute(r) +} + +/* + * DeleteVirtualGateway Method for DeleteVirtualGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteVirtualGatewayRequest + */ +func (a *VirtualGatewayApiService) DeleteVirtualGateway(ctx _context.Context) ApiDeleteVirtualGatewayRequest { + return ApiDeleteVirtualGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteVirtualGatewayResponse + */ +func (a *VirtualGatewayApiService) DeleteVirtualGatewayExecute(r ApiDeleteVirtualGatewayRequest) (DeleteVirtualGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteVirtualGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.DeleteVirtualGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteVirtualGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteVirtualGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkVirtualGatewayRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + linkVirtualGatewayRequest *LinkVirtualGatewayRequest +} + +func (r ApiLinkVirtualGatewayRequest) LinkVirtualGatewayRequest(linkVirtualGatewayRequest LinkVirtualGatewayRequest) ApiLinkVirtualGatewayRequest { + r.linkVirtualGatewayRequest = &linkVirtualGatewayRequest + return r +} + +func (r ApiLinkVirtualGatewayRequest) Execute() (LinkVirtualGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.LinkVirtualGatewayExecute(r) +} + +/* + * LinkVirtualGateway Method for LinkVirtualGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkVirtualGatewayRequest + */ +func (a *VirtualGatewayApiService) LinkVirtualGateway(ctx _context.Context) ApiLinkVirtualGatewayRequest { + return ApiLinkVirtualGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkVirtualGatewayResponse + */ +func (a *VirtualGatewayApiService) LinkVirtualGatewayExecute(r ApiLinkVirtualGatewayRequest) (LinkVirtualGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkVirtualGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.LinkVirtualGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkVirtualGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkVirtualGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVirtualGatewaysRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + readVirtualGatewaysRequest *ReadVirtualGatewaysRequest +} + +func (r ApiReadVirtualGatewaysRequest) ReadVirtualGatewaysRequest(readVirtualGatewaysRequest ReadVirtualGatewaysRequest) ApiReadVirtualGatewaysRequest { + r.readVirtualGatewaysRequest = &readVirtualGatewaysRequest + return r +} + +func (r ApiReadVirtualGatewaysRequest) Execute() (ReadVirtualGatewaysResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVirtualGatewaysExecute(r) +} + +/* + * ReadVirtualGateways Method for ReadVirtualGateways + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVirtualGatewaysRequest + */ +func (a *VirtualGatewayApiService) ReadVirtualGateways(ctx _context.Context) ApiReadVirtualGatewaysRequest { + return ApiReadVirtualGatewaysRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVirtualGatewaysResponse + */ +func (a *VirtualGatewayApiService) ReadVirtualGatewaysExecute(r ApiReadVirtualGatewaysRequest) (ReadVirtualGatewaysResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVirtualGatewaysResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.ReadVirtualGateways") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVirtualGateways" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVirtualGatewaysRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkVirtualGatewayRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + unlinkVirtualGatewayRequest *UnlinkVirtualGatewayRequest +} + +func (r ApiUnlinkVirtualGatewayRequest) UnlinkVirtualGatewayRequest(unlinkVirtualGatewayRequest UnlinkVirtualGatewayRequest) ApiUnlinkVirtualGatewayRequest { + r.unlinkVirtualGatewayRequest = &unlinkVirtualGatewayRequest + return r +} + +func (r ApiUnlinkVirtualGatewayRequest) Execute() (UnlinkVirtualGatewayResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkVirtualGatewayExecute(r) +} + +/* + * UnlinkVirtualGateway Method for UnlinkVirtualGateway + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkVirtualGatewayRequest + */ +func (a *VirtualGatewayApiService) UnlinkVirtualGateway(ctx _context.Context) ApiUnlinkVirtualGatewayRequest { + return ApiUnlinkVirtualGatewayRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkVirtualGatewayResponse + */ +func (a *VirtualGatewayApiService) UnlinkVirtualGatewayExecute(r ApiUnlinkVirtualGatewayRequest) (UnlinkVirtualGatewayResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkVirtualGatewayResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.UnlinkVirtualGateway") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkVirtualGateway" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkVirtualGatewayRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateRoutePropagationRequest struct { + ctx _context.Context + ApiService *VirtualGatewayApiService + updateRoutePropagationRequest *UpdateRoutePropagationRequest +} + +func (r ApiUpdateRoutePropagationRequest) UpdateRoutePropagationRequest(updateRoutePropagationRequest UpdateRoutePropagationRequest) ApiUpdateRoutePropagationRequest { + r.updateRoutePropagationRequest = &updateRoutePropagationRequest + return r +} + +func (r ApiUpdateRoutePropagationRequest) Execute() (UpdateRoutePropagationResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateRoutePropagationExecute(r) +} + +/* + * UpdateRoutePropagation Method for UpdateRoutePropagation + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateRoutePropagationRequest + */ +func (a *VirtualGatewayApiService) UpdateRoutePropagation(ctx _context.Context) ApiUpdateRoutePropagationRequest { + return ApiUpdateRoutePropagationRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateRoutePropagationResponse + */ +func (a *VirtualGatewayApiService) UpdateRoutePropagationExecute(r ApiUpdateRoutePropagationRequest) (UpdateRoutePropagationResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateRoutePropagationResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VirtualGatewayApiService.UpdateRoutePropagation") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateRoutePropagation" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateRoutePropagationRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go new file mode 100644 index 000000000..ad34da1f6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go @@ -0,0 +1,1634 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// VmApiService VmApi service +type VmApiService service + +type ApiCreateVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + createVmsRequest *CreateVmsRequest +} + +func (r ApiCreateVmsRequest) CreateVmsRequest(createVmsRequest CreateVmsRequest) ApiCreateVmsRequest { + r.createVmsRequest = &createVmsRequest + return r +} + +func (r ApiCreateVmsRequest) Execute() (CreateVmsResponse, *_nethttp.Response, error) { + return r.ApiService.CreateVmsExecute(r) +} + +/* + * CreateVms Method for CreateVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateVmsRequest + */ +func (a *VmApiService) CreateVms(ctx _context.Context) ApiCreateVmsRequest { + return ApiCreateVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateVmsResponse + */ +func (a *VmApiService) CreateVmsExecute(r ApiCreateVmsRequest) (CreateVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.CreateVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + deleteVmsRequest *DeleteVmsRequest +} + +func (r ApiDeleteVmsRequest) DeleteVmsRequest(deleteVmsRequest DeleteVmsRequest) ApiDeleteVmsRequest { + r.deleteVmsRequest = &deleteVmsRequest + return r +} + +func (r ApiDeleteVmsRequest) Execute() (DeleteVmsResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteVmsExecute(r) +} + +/* + * DeleteVms Method for DeleteVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteVmsRequest + */ +func (a *VmApiService) DeleteVms(ctx _context.Context) ApiDeleteVmsRequest { + return ApiDeleteVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteVmsResponse + */ +func (a *VmApiService) DeleteVmsExecute(r ApiDeleteVmsRequest) (DeleteVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.DeleteVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadAdminPasswordRequest struct { + ctx _context.Context + ApiService *VmApiService + readAdminPasswordRequest *ReadAdminPasswordRequest +} + +func (r ApiReadAdminPasswordRequest) ReadAdminPasswordRequest(readAdminPasswordRequest ReadAdminPasswordRequest) ApiReadAdminPasswordRequest { + r.readAdminPasswordRequest = &readAdminPasswordRequest + return r +} + +func (r ApiReadAdminPasswordRequest) Execute() (ReadAdminPasswordResponse, *_nethttp.Response, error) { + return r.ApiService.ReadAdminPasswordExecute(r) +} + +/* + * ReadAdminPassword Method for ReadAdminPassword + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadAdminPasswordRequest + */ +func (a *VmApiService) ReadAdminPassword(ctx _context.Context) ApiReadAdminPasswordRequest { + return ApiReadAdminPasswordRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadAdminPasswordResponse + */ +func (a *VmApiService) ReadAdminPasswordExecute(r ApiReadAdminPasswordRequest) (ReadAdminPasswordResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadAdminPasswordResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.ReadAdminPassword") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadAdminPassword" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readAdminPasswordRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadConsoleOutputRequest struct { + ctx _context.Context + ApiService *VmApiService + readConsoleOutputRequest *ReadConsoleOutputRequest +} + +func (r ApiReadConsoleOutputRequest) ReadConsoleOutputRequest(readConsoleOutputRequest ReadConsoleOutputRequest) ApiReadConsoleOutputRequest { + r.readConsoleOutputRequest = &readConsoleOutputRequest + return r +} + +func (r ApiReadConsoleOutputRequest) Execute() (ReadConsoleOutputResponse, *_nethttp.Response, error) { + return r.ApiService.ReadConsoleOutputExecute(r) +} + +/* + * ReadConsoleOutput Method for ReadConsoleOutput + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadConsoleOutputRequest + */ +func (a *VmApiService) ReadConsoleOutput(ctx _context.Context) ApiReadConsoleOutputRequest { + return ApiReadConsoleOutputRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadConsoleOutputResponse + */ +func (a *VmApiService) ReadConsoleOutputExecute(r ApiReadConsoleOutputRequest) (ReadConsoleOutputResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadConsoleOutputResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.ReadConsoleOutput") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadConsoleOutput" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readConsoleOutputRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVmTypesRequest struct { + ctx _context.Context + ApiService *VmApiService + readVmTypesRequest *ReadVmTypesRequest +} + +func (r ApiReadVmTypesRequest) ReadVmTypesRequest(readVmTypesRequest ReadVmTypesRequest) ApiReadVmTypesRequest { + r.readVmTypesRequest = &readVmTypesRequest + return r +} + +func (r ApiReadVmTypesRequest) Execute() (ReadVmTypesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVmTypesExecute(r) +} + +/* + * ReadVmTypes Method for ReadVmTypes + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVmTypesRequest + */ +func (a *VmApiService) ReadVmTypes(ctx _context.Context) ApiReadVmTypesRequest { + return ApiReadVmTypesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVmTypesResponse + */ +func (a *VmApiService) ReadVmTypesExecute(r ApiReadVmTypesRequest) (ReadVmTypesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVmTypesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.ReadVmTypes") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVmTypes" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVmTypesRequest + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + readVmsRequest *ReadVmsRequest +} + +func (r ApiReadVmsRequest) ReadVmsRequest(readVmsRequest ReadVmsRequest) ApiReadVmsRequest { + r.readVmsRequest = &readVmsRequest + return r +} + +func (r ApiReadVmsRequest) Execute() (ReadVmsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVmsExecute(r) +} + +/* + * ReadVms Method for ReadVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVmsRequest + */ +func (a *VmApiService) ReadVms(ctx _context.Context) ApiReadVmsRequest { + return ApiReadVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVmsResponse + */ +func (a *VmApiService) ReadVmsExecute(r ApiReadVmsRequest) (ReadVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.ReadVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVmsStateRequest struct { + ctx _context.Context + ApiService *VmApiService + readVmsStateRequest *ReadVmsStateRequest +} + +func (r ApiReadVmsStateRequest) ReadVmsStateRequest(readVmsStateRequest ReadVmsStateRequest) ApiReadVmsStateRequest { + r.readVmsStateRequest = &readVmsStateRequest + return r +} + +func (r ApiReadVmsStateRequest) Execute() (ReadVmsStateResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVmsStateExecute(r) +} + +/* + * ReadVmsState Method for ReadVmsState + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVmsStateRequest + */ +func (a *VmApiService) ReadVmsState(ctx _context.Context) ApiReadVmsStateRequest { + return ApiReadVmsStateRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVmsStateResponse + */ +func (a *VmApiService) ReadVmsStateExecute(r ApiReadVmsStateRequest) (ReadVmsStateResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVmsStateResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.ReadVmsState") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVmsState" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVmsStateRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiRebootVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + rebootVmsRequest *RebootVmsRequest +} + +func (r ApiRebootVmsRequest) RebootVmsRequest(rebootVmsRequest RebootVmsRequest) ApiRebootVmsRequest { + r.rebootVmsRequest = &rebootVmsRequest + return r +} + +func (r ApiRebootVmsRequest) Execute() (RebootVmsResponse, *_nethttp.Response, error) { + return r.ApiService.RebootVmsExecute(r) +} + +/* + * RebootVms Method for RebootVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiRebootVmsRequest + */ +func (a *VmApiService) RebootVms(ctx _context.Context) ApiRebootVmsRequest { + return ApiRebootVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return RebootVmsResponse + */ +func (a *VmApiService) RebootVmsExecute(r ApiRebootVmsRequest) (RebootVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue RebootVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.RebootVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/RebootVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.rebootVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiStartVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + startVmsRequest *StartVmsRequest +} + +func (r ApiStartVmsRequest) StartVmsRequest(startVmsRequest StartVmsRequest) ApiStartVmsRequest { + r.startVmsRequest = &startVmsRequest + return r +} + +func (r ApiStartVmsRequest) Execute() (StartVmsResponse, *_nethttp.Response, error) { + return r.ApiService.StartVmsExecute(r) +} + +/* + * StartVms Method for StartVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiStartVmsRequest + */ +func (a *VmApiService) StartVms(ctx _context.Context) ApiStartVmsRequest { + return ApiStartVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return StartVmsResponse + */ +func (a *VmApiService) StartVmsExecute(r ApiStartVmsRequest) (StartVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue StartVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.StartVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/StartVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.startVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiStopVmsRequest struct { + ctx _context.Context + ApiService *VmApiService + stopVmsRequest *StopVmsRequest +} + +func (r ApiStopVmsRequest) StopVmsRequest(stopVmsRequest StopVmsRequest) ApiStopVmsRequest { + r.stopVmsRequest = &stopVmsRequest + return r +} + +func (r ApiStopVmsRequest) Execute() (StopVmsResponse, *_nethttp.Response, error) { + return r.ApiService.StopVmsExecute(r) +} + +/* + * StopVms Method for StopVms + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiStopVmsRequest + */ +func (a *VmApiService) StopVms(ctx _context.Context) ApiStopVmsRequest { + return ApiStopVmsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return StopVmsResponse + */ +func (a *VmApiService) StopVmsExecute(r ApiStopVmsRequest) (StopVmsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue StopVmsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.StopVms") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/StopVms" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.stopVmsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUpdateVmRequest struct { + ctx _context.Context + ApiService *VmApiService + updateVmRequest *UpdateVmRequest +} + +func (r ApiUpdateVmRequest) UpdateVmRequest(updateVmRequest UpdateVmRequest) ApiUpdateVmRequest { + r.updateVmRequest = &updateVmRequest + return r +} + +func (r ApiUpdateVmRequest) Execute() (UpdateVmResponse, *_nethttp.Response, error) { + return r.ApiService.UpdateVmExecute(r) +} + +/* + * UpdateVm Method for UpdateVm + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUpdateVmRequest + */ +func (a *VmApiService) UpdateVm(ctx _context.Context) ApiUpdateVmRequest { + return ApiUpdateVmRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UpdateVmResponse + */ +func (a *VmApiService) UpdateVmExecute(r ApiUpdateVmRequest) (UpdateVmResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UpdateVmResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VmApiService.UpdateVm") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UpdateVm" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.updateVmRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go new file mode 100644 index 000000000..ab79d87e0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go @@ -0,0 +1,777 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// VolumeApiService VolumeApi service +type VolumeApiService service + +type ApiCreateVolumeRequest struct { + ctx _context.Context + ApiService *VolumeApiService + createVolumeRequest *CreateVolumeRequest +} + +func (r ApiCreateVolumeRequest) CreateVolumeRequest(createVolumeRequest CreateVolumeRequest) ApiCreateVolumeRequest { + r.createVolumeRequest = &createVolumeRequest + return r +} + +func (r ApiCreateVolumeRequest) Execute() (CreateVolumeResponse, *_nethttp.Response, error) { + return r.ApiService.CreateVolumeExecute(r) +} + +/* + * CreateVolume Method for CreateVolume + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateVolumeRequest + */ +func (a *VolumeApiService) CreateVolume(ctx _context.Context) ApiCreateVolumeRequest { + return ApiCreateVolumeRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateVolumeResponse + */ +func (a *VolumeApiService) CreateVolumeExecute(r ApiCreateVolumeRequest) (CreateVolumeResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateVolumeResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumeApiService.CreateVolume") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateVolume" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createVolumeRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteVolumeRequest struct { + ctx _context.Context + ApiService *VolumeApiService + deleteVolumeRequest *DeleteVolumeRequest +} + +func (r ApiDeleteVolumeRequest) DeleteVolumeRequest(deleteVolumeRequest DeleteVolumeRequest) ApiDeleteVolumeRequest { + r.deleteVolumeRequest = &deleteVolumeRequest + return r +} + +func (r ApiDeleteVolumeRequest) Execute() (DeleteVolumeResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteVolumeExecute(r) +} + +/* + * DeleteVolume Method for DeleteVolume + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteVolumeRequest + */ +func (a *VolumeApiService) DeleteVolume(ctx _context.Context) ApiDeleteVolumeRequest { + return ApiDeleteVolumeRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteVolumeResponse + */ +func (a *VolumeApiService) DeleteVolumeExecute(r ApiDeleteVolumeRequest) (DeleteVolumeResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteVolumeResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumeApiService.DeleteVolume") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteVolume" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteVolumeRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiLinkVolumeRequest struct { + ctx _context.Context + ApiService *VolumeApiService + linkVolumeRequest *LinkVolumeRequest +} + +func (r ApiLinkVolumeRequest) LinkVolumeRequest(linkVolumeRequest LinkVolumeRequest) ApiLinkVolumeRequest { + r.linkVolumeRequest = &linkVolumeRequest + return r +} + +func (r ApiLinkVolumeRequest) Execute() (LinkVolumeResponse, *_nethttp.Response, error) { + return r.ApiService.LinkVolumeExecute(r) +} + +/* + * LinkVolume Method for LinkVolume + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiLinkVolumeRequest + */ +func (a *VolumeApiService) LinkVolume(ctx _context.Context) ApiLinkVolumeRequest { + return ApiLinkVolumeRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return LinkVolumeResponse + */ +func (a *VolumeApiService) LinkVolumeExecute(r ApiLinkVolumeRequest) (LinkVolumeResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue LinkVolumeResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumeApiService.LinkVolume") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/LinkVolume" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.linkVolumeRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVolumesRequest struct { + ctx _context.Context + ApiService *VolumeApiService + readVolumesRequest *ReadVolumesRequest +} + +func (r ApiReadVolumesRequest) ReadVolumesRequest(readVolumesRequest ReadVolumesRequest) ApiReadVolumesRequest { + r.readVolumesRequest = &readVolumesRequest + return r +} + +func (r ApiReadVolumesRequest) Execute() (ReadVolumesResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVolumesExecute(r) +} + +/* + * ReadVolumes Method for ReadVolumes + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVolumesRequest + */ +func (a *VolumeApiService) ReadVolumes(ctx _context.Context) ApiReadVolumesRequest { + return ApiReadVolumesRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVolumesResponse + */ +func (a *VolumeApiService) ReadVolumesExecute(r ApiReadVolumesRequest) (ReadVolumesResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVolumesResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumeApiService.ReadVolumes") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVolumes" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVolumesRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiUnlinkVolumeRequest struct { + ctx _context.Context + ApiService *VolumeApiService + unlinkVolumeRequest *UnlinkVolumeRequest +} + +func (r ApiUnlinkVolumeRequest) UnlinkVolumeRequest(unlinkVolumeRequest UnlinkVolumeRequest) ApiUnlinkVolumeRequest { + r.unlinkVolumeRequest = &unlinkVolumeRequest + return r +} + +func (r ApiUnlinkVolumeRequest) Execute() (UnlinkVolumeResponse, *_nethttp.Response, error) { + return r.ApiService.UnlinkVolumeExecute(r) +} + +/* + * UnlinkVolume Method for UnlinkVolume + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiUnlinkVolumeRequest + */ +func (a *VolumeApiService) UnlinkVolume(ctx _context.Context) ApiUnlinkVolumeRequest { + return ApiUnlinkVolumeRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return UnlinkVolumeResponse + */ +func (a *VolumeApiService) UnlinkVolumeExecute(r ApiUnlinkVolumeRequest) (UnlinkVolumeResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue UnlinkVolumeResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VolumeApiService.UnlinkVolume") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/UnlinkVolume" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.unlinkVolumeRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 400 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 401 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHTTPResponse, newErr + } + if localVarHTTPResponse.StatusCode == 500 { + var v ErrorResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go new file mode 100644 index 000000000..c17dd34dc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go @@ -0,0 +1,632 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + _context "context" + _ioutil "io/ioutil" + _nethttp "net/http" + _neturl "net/url" +) + +// Linger please +var ( + _ _context.Context +) + +// VpnConnectionApiService VpnConnectionApi service +type VpnConnectionApiService service + +type ApiCreateVpnConnectionRequest struct { + ctx _context.Context + ApiService *VpnConnectionApiService + createVpnConnectionRequest *CreateVpnConnectionRequest +} + +func (r ApiCreateVpnConnectionRequest) CreateVpnConnectionRequest(createVpnConnectionRequest CreateVpnConnectionRequest) ApiCreateVpnConnectionRequest { + r.createVpnConnectionRequest = &createVpnConnectionRequest + return r +} + +func (r ApiCreateVpnConnectionRequest) Execute() (CreateVpnConnectionResponse, *_nethttp.Response, error) { + return r.ApiService.CreateVpnConnectionExecute(r) +} + +/* + * CreateVpnConnection Method for CreateVpnConnection + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateVpnConnectionRequest + */ +func (a *VpnConnectionApiService) CreateVpnConnection(ctx _context.Context) ApiCreateVpnConnectionRequest { + return ApiCreateVpnConnectionRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateVpnConnectionResponse + */ +func (a *VpnConnectionApiService) CreateVpnConnectionExecute(r ApiCreateVpnConnectionRequest) (CreateVpnConnectionResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateVpnConnectionResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VpnConnectionApiService.CreateVpnConnection") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateVpnConnection" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createVpnConnectionRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiCreateVpnConnectionRouteRequest struct { + ctx _context.Context + ApiService *VpnConnectionApiService + createVpnConnectionRouteRequest *CreateVpnConnectionRouteRequest +} + +func (r ApiCreateVpnConnectionRouteRequest) CreateVpnConnectionRouteRequest(createVpnConnectionRouteRequest CreateVpnConnectionRouteRequest) ApiCreateVpnConnectionRouteRequest { + r.createVpnConnectionRouteRequest = &createVpnConnectionRouteRequest + return r +} + +func (r ApiCreateVpnConnectionRouteRequest) Execute() (CreateVpnConnectionRouteResponse, *_nethttp.Response, error) { + return r.ApiService.CreateVpnConnectionRouteExecute(r) +} + +/* + * CreateVpnConnectionRoute Method for CreateVpnConnectionRoute + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiCreateVpnConnectionRouteRequest + */ +func (a *VpnConnectionApiService) CreateVpnConnectionRoute(ctx _context.Context) ApiCreateVpnConnectionRouteRequest { + return ApiCreateVpnConnectionRouteRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return CreateVpnConnectionRouteResponse + */ +func (a *VpnConnectionApiService) CreateVpnConnectionRouteExecute(r ApiCreateVpnConnectionRouteRequest) (CreateVpnConnectionRouteResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue CreateVpnConnectionRouteResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VpnConnectionApiService.CreateVpnConnectionRoute") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/CreateVpnConnectionRoute" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.createVpnConnectionRouteRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteVpnConnectionRequest struct { + ctx _context.Context + ApiService *VpnConnectionApiService + deleteVpnConnectionRequest *DeleteVpnConnectionRequest +} + +func (r ApiDeleteVpnConnectionRequest) DeleteVpnConnectionRequest(deleteVpnConnectionRequest DeleteVpnConnectionRequest) ApiDeleteVpnConnectionRequest { + r.deleteVpnConnectionRequest = &deleteVpnConnectionRequest + return r +} + +func (r ApiDeleteVpnConnectionRequest) Execute() (DeleteVpnConnectionResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteVpnConnectionExecute(r) +} + +/* + * DeleteVpnConnection Method for DeleteVpnConnection + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteVpnConnectionRequest + */ +func (a *VpnConnectionApiService) DeleteVpnConnection(ctx _context.Context) ApiDeleteVpnConnectionRequest { + return ApiDeleteVpnConnectionRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteVpnConnectionResponse + */ +func (a *VpnConnectionApiService) DeleteVpnConnectionExecute(r ApiDeleteVpnConnectionRequest) (DeleteVpnConnectionResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteVpnConnectionResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VpnConnectionApiService.DeleteVpnConnection") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteVpnConnection" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteVpnConnectionRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiDeleteVpnConnectionRouteRequest struct { + ctx _context.Context + ApiService *VpnConnectionApiService + deleteVpnConnectionRouteRequest *DeleteVpnConnectionRouteRequest +} + +func (r ApiDeleteVpnConnectionRouteRequest) DeleteVpnConnectionRouteRequest(deleteVpnConnectionRouteRequest DeleteVpnConnectionRouteRequest) ApiDeleteVpnConnectionRouteRequest { + r.deleteVpnConnectionRouteRequest = &deleteVpnConnectionRouteRequest + return r +} + +func (r ApiDeleteVpnConnectionRouteRequest) Execute() (DeleteVpnConnectionRouteResponse, *_nethttp.Response, error) { + return r.ApiService.DeleteVpnConnectionRouteExecute(r) +} + +/* + * DeleteVpnConnectionRoute Method for DeleteVpnConnectionRoute + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiDeleteVpnConnectionRouteRequest + */ +func (a *VpnConnectionApiService) DeleteVpnConnectionRoute(ctx _context.Context) ApiDeleteVpnConnectionRouteRequest { + return ApiDeleteVpnConnectionRouteRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return DeleteVpnConnectionRouteResponse + */ +func (a *VpnConnectionApiService) DeleteVpnConnectionRouteExecute(r ApiDeleteVpnConnectionRouteRequest) (DeleteVpnConnectionRouteResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue DeleteVpnConnectionRouteResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VpnConnectionApiService.DeleteVpnConnectionRoute") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/DeleteVpnConnectionRoute" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.deleteVpnConnectionRouteRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + +type ApiReadVpnConnectionsRequest struct { + ctx _context.Context + ApiService *VpnConnectionApiService + readVpnConnectionsRequest *ReadVpnConnectionsRequest +} + +func (r ApiReadVpnConnectionsRequest) ReadVpnConnectionsRequest(readVpnConnectionsRequest ReadVpnConnectionsRequest) ApiReadVpnConnectionsRequest { + r.readVpnConnectionsRequest = &readVpnConnectionsRequest + return r +} + +func (r ApiReadVpnConnectionsRequest) Execute() (ReadVpnConnectionsResponse, *_nethttp.Response, error) { + return r.ApiService.ReadVpnConnectionsExecute(r) +} + +/* + * ReadVpnConnections Method for ReadVpnConnections + * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @return ApiReadVpnConnectionsRequest + */ +func (a *VpnConnectionApiService) ReadVpnConnections(ctx _context.Context) ApiReadVpnConnectionsRequest { + return ApiReadVpnConnectionsRequest{ + ApiService: a, + ctx: ctx, + } +} + +/* + * Execute executes the request + * @return ReadVpnConnectionsResponse + */ +func (a *VpnConnectionApiService) ReadVpnConnectionsExecute(r ApiReadVpnConnectionsRequest) (ReadVpnConnectionsResponse, *_nethttp.Response, error) { + var ( + localVarHTTPMethod = _nethttp.MethodPost + localVarPostBody interface{} + localVarFormFileName string + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ReadVpnConnectionsResponse + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "VpnConnectionApiService.ReadVpnConnections") + if err != nil { + return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/ReadVpnConnections" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := _neturl.Values{} + localVarFormParams := _neturl.Values{} + + // to determine the Content-Type header + localVarHTTPContentTypes := []string{"application/json"} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + // body params + localVarPostBody = r.readVpnConnectionsRequest + if r.ctx != nil { + // API Key Authentication + if auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { + if apiKey, ok := auth["ApiKeyAuth"]; ok { + var key string + if apiKey.Prefix != "" { + key = apiKey.Prefix + " " + apiKey.Key + } else { + key = apiKey.Key + } + localVarHeaderParams["Authorization"] = key + } + } + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/client.go b/vendor/github.com/outscale/osc-sdk-go/osc/client.go new file mode 100644 index 000000000..65d3915c0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/client.go @@ -0,0 +1,664 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "bytes" + "context" + "encoding/json" + "encoding/xml" + "errors" + "fmt" + "io" + "log" + "mime/multipart" + "net/http" + "net/http/httputil" + "net/url" + "os" + "path/filepath" + "reflect" + "regexp" + "strconv" + "strings" + "time" + "unicode/utf8" + + "golang.org/x/oauth2" + awsv4 "github.com/aws/aws-sdk-go/aws/signer/v4" + awscredentials "github.com/aws/aws-sdk-go/aws/credentials" +) + +var ( + jsonCheck = regexp.MustCompile(`(?i:(?:application|text)/(?:vnd\.[^;]+\+)?json)`) + xmlCheck = regexp.MustCompile(`(?i:(?:application|text)/xml)`) +) + +// APIClient manages communication with the 3DS OUTSCALE API API v1.4 +// In most cases there should be only one, shared, APIClient. +type APIClient struct { + cfg *Configuration + common service // Reuse a single struct instead of allocating one for each service on the heap. + + // API Services + + AccessKeyApi *AccessKeyApiService + + AccountApi *AccountApiService + + ApiLogApi *ApiLogApiService + + ClientGatewayApi *ClientGatewayApiService + + DhcpOptionApi *DhcpOptionApiService + + DirectLinkApi *DirectLinkApiService + + DirectLinkInterfaceApi *DirectLinkInterfaceApiService + + FlexibleGpuApi *FlexibleGpuApiService + + ImageApi *ImageApiService + + InternetServiceApi *InternetServiceApiService + + KeypairApi *KeypairApiService + + ListenerApi *ListenerApiService + + LoadBalancerApi *LoadBalancerApiService + + LoadBalancerPolicyApi *LoadBalancerPolicyApiService + + LocationApi *LocationApiService + + NatServiceApi *NatServiceApiService + + NetApi *NetApiService + + NetAccessPointApi *NetAccessPointApiService + + NetPeeringApi *NetPeeringApiService + + NicApi *NicApiService + + ProductTypeApi *ProductTypeApiService + + PublicIpApi *PublicIpApiService + + QuotaApi *QuotaApiService + + RegionApi *RegionApiService + + RouteApi *RouteApiService + + RouteTableApi *RouteTableApiService + + SecurityGroupApi *SecurityGroupApiService + + SecurityGroupRuleApi *SecurityGroupRuleApiService + + ServerCertificateApi *ServerCertificateApiService + + SnapshotApi *SnapshotApiService + + SubnetApi *SubnetApiService + + SubregionApi *SubregionApiService + + TagApi *TagApiService + + TaskApi *TaskApiService + + VirtualGatewayApi *VirtualGatewayApiService + + VmApi *VmApiService + + VolumeApi *VolumeApiService + + VpnConnectionApi *VpnConnectionApiService +} + +type service struct { + client *APIClient +} + +// NewAPIClient creates a new API client. Requires a userAgent string describing your application. +// optionally a custom http.Client to allow for advanced features such as caching. +func NewAPIClient(cfg *Configuration) *APIClient { + if cfg.HTTPClient == nil { + cfg.HTTPClient = http.DefaultClient + } + + c := &APIClient{} + c.cfg = cfg + c.common.client = c + + // API Services + c.AccessKeyApi = (*AccessKeyApiService)(&c.common) + c.AccountApi = (*AccountApiService)(&c.common) + c.ApiLogApi = (*ApiLogApiService)(&c.common) + c.ClientGatewayApi = (*ClientGatewayApiService)(&c.common) + c.DhcpOptionApi = (*DhcpOptionApiService)(&c.common) + c.DirectLinkApi = (*DirectLinkApiService)(&c.common) + c.DirectLinkInterfaceApi = (*DirectLinkInterfaceApiService)(&c.common) + c.FlexibleGpuApi = (*FlexibleGpuApiService)(&c.common) + c.ImageApi = (*ImageApiService)(&c.common) + c.InternetServiceApi = (*InternetServiceApiService)(&c.common) + c.KeypairApi = (*KeypairApiService)(&c.common) + c.ListenerApi = (*ListenerApiService)(&c.common) + c.LoadBalancerApi = (*LoadBalancerApiService)(&c.common) + c.LoadBalancerPolicyApi = (*LoadBalancerPolicyApiService)(&c.common) + c.LocationApi = (*LocationApiService)(&c.common) + c.NatServiceApi = (*NatServiceApiService)(&c.common) + c.NetApi = (*NetApiService)(&c.common) + c.NetAccessPointApi = (*NetAccessPointApiService)(&c.common) + c.NetPeeringApi = (*NetPeeringApiService)(&c.common) + c.NicApi = (*NicApiService)(&c.common) + c.ProductTypeApi = (*ProductTypeApiService)(&c.common) + c.PublicIpApi = (*PublicIpApiService)(&c.common) + c.QuotaApi = (*QuotaApiService)(&c.common) + c.RegionApi = (*RegionApiService)(&c.common) + c.RouteApi = (*RouteApiService)(&c.common) + c.RouteTableApi = (*RouteTableApiService)(&c.common) + c.SecurityGroupApi = (*SecurityGroupApiService)(&c.common) + c.SecurityGroupRuleApi = (*SecurityGroupRuleApiService)(&c.common) + c.ServerCertificateApi = (*ServerCertificateApiService)(&c.common) + c.SnapshotApi = (*SnapshotApiService)(&c.common) + c.SubnetApi = (*SubnetApiService)(&c.common) + c.SubregionApi = (*SubregionApiService)(&c.common) + c.TagApi = (*TagApiService)(&c.common) + c.TaskApi = (*TaskApiService)(&c.common) + c.VirtualGatewayApi = (*VirtualGatewayApiService)(&c.common) + c.VmApi = (*VmApiService)(&c.common) + c.VolumeApi = (*VolumeApiService)(&c.common) + c.VpnConnectionApi = (*VpnConnectionApiService)(&c.common) + + return c +} + +func atoi(in string) (int, error) { + return strconv.Atoi(in) +} + +// selectHeaderContentType select a content type from the available list. +func selectHeaderContentType(contentTypes []string) string { + if len(contentTypes) == 0 { + return "" + } + if contains(contentTypes, "application/json") { + return "application/json" + } + return contentTypes[0] // use the first content type specified in 'consumes' +} + +// selectHeaderAccept join all accept types and return +func selectHeaderAccept(accepts []string) string { + if len(accepts) == 0 { + return "" + } + + if contains(accepts, "application/json") { + return "application/json" + } + + return strings.Join(accepts, ",") +} + +// contains is a case insenstive match, finding needle in a haystack +func contains(haystack []string, needle string) bool { + for _, a := range haystack { + if strings.ToLower(a) == strings.ToLower(needle) { + return true + } + } + return false +} + +// Verify optional parameters are of the correct type. +func typeCheckParameter(obj interface{}, expected string, name string) error { + // Make sure there is an object. + if obj == nil { + return nil + } + + // Check the type is as expected. + if reflect.TypeOf(obj).String() != expected { + return fmt.Errorf("Expected %s to be of type %s but received %s.", name, expected, reflect.TypeOf(obj).String()) + } + return nil +} + +// parameterToString convert interface{} parameters to string, using a delimiter if format is provided. +func parameterToString(obj interface{}, collectionFormat string) string { + var delimiter string + + switch collectionFormat { + case "pipes": + delimiter = "|" + case "ssv": + delimiter = " " + case "tsv": + delimiter = "\t" + case "csv": + delimiter = "," + } + + if reflect.TypeOf(obj).Kind() == reflect.Slice { + return strings.Trim(strings.Replace(fmt.Sprint(obj), " ", delimiter, -1), "[]") + } else if t, ok := obj.(time.Time); ok { + return t.Format(time.RFC3339) + } + + return fmt.Sprintf("%v", obj) +} + +// helper for converting interface{} parameters to json strings +func parameterToJson(obj interface{}) (string, error) { + jsonBuf, err := json.Marshal(obj) + if err != nil { + return "", err + } + return string(jsonBuf), err +} + + +// callAPI do the request. +func (c *APIClient) callAPI(request *http.Request) (*http.Response, error) { + if c.cfg.Debug { + dump, err := httputil.DumpRequestOut(request, true) + if err != nil { + return nil, err + } + log.Printf("\n%s\n", string(dump)) + } + + resp, err := c.cfg.HTTPClient.Do(request) + if err != nil { + return resp, err + } + + if c.cfg.Debug { + dump, err := httputil.DumpResponse(resp, true) + if err != nil { + return resp, err + } + log.Printf("\n%s\n", string(dump)) + } + return resp, err +} + +// Allow modification of underlying config for alternate implementations and testing +// Caution: modifying the configuration while live can cause data races and potentially unwanted behavior +func (c *APIClient) GetConfig() *Configuration { + return c.cfg +} + +// prepareRequest build the request +func (c *APIClient) prepareRequest( + ctx context.Context, + path string, method string, + postBody interface{}, + headerParams map[string]string, + queryParams url.Values, + formParams url.Values, + formFileName string, + fileName string, + fileBytes []byte) (localVarRequest *http.Request, err error) { + + var body *bytes.Buffer + + // Detect postBody type and post. + if postBody != nil { + contentType := headerParams["Content-Type"] + if contentType == "" { + contentType = detectContentType(postBody) + headerParams["Content-Type"] = contentType + } + + body, err = setBody(postBody, contentType) + if err != nil { + return nil, err + } + } + + // add form parameters and file if available. + if strings.HasPrefix(headerParams["Content-Type"], "multipart/form-data") && len(formParams) > 0 || (len(fileBytes) > 0 && fileName != "") { + if body != nil { + return nil, errors.New("Cannot specify postBody and multipart form at the same time.") + } + body = &bytes.Buffer{} + w := multipart.NewWriter(body) + + for k, v := range formParams { + for _, iv := range v { + if strings.HasPrefix(k, "@") { // file + err = addFile(w, k[1:], iv) + if err != nil { + return nil, err + } + } else { // form value + w.WriteField(k, iv) + } + } + } + if len(fileBytes) > 0 && fileName != "" { + w.Boundary() + //_, fileNm := filepath.Split(fileName) + part, err := w.CreateFormFile(formFileName, filepath.Base(fileName)) + if err != nil { + return nil, err + } + _, err = part.Write(fileBytes) + if err != nil { + return nil, err + } + } + + // Set the Boundary in the Content-Type + headerParams["Content-Type"] = w.FormDataContentType() + + // Set Content-Length + headerParams["Content-Length"] = fmt.Sprintf("%d", body.Len()) + w.Close() + } + + if strings.HasPrefix(headerParams["Content-Type"], "application/x-www-form-urlencoded") && len(formParams) > 0 { + if body != nil { + return nil, errors.New("Cannot specify postBody and x-www-form-urlencoded form at the same time.") + } + body = &bytes.Buffer{} + body.WriteString(formParams.Encode()) + // Set Content-Length + headerParams["Content-Length"] = fmt.Sprintf("%d", body.Len()) + } + + // Setup path and query parameters + url, err := url.Parse(path) + if err != nil { + return nil, err + } + + // Override request host, if applicable + if c.cfg.Host != "" { + url.Host = c.cfg.Host + } + + // Override request scheme, if applicable + if c.cfg.Scheme != "" { + url.Scheme = c.cfg.Scheme + } + + // Adding Query Param + query := url.Query() + for k, v := range queryParams { + for _, iv := range v { + query.Add(k, iv) + } + } + + // Encode the parameters. + url.RawQuery = query.Encode() + + // Generate a new request + if body != nil { + localVarRequest, err = http.NewRequest(method, url.String(), body) + } else { + localVarRequest, err = http.NewRequest(method, url.String(), nil) + } + if err != nil { + return nil, err + } + + // add header parameters, if any + if len(headerParams) > 0 { + headers := http.Header{} + for h, v := range headerParams { + headers.Set(h, v) + } + localVarRequest.Header = headers + } + + // Add the user agent to the request. + localVarRequest.Header.Add("User-Agent", c.cfg.UserAgent) + + if ctx != nil { + // add context to the request + localVarRequest = localVarRequest.WithContext(ctx) + + // Walk through any authentication. + + // OAuth2 authentication + if tok, ok := ctx.Value(ContextOAuth2).(oauth2.TokenSource); ok { + // We were able to grab an oauth2 token from the context + var latestToken *oauth2.Token + if latestToken, err = tok.Token(); err != nil { + return nil, err + } + + latestToken.SetAuthHeader(localVarRequest) + } + + // Basic HTTP Authentication + if auth, ok := ctx.Value(ContextBasicAuth).(BasicAuth); ok { + localVarRequest.SetBasicAuth(auth.UserName, auth.Password) + } + + // AccessToken Authentication + if auth, ok := ctx.Value(ContextAccessToken).(string); ok { + localVarRequest.Header.Add("Authorization", "Bearer "+auth) + } + + // AWS Signature v4 Authentication + if auth, ok := ctx.Value(ContextAWSv4).(AWSv4); ok { + creds := awscredentials.NewStaticCredentials(auth.AccessKey, auth.SecretKey, "") + signer := awsv4.NewSigner(creds) + var reader *strings.Reader + if body == nil { + reader = strings.NewReader("") + } else { + reader = strings.NewReader(body.String()) + } + timestamp := time.Now() + _, err := signer.Sign(localVarRequest, reader, "oapi", "eu-west-2", timestamp) + if err != nil { + return nil, err + } + } + } + + for header, value := range c.cfg.DefaultHeader { + localVarRequest.Header.Add(header, value) + } + return localVarRequest, nil +} + +func (c *APIClient) decode(v interface{}, b []byte, contentType string) (err error) { + if len(b) == 0 { + return nil + } + if s, ok := v.(*string); ok { + *s = string(b) + return nil + } + if xmlCheck.MatchString(contentType) { + if err = xml.Unmarshal(b, v); err != nil { + return err + } + return nil + } + if jsonCheck.MatchString(contentType) { + if actualObj, ok := v.(interface{GetActualInstance() interface{}}); ok { // oneOf, anyOf schemas + if unmarshalObj, ok := actualObj.(interface{UnmarshalJSON([]byte) error}); ok { // make sure it has UnmarshalJSON defined + if err = unmarshalObj.UnmarshalJSON(b); err!= nil { + return err + } + } else { + errors.New("Unknown type with GetActualInstance but no unmarshalObj.UnmarshalJSON defined") + } + } else if err = json.Unmarshal(b, v); err != nil { // simple model + return err + } + return nil + } + return errors.New("undefined response type") +} + +// Add a file to the multipart request +func addFile(w *multipart.Writer, fieldName, path string) error { + file, err := os.Open(path) + if err != nil { + return err + } + defer file.Close() + + part, err := w.CreateFormFile(fieldName, filepath.Base(path)) + if err != nil { + return err + } + _, err = io.Copy(part, file) + + return err +} + +// Prevent trying to import "fmt" +func reportError(format string, a ...interface{}) error { + return fmt.Errorf(format, a...) +} + +// Set request body from an interface{} +func setBody(body interface{}, contentType string) (bodyBuf *bytes.Buffer, err error) { + if bodyBuf == nil { + bodyBuf = &bytes.Buffer{} + } + + if reader, ok := body.(io.Reader); ok { + _, err = bodyBuf.ReadFrom(reader) + } else if b, ok := body.([]byte); ok { + _, err = bodyBuf.Write(b) + } else if s, ok := body.(string); ok { + _, err = bodyBuf.WriteString(s) + } else if s, ok := body.(*string); ok { + _, err = bodyBuf.WriteString(*s) + } else if jsonCheck.MatchString(contentType) { + err = json.NewEncoder(bodyBuf).Encode(body) + } else if xmlCheck.MatchString(contentType) { + err = xml.NewEncoder(bodyBuf).Encode(body) + } + + if err != nil { + return nil, err + } + + if bodyBuf.Len() == 0 { + err = fmt.Errorf("Invalid body type %s\n", contentType) + return nil, err + } + return bodyBuf, nil +} + +// detectContentType method is used to figure out `Request.Body` content type for request header +func detectContentType(body interface{}) string { + contentType := "text/plain; charset=utf-8" + kind := reflect.TypeOf(body).Kind() + + switch kind { + case reflect.Struct, reflect.Map, reflect.Ptr: + contentType = "application/json; charset=utf-8" + case reflect.String: + contentType = "text/plain; charset=utf-8" + default: + if b, ok := body.([]byte); ok { + contentType = http.DetectContentType(b) + } else if kind == reflect.Slice { + contentType = "application/json; charset=utf-8" + } + } + + return contentType +} + +// Ripped from https://github.com/gregjones/httpcache/blob/master/httpcache.go +type cacheControl map[string]string + +func parseCacheControl(headers http.Header) cacheControl { + cc := cacheControl{} + ccHeader := headers.Get("Cache-Control") + for _, part := range strings.Split(ccHeader, ",") { + part = strings.Trim(part, " ") + if part == "" { + continue + } + if strings.ContainsRune(part, '=') { + keyval := strings.Split(part, "=") + cc[strings.Trim(keyval[0], " ")] = strings.Trim(keyval[1], ",") + } else { + cc[part] = "" + } + } + return cc +} + +// CacheExpires helper function to determine remaining time before repeating a request. +func CacheExpires(r *http.Response) time.Time { + // Figure out when the cache expires. + var expires time.Time + now, err := time.Parse(time.RFC1123, r.Header.Get("date")) + if err != nil { + return time.Now() + } + respCacheControl := parseCacheControl(r.Header) + + if maxAge, ok := respCacheControl["max-age"]; ok { + lifetime, err := time.ParseDuration(maxAge + "s") + if err != nil { + expires = now + } else { + expires = now.Add(lifetime) + } + } else { + expiresHeader := r.Header.Get("Expires") + if expiresHeader != "" { + expires, err = time.Parse(time.RFC1123, expiresHeader) + if err != nil { + expires = now + } + } + } + return expires +} + +func strlen(s string) int { + return utf8.RuneCountInString(s) +} + +// GenericOpenAPIError Provides access to the body, error and model on returned errors. +type GenericOpenAPIError struct { + body []byte + error string + model interface{} +} + +// Error returns non-empty string if there was an error. +func (e GenericOpenAPIError) Error() string { + return e.error +} + +// Body returns the raw bytes of the response +func (e GenericOpenAPIError) Body() []byte { + return e.body +} + +// Model returns the unpacked model of the error +func (e GenericOpenAPIError) Model() interface{} { + return e.model +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/configuration.go b/vendor/github.com/outscale/osc-sdk-go/osc/configuration.go new file mode 100644 index 000000000..ac823894b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/configuration.go @@ -0,0 +1,266 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "context" + "fmt" + "net/http" + "strings" +) + +// contextKeys are used to identify the type of value in the context. +// Since these are string, it is possible to get a short description of the +// context key for logging and debugging using key.String(). + +type contextKey string + +func (c contextKey) String() string { + return "auth " + string(c) +} + +var ( + // ContextOAuth2 takes an oauth2.TokenSource as authentication for the request. + ContextOAuth2 = contextKey("token") + + // ContextBasicAuth takes BasicAuth as authentication for the request. + ContextBasicAuth = contextKey("basic") + + // ContextAccessToken takes a string oauth2 access token as authentication for the request. + ContextAccessToken = contextKey("accesstoken") + + // ContextAPIKeys takes a string apikey as authentication for the request + ContextAPIKeys = contextKey("apiKeys") + + // ContextAWSv4 takes an Access Key and a Secret Key for signing AWS Signature v4 + ContextAWSv4 = contextKey("awsv4") + + // ContextHttpSignatureAuth takes HttpSignatureAuth as authentication for the request. + ContextHttpSignatureAuth = contextKey("httpsignature") + + // ContextServerIndex uses a server configuration from the index. + ContextServerIndex = contextKey("serverIndex") + + // ContextOperationServerIndices uses a server configuration from the index mapping. + ContextOperationServerIndices = contextKey("serverOperationIndices") + + // ContextServerVariables overrides a server configuration variables. + ContextServerVariables = contextKey("serverVariables") + + // ContextOperationServerVariables overrides a server configuration variables using operation specific values. + ContextOperationServerVariables = contextKey("serverOperationVariables") +) + +// BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth +type BasicAuth struct { + UserName string `json:"userName,omitempty"` + Password string `json:"password,omitempty"` +} + +// APIKey provides API key based authentication to a request passed via context using ContextAPIKey +type APIKey struct { + Key string + Prefix string +} + +// AWSv4 provides AWS Signature to a request passed via context using ContextAWSv4 +// https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html +type AWSv4 struct { + AccessKey string + SecretKey string +} + +// ServerVariable stores the information about a server variable +type ServerVariable struct { + Description string + DefaultValue string + EnumValues []string +} + +// ServerConfiguration stores the information about a server +type ServerConfiguration struct { + URL string + Description string + Variables map[string]ServerVariable +} + +// ServerConfigurations stores multiple ServerConfiguration items +type ServerConfigurations []ServerConfiguration + +// Configuration stores the configuration of the API client +type Configuration struct { + Host string `json:"host,omitempty"` + Scheme string `json:"scheme,omitempty"` + DefaultHeader map[string]string `json:"defaultHeader,omitempty"` + UserAgent string `json:"userAgent,omitempty"` + Debug bool `json:"debug,omitempty"` + Servers ServerConfigurations + OperationServers map[string]ServerConfigurations + HTTPClient *http.Client +} + +// NewConfiguration returns a new Configuration object +func NewConfiguration() *Configuration { + cfg := &Configuration{ + DefaultHeader: make(map[string]string), + UserAgent: "OpenAPI-Generator/1.0.0/go", + Debug: false, + Servers: ServerConfigurations{ + { + URL: "https://api.{region}.outscale.com/api/v1", + Description: "No description provided", + Variables: map[string]ServerVariable{ + "region": ServerVariable{ + Description: "No description provided", + DefaultValue: "eu-west-2", + EnumValues: []string{ + "cloudgouv-eu-west-1", + "eu-west-2", + "us-east-2", + "us-west-1", + }, + }, + }, + }, + { + URL: "https://api.{region}.outscale.hk/api/v1", + Description: "No description provided", + Variables: map[string]ServerVariable{ + "region": ServerVariable{ + Description: "No description provided", + DefaultValue: "cn-southeast-1", + EnumValues: []string{ + "cn-southeast-1", + }, + }, + }, + }, + }, + OperationServers: map[string]ServerConfigurations{ + }, + } + return cfg +} + +// AddDefaultHeader adds a new HTTP header to the default header in the request +func (c *Configuration) AddDefaultHeader(key string, value string) { + c.DefaultHeader[key] = value +} + +// URL formats template on a index using given variables +func (sc ServerConfigurations) URL(index int, variables map[string]string) (string, error) { + if index < 0 || len(sc) <= index { + return "", fmt.Errorf("Index %v out of range %v", index, len(sc)-1) + } + server := sc[index] + url := server.URL + + // go through variables and replace placeholders + for name, variable := range server.Variables { + if value, ok := variables[name]; ok { + found := bool(len(variable.EnumValues) == 0) + for _, enumValue := range variable.EnumValues { + if value == enumValue { + found = true + } + } + if !found { + return "", fmt.Errorf("The variable %s in the server URL has invalid value %v. Must be %v", name, value, variable.EnumValues) + } + url = strings.Replace(url, "{"+name+"}", value, -1) + } else { + url = strings.Replace(url, "{"+name+"}", variable.DefaultValue, -1) + } + } + return url, nil +} + +// ServerURL returns URL based on server settings +func (c *Configuration) ServerURL(index int, variables map[string]string) (string, error) { + return c.Servers.URL(index, variables) +} + +func getServerIndex(ctx context.Context) (int, error) { + si := ctx.Value(ContextServerIndex) + if si != nil { + if index, ok := si.(int); ok { + return index, nil + } + return 0, reportError("Invalid type %T should be int", si) + } + return 0, nil +} + +func getServerOperationIndex(ctx context.Context, endpoint string) (int, error) { + osi := ctx.Value(ContextOperationServerIndices) + if osi != nil { + if operationIndices, ok := osi.(map[string]int); !ok { + return 0, reportError("Invalid type %T should be map[string]int", osi) + } else { + index, ok := operationIndices[endpoint] + if ok { + return index, nil + } + } + } + return getServerIndex(ctx) +} + +func getServerVariables(ctx context.Context) (map[string]string, error) { + sv := ctx.Value(ContextServerVariables) + if sv != nil { + if variables, ok := sv.(map[string]string); ok { + return variables, nil + } + return nil, reportError("ctx value of ContextServerVariables has invalid type %T should be map[string]string", sv) + } + return nil, nil +} + +func getServerOperationVariables(ctx context.Context, endpoint string) (map[string]string, error) { + osv := ctx.Value(ContextOperationServerVariables) + if osv != nil { + if operationVariables, ok := osv.(map[string]map[string]string); !ok { + return nil, reportError("ctx value of ContextOperationServerVariables has invalid type %T should be map[string]map[string]string", osv) + } else { + variables, ok := operationVariables[endpoint] + if ok { + return variables, nil + } + } + } + return getServerVariables(ctx) +} + +// ServerURLWithContext returns a new server URL given an endpoint +func (c *Configuration) ServerURLWithContext(ctx context.Context, endpoint string) (string, error) { + sc, ok := c.OperationServers[endpoint] + if !ok { + sc = c.Servers + } + + if ctx == nil { + return sc.URL(0, nil) + } + + index, err := getServerOperationIndex(ctx, endpoint) + if err != nil { + return "", err + } + + variables, err := getServerOperationVariables(ctx, endpoint) + if err != nil { + return "", err + } + + return sc.URL(index, variables) +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh b/vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh new file mode 100644 index 000000000..babca737b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh @@ -0,0 +1,58 @@ +#!/bin/sh +# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ +# +# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com" + +git_user_id=$1 +git_repo_id=$2 +release_note=$3 +git_host=$4 + +if [ "$git_host" = "" ]; then + git_host="github.com" + echo "[INFO] No command line input provided. Set \$git_host to $git_host" +fi + +if [ "$git_user_id" = "" ]; then + git_user_id="outscale" + echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" +fi + +if [ "$git_repo_id" = "" ]; then + git_repo_id="osc-sdk-go/osc" + echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" +fi + +if [ "$release_note" = "" ]; then + release_note="Minor update" + echo "[INFO] No command line input provided. Set \$release_note to $release_note" +fi + +# Initialize the local directory as a Git repository +git init + +# Adds the files in the local repository and stages them for commit. +git add . + +# Commits the tracked changes and prepares them to be pushed to a remote repository. +git commit -m "$release_note" + +# Sets the new remote +git_remote=`git remote` +if [ "$git_remote" = "" ]; then # git remote not defined + + if [ "$GIT_TOKEN" = "" ]; then + echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." + git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git + else + git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git + fi + +fi + +git pull origin master + +# Pushes (Forces) the changes in the local repository up to the remote repository +echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" +git push origin master 2>&1 | grep -v 'To https' + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/go.mod b/vendor/github.com/outscale/osc-sdk-go/osc/go.mod new file mode 100644 index 000000000..10c2adcf3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/go.mod @@ -0,0 +1,8 @@ +module github.com/outscale/osc-sdk-go/osc + +go 1.13 + +require ( + golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 + github.com/aws/aws-sdk-go v1.34.14 +) diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/go.sum b/vendor/github.com/outscale/osc-sdk-go/osc/go.sum new file mode 100644 index 000000000..734252e68 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/go.sum @@ -0,0 +1,13 @@ +cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= +github.com/golang/protobuf v1.2.0 h1:P3YflyNX/ehuJFLhxviNdFxQPkGK5cDcApsge1SqnvM= +github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e h1:bRhVy7zSSasaqNksaRZiA5EEI+Ei4I1nO5Jh72wfHlg= +golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 h1:SVwTIAaPC2U/AvvLNZ2a7OVsmBpC8L5BlwK1whH3hm0= +golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= +golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4 h1:YUO/7uOKsKeq9UokNS62b8FYywz3ker1l1vDZRCRefw= +golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +google.golang.org/appengine v1.4.0 h1:/wp5JvzpHIxhs/dumFmF7BXTf3Z+dd4uXta4kVyO508= +google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go new file mode 100644 index 000000000..33d9266e8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AcceptNetPeeringRequest struct for AcceptNetPeeringRequest +type AcceptNetPeeringRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net peering connection you want to accept. + NetPeeringId string `json:"NetPeeringId"` +} + +// NewAcceptNetPeeringRequest instantiates a new AcceptNetPeeringRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAcceptNetPeeringRequest(netPeeringId string, ) *AcceptNetPeeringRequest { + this := AcceptNetPeeringRequest{} + this.NetPeeringId = netPeeringId + return &this +} + +// NewAcceptNetPeeringRequestWithDefaults instantiates a new AcceptNetPeeringRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAcceptNetPeeringRequestWithDefaults() *AcceptNetPeeringRequest { + this := AcceptNetPeeringRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *AcceptNetPeeringRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AcceptNetPeeringRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *AcceptNetPeeringRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *AcceptNetPeeringRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetPeeringId returns the NetPeeringId field value +func (o *AcceptNetPeeringRequest) GetNetPeeringId() string { + if o == nil { + var ret string + return ret + } + + return o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value +// and a boolean to check if the value has been set. +func (o *AcceptNetPeeringRequest) GetNetPeeringIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetPeeringId, true +} + +// SetNetPeeringId sets field value +func (o *AcceptNetPeeringRequest) SetNetPeeringId(v string) { + o.NetPeeringId = v +} + +func (o AcceptNetPeeringRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + return json.Marshal(toSerialize) +} + +type NullableAcceptNetPeeringRequest struct { + value *AcceptNetPeeringRequest + isSet bool +} + +func (v NullableAcceptNetPeeringRequest) Get() *AcceptNetPeeringRequest { + return v.value +} + +func (v *NullableAcceptNetPeeringRequest) Set(val *AcceptNetPeeringRequest) { + v.value = val + v.isSet = true +} + +func (v NullableAcceptNetPeeringRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableAcceptNetPeeringRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAcceptNetPeeringRequest(val *AcceptNetPeeringRequest) *NullableAcceptNetPeeringRequest { + return &NullableAcceptNetPeeringRequest{value: val, isSet: true} +} + +func (v NullableAcceptNetPeeringRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAcceptNetPeeringRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go new file mode 100644 index 000000000..94ee81afb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AcceptNetPeeringResponse struct for AcceptNetPeeringResponse +type AcceptNetPeeringResponse struct { + NetPeering *NetPeering `json:"NetPeering,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewAcceptNetPeeringResponse instantiates a new AcceptNetPeeringResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAcceptNetPeeringResponse() *AcceptNetPeeringResponse { + this := AcceptNetPeeringResponse{} + return &this +} + +// NewAcceptNetPeeringResponseWithDefaults instantiates a new AcceptNetPeeringResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAcceptNetPeeringResponseWithDefaults() *AcceptNetPeeringResponse { + this := AcceptNetPeeringResponse{} + return &this +} + +// GetNetPeering returns the NetPeering field value if set, zero value otherwise. +func (o *AcceptNetPeeringResponse) GetNetPeering() NetPeering { + if o == nil || o.NetPeering == nil { + var ret NetPeering + return ret + } + return *o.NetPeering +} + +// GetNetPeeringOk returns a tuple with the NetPeering field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AcceptNetPeeringResponse) GetNetPeeringOk() (*NetPeering, bool) { + if o == nil || o.NetPeering == nil { + return nil, false + } + return o.NetPeering, true +} + +// HasNetPeering returns a boolean if a field has been set. +func (o *AcceptNetPeeringResponse) HasNetPeering() bool { + if o != nil && o.NetPeering != nil { + return true + } + + return false +} + +// SetNetPeering gets a reference to the given NetPeering and assigns it to the NetPeering field. +func (o *AcceptNetPeeringResponse) SetNetPeering(v NetPeering) { + o.NetPeering = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *AcceptNetPeeringResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AcceptNetPeeringResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *AcceptNetPeeringResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *AcceptNetPeeringResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o AcceptNetPeeringResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetPeering != nil { + toSerialize["NetPeering"] = o.NetPeering + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableAcceptNetPeeringResponse struct { + value *AcceptNetPeeringResponse + isSet bool +} + +func (v NullableAcceptNetPeeringResponse) Get() *AcceptNetPeeringResponse { + return v.value +} + +func (v *NullableAcceptNetPeeringResponse) Set(val *AcceptNetPeeringResponse) { + v.value = val + v.isSet = true +} + +func (v NullableAcceptNetPeeringResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableAcceptNetPeeringResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAcceptNetPeeringResponse(val *AcceptNetPeeringResponse) *NullableAcceptNetPeeringResponse { + return &NullableAcceptNetPeeringResponse{value: val, isSet: true} +} + +func (v NullableAcceptNetPeeringResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAcceptNetPeeringResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go new file mode 100644 index 000000000..e4e8106fa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AccepterNet Information about the accepter Net. +type AccepterNet struct { + // The account ID of the owner of the accepter Net. + AccountId *string `json:"AccountId,omitempty"` + // The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // The ID of the accepter Net. + NetId *string `json:"NetId,omitempty"` +} + +// NewAccepterNet instantiates a new AccepterNet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAccepterNet() *AccepterNet { + this := AccepterNet{} + return &this +} + +// NewAccepterNetWithDefaults instantiates a new AccepterNet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAccepterNetWithDefaults() *AccepterNet { + this := AccepterNet{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *AccepterNet) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccepterNet) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *AccepterNet) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *AccepterNet) SetAccountId(v string) { + o.AccountId = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *AccepterNet) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccepterNet) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *AccepterNet) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *AccepterNet) SetIpRange(v string) { + o.IpRange = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *AccepterNet) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccepterNet) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *AccepterNet) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *AccepterNet) SetNetId(v string) { + o.NetId = &v +} + +func (o AccepterNet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableAccepterNet struct { + value *AccepterNet + isSet bool +} + +func (v NullableAccepterNet) Get() *AccepterNet { + return v.value +} + +func (v *NullableAccepterNet) Set(val *AccepterNet) { + v.value = val + v.isSet = true +} + +func (v NullableAccepterNet) IsSet() bool { + return v.isSet +} + +func (v *NullableAccepterNet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccepterNet(val *AccepterNet) *NullableAccepterNet { + return &NullableAccepterNet{value: val, isSet: true} +} + +func (v NullableAccepterNet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccepterNet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go new file mode 100644 index 000000000..2b2baf1dc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AccessKey Information about the access key. +type AccessKey struct { + // The ID of the access key. + AccessKeyId *string `json:"AccessKeyId,omitempty"` + // The date and time of creation of the access key. + CreationDate *string `json:"CreationDate,omitempty"` + // The date at which the access key expires. + ExpirationDate *string `json:"ExpirationDate,omitempty"` + // The date and time of the last modification of the access key. + LastModificationDate *string `json:"LastModificationDate,omitempty"` + // The state of the access key (`ACTIVE` if the key is valid for API calls, or `INACTIVE` if not). + State *string `json:"State,omitempty"` +} + +// NewAccessKey instantiates a new AccessKey object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAccessKey() *AccessKey { + this := AccessKey{} + return &this +} + +// NewAccessKeyWithDefaults instantiates a new AccessKey object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAccessKeyWithDefaults() *AccessKey { + this := AccessKey{} + return &this +} + +// GetAccessKeyId returns the AccessKeyId field value if set, zero value otherwise. +func (o *AccessKey) GetAccessKeyId() string { + if o == nil || o.AccessKeyId == nil { + var ret string + return ret + } + return *o.AccessKeyId +} + +// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKey) GetAccessKeyIdOk() (*string, bool) { + if o == nil || o.AccessKeyId == nil { + return nil, false + } + return o.AccessKeyId, true +} + +// HasAccessKeyId returns a boolean if a field has been set. +func (o *AccessKey) HasAccessKeyId() bool { + if o != nil && o.AccessKeyId != nil { + return true + } + + return false +} + +// SetAccessKeyId gets a reference to the given string and assigns it to the AccessKeyId field. +func (o *AccessKey) SetAccessKeyId(v string) { + o.AccessKeyId = &v +} + +// GetCreationDate returns the CreationDate field value if set, zero value otherwise. +func (o *AccessKey) GetCreationDate() string { + if o == nil || o.CreationDate == nil { + var ret string + return ret + } + return *o.CreationDate +} + +// GetCreationDateOk returns a tuple with the CreationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKey) GetCreationDateOk() (*string, bool) { + if o == nil || o.CreationDate == nil { + return nil, false + } + return o.CreationDate, true +} + +// HasCreationDate returns a boolean if a field has been set. +func (o *AccessKey) HasCreationDate() bool { + if o != nil && o.CreationDate != nil { + return true + } + + return false +} + +// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. +func (o *AccessKey) SetCreationDate(v string) { + o.CreationDate = &v +} + +// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. +func (o *AccessKey) GetExpirationDate() string { + if o == nil || o.ExpirationDate == nil { + var ret string + return ret + } + return *o.ExpirationDate +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKey) GetExpirationDateOk() (*string, bool) { + if o == nil || o.ExpirationDate == nil { + return nil, false + } + return o.ExpirationDate, true +} + +// HasExpirationDate returns a boolean if a field has been set. +func (o *AccessKey) HasExpirationDate() bool { + if o != nil && o.ExpirationDate != nil { + return true + } + + return false +} + +// SetExpirationDate gets a reference to the given string and assigns it to the ExpirationDate field. +func (o *AccessKey) SetExpirationDate(v string) { + o.ExpirationDate = &v +} + +// GetLastModificationDate returns the LastModificationDate field value if set, zero value otherwise. +func (o *AccessKey) GetLastModificationDate() string { + if o == nil || o.LastModificationDate == nil { + var ret string + return ret + } + return *o.LastModificationDate +} + +// GetLastModificationDateOk returns a tuple with the LastModificationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKey) GetLastModificationDateOk() (*string, bool) { + if o == nil || o.LastModificationDate == nil { + return nil, false + } + return o.LastModificationDate, true +} + +// HasLastModificationDate returns a boolean if a field has been set. +func (o *AccessKey) HasLastModificationDate() bool { + if o != nil && o.LastModificationDate != nil { + return true + } + + return false +} + +// SetLastModificationDate gets a reference to the given string and assigns it to the LastModificationDate field. +func (o *AccessKey) SetLastModificationDate(v string) { + o.LastModificationDate = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *AccessKey) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKey) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *AccessKey) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *AccessKey) SetState(v string) { + o.State = &v +} + +func (o AccessKey) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKeyId != nil { + toSerialize["AccessKeyId"] = o.AccessKeyId + } + if o.CreationDate != nil { + toSerialize["CreationDate"] = o.CreationDate + } + if o.ExpirationDate != nil { + toSerialize["ExpirationDate"] = o.ExpirationDate + } + if o.LastModificationDate != nil { + toSerialize["LastModificationDate"] = o.LastModificationDate + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableAccessKey struct { + value *AccessKey + isSet bool +} + +func (v NullableAccessKey) Get() *AccessKey { + return v.value +} + +func (v *NullableAccessKey) Set(val *AccessKey) { + v.value = val + v.isSet = true +} + +func (v NullableAccessKey) IsSet() bool { + return v.isSet +} + +func (v *NullableAccessKey) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccessKey(val *AccessKey) *NullableAccessKey { + return &NullableAccessKey{value: val, isSet: true} +} + +func (v NullableAccessKey) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccessKey) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go new file mode 100644 index 000000000..969937b91 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AccessKeySecretKey Information about the secret access key. +type AccessKeySecretKey struct { + // The ID of the secret access key. + AccessKeyId *string `json:"AccessKeyId,omitempty"` + // The date and time of creation of the secret access key. + CreationDate *string `json:"CreationDate,omitempty"` + // The date at which the access key expires. + ExpirationDate *string `json:"ExpirationDate,omitempty"` + // The date and time of the last modification of the secret access key. + LastModificationDate *string `json:"LastModificationDate,omitempty"` + // The secret access key that enables you to send requests. + SecretKey *string `json:"SecretKey,omitempty"` + // The state of the secret access key (`ACTIVE` if the key is valid for API calls, or `INACTIVE` if not). + State *string `json:"State,omitempty"` +} + +// NewAccessKeySecretKey instantiates a new AccessKeySecretKey object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAccessKeySecretKey() *AccessKeySecretKey { + this := AccessKeySecretKey{} + return &this +} + +// NewAccessKeySecretKeyWithDefaults instantiates a new AccessKeySecretKey object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAccessKeySecretKeyWithDefaults() *AccessKeySecretKey { + this := AccessKeySecretKey{} + return &this +} + +// GetAccessKeyId returns the AccessKeyId field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetAccessKeyId() string { + if o == nil || o.AccessKeyId == nil { + var ret string + return ret + } + return *o.AccessKeyId +} + +// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetAccessKeyIdOk() (*string, bool) { + if o == nil || o.AccessKeyId == nil { + return nil, false + } + return o.AccessKeyId, true +} + +// HasAccessKeyId returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasAccessKeyId() bool { + if o != nil && o.AccessKeyId != nil { + return true + } + + return false +} + +// SetAccessKeyId gets a reference to the given string and assigns it to the AccessKeyId field. +func (o *AccessKeySecretKey) SetAccessKeyId(v string) { + o.AccessKeyId = &v +} + +// GetCreationDate returns the CreationDate field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetCreationDate() string { + if o == nil || o.CreationDate == nil { + var ret string + return ret + } + return *o.CreationDate +} + +// GetCreationDateOk returns a tuple with the CreationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetCreationDateOk() (*string, bool) { + if o == nil || o.CreationDate == nil { + return nil, false + } + return o.CreationDate, true +} + +// HasCreationDate returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasCreationDate() bool { + if o != nil && o.CreationDate != nil { + return true + } + + return false +} + +// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. +func (o *AccessKeySecretKey) SetCreationDate(v string) { + o.CreationDate = &v +} + +// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetExpirationDate() string { + if o == nil || o.ExpirationDate == nil { + var ret string + return ret + } + return *o.ExpirationDate +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetExpirationDateOk() (*string, bool) { + if o == nil || o.ExpirationDate == nil { + return nil, false + } + return o.ExpirationDate, true +} + +// HasExpirationDate returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasExpirationDate() bool { + if o != nil && o.ExpirationDate != nil { + return true + } + + return false +} + +// SetExpirationDate gets a reference to the given string and assigns it to the ExpirationDate field. +func (o *AccessKeySecretKey) SetExpirationDate(v string) { + o.ExpirationDate = &v +} + +// GetLastModificationDate returns the LastModificationDate field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetLastModificationDate() string { + if o == nil || o.LastModificationDate == nil { + var ret string + return ret + } + return *o.LastModificationDate +} + +// GetLastModificationDateOk returns a tuple with the LastModificationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetLastModificationDateOk() (*string, bool) { + if o == nil || o.LastModificationDate == nil { + return nil, false + } + return o.LastModificationDate, true +} + +// HasLastModificationDate returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasLastModificationDate() bool { + if o != nil && o.LastModificationDate != nil { + return true + } + + return false +} + +// SetLastModificationDate gets a reference to the given string and assigns it to the LastModificationDate field. +func (o *AccessKeySecretKey) SetLastModificationDate(v string) { + o.LastModificationDate = &v +} + +// GetSecretKey returns the SecretKey field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetSecretKey() string { + if o == nil || o.SecretKey == nil { + var ret string + return ret + } + return *o.SecretKey +} + +// GetSecretKeyOk returns a tuple with the SecretKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetSecretKeyOk() (*string, bool) { + if o == nil || o.SecretKey == nil { + return nil, false + } + return o.SecretKey, true +} + +// HasSecretKey returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasSecretKey() bool { + if o != nil && o.SecretKey != nil { + return true + } + + return false +} + +// SetSecretKey gets a reference to the given string and assigns it to the SecretKey field. +func (o *AccessKeySecretKey) SetSecretKey(v string) { + o.SecretKey = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *AccessKeySecretKey) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessKeySecretKey) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *AccessKeySecretKey) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *AccessKeySecretKey) SetState(v string) { + o.State = &v +} + +func (o AccessKeySecretKey) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKeyId != nil { + toSerialize["AccessKeyId"] = o.AccessKeyId + } + if o.CreationDate != nil { + toSerialize["CreationDate"] = o.CreationDate + } + if o.ExpirationDate != nil { + toSerialize["ExpirationDate"] = o.ExpirationDate + } + if o.LastModificationDate != nil { + toSerialize["LastModificationDate"] = o.LastModificationDate + } + if o.SecretKey != nil { + toSerialize["SecretKey"] = o.SecretKey + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableAccessKeySecretKey struct { + value *AccessKeySecretKey + isSet bool +} + +func (v NullableAccessKeySecretKey) Get() *AccessKeySecretKey { + return v.value +} + +func (v *NullableAccessKeySecretKey) Set(val *AccessKeySecretKey) { + v.value = val + v.isSet = true +} + +func (v NullableAccessKeySecretKey) IsSet() bool { + return v.isSet +} + +func (v *NullableAccessKeySecretKey) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccessKeySecretKey(val *AccessKeySecretKey) *NullableAccessKeySecretKey { + return &NullableAccessKeySecretKey{value: val, isSet: true} +} + +func (v NullableAccessKeySecretKey) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccessKeySecretKey) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go new file mode 100644 index 000000000..e12b3c50e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// AccessLog Information about access logs. +type AccessLog struct { + // If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + IsEnabled *bool `json:"IsEnabled,omitempty"` + // The name of the Object Storage Unit (OSU) bucket for the access logs. + OsuBucketName *string `json:"OsuBucketName,omitempty"` + // The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + OsuBucketPrefix *string `json:"OsuBucketPrefix,omitempty"` + // The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + PublicationInterval *int32 `json:"PublicationInterval,omitempty"` +} + +// NewAccessLog instantiates a new AccessLog object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAccessLog() *AccessLog { + this := AccessLog{} + return &this +} + +// NewAccessLogWithDefaults instantiates a new AccessLog object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAccessLogWithDefaults() *AccessLog { + this := AccessLog{} + return &this +} + +// GetIsEnabled returns the IsEnabled field value if set, zero value otherwise. +func (o *AccessLog) GetIsEnabled() bool { + if o == nil || o.IsEnabled == nil { + var ret bool + return ret + } + return *o.IsEnabled +} + +// GetIsEnabledOk returns a tuple with the IsEnabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessLog) GetIsEnabledOk() (*bool, bool) { + if o == nil || o.IsEnabled == nil { + return nil, false + } + return o.IsEnabled, true +} + +// HasIsEnabled returns a boolean if a field has been set. +func (o *AccessLog) HasIsEnabled() bool { + if o != nil && o.IsEnabled != nil { + return true + } + + return false +} + +// SetIsEnabled gets a reference to the given bool and assigns it to the IsEnabled field. +func (o *AccessLog) SetIsEnabled(v bool) { + o.IsEnabled = &v +} + +// GetOsuBucketName returns the OsuBucketName field value if set, zero value otherwise. +func (o *AccessLog) GetOsuBucketName() string { + if o == nil || o.OsuBucketName == nil { + var ret string + return ret + } + return *o.OsuBucketName +} + +// GetOsuBucketNameOk returns a tuple with the OsuBucketName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessLog) GetOsuBucketNameOk() (*string, bool) { + if o == nil || o.OsuBucketName == nil { + return nil, false + } + return o.OsuBucketName, true +} + +// HasOsuBucketName returns a boolean if a field has been set. +func (o *AccessLog) HasOsuBucketName() bool { + if o != nil && o.OsuBucketName != nil { + return true + } + + return false +} + +// SetOsuBucketName gets a reference to the given string and assigns it to the OsuBucketName field. +func (o *AccessLog) SetOsuBucketName(v string) { + o.OsuBucketName = &v +} + +// GetOsuBucketPrefix returns the OsuBucketPrefix field value if set, zero value otherwise. +func (o *AccessLog) GetOsuBucketPrefix() string { + if o == nil || o.OsuBucketPrefix == nil { + var ret string + return ret + } + return *o.OsuBucketPrefix +} + +// GetOsuBucketPrefixOk returns a tuple with the OsuBucketPrefix field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessLog) GetOsuBucketPrefixOk() (*string, bool) { + if o == nil || o.OsuBucketPrefix == nil { + return nil, false + } + return o.OsuBucketPrefix, true +} + +// HasOsuBucketPrefix returns a boolean if a field has been set. +func (o *AccessLog) HasOsuBucketPrefix() bool { + if o != nil && o.OsuBucketPrefix != nil { + return true + } + + return false +} + +// SetOsuBucketPrefix gets a reference to the given string and assigns it to the OsuBucketPrefix field. +func (o *AccessLog) SetOsuBucketPrefix(v string) { + o.OsuBucketPrefix = &v +} + +// GetPublicationInterval returns the PublicationInterval field value if set, zero value otherwise. +func (o *AccessLog) GetPublicationInterval() int32 { + if o == nil || o.PublicationInterval == nil { + var ret int32 + return ret + } + return *o.PublicationInterval +} + +// GetPublicationIntervalOk returns a tuple with the PublicationInterval field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AccessLog) GetPublicationIntervalOk() (*int32, bool) { + if o == nil || o.PublicationInterval == nil { + return nil, false + } + return o.PublicationInterval, true +} + +// HasPublicationInterval returns a boolean if a field has been set. +func (o *AccessLog) HasPublicationInterval() bool { + if o != nil && o.PublicationInterval != nil { + return true + } + + return false +} + +// SetPublicationInterval gets a reference to the given int32 and assigns it to the PublicationInterval field. +func (o *AccessLog) SetPublicationInterval(v int32) { + o.PublicationInterval = &v +} + +func (o AccessLog) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.IsEnabled != nil { + toSerialize["IsEnabled"] = o.IsEnabled + } + if o.OsuBucketName != nil { + toSerialize["OsuBucketName"] = o.OsuBucketName + } + if o.OsuBucketPrefix != nil { + toSerialize["OsuBucketPrefix"] = o.OsuBucketPrefix + } + if o.PublicationInterval != nil { + toSerialize["PublicationInterval"] = o.PublicationInterval + } + return json.Marshal(toSerialize) +} + +type NullableAccessLog struct { + value *AccessLog + isSet bool +} + +func (v NullableAccessLog) Get() *AccessLog { + return v.value +} + +func (v *NullableAccessLog) Set(val *AccessLog) { + v.value = val + v.isSet = true +} + +func (v NullableAccessLog) IsSet() bool { + return v.isSet +} + +func (v *NullableAccessLog) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccessLog(val *AccessLog) *NullableAccessLog { + return &NullableAccessLog{value: val, isSet: true} +} + +func (v NullableAccessLog) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccessLog) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_account.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_account.go new file mode 100644 index 000000000..43ee7d97e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_account.go @@ -0,0 +1,598 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Account Information about the account. +type Account struct { + // The ID of the account. + AccountId *string `json:"AccountId,omitempty"` + // The city of the account owner. + City *string `json:"City,omitempty"` + // The name of the company for the account. + CompanyName *string `json:"CompanyName,omitempty"` + // The country of the account owner. + Country *string `json:"Country,omitempty"` + // The ID of the customer. + CustomerId *string `json:"CustomerId,omitempty"` + // The email address for the account. + Email *string `json:"Email,omitempty"` + // The first name of the account owner. + FirstName *string `json:"FirstName,omitempty"` + // The job title of the account owner. + JobTitle *string `json:"JobTitle,omitempty"` + // The last name of the account owner. + LastName *string `json:"LastName,omitempty"` + // The mobile phone number of the account owner. + MobileNumber *string `json:"MobileNumber,omitempty"` + // The landline phone number of the account owner. + PhoneNumber *string `json:"PhoneNumber,omitempty"` + // The state/province of the account. + StateProvince *string `json:"StateProvince,omitempty"` + // The value added tax (VAT) number for the account. + VatNumber *string `json:"VatNumber,omitempty"` + // The ZIP code of the city. + ZipCode *string `json:"ZipCode,omitempty"` +} + +// NewAccount instantiates a new Account object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAccount() *Account { + this := Account{} + return &this +} + +// NewAccountWithDefaults instantiates a new Account object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAccountWithDefaults() *Account { + this := Account{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Account) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Account) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Account) SetAccountId(v string) { + o.AccountId = &v +} + +// GetCity returns the City field value if set, zero value otherwise. +func (o *Account) GetCity() string { + if o == nil || o.City == nil { + var ret string + return ret + } + return *o.City +} + +// GetCityOk returns a tuple with the City field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCityOk() (*string, bool) { + if o == nil || o.City == nil { + return nil, false + } + return o.City, true +} + +// HasCity returns a boolean if a field has been set. +func (o *Account) HasCity() bool { + if o != nil && o.City != nil { + return true + } + + return false +} + +// SetCity gets a reference to the given string and assigns it to the City field. +func (o *Account) SetCity(v string) { + o.City = &v +} + +// GetCompanyName returns the CompanyName field value if set, zero value otherwise. +func (o *Account) GetCompanyName() string { + if o == nil || o.CompanyName == nil { + var ret string + return ret + } + return *o.CompanyName +} + +// GetCompanyNameOk returns a tuple with the CompanyName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCompanyNameOk() (*string, bool) { + if o == nil || o.CompanyName == nil { + return nil, false + } + return o.CompanyName, true +} + +// HasCompanyName returns a boolean if a field has been set. +func (o *Account) HasCompanyName() bool { + if o != nil && o.CompanyName != nil { + return true + } + + return false +} + +// SetCompanyName gets a reference to the given string and assigns it to the CompanyName field. +func (o *Account) SetCompanyName(v string) { + o.CompanyName = &v +} + +// GetCountry returns the Country field value if set, zero value otherwise. +func (o *Account) GetCountry() string { + if o == nil || o.Country == nil { + var ret string + return ret + } + return *o.Country +} + +// GetCountryOk returns a tuple with the Country field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCountryOk() (*string, bool) { + if o == nil || o.Country == nil { + return nil, false + } + return o.Country, true +} + +// HasCountry returns a boolean if a field has been set. +func (o *Account) HasCountry() bool { + if o != nil && o.Country != nil { + return true + } + + return false +} + +// SetCountry gets a reference to the given string and assigns it to the Country field. +func (o *Account) SetCountry(v string) { + o.Country = &v +} + +// GetCustomerId returns the CustomerId field value if set, zero value otherwise. +func (o *Account) GetCustomerId() string { + if o == nil || o.CustomerId == nil { + var ret string + return ret + } + return *o.CustomerId +} + +// GetCustomerIdOk returns a tuple with the CustomerId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetCustomerIdOk() (*string, bool) { + if o == nil || o.CustomerId == nil { + return nil, false + } + return o.CustomerId, true +} + +// HasCustomerId returns a boolean if a field has been set. +func (o *Account) HasCustomerId() bool { + if o != nil && o.CustomerId != nil { + return true + } + + return false +} + +// SetCustomerId gets a reference to the given string and assigns it to the CustomerId field. +func (o *Account) SetCustomerId(v string) { + o.CustomerId = &v +} + +// GetEmail returns the Email field value if set, zero value otherwise. +func (o *Account) GetEmail() string { + if o == nil || o.Email == nil { + var ret string + return ret + } + return *o.Email +} + +// GetEmailOk returns a tuple with the Email field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetEmailOk() (*string, bool) { + if o == nil || o.Email == nil { + return nil, false + } + return o.Email, true +} + +// HasEmail returns a boolean if a field has been set. +func (o *Account) HasEmail() bool { + if o != nil && o.Email != nil { + return true + } + + return false +} + +// SetEmail gets a reference to the given string and assigns it to the Email field. +func (o *Account) SetEmail(v string) { + o.Email = &v +} + +// GetFirstName returns the FirstName field value if set, zero value otherwise. +func (o *Account) GetFirstName() string { + if o == nil || o.FirstName == nil { + var ret string + return ret + } + return *o.FirstName +} + +// GetFirstNameOk returns a tuple with the FirstName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetFirstNameOk() (*string, bool) { + if o == nil || o.FirstName == nil { + return nil, false + } + return o.FirstName, true +} + +// HasFirstName returns a boolean if a field has been set. +func (o *Account) HasFirstName() bool { + if o != nil && o.FirstName != nil { + return true + } + + return false +} + +// SetFirstName gets a reference to the given string and assigns it to the FirstName field. +func (o *Account) SetFirstName(v string) { + o.FirstName = &v +} + +// GetJobTitle returns the JobTitle field value if set, zero value otherwise. +func (o *Account) GetJobTitle() string { + if o == nil || o.JobTitle == nil { + var ret string + return ret + } + return *o.JobTitle +} + +// GetJobTitleOk returns a tuple with the JobTitle field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetJobTitleOk() (*string, bool) { + if o == nil || o.JobTitle == nil { + return nil, false + } + return o.JobTitle, true +} + +// HasJobTitle returns a boolean if a field has been set. +func (o *Account) HasJobTitle() bool { + if o != nil && o.JobTitle != nil { + return true + } + + return false +} + +// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. +func (o *Account) SetJobTitle(v string) { + o.JobTitle = &v +} + +// GetLastName returns the LastName field value if set, zero value otherwise. +func (o *Account) GetLastName() string { + if o == nil || o.LastName == nil { + var ret string + return ret + } + return *o.LastName +} + +// GetLastNameOk returns a tuple with the LastName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetLastNameOk() (*string, bool) { + if o == nil || o.LastName == nil { + return nil, false + } + return o.LastName, true +} + +// HasLastName returns a boolean if a field has been set. +func (o *Account) HasLastName() bool { + if o != nil && o.LastName != nil { + return true + } + + return false +} + +// SetLastName gets a reference to the given string and assigns it to the LastName field. +func (o *Account) SetLastName(v string) { + o.LastName = &v +} + +// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. +func (o *Account) GetMobileNumber() string { + if o == nil || o.MobileNumber == nil { + var ret string + return ret + } + return *o.MobileNumber +} + +// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetMobileNumberOk() (*string, bool) { + if o == nil || o.MobileNumber == nil { + return nil, false + } + return o.MobileNumber, true +} + +// HasMobileNumber returns a boolean if a field has been set. +func (o *Account) HasMobileNumber() bool { + if o != nil && o.MobileNumber != nil { + return true + } + + return false +} + +// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. +func (o *Account) SetMobileNumber(v string) { + o.MobileNumber = &v +} + +// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. +func (o *Account) GetPhoneNumber() string { + if o == nil || o.PhoneNumber == nil { + var ret string + return ret + } + return *o.PhoneNumber +} + +// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetPhoneNumberOk() (*string, bool) { + if o == nil || o.PhoneNumber == nil { + return nil, false + } + return o.PhoneNumber, true +} + +// HasPhoneNumber returns a boolean if a field has been set. +func (o *Account) HasPhoneNumber() bool { + if o != nil && o.PhoneNumber != nil { + return true + } + + return false +} + +// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. +func (o *Account) SetPhoneNumber(v string) { + o.PhoneNumber = &v +} + +// GetStateProvince returns the StateProvince field value if set, zero value otherwise. +func (o *Account) GetStateProvince() string { + if o == nil || o.StateProvince == nil { + var ret string + return ret + } + return *o.StateProvince +} + +// GetStateProvinceOk returns a tuple with the StateProvince field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetStateProvinceOk() (*string, bool) { + if o == nil || o.StateProvince == nil { + return nil, false + } + return o.StateProvince, true +} + +// HasStateProvince returns a boolean if a field has been set. +func (o *Account) HasStateProvince() bool { + if o != nil && o.StateProvince != nil { + return true + } + + return false +} + +// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. +func (o *Account) SetStateProvince(v string) { + o.StateProvince = &v +} + +// GetVatNumber returns the VatNumber field value if set, zero value otherwise. +func (o *Account) GetVatNumber() string { + if o == nil || o.VatNumber == nil { + var ret string + return ret + } + return *o.VatNumber +} + +// GetVatNumberOk returns a tuple with the VatNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetVatNumberOk() (*string, bool) { + if o == nil || o.VatNumber == nil { + return nil, false + } + return o.VatNumber, true +} + +// HasVatNumber returns a boolean if a field has been set. +func (o *Account) HasVatNumber() bool { + if o != nil && o.VatNumber != nil { + return true + } + + return false +} + +// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. +func (o *Account) SetVatNumber(v string) { + o.VatNumber = &v +} + +// GetZipCode returns the ZipCode field value if set, zero value otherwise. +func (o *Account) GetZipCode() string { + if o == nil || o.ZipCode == nil { + var ret string + return ret + } + return *o.ZipCode +} + +// GetZipCodeOk returns a tuple with the ZipCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Account) GetZipCodeOk() (*string, bool) { + if o == nil || o.ZipCode == nil { + return nil, false + } + return o.ZipCode, true +} + +// HasZipCode returns a boolean if a field has been set. +func (o *Account) HasZipCode() bool { + if o != nil && o.ZipCode != nil { + return true + } + + return false +} + +// SetZipCode gets a reference to the given string and assigns it to the ZipCode field. +func (o *Account) SetZipCode(v string) { + o.ZipCode = &v +} + +func (o Account) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.City != nil { + toSerialize["City"] = o.City + } + if o.CompanyName != nil { + toSerialize["CompanyName"] = o.CompanyName + } + if o.Country != nil { + toSerialize["Country"] = o.Country + } + if o.CustomerId != nil { + toSerialize["CustomerId"] = o.CustomerId + } + if o.Email != nil { + toSerialize["Email"] = o.Email + } + if o.FirstName != nil { + toSerialize["FirstName"] = o.FirstName + } + if o.JobTitle != nil { + toSerialize["JobTitle"] = o.JobTitle + } + if o.LastName != nil { + toSerialize["LastName"] = o.LastName + } + if o.MobileNumber != nil { + toSerialize["MobileNumber"] = o.MobileNumber + } + if o.PhoneNumber != nil { + toSerialize["PhoneNumber"] = o.PhoneNumber + } + if o.StateProvince != nil { + toSerialize["StateProvince"] = o.StateProvince + } + if o.VatNumber != nil { + toSerialize["VatNumber"] = o.VatNumber + } + if o.ZipCode != nil { + toSerialize["ZipCode"] = o.ZipCode + } + return json.Marshal(toSerialize) +} + +type NullableAccount struct { + value *Account + isSet bool +} + +func (v NullableAccount) Get() *Account { + return v.value +} + +func (v *NullableAccount) Set(val *Account) { + v.value = val + v.isSet = true +} + +func (v NullableAccount) IsSet() bool { + return v.isSet +} + +func (v *NullableAccount) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccount(val *Account) *NullableAccount { + return &NullableAccount{value: val, isSet: true} +} + +func (v NullableAccount) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccount) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go new file mode 100644 index 000000000..40b5b897a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ApplicationStickyCookiePolicy Information about the stickiness policy. +type ApplicationStickyCookiePolicy struct { + // The name of the application cookie used for stickiness. + CookieName *string `json:"CookieName,omitempty"` + // The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + PolicyName *string `json:"PolicyName,omitempty"` +} + +// NewApplicationStickyCookiePolicy instantiates a new ApplicationStickyCookiePolicy object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewApplicationStickyCookiePolicy() *ApplicationStickyCookiePolicy { + this := ApplicationStickyCookiePolicy{} + return &this +} + +// NewApplicationStickyCookiePolicyWithDefaults instantiates a new ApplicationStickyCookiePolicy object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewApplicationStickyCookiePolicyWithDefaults() *ApplicationStickyCookiePolicy { + this := ApplicationStickyCookiePolicy{} + return &this +} + +// GetCookieName returns the CookieName field value if set, zero value otherwise. +func (o *ApplicationStickyCookiePolicy) GetCookieName() string { + if o == nil || o.CookieName == nil { + var ret string + return ret + } + return *o.CookieName +} + +// GetCookieNameOk returns a tuple with the CookieName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ApplicationStickyCookiePolicy) GetCookieNameOk() (*string, bool) { + if o == nil || o.CookieName == nil { + return nil, false + } + return o.CookieName, true +} + +// HasCookieName returns a boolean if a field has been set. +func (o *ApplicationStickyCookiePolicy) HasCookieName() bool { + if o != nil && o.CookieName != nil { + return true + } + + return false +} + +// SetCookieName gets a reference to the given string and assigns it to the CookieName field. +func (o *ApplicationStickyCookiePolicy) SetCookieName(v string) { + o.CookieName = &v +} + +// GetPolicyName returns the PolicyName field value if set, zero value otherwise. +func (o *ApplicationStickyCookiePolicy) GetPolicyName() string { + if o == nil || o.PolicyName == nil { + var ret string + return ret + } + return *o.PolicyName +} + +// GetPolicyNameOk returns a tuple with the PolicyName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ApplicationStickyCookiePolicy) GetPolicyNameOk() (*string, bool) { + if o == nil || o.PolicyName == nil { + return nil, false + } + return o.PolicyName, true +} + +// HasPolicyName returns a boolean if a field has been set. +func (o *ApplicationStickyCookiePolicy) HasPolicyName() bool { + if o != nil && o.PolicyName != nil { + return true + } + + return false +} + +// SetPolicyName gets a reference to the given string and assigns it to the PolicyName field. +func (o *ApplicationStickyCookiePolicy) SetPolicyName(v string) { + o.PolicyName = &v +} + +func (o ApplicationStickyCookiePolicy) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.CookieName != nil { + toSerialize["CookieName"] = o.CookieName + } + if o.PolicyName != nil { + toSerialize["PolicyName"] = o.PolicyName + } + return json.Marshal(toSerialize) +} + +type NullableApplicationStickyCookiePolicy struct { + value *ApplicationStickyCookiePolicy + isSet bool +} + +func (v NullableApplicationStickyCookiePolicy) Get() *ApplicationStickyCookiePolicy { + return v.value +} + +func (v *NullableApplicationStickyCookiePolicy) Set(val *ApplicationStickyCookiePolicy) { + v.value = val + v.isSet = true +} + +func (v NullableApplicationStickyCookiePolicy) IsSet() bool { + return v.isSet +} + +func (v *NullableApplicationStickyCookiePolicy) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableApplicationStickyCookiePolicy(val *ApplicationStickyCookiePolicy) *NullableApplicationStickyCookiePolicy { + return &NullableApplicationStickyCookiePolicy{value: val, isSet: true} +} + +func (v NullableApplicationStickyCookiePolicy) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableApplicationStickyCookiePolicy) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go new file mode 100644 index 000000000..f8d6dd089 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BackendVmHealth Information about the health of a back-end VM. +type BackendVmHealth struct { + // The description of the state of the back-end VM. + Description *string `json:"Description,omitempty"` + // The state of the back-end VM (`InService` \\| `OutOfService` \\| `Unknown`). + State *string `json:"State,omitempty"` + // Information about the cause of `OutOfService` VMs.
Specifically, whether the cause is Elastic Load Balancing or the VM (`ELB` \\| `Instance` \\| `N/A`). + StateReason *string `json:"StateReason,omitempty"` + // The ID of the back-end VM. + VmId *string `json:"VmId,omitempty"` +} + +// NewBackendVmHealth instantiates a new BackendVmHealth object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBackendVmHealth() *BackendVmHealth { + this := BackendVmHealth{} + return &this +} + +// NewBackendVmHealthWithDefaults instantiates a new BackendVmHealth object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBackendVmHealthWithDefaults() *BackendVmHealth { + this := BackendVmHealth{} + return &this +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *BackendVmHealth) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BackendVmHealth) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *BackendVmHealth) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *BackendVmHealth) SetDescription(v string) { + o.Description = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *BackendVmHealth) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BackendVmHealth) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *BackendVmHealth) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *BackendVmHealth) SetState(v string) { + o.State = &v +} + +// GetStateReason returns the StateReason field value if set, zero value otherwise. +func (o *BackendVmHealth) GetStateReason() string { + if o == nil || o.StateReason == nil { + var ret string + return ret + } + return *o.StateReason +} + +// GetStateReasonOk returns a tuple with the StateReason field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BackendVmHealth) GetStateReasonOk() (*string, bool) { + if o == nil || o.StateReason == nil { + return nil, false + } + return o.StateReason, true +} + +// HasStateReason returns a boolean if a field has been set. +func (o *BackendVmHealth) HasStateReason() bool { + if o != nil && o.StateReason != nil { + return true + } + + return false +} + +// SetStateReason gets a reference to the given string and assigns it to the StateReason field. +func (o *BackendVmHealth) SetStateReason(v string) { + o.StateReason = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *BackendVmHealth) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BackendVmHealth) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *BackendVmHealth) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *BackendVmHealth) SetVmId(v string) { + o.VmId = &v +} + +func (o BackendVmHealth) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.StateReason != nil { + toSerialize["StateReason"] = o.StateReason + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableBackendVmHealth struct { + value *BackendVmHealth + isSet bool +} + +func (v NullableBackendVmHealth) Get() *BackendVmHealth { + return v.value +} + +func (v *NullableBackendVmHealth) Set(val *BackendVmHealth) { + v.value = val + v.isSet = true +} + +func (v NullableBackendVmHealth) IsSet() bool { + return v.isSet +} + +func (v *NullableBackendVmHealth) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBackendVmHealth(val *BackendVmHealth) *NullableBackendVmHealth { + return &NullableBackendVmHealth{value: val, isSet: true} +} + +func (v NullableBackendVmHealth) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBackendVmHealth) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go new file mode 100644 index 000000000..bbce42a01 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BlockDeviceMappingCreated Information about the created block device mapping. +type BlockDeviceMappingCreated struct { + Bsu *BsuCreated `json:"Bsu,omitempty"` + // The name of the device. + DeviceName *string `json:"DeviceName,omitempty"` +} + +// NewBlockDeviceMappingCreated instantiates a new BlockDeviceMappingCreated object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBlockDeviceMappingCreated() *BlockDeviceMappingCreated { + this := BlockDeviceMappingCreated{} + return &this +} + +// NewBlockDeviceMappingCreatedWithDefaults instantiates a new BlockDeviceMappingCreated object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBlockDeviceMappingCreatedWithDefaults() *BlockDeviceMappingCreated { + this := BlockDeviceMappingCreated{} + return &this +} + +// GetBsu returns the Bsu field value if set, zero value otherwise. +func (o *BlockDeviceMappingCreated) GetBsu() BsuCreated { + if o == nil || o.Bsu == nil { + var ret BsuCreated + return ret + } + return *o.Bsu +} + +// GetBsuOk returns a tuple with the Bsu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingCreated) GetBsuOk() (*BsuCreated, bool) { + if o == nil || o.Bsu == nil { + return nil, false + } + return o.Bsu, true +} + +// HasBsu returns a boolean if a field has been set. +func (o *BlockDeviceMappingCreated) HasBsu() bool { + if o != nil && o.Bsu != nil { + return true + } + + return false +} + +// SetBsu gets a reference to the given BsuCreated and assigns it to the Bsu field. +func (o *BlockDeviceMappingCreated) SetBsu(v BsuCreated) { + o.Bsu = &v +} + +// GetDeviceName returns the DeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingCreated) GetDeviceName() string { + if o == nil || o.DeviceName == nil { + var ret string + return ret + } + return *o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingCreated) GetDeviceNameOk() (*string, bool) { + if o == nil || o.DeviceName == nil { + return nil, false + } + return o.DeviceName, true +} + +// HasDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingCreated) HasDeviceName() bool { + if o != nil && o.DeviceName != nil { + return true + } + + return false +} + +// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. +func (o *BlockDeviceMappingCreated) SetDeviceName(v string) { + o.DeviceName = &v +} + +func (o BlockDeviceMappingCreated) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bsu != nil { + toSerialize["Bsu"] = o.Bsu + } + if o.DeviceName != nil { + toSerialize["DeviceName"] = o.DeviceName + } + return json.Marshal(toSerialize) +} + +type NullableBlockDeviceMappingCreated struct { + value *BlockDeviceMappingCreated + isSet bool +} + +func (v NullableBlockDeviceMappingCreated) Get() *BlockDeviceMappingCreated { + return v.value +} + +func (v *NullableBlockDeviceMappingCreated) Set(val *BlockDeviceMappingCreated) { + v.value = val + v.isSet = true +} + +func (v NullableBlockDeviceMappingCreated) IsSet() bool { + return v.isSet +} + +func (v *NullableBlockDeviceMappingCreated) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBlockDeviceMappingCreated(val *BlockDeviceMappingCreated) *NullableBlockDeviceMappingCreated { + return &NullableBlockDeviceMappingCreated{value: val, isSet: true} +} + +func (v NullableBlockDeviceMappingCreated) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBlockDeviceMappingCreated) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go new file mode 100644 index 000000000..dbe4b89d5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go @@ -0,0 +1,190 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BlockDeviceMappingImage One or more parameters used to automatically set up volumes when the VM is created. +type BlockDeviceMappingImage struct { + Bsu *BsuToCreate `json:"Bsu,omitempty"` + // The name of the device. + DeviceName *string `json:"DeviceName,omitempty"` + // The name of the virtual device (ephemeralN). + VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` +} + +// NewBlockDeviceMappingImage instantiates a new BlockDeviceMappingImage object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBlockDeviceMappingImage() *BlockDeviceMappingImage { + this := BlockDeviceMappingImage{} + return &this +} + +// NewBlockDeviceMappingImageWithDefaults instantiates a new BlockDeviceMappingImage object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBlockDeviceMappingImageWithDefaults() *BlockDeviceMappingImage { + this := BlockDeviceMappingImage{} + return &this +} + +// GetBsu returns the Bsu field value if set, zero value otherwise. +func (o *BlockDeviceMappingImage) GetBsu() BsuToCreate { + if o == nil || o.Bsu == nil { + var ret BsuToCreate + return ret + } + return *o.Bsu +} + +// GetBsuOk returns a tuple with the Bsu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingImage) GetBsuOk() (*BsuToCreate, bool) { + if o == nil || o.Bsu == nil { + return nil, false + } + return o.Bsu, true +} + +// HasBsu returns a boolean if a field has been set. +func (o *BlockDeviceMappingImage) HasBsu() bool { + if o != nil && o.Bsu != nil { + return true + } + + return false +} + +// SetBsu gets a reference to the given BsuToCreate and assigns it to the Bsu field. +func (o *BlockDeviceMappingImage) SetBsu(v BsuToCreate) { + o.Bsu = &v +} + +// GetDeviceName returns the DeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingImage) GetDeviceName() string { + if o == nil || o.DeviceName == nil { + var ret string + return ret + } + return *o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingImage) GetDeviceNameOk() (*string, bool) { + if o == nil || o.DeviceName == nil { + return nil, false + } + return o.DeviceName, true +} + +// HasDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingImage) HasDeviceName() bool { + if o != nil && o.DeviceName != nil { + return true + } + + return false +} + +// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. +func (o *BlockDeviceMappingImage) SetDeviceName(v string) { + o.DeviceName = &v +} + +// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingImage) GetVirtualDeviceName() string { + if o == nil || o.VirtualDeviceName == nil { + var ret string + return ret + } + return *o.VirtualDeviceName +} + +// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingImage) GetVirtualDeviceNameOk() (*string, bool) { + if o == nil || o.VirtualDeviceName == nil { + return nil, false + } + return o.VirtualDeviceName, true +} + +// HasVirtualDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingImage) HasVirtualDeviceName() bool { + if o != nil && o.VirtualDeviceName != nil { + return true + } + + return false +} + +// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. +func (o *BlockDeviceMappingImage) SetVirtualDeviceName(v string) { + o.VirtualDeviceName = &v +} + +func (o BlockDeviceMappingImage) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bsu != nil { + toSerialize["Bsu"] = o.Bsu + } + if o.DeviceName != nil { + toSerialize["DeviceName"] = o.DeviceName + } + if o.VirtualDeviceName != nil { + toSerialize["VirtualDeviceName"] = o.VirtualDeviceName + } + return json.Marshal(toSerialize) +} + +type NullableBlockDeviceMappingImage struct { + value *BlockDeviceMappingImage + isSet bool +} + +func (v NullableBlockDeviceMappingImage) Get() *BlockDeviceMappingImage { + return v.value +} + +func (v *NullableBlockDeviceMappingImage) Set(val *BlockDeviceMappingImage) { + v.value = val + v.isSet = true +} + +func (v NullableBlockDeviceMappingImage) IsSet() bool { + return v.isSet +} + +func (v *NullableBlockDeviceMappingImage) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBlockDeviceMappingImage(val *BlockDeviceMappingImage) *NullableBlockDeviceMappingImage { + return &NullableBlockDeviceMappingImage{value: val, isSet: true} +} + +func (v NullableBlockDeviceMappingImage) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBlockDeviceMappingImage) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go new file mode 100644 index 000000000..79045542e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go @@ -0,0 +1,227 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BlockDeviceMappingVmCreation Information about the block device mapping. +type BlockDeviceMappingVmCreation struct { + Bsu *BsuToCreate `json:"Bsu,omitempty"` + // The name of the device. + DeviceName *string `json:"DeviceName,omitempty"` + // Removes the device which is included in the block device mapping of the OMI. + NoDevice *string `json:"NoDevice,omitempty"` + // The name of the virtual device (ephemeralN). + VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` +} + +// NewBlockDeviceMappingVmCreation instantiates a new BlockDeviceMappingVmCreation object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBlockDeviceMappingVmCreation() *BlockDeviceMappingVmCreation { + this := BlockDeviceMappingVmCreation{} + return &this +} + +// NewBlockDeviceMappingVmCreationWithDefaults instantiates a new BlockDeviceMappingVmCreation object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBlockDeviceMappingVmCreationWithDefaults() *BlockDeviceMappingVmCreation { + this := BlockDeviceMappingVmCreation{} + return &this +} + +// GetBsu returns the Bsu field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmCreation) GetBsu() BsuToCreate { + if o == nil || o.Bsu == nil { + var ret BsuToCreate + return ret + } + return *o.Bsu +} + +// GetBsuOk returns a tuple with the Bsu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmCreation) GetBsuOk() (*BsuToCreate, bool) { + if o == nil || o.Bsu == nil { + return nil, false + } + return o.Bsu, true +} + +// HasBsu returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmCreation) HasBsu() bool { + if o != nil && o.Bsu != nil { + return true + } + + return false +} + +// SetBsu gets a reference to the given BsuToCreate and assigns it to the Bsu field. +func (o *BlockDeviceMappingVmCreation) SetBsu(v BsuToCreate) { + o.Bsu = &v +} + +// GetDeviceName returns the DeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmCreation) GetDeviceName() string { + if o == nil || o.DeviceName == nil { + var ret string + return ret + } + return *o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmCreation) GetDeviceNameOk() (*string, bool) { + if o == nil || o.DeviceName == nil { + return nil, false + } + return o.DeviceName, true +} + +// HasDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmCreation) HasDeviceName() bool { + if o != nil && o.DeviceName != nil { + return true + } + + return false +} + +// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. +func (o *BlockDeviceMappingVmCreation) SetDeviceName(v string) { + o.DeviceName = &v +} + +// GetNoDevice returns the NoDevice field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmCreation) GetNoDevice() string { + if o == nil || o.NoDevice == nil { + var ret string + return ret + } + return *o.NoDevice +} + +// GetNoDeviceOk returns a tuple with the NoDevice field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmCreation) GetNoDeviceOk() (*string, bool) { + if o == nil || o.NoDevice == nil { + return nil, false + } + return o.NoDevice, true +} + +// HasNoDevice returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmCreation) HasNoDevice() bool { + if o != nil && o.NoDevice != nil { + return true + } + + return false +} + +// SetNoDevice gets a reference to the given string and assigns it to the NoDevice field. +func (o *BlockDeviceMappingVmCreation) SetNoDevice(v string) { + o.NoDevice = &v +} + +// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmCreation) GetVirtualDeviceName() string { + if o == nil || o.VirtualDeviceName == nil { + var ret string + return ret + } + return *o.VirtualDeviceName +} + +// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmCreation) GetVirtualDeviceNameOk() (*string, bool) { + if o == nil || o.VirtualDeviceName == nil { + return nil, false + } + return o.VirtualDeviceName, true +} + +// HasVirtualDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmCreation) HasVirtualDeviceName() bool { + if o != nil && o.VirtualDeviceName != nil { + return true + } + + return false +} + +// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. +func (o *BlockDeviceMappingVmCreation) SetVirtualDeviceName(v string) { + o.VirtualDeviceName = &v +} + +func (o BlockDeviceMappingVmCreation) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bsu != nil { + toSerialize["Bsu"] = o.Bsu + } + if o.DeviceName != nil { + toSerialize["DeviceName"] = o.DeviceName + } + if o.NoDevice != nil { + toSerialize["NoDevice"] = o.NoDevice + } + if o.VirtualDeviceName != nil { + toSerialize["VirtualDeviceName"] = o.VirtualDeviceName + } + return json.Marshal(toSerialize) +} + +type NullableBlockDeviceMappingVmCreation struct { + value *BlockDeviceMappingVmCreation + isSet bool +} + +func (v NullableBlockDeviceMappingVmCreation) Get() *BlockDeviceMappingVmCreation { + return v.value +} + +func (v *NullableBlockDeviceMappingVmCreation) Set(val *BlockDeviceMappingVmCreation) { + v.value = val + v.isSet = true +} + +func (v NullableBlockDeviceMappingVmCreation) IsSet() bool { + return v.isSet +} + +func (v *NullableBlockDeviceMappingVmCreation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBlockDeviceMappingVmCreation(val *BlockDeviceMappingVmCreation) *NullableBlockDeviceMappingVmCreation { + return &NullableBlockDeviceMappingVmCreation{value: val, isSet: true} +} + +func (v NullableBlockDeviceMappingVmCreation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBlockDeviceMappingVmCreation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go new file mode 100644 index 000000000..c1cfd96cb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go @@ -0,0 +1,227 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BlockDeviceMappingVmUpdate Information about the block device mapping. +type BlockDeviceMappingVmUpdate struct { + Bsu *BsuToUpdateVm `json:"Bsu,omitempty"` + // The name of the device. + DeviceName *string `json:"DeviceName,omitempty"` + // Removes the device which is included in the block device mapping of the OMI. + NoDevice *string `json:"NoDevice,omitempty"` + // The name of the virtual device (ephemeralN). + VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` +} + +// NewBlockDeviceMappingVmUpdate instantiates a new BlockDeviceMappingVmUpdate object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBlockDeviceMappingVmUpdate() *BlockDeviceMappingVmUpdate { + this := BlockDeviceMappingVmUpdate{} + return &this +} + +// NewBlockDeviceMappingVmUpdateWithDefaults instantiates a new BlockDeviceMappingVmUpdate object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBlockDeviceMappingVmUpdateWithDefaults() *BlockDeviceMappingVmUpdate { + this := BlockDeviceMappingVmUpdate{} + return &this +} + +// GetBsu returns the Bsu field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmUpdate) GetBsu() BsuToUpdateVm { + if o == nil || o.Bsu == nil { + var ret BsuToUpdateVm + return ret + } + return *o.Bsu +} + +// GetBsuOk returns a tuple with the Bsu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmUpdate) GetBsuOk() (*BsuToUpdateVm, bool) { + if o == nil || o.Bsu == nil { + return nil, false + } + return o.Bsu, true +} + +// HasBsu returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmUpdate) HasBsu() bool { + if o != nil && o.Bsu != nil { + return true + } + + return false +} + +// SetBsu gets a reference to the given BsuToUpdateVm and assigns it to the Bsu field. +func (o *BlockDeviceMappingVmUpdate) SetBsu(v BsuToUpdateVm) { + o.Bsu = &v +} + +// GetDeviceName returns the DeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmUpdate) GetDeviceName() string { + if o == nil || o.DeviceName == nil { + var ret string + return ret + } + return *o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmUpdate) GetDeviceNameOk() (*string, bool) { + if o == nil || o.DeviceName == nil { + return nil, false + } + return o.DeviceName, true +} + +// HasDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmUpdate) HasDeviceName() bool { + if o != nil && o.DeviceName != nil { + return true + } + + return false +} + +// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. +func (o *BlockDeviceMappingVmUpdate) SetDeviceName(v string) { + o.DeviceName = &v +} + +// GetNoDevice returns the NoDevice field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmUpdate) GetNoDevice() string { + if o == nil || o.NoDevice == nil { + var ret string + return ret + } + return *o.NoDevice +} + +// GetNoDeviceOk returns a tuple with the NoDevice field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmUpdate) GetNoDeviceOk() (*string, bool) { + if o == nil || o.NoDevice == nil { + return nil, false + } + return o.NoDevice, true +} + +// HasNoDevice returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmUpdate) HasNoDevice() bool { + if o != nil && o.NoDevice != nil { + return true + } + + return false +} + +// SetNoDevice gets a reference to the given string and assigns it to the NoDevice field. +func (o *BlockDeviceMappingVmUpdate) SetNoDevice(v string) { + o.NoDevice = &v +} + +// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. +func (o *BlockDeviceMappingVmUpdate) GetVirtualDeviceName() string { + if o == nil || o.VirtualDeviceName == nil { + var ret string + return ret + } + return *o.VirtualDeviceName +} + +// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BlockDeviceMappingVmUpdate) GetVirtualDeviceNameOk() (*string, bool) { + if o == nil || o.VirtualDeviceName == nil { + return nil, false + } + return o.VirtualDeviceName, true +} + +// HasVirtualDeviceName returns a boolean if a field has been set. +func (o *BlockDeviceMappingVmUpdate) HasVirtualDeviceName() bool { + if o != nil && o.VirtualDeviceName != nil { + return true + } + + return false +} + +// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. +func (o *BlockDeviceMappingVmUpdate) SetVirtualDeviceName(v string) { + o.VirtualDeviceName = &v +} + +func (o BlockDeviceMappingVmUpdate) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Bsu != nil { + toSerialize["Bsu"] = o.Bsu + } + if o.DeviceName != nil { + toSerialize["DeviceName"] = o.DeviceName + } + if o.NoDevice != nil { + toSerialize["NoDevice"] = o.NoDevice + } + if o.VirtualDeviceName != nil { + toSerialize["VirtualDeviceName"] = o.VirtualDeviceName + } + return json.Marshal(toSerialize) +} + +type NullableBlockDeviceMappingVmUpdate struct { + value *BlockDeviceMappingVmUpdate + isSet bool +} + +func (v NullableBlockDeviceMappingVmUpdate) Get() *BlockDeviceMappingVmUpdate { + return v.value +} + +func (v *NullableBlockDeviceMappingVmUpdate) Set(val *BlockDeviceMappingVmUpdate) { + v.value = val + v.isSet = true +} + +func (v NullableBlockDeviceMappingVmUpdate) IsSet() bool { + return v.isSet +} + +func (v *NullableBlockDeviceMappingVmUpdate) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBlockDeviceMappingVmUpdate(val *BlockDeviceMappingVmUpdate) *NullableBlockDeviceMappingVmUpdate { + return &NullableBlockDeviceMappingVmUpdate{value: val, isSet: true} +} + +func (v NullableBlockDeviceMappingVmUpdate) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBlockDeviceMappingVmUpdate) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go new file mode 100644 index 000000000..331e63eb2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BsuCreated Information about the created BSU volume. +type BsuCreated struct { + // Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The time and date of attachment of the volume to the VM. + LinkDate *string `json:"LinkDate,omitempty"` + // The state of the volume. + State *string `json:"State,omitempty"` + // The ID of the volume. + VolumeId *string `json:"VolumeId,omitempty"` +} + +// NewBsuCreated instantiates a new BsuCreated object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBsuCreated() *BsuCreated { + this := BsuCreated{} + return &this +} + +// NewBsuCreatedWithDefaults instantiates a new BsuCreated object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBsuCreatedWithDefaults() *BsuCreated { + this := BsuCreated{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *BsuCreated) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuCreated) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *BsuCreated) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *BsuCreated) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetLinkDate returns the LinkDate field value if set, zero value otherwise. +func (o *BsuCreated) GetLinkDate() string { + if o == nil || o.LinkDate == nil { + var ret string + return ret + } + return *o.LinkDate +} + +// GetLinkDateOk returns a tuple with the LinkDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuCreated) GetLinkDateOk() (*string, bool) { + if o == nil || o.LinkDate == nil { + return nil, false + } + return o.LinkDate, true +} + +// HasLinkDate returns a boolean if a field has been set. +func (o *BsuCreated) HasLinkDate() bool { + if o != nil && o.LinkDate != nil { + return true + } + + return false +} + +// SetLinkDate gets a reference to the given string and assigns it to the LinkDate field. +func (o *BsuCreated) SetLinkDate(v string) { + o.LinkDate = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *BsuCreated) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuCreated) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *BsuCreated) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *BsuCreated) SetState(v string) { + o.State = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *BsuCreated) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuCreated) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *BsuCreated) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *BsuCreated) SetVolumeId(v string) { + o.VolumeId = &v +} + +func (o BsuCreated) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.LinkDate != nil { + toSerialize["LinkDate"] = o.LinkDate + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableBsuCreated struct { + value *BsuCreated + isSet bool +} + +func (v NullableBsuCreated) Get() *BsuCreated { + return v.value +} + +func (v *NullableBsuCreated) Set(val *BsuCreated) { + v.value = val + v.isSet = true +} + +func (v NullableBsuCreated) IsSet() bool { + return v.isSet +} + +func (v *NullableBsuCreated) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBsuCreated(val *BsuCreated) *NullableBsuCreated { + return &NullableBsuCreated{value: val, isSet: true} +} + +func (v NullableBsuCreated) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBsuCreated) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go new file mode 100644 index 000000000..c5193fa8f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BsuToCreate Information about the BSU volume to create. +type BsuToCreate struct { + // Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + Iops *int32 `json:"Iops,omitempty"` + // The ID of the snapshot used to create the volume. + SnapshotId *string `json:"SnapshotId,omitempty"` + // The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. + VolumeSize *int32 `json:"VolumeSize,omitempty"` + // The type of the volume (`standard` \\| `io1` \\| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). + VolumeType *string `json:"VolumeType,omitempty"` +} + +// NewBsuToCreate instantiates a new BsuToCreate object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBsuToCreate() *BsuToCreate { + this := BsuToCreate{} + return &this +} + +// NewBsuToCreateWithDefaults instantiates a new BsuToCreate object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBsuToCreateWithDefaults() *BsuToCreate { + this := BsuToCreate{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *BsuToCreate) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToCreate) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *BsuToCreate) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *BsuToCreate) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetIops returns the Iops field value if set, zero value otherwise. +func (o *BsuToCreate) GetIops() int32 { + if o == nil || o.Iops == nil { + var ret int32 + return ret + } + return *o.Iops +} + +// GetIopsOk returns a tuple with the Iops field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToCreate) GetIopsOk() (*int32, bool) { + if o == nil || o.Iops == nil { + return nil, false + } + return o.Iops, true +} + +// HasIops returns a boolean if a field has been set. +func (o *BsuToCreate) HasIops() bool { + if o != nil && o.Iops != nil { + return true + } + + return false +} + +// SetIops gets a reference to the given int32 and assigns it to the Iops field. +func (o *BsuToCreate) SetIops(v int32) { + o.Iops = &v +} + +// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. +func (o *BsuToCreate) GetSnapshotId() string { + if o == nil || o.SnapshotId == nil { + var ret string + return ret + } + return *o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToCreate) GetSnapshotIdOk() (*string, bool) { + if o == nil || o.SnapshotId == nil { + return nil, false + } + return o.SnapshotId, true +} + +// HasSnapshotId returns a boolean if a field has been set. +func (o *BsuToCreate) HasSnapshotId() bool { + if o != nil && o.SnapshotId != nil { + return true + } + + return false +} + +// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. +func (o *BsuToCreate) SetSnapshotId(v string) { + o.SnapshotId = &v +} + +// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. +func (o *BsuToCreate) GetVolumeSize() int32 { + if o == nil || o.VolumeSize == nil { + var ret int32 + return ret + } + return *o.VolumeSize +} + +// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToCreate) GetVolumeSizeOk() (*int32, bool) { + if o == nil || o.VolumeSize == nil { + return nil, false + } + return o.VolumeSize, true +} + +// HasVolumeSize returns a boolean if a field has been set. +func (o *BsuToCreate) HasVolumeSize() bool { + if o != nil && o.VolumeSize != nil { + return true + } + + return false +} + +// SetVolumeSize gets a reference to the given int32 and assigns it to the VolumeSize field. +func (o *BsuToCreate) SetVolumeSize(v int32) { + o.VolumeSize = &v +} + +// GetVolumeType returns the VolumeType field value if set, zero value otherwise. +func (o *BsuToCreate) GetVolumeType() string { + if o == nil || o.VolumeType == nil { + var ret string + return ret + } + return *o.VolumeType +} + +// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToCreate) GetVolumeTypeOk() (*string, bool) { + if o == nil || o.VolumeType == nil { + return nil, false + } + return o.VolumeType, true +} + +// HasVolumeType returns a boolean if a field has been set. +func (o *BsuToCreate) HasVolumeType() bool { + if o != nil && o.VolumeType != nil { + return true + } + + return false +} + +// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. +func (o *BsuToCreate) SetVolumeType(v string) { + o.VolumeType = &v +} + +func (o BsuToCreate) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.Iops != nil { + toSerialize["Iops"] = o.Iops + } + if o.SnapshotId != nil { + toSerialize["SnapshotId"] = o.SnapshotId + } + if o.VolumeSize != nil { + toSerialize["VolumeSize"] = o.VolumeSize + } + if o.VolumeType != nil { + toSerialize["VolumeType"] = o.VolumeType + } + return json.Marshal(toSerialize) +} + +type NullableBsuToCreate struct { + value *BsuToCreate + isSet bool +} + +func (v NullableBsuToCreate) Get() *BsuToCreate { + return v.value +} + +func (v *NullableBsuToCreate) Set(val *BsuToCreate) { + v.value = val + v.isSet = true +} + +func (v NullableBsuToCreate) IsSet() bool { + return v.isSet +} + +func (v *NullableBsuToCreate) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBsuToCreate(val *BsuToCreate) *NullableBsuToCreate { + return &NullableBsuToCreate{value: val, isSet: true} +} + +func (v NullableBsuToCreate) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBsuToCreate) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go new file mode 100644 index 000000000..a9226ba76 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// BsuToUpdateVm Information about the BSU volume. +type BsuToUpdateVm struct { + // If `true`, the volume is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The ID of the volume. + VolumeId *string `json:"VolumeId,omitempty"` +} + +// NewBsuToUpdateVm instantiates a new BsuToUpdateVm object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewBsuToUpdateVm() *BsuToUpdateVm { + this := BsuToUpdateVm{} + return &this +} + +// NewBsuToUpdateVmWithDefaults instantiates a new BsuToUpdateVm object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewBsuToUpdateVmWithDefaults() *BsuToUpdateVm { + this := BsuToUpdateVm{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *BsuToUpdateVm) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToUpdateVm) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *BsuToUpdateVm) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *BsuToUpdateVm) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *BsuToUpdateVm) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *BsuToUpdateVm) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *BsuToUpdateVm) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *BsuToUpdateVm) SetVolumeId(v string) { + o.VolumeId = &v +} + +func (o BsuToUpdateVm) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableBsuToUpdateVm struct { + value *BsuToUpdateVm + isSet bool +} + +func (v NullableBsuToUpdateVm) Get() *BsuToUpdateVm { + return v.value +} + +func (v *NullableBsuToUpdateVm) Set(val *BsuToUpdateVm) { + v.value = val + v.isSet = true +} + +func (v NullableBsuToUpdateVm) IsSet() bool { + return v.isSet +} + +func (v *NullableBsuToUpdateVm) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBsuToUpdateVm(val *BsuToUpdateVm) *NullableBsuToUpdateVm { + return &NullableBsuToUpdateVm{value: val, isSet: true} +} + +func (v NullableBsuToUpdateVm) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBsuToUpdateVm) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go new file mode 100644 index 000000000..f75bc5a99 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CheckAuthenticationRequest struct for CheckAuthenticationRequest +type CheckAuthenticationRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The email address of the account. + Login *string `json:"Login,omitempty"` + // The password of the account. + Password *string `json:"Password,omitempty"` +} + +// NewCheckAuthenticationRequest instantiates a new CheckAuthenticationRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCheckAuthenticationRequest() *CheckAuthenticationRequest { + this := CheckAuthenticationRequest{} + return &this +} + +// NewCheckAuthenticationRequestWithDefaults instantiates a new CheckAuthenticationRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCheckAuthenticationRequestWithDefaults() *CheckAuthenticationRequest { + this := CheckAuthenticationRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CheckAuthenticationRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CheckAuthenticationRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CheckAuthenticationRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CheckAuthenticationRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLogin returns the Login field value if set, zero value otherwise. +func (o *CheckAuthenticationRequest) GetLogin() string { + if o == nil || o.Login == nil { + var ret string + return ret + } + return *o.Login +} + +// GetLoginOk returns a tuple with the Login field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CheckAuthenticationRequest) GetLoginOk() (*string, bool) { + if o == nil || o.Login == nil { + return nil, false + } + return o.Login, true +} + +// HasLogin returns a boolean if a field has been set. +func (o *CheckAuthenticationRequest) HasLogin() bool { + if o != nil && o.Login != nil { + return true + } + + return false +} + +// SetLogin gets a reference to the given string and assigns it to the Login field. +func (o *CheckAuthenticationRequest) SetLogin(v string) { + o.Login = &v +} + +// GetPassword returns the Password field value if set, zero value otherwise. +func (o *CheckAuthenticationRequest) GetPassword() string { + if o == nil || o.Password == nil { + var ret string + return ret + } + return *o.Password +} + +// GetPasswordOk returns a tuple with the Password field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CheckAuthenticationRequest) GetPasswordOk() (*string, bool) { + if o == nil || o.Password == nil { + return nil, false + } + return o.Password, true +} + +// HasPassword returns a boolean if a field has been set. +func (o *CheckAuthenticationRequest) HasPassword() bool { + if o != nil && o.Password != nil { + return true + } + + return false +} + +// SetPassword gets a reference to the given string and assigns it to the Password field. +func (o *CheckAuthenticationRequest) SetPassword(v string) { + o.Password = &v +} + +func (o CheckAuthenticationRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Login != nil { + toSerialize["Login"] = o.Login + } + if o.Password != nil { + toSerialize["Password"] = o.Password + } + return json.Marshal(toSerialize) +} + +type NullableCheckAuthenticationRequest struct { + value *CheckAuthenticationRequest + isSet bool +} + +func (v NullableCheckAuthenticationRequest) Get() *CheckAuthenticationRequest { + return v.value +} + +func (v *NullableCheckAuthenticationRequest) Set(val *CheckAuthenticationRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCheckAuthenticationRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCheckAuthenticationRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCheckAuthenticationRequest(val *CheckAuthenticationRequest) *NullableCheckAuthenticationRequest { + return &NullableCheckAuthenticationRequest{value: val, isSet: true} +} + +func (v NullableCheckAuthenticationRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCheckAuthenticationRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go new file mode 100644 index 000000000..fdb43bd20 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CheckAuthenticationResponse struct for CheckAuthenticationResponse +type CheckAuthenticationResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCheckAuthenticationResponse instantiates a new CheckAuthenticationResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCheckAuthenticationResponse() *CheckAuthenticationResponse { + this := CheckAuthenticationResponse{} + return &this +} + +// NewCheckAuthenticationResponseWithDefaults instantiates a new CheckAuthenticationResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCheckAuthenticationResponseWithDefaults() *CheckAuthenticationResponse { + this := CheckAuthenticationResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CheckAuthenticationResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CheckAuthenticationResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CheckAuthenticationResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CheckAuthenticationResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CheckAuthenticationResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCheckAuthenticationResponse struct { + value *CheckAuthenticationResponse + isSet bool +} + +func (v NullableCheckAuthenticationResponse) Get() *CheckAuthenticationResponse { + return v.value +} + +func (v *NullableCheckAuthenticationResponse) Set(val *CheckAuthenticationResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCheckAuthenticationResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCheckAuthenticationResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCheckAuthenticationResponse(val *CheckAuthenticationResponse) *NullableCheckAuthenticationResponse { + return &NullableCheckAuthenticationResponse{value: val, isSet: true} +} + +func (v NullableCheckAuthenticationResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCheckAuthenticationResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go new file mode 100644 index 000000000..5eb844319 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ClientGateway Information about the client gateway. +type ClientGateway struct { + // An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. + BgpAsn *int32 `json:"BgpAsn,omitempty"` + // The ID of the client gateway. + ClientGatewayId *string `json:"ClientGatewayId,omitempty"` + // The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). + ConnectionType *string `json:"ConnectionType,omitempty"` + // The public IPv4 address of the client gateway (must be a fixed address into a NATed network). + PublicIp *string `json:"PublicIp,omitempty"` + // The state of the client gateway (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` + // One or more tags associated with the client gateway. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewClientGateway instantiates a new ClientGateway object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewClientGateway() *ClientGateway { + this := ClientGateway{} + return &this +} + +// NewClientGatewayWithDefaults instantiates a new ClientGateway object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewClientGatewayWithDefaults() *ClientGateway { + this := ClientGateway{} + return &this +} + +// GetBgpAsn returns the BgpAsn field value if set, zero value otherwise. +func (o *ClientGateway) GetBgpAsn() int32 { + if o == nil || o.BgpAsn == nil { + var ret int32 + return ret + } + return *o.BgpAsn +} + +// GetBgpAsnOk returns a tuple with the BgpAsn field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetBgpAsnOk() (*int32, bool) { + if o == nil || o.BgpAsn == nil { + return nil, false + } + return o.BgpAsn, true +} + +// HasBgpAsn returns a boolean if a field has been set. +func (o *ClientGateway) HasBgpAsn() bool { + if o != nil && o.BgpAsn != nil { + return true + } + + return false +} + +// SetBgpAsn gets a reference to the given int32 and assigns it to the BgpAsn field. +func (o *ClientGateway) SetBgpAsn(v int32) { + o.BgpAsn = &v +} + +// GetClientGatewayId returns the ClientGatewayId field value if set, zero value otherwise. +func (o *ClientGateway) GetClientGatewayId() string { + if o == nil || o.ClientGatewayId == nil { + var ret string + return ret + } + return *o.ClientGatewayId +} + +// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetClientGatewayIdOk() (*string, bool) { + if o == nil || o.ClientGatewayId == nil { + return nil, false + } + return o.ClientGatewayId, true +} + +// HasClientGatewayId returns a boolean if a field has been set. +func (o *ClientGateway) HasClientGatewayId() bool { + if o != nil && o.ClientGatewayId != nil { + return true + } + + return false +} + +// SetClientGatewayId gets a reference to the given string and assigns it to the ClientGatewayId field. +func (o *ClientGateway) SetClientGatewayId(v string) { + o.ClientGatewayId = &v +} + +// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. +func (o *ClientGateway) GetConnectionType() string { + if o == nil || o.ConnectionType == nil { + var ret string + return ret + } + return *o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetConnectionTypeOk() (*string, bool) { + if o == nil || o.ConnectionType == nil { + return nil, false + } + return o.ConnectionType, true +} + +// HasConnectionType returns a boolean if a field has been set. +func (o *ClientGateway) HasConnectionType() bool { + if o != nil && o.ConnectionType != nil { + return true + } + + return false +} + +// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. +func (o *ClientGateway) SetConnectionType(v string) { + o.ConnectionType = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *ClientGateway) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *ClientGateway) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *ClientGateway) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *ClientGateway) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *ClientGateway) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *ClientGateway) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *ClientGateway) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClientGateway) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *ClientGateway) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *ClientGateway) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o ClientGateway) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BgpAsn != nil { + toSerialize["BgpAsn"] = o.BgpAsn + } + if o.ClientGatewayId != nil { + toSerialize["ClientGatewayId"] = o.ClientGatewayId + } + if o.ConnectionType != nil { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableClientGateway struct { + value *ClientGateway + isSet bool +} + +func (v NullableClientGateway) Get() *ClientGateway { + return v.value +} + +func (v *NullableClientGateway) Set(val *ClientGateway) { + v.value = val + v.isSet = true +} + +func (v NullableClientGateway) IsSet() bool { + return v.isSet +} + +func (v *NullableClientGateway) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableClientGateway(val *ClientGateway) *NullableClientGateway { + return &NullableClientGateway{value: val, isSet: true} +} + +func (v NullableClientGateway) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableClientGateway) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go new file mode 100644 index 000000000..3f4a81c4e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ConsumptionEntry Information about the resources consumed during the specified time period. +type ConsumptionEntry struct { + // The category of the resource (for example, `network`). + Category *string `json:"Category,omitempty"` + // The beginning of the time period. + FromDate *string `json:"FromDate,omitempty"` + // The API call that triggered the resource consumption (for example, `RunInstances` or `CreateVolume`). + Operation *string `json:"Operation,omitempty"` + // The service of the API call (`TinaOS-FCU`, `TinaOS-LBU`, `TinaOS-OSU` or `TinaOS-DirectLink`). + Service *string `json:"Service,omitempty"` + // A description of the consumed resource. + Title *string `json:"Title,omitempty"` + // The end of the time period. + ToDate *string `json:"ToDate,omitempty"` + // The type of resource, depending on the API call. + Type *string `json:"Type,omitempty"` + // The consumed amount for the resource. The unit depends on the resource type. For more information, see the `Title` element. + Value *string `json:"Value,omitempty"` +} + +// NewConsumptionEntry instantiates a new ConsumptionEntry object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewConsumptionEntry() *ConsumptionEntry { + this := ConsumptionEntry{} + return &this +} + +// NewConsumptionEntryWithDefaults instantiates a new ConsumptionEntry object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewConsumptionEntryWithDefaults() *ConsumptionEntry { + this := ConsumptionEntry{} + return &this +} + +// GetCategory returns the Category field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetCategory() string { + if o == nil || o.Category == nil { + var ret string + return ret + } + return *o.Category +} + +// GetCategoryOk returns a tuple with the Category field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetCategoryOk() (*string, bool) { + if o == nil || o.Category == nil { + return nil, false + } + return o.Category, true +} + +// HasCategory returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasCategory() bool { + if o != nil && o.Category != nil { + return true + } + + return false +} + +// SetCategory gets a reference to the given string and assigns it to the Category field. +func (o *ConsumptionEntry) SetCategory(v string) { + o.Category = &v +} + +// GetFromDate returns the FromDate field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetFromDate() string { + if o == nil || o.FromDate == nil { + var ret string + return ret + } + return *o.FromDate +} + +// GetFromDateOk returns a tuple with the FromDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetFromDateOk() (*string, bool) { + if o == nil || o.FromDate == nil { + return nil, false + } + return o.FromDate, true +} + +// HasFromDate returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasFromDate() bool { + if o != nil && o.FromDate != nil { + return true + } + + return false +} + +// SetFromDate gets a reference to the given string and assigns it to the FromDate field. +func (o *ConsumptionEntry) SetFromDate(v string) { + o.FromDate = &v +} + +// GetOperation returns the Operation field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetOperation() string { + if o == nil || o.Operation == nil { + var ret string + return ret + } + return *o.Operation +} + +// GetOperationOk returns a tuple with the Operation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetOperationOk() (*string, bool) { + if o == nil || o.Operation == nil { + return nil, false + } + return o.Operation, true +} + +// HasOperation returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasOperation() bool { + if o != nil && o.Operation != nil { + return true + } + + return false +} + +// SetOperation gets a reference to the given string and assigns it to the Operation field. +func (o *ConsumptionEntry) SetOperation(v string) { + o.Operation = &v +} + +// GetService returns the Service field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetService() string { + if o == nil || o.Service == nil { + var ret string + return ret + } + return *o.Service +} + +// GetServiceOk returns a tuple with the Service field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetServiceOk() (*string, bool) { + if o == nil || o.Service == nil { + return nil, false + } + return o.Service, true +} + +// HasService returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasService() bool { + if o != nil && o.Service != nil { + return true + } + + return false +} + +// SetService gets a reference to the given string and assigns it to the Service field. +func (o *ConsumptionEntry) SetService(v string) { + o.Service = &v +} + +// GetTitle returns the Title field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetTitle() string { + if o == nil || o.Title == nil { + var ret string + return ret + } + return *o.Title +} + +// GetTitleOk returns a tuple with the Title field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetTitleOk() (*string, bool) { + if o == nil || o.Title == nil { + return nil, false + } + return o.Title, true +} + +// HasTitle returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasTitle() bool { + if o != nil && o.Title != nil { + return true + } + + return false +} + +// SetTitle gets a reference to the given string and assigns it to the Title field. +func (o *ConsumptionEntry) SetTitle(v string) { + o.Title = &v +} + +// GetToDate returns the ToDate field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetToDate() string { + if o == nil || o.ToDate == nil { + var ret string + return ret + } + return *o.ToDate +} + +// GetToDateOk returns a tuple with the ToDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetToDateOk() (*string, bool) { + if o == nil || o.ToDate == nil { + return nil, false + } + return o.ToDate, true +} + +// HasToDate returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasToDate() bool { + if o != nil && o.ToDate != nil { + return true + } + + return false +} + +// SetToDate gets a reference to the given string and assigns it to the ToDate field. +func (o *ConsumptionEntry) SetToDate(v string) { + o.ToDate = &v +} + +// GetType returns the Type field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetType() string { + if o == nil || o.Type == nil { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetTypeOk() (*string, bool) { + if o == nil || o.Type == nil { + return nil, false + } + return o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasType() bool { + if o != nil && o.Type != nil { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *ConsumptionEntry) SetType(v string) { + o.Type = &v +} + +// GetValue returns the Value field value if set, zero value otherwise. +func (o *ConsumptionEntry) GetValue() string { + if o == nil || o.Value == nil { + var ret string + return ret + } + return *o.Value +} + +// GetValueOk returns a tuple with the Value field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ConsumptionEntry) GetValueOk() (*string, bool) { + if o == nil || o.Value == nil { + return nil, false + } + return o.Value, true +} + +// HasValue returns a boolean if a field has been set. +func (o *ConsumptionEntry) HasValue() bool { + if o != nil && o.Value != nil { + return true + } + + return false +} + +// SetValue gets a reference to the given string and assigns it to the Value field. +func (o *ConsumptionEntry) SetValue(v string) { + o.Value = &v +} + +func (o ConsumptionEntry) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Category != nil { + toSerialize["Category"] = o.Category + } + if o.FromDate != nil { + toSerialize["FromDate"] = o.FromDate + } + if o.Operation != nil { + toSerialize["Operation"] = o.Operation + } + if o.Service != nil { + toSerialize["Service"] = o.Service + } + if o.Title != nil { + toSerialize["Title"] = o.Title + } + if o.ToDate != nil { + toSerialize["ToDate"] = o.ToDate + } + if o.Type != nil { + toSerialize["Type"] = o.Type + } + if o.Value != nil { + toSerialize["Value"] = o.Value + } + return json.Marshal(toSerialize) +} + +type NullableConsumptionEntry struct { + value *ConsumptionEntry + isSet bool +} + +func (v NullableConsumptionEntry) Get() *ConsumptionEntry { + return v.value +} + +func (v *NullableConsumptionEntry) Set(val *ConsumptionEntry) { + v.value = val + v.isSet = true +} + +func (v NullableConsumptionEntry) IsSet() bool { + return v.isSet +} + +func (v *NullableConsumptionEntry) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableConsumptionEntry(val *ConsumptionEntry) *NullableConsumptionEntry { + return &NullableConsumptionEntry{value: val, isSet: true} +} + +func (v NullableConsumptionEntry) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableConsumptionEntry) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go new file mode 100644 index 000000000..6f1715db2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateAccessKeyRequest struct for CreateAccessKeyRequest +type CreateAccessKeyRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The date and time at which you want the access key to expire, in ISO 8601 format (for example, `2017-06-14` or `2017-06-14T00:00:00Z`). If not specified, the access key has no expiration date. + ExpirationDate *string `json:"ExpirationDate,omitempty"` +} + +// NewCreateAccessKeyRequest instantiates a new CreateAccessKeyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateAccessKeyRequest() *CreateAccessKeyRequest { + this := CreateAccessKeyRequest{} + return &this +} + +// NewCreateAccessKeyRequestWithDefaults instantiates a new CreateAccessKeyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateAccessKeyRequestWithDefaults() *CreateAccessKeyRequest { + this := CreateAccessKeyRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateAccessKeyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateAccessKeyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateAccessKeyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. +func (o *CreateAccessKeyRequest) GetExpirationDate() string { + if o == nil || o.ExpirationDate == nil { + var ret string + return ret + } + return *o.ExpirationDate +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyRequest) GetExpirationDateOk() (*string, bool) { + if o == nil || o.ExpirationDate == nil { + return nil, false + } + return o.ExpirationDate, true +} + +// HasExpirationDate returns a boolean if a field has been set. +func (o *CreateAccessKeyRequest) HasExpirationDate() bool { + if o != nil && o.ExpirationDate != nil { + return true + } + + return false +} + +// SetExpirationDate gets a reference to the given string and assigns it to the ExpirationDate field. +func (o *CreateAccessKeyRequest) SetExpirationDate(v string) { + o.ExpirationDate = &v +} + +func (o CreateAccessKeyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.ExpirationDate != nil { + toSerialize["ExpirationDate"] = o.ExpirationDate + } + return json.Marshal(toSerialize) +} + +type NullableCreateAccessKeyRequest struct { + value *CreateAccessKeyRequest + isSet bool +} + +func (v NullableCreateAccessKeyRequest) Get() *CreateAccessKeyRequest { + return v.value +} + +func (v *NullableCreateAccessKeyRequest) Set(val *CreateAccessKeyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccessKeyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccessKeyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccessKeyRequest(val *CreateAccessKeyRequest) *NullableCreateAccessKeyRequest { + return &NullableCreateAccessKeyRequest{value: val, isSet: true} +} + +func (v NullableCreateAccessKeyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccessKeyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go new file mode 100644 index 000000000..cac0d7478 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateAccessKeyResponse struct for CreateAccessKeyResponse +type CreateAccessKeyResponse struct { + AccessKey *AccessKeySecretKey `json:"AccessKey,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateAccessKeyResponse instantiates a new CreateAccessKeyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateAccessKeyResponse() *CreateAccessKeyResponse { + this := CreateAccessKeyResponse{} + return &this +} + +// NewCreateAccessKeyResponseWithDefaults instantiates a new CreateAccessKeyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateAccessKeyResponseWithDefaults() *CreateAccessKeyResponse { + this := CreateAccessKeyResponse{} + return &this +} + +// GetAccessKey returns the AccessKey field value if set, zero value otherwise. +func (o *CreateAccessKeyResponse) GetAccessKey() AccessKeySecretKey { + if o == nil || o.AccessKey == nil { + var ret AccessKeySecretKey + return ret + } + return *o.AccessKey +} + +// GetAccessKeyOk returns a tuple with the AccessKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetAccessKeyOk() (*AccessKeySecretKey, bool) { + if o == nil || o.AccessKey == nil { + return nil, false + } + return o.AccessKey, true +} + +// HasAccessKey returns a boolean if a field has been set. +func (o *CreateAccessKeyResponse) HasAccessKey() bool { + if o != nil && o.AccessKey != nil { + return true + } + + return false +} + +// SetAccessKey gets a reference to the given AccessKeySecretKey and assigns it to the AccessKey field. +func (o *CreateAccessKeyResponse) SetAccessKey(v AccessKeySecretKey) { + o.AccessKey = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateAccessKeyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateAccessKeyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateAccessKeyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateAccessKeyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKey != nil { + toSerialize["AccessKey"] = o.AccessKey + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateAccessKeyResponse struct { + value *CreateAccessKeyResponse + isSet bool +} + +func (v NullableCreateAccessKeyResponse) Get() *CreateAccessKeyResponse { + return v.value +} + +func (v *NullableCreateAccessKeyResponse) Set(val *CreateAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccessKeyResponse(val *CreateAccessKeyResponse) *NullableCreateAccessKeyResponse { + return &NullableCreateAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableCreateAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go new file mode 100644 index 000000000..fe9c767ed --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go @@ -0,0 +1,542 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateAccountRequest struct for CreateAccountRequest +type CreateAccountRequest struct { + // The city of the account owner. + City string `json:"City"` + // The name of the company for the account. + CompanyName string `json:"CompanyName"` + // The country of the account owner. + Country string `json:"Country"` + // The ID of the customer. It must be 8 digits. + CustomerId string `json:"CustomerId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The email address for the account. + Email string `json:"Email"` + // The first name of the account owner. + FirstName string `json:"FirstName"` + // The job title of the account owner. + JobTitle *string `json:"JobTitle,omitempty"` + // The last name of the account owner. + LastName string `json:"LastName"` + // The mobile phone number of the account owner. + MobileNumber *string `json:"MobileNumber,omitempty"` + // The landline phone number of the account owner. + PhoneNumber *string `json:"PhoneNumber,omitempty"` + // The state/province of the account. + StateProvince *string `json:"StateProvince,omitempty"` + // The value added tax (VAT) number for the account. + VatNumber *string `json:"VatNumber,omitempty"` + // The ZIP code of the city. + ZipCode string `json:"ZipCode"` +} + +// NewCreateAccountRequest instantiates a new CreateAccountRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateAccountRequest(city string, companyName string, country string, customerId string, email string, firstName string, lastName string, zipCode string, ) *CreateAccountRequest { + this := CreateAccountRequest{} + this.City = city + this.CompanyName = companyName + this.Country = country + this.CustomerId = customerId + this.Email = email + this.FirstName = firstName + this.LastName = lastName + this.ZipCode = zipCode + return &this +} + +// NewCreateAccountRequestWithDefaults instantiates a new CreateAccountRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateAccountRequestWithDefaults() *CreateAccountRequest { + this := CreateAccountRequest{} + return &this +} + +// GetCity returns the City field value +func (o *CreateAccountRequest) GetCity() string { + if o == nil { + var ret string + return ret + } + + return o.City +} + +// GetCityOk returns a tuple with the City field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetCityOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.City, true +} + +// SetCity sets field value +func (o *CreateAccountRequest) SetCity(v string) { + o.City = v +} + +// GetCompanyName returns the CompanyName field value +func (o *CreateAccountRequest) GetCompanyName() string { + if o == nil { + var ret string + return ret + } + + return o.CompanyName +} + +// GetCompanyNameOk returns a tuple with the CompanyName field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetCompanyNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.CompanyName, true +} + +// SetCompanyName sets field value +func (o *CreateAccountRequest) SetCompanyName(v string) { + o.CompanyName = v +} + +// GetCountry returns the Country field value +func (o *CreateAccountRequest) GetCountry() string { + if o == nil { + var ret string + return ret + } + + return o.Country +} + +// GetCountryOk returns a tuple with the Country field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetCountryOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Country, true +} + +// SetCountry sets field value +func (o *CreateAccountRequest) SetCountry(v string) { + o.Country = v +} + +// GetCustomerId returns the CustomerId field value +func (o *CreateAccountRequest) GetCustomerId() string { + if o == nil { + var ret string + return ret + } + + return o.CustomerId +} + +// GetCustomerIdOk returns a tuple with the CustomerId field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetCustomerIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.CustomerId, true +} + +// SetCustomerId sets field value +func (o *CreateAccountRequest) SetCustomerId(v string) { + o.CustomerId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateAccountRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetEmail returns the Email field value +func (o *CreateAccountRequest) GetEmail() string { + if o == nil { + var ret string + return ret + } + + return o.Email +} + +// GetEmailOk returns a tuple with the Email field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetEmailOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Email, true +} + +// SetEmail sets field value +func (o *CreateAccountRequest) SetEmail(v string) { + o.Email = v +} + +// GetFirstName returns the FirstName field value +func (o *CreateAccountRequest) GetFirstName() string { + if o == nil { + var ret string + return ret + } + + return o.FirstName +} + +// GetFirstNameOk returns a tuple with the FirstName field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetFirstNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FirstName, true +} + +// SetFirstName sets field value +func (o *CreateAccountRequest) SetFirstName(v string) { + o.FirstName = v +} + +// GetJobTitle returns the JobTitle field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetJobTitle() string { + if o == nil || o.JobTitle == nil { + var ret string + return ret + } + return *o.JobTitle +} + +// GetJobTitleOk returns a tuple with the JobTitle field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetJobTitleOk() (*string, bool) { + if o == nil || o.JobTitle == nil { + return nil, false + } + return o.JobTitle, true +} + +// HasJobTitle returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasJobTitle() bool { + if o != nil && o.JobTitle != nil { + return true + } + + return false +} + +// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. +func (o *CreateAccountRequest) SetJobTitle(v string) { + o.JobTitle = &v +} + +// GetLastName returns the LastName field value +func (o *CreateAccountRequest) GetLastName() string { + if o == nil { + var ret string + return ret + } + + return o.LastName +} + +// GetLastNameOk returns a tuple with the LastName field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetLastNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LastName, true +} + +// SetLastName sets field value +func (o *CreateAccountRequest) SetLastName(v string) { + o.LastName = v +} + +// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetMobileNumber() string { + if o == nil || o.MobileNumber == nil { + var ret string + return ret + } + return *o.MobileNumber +} + +// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetMobileNumberOk() (*string, bool) { + if o == nil || o.MobileNumber == nil { + return nil, false + } + return o.MobileNumber, true +} + +// HasMobileNumber returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasMobileNumber() bool { + if o != nil && o.MobileNumber != nil { + return true + } + + return false +} + +// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. +func (o *CreateAccountRequest) SetMobileNumber(v string) { + o.MobileNumber = &v +} + +// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetPhoneNumber() string { + if o == nil || o.PhoneNumber == nil { + var ret string + return ret + } + return *o.PhoneNumber +} + +// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetPhoneNumberOk() (*string, bool) { + if o == nil || o.PhoneNumber == nil { + return nil, false + } + return o.PhoneNumber, true +} + +// HasPhoneNumber returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasPhoneNumber() bool { + if o != nil && o.PhoneNumber != nil { + return true + } + + return false +} + +// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. +func (o *CreateAccountRequest) SetPhoneNumber(v string) { + o.PhoneNumber = &v +} + +// GetStateProvince returns the StateProvince field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetStateProvince() string { + if o == nil || o.StateProvince == nil { + var ret string + return ret + } + return *o.StateProvince +} + +// GetStateProvinceOk returns a tuple with the StateProvince field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetStateProvinceOk() (*string, bool) { + if o == nil || o.StateProvince == nil { + return nil, false + } + return o.StateProvince, true +} + +// HasStateProvince returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasStateProvince() bool { + if o != nil && o.StateProvince != nil { + return true + } + + return false +} + +// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. +func (o *CreateAccountRequest) SetStateProvince(v string) { + o.StateProvince = &v +} + +// GetVatNumber returns the VatNumber field value if set, zero value otherwise. +func (o *CreateAccountRequest) GetVatNumber() string { + if o == nil || o.VatNumber == nil { + var ret string + return ret + } + return *o.VatNumber +} + +// GetVatNumberOk returns a tuple with the VatNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetVatNumberOk() (*string, bool) { + if o == nil || o.VatNumber == nil { + return nil, false + } + return o.VatNumber, true +} + +// HasVatNumber returns a boolean if a field has been set. +func (o *CreateAccountRequest) HasVatNumber() bool { + if o != nil && o.VatNumber != nil { + return true + } + + return false +} + +// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. +func (o *CreateAccountRequest) SetVatNumber(v string) { + o.VatNumber = &v +} + +// GetZipCode returns the ZipCode field value +func (o *CreateAccountRequest) GetZipCode() string { + if o == nil { + var ret string + return ret + } + + return o.ZipCode +} + +// GetZipCodeOk returns a tuple with the ZipCode field value +// and a boolean to check if the value has been set. +func (o *CreateAccountRequest) GetZipCodeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ZipCode, true +} + +// SetZipCode sets field value +func (o *CreateAccountRequest) SetZipCode(v string) { + o.ZipCode = v +} + +func (o CreateAccountRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["City"] = o.City + } + if true { + toSerialize["CompanyName"] = o.CompanyName + } + if true { + toSerialize["Country"] = o.Country + } + if true { + toSerialize["CustomerId"] = o.CustomerId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Email"] = o.Email + } + if true { + toSerialize["FirstName"] = o.FirstName + } + if o.JobTitle != nil { + toSerialize["JobTitle"] = o.JobTitle + } + if true { + toSerialize["LastName"] = o.LastName + } + if o.MobileNumber != nil { + toSerialize["MobileNumber"] = o.MobileNumber + } + if o.PhoneNumber != nil { + toSerialize["PhoneNumber"] = o.PhoneNumber + } + if o.StateProvince != nil { + toSerialize["StateProvince"] = o.StateProvince + } + if o.VatNumber != nil { + toSerialize["VatNumber"] = o.VatNumber + } + if true { + toSerialize["ZipCode"] = o.ZipCode + } + return json.Marshal(toSerialize) +} + +type NullableCreateAccountRequest struct { + value *CreateAccountRequest + isSet bool +} + +func (v NullableCreateAccountRequest) Get() *CreateAccountRequest { + return v.value +} + +func (v *NullableCreateAccountRequest) Set(val *CreateAccountRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccountRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccountRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccountRequest(val *CreateAccountRequest) *NullableCreateAccountRequest { + return &NullableCreateAccountRequest{value: val, isSet: true} +} + +func (v NullableCreateAccountRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccountRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go new file mode 100644 index 000000000..ab5a0cf1d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateAccountResponse struct for CreateAccountResponse +type CreateAccountResponse struct { + Account *Account `json:"Account,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateAccountResponse instantiates a new CreateAccountResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateAccountResponse() *CreateAccountResponse { + this := CreateAccountResponse{} + return &this +} + +// NewCreateAccountResponseWithDefaults instantiates a new CreateAccountResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateAccountResponseWithDefaults() *CreateAccountResponse { + this := CreateAccountResponse{} + return &this +} + +// GetAccount returns the Account field value if set, zero value otherwise. +func (o *CreateAccountResponse) GetAccount() Account { + if o == nil || o.Account == nil { + var ret Account + return ret + } + return *o.Account +} + +// GetAccountOk returns a tuple with the Account field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountResponse) GetAccountOk() (*Account, bool) { + if o == nil || o.Account == nil { + return nil, false + } + return o.Account, true +} + +// HasAccount returns a boolean if a field has been set. +func (o *CreateAccountResponse) HasAccount() bool { + if o != nil && o.Account != nil { + return true + } + + return false +} + +// SetAccount gets a reference to the given Account and assigns it to the Account field. +func (o *CreateAccountResponse) SetAccount(v Account) { + o.Account = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateAccountResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccountResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateAccountResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateAccountResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateAccountResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Account != nil { + toSerialize["Account"] = o.Account + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateAccountResponse struct { + value *CreateAccountResponse + isSet bool +} + +func (v NullableCreateAccountResponse) Get() *CreateAccountResponse { + return v.value +} + +func (v *NullableCreateAccountResponse) Set(val *CreateAccountResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccountResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccountResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccountResponse(val *CreateAccountResponse) *NullableCreateAccountResponse { + return &NullableCreateAccountResponse{value: val, isSet: true} +} + +func (v NullableCreateAccountResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccountResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go new file mode 100644 index 000000000..2b5531a8e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go @@ -0,0 +1,207 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateClientGatewayRequest struct for CreateClientGatewayRequest +type CreateClientGatewayRequest struct { + // An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. + BgpAsn int32 `json:"BgpAsn"` + // The communication protocol used to establish tunnel with your client gateway (only `ipsec.1` is supported). + ConnectionType string `json:"ConnectionType"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The public fixed IPv4 address of your client gateway. + PublicIp string `json:"PublicIp"` +} + +// NewCreateClientGatewayRequest instantiates a new CreateClientGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateClientGatewayRequest(bgpAsn int32, connectionType string, publicIp string, ) *CreateClientGatewayRequest { + this := CreateClientGatewayRequest{} + this.BgpAsn = bgpAsn + this.ConnectionType = connectionType + this.PublicIp = publicIp + return &this +} + +// NewCreateClientGatewayRequestWithDefaults instantiates a new CreateClientGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateClientGatewayRequestWithDefaults() *CreateClientGatewayRequest { + this := CreateClientGatewayRequest{} + return &this +} + +// GetBgpAsn returns the BgpAsn field value +func (o *CreateClientGatewayRequest) GetBgpAsn() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.BgpAsn +} + +// GetBgpAsnOk returns a tuple with the BgpAsn field value +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayRequest) GetBgpAsnOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.BgpAsn, true +} + +// SetBgpAsn sets field value +func (o *CreateClientGatewayRequest) SetBgpAsn(v int32) { + o.BgpAsn = v +} + +// GetConnectionType returns the ConnectionType field value +func (o *CreateClientGatewayRequest) GetConnectionType() string { + if o == nil { + var ret string + return ret + } + + return o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayRequest) GetConnectionTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ConnectionType, true +} + +// SetConnectionType sets field value +func (o *CreateClientGatewayRequest) SetConnectionType(v string) { + o.ConnectionType = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateClientGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateClientGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateClientGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPublicIp returns the PublicIp field value +func (o *CreateClientGatewayRequest) GetPublicIp() string { + if o == nil { + var ret string + return ret + } + + return o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayRequest) GetPublicIpOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PublicIp, true +} + +// SetPublicIp sets field value +func (o *CreateClientGatewayRequest) SetPublicIp(v string) { + o.PublicIp = v +} + +func (o CreateClientGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["BgpAsn"] = o.BgpAsn + } + if true { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["PublicIp"] = o.PublicIp + } + return json.Marshal(toSerialize) +} + +type NullableCreateClientGatewayRequest struct { + value *CreateClientGatewayRequest + isSet bool +} + +func (v NullableCreateClientGatewayRequest) Get() *CreateClientGatewayRequest { + return v.value +} + +func (v *NullableCreateClientGatewayRequest) Set(val *CreateClientGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateClientGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateClientGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateClientGatewayRequest(val *CreateClientGatewayRequest) *NullableCreateClientGatewayRequest { + return &NullableCreateClientGatewayRequest{value: val, isSet: true} +} + +func (v NullableCreateClientGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateClientGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go new file mode 100644 index 000000000..cd90ce2a0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateClientGatewayResponse struct for CreateClientGatewayResponse +type CreateClientGatewayResponse struct { + ClientGateway *ClientGateway `json:"ClientGateway,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateClientGatewayResponse instantiates a new CreateClientGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateClientGatewayResponse() *CreateClientGatewayResponse { + this := CreateClientGatewayResponse{} + return &this +} + +// NewCreateClientGatewayResponseWithDefaults instantiates a new CreateClientGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateClientGatewayResponseWithDefaults() *CreateClientGatewayResponse { + this := CreateClientGatewayResponse{} + return &this +} + +// GetClientGateway returns the ClientGateway field value if set, zero value otherwise. +func (o *CreateClientGatewayResponse) GetClientGateway() ClientGateway { + if o == nil || o.ClientGateway == nil { + var ret ClientGateway + return ret + } + return *o.ClientGateway +} + +// GetClientGatewayOk returns a tuple with the ClientGateway field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayResponse) GetClientGatewayOk() (*ClientGateway, bool) { + if o == nil || o.ClientGateway == nil { + return nil, false + } + return o.ClientGateway, true +} + +// HasClientGateway returns a boolean if a field has been set. +func (o *CreateClientGatewayResponse) HasClientGateway() bool { + if o != nil && o.ClientGateway != nil { + return true + } + + return false +} + +// SetClientGateway gets a reference to the given ClientGateway and assigns it to the ClientGateway field. +func (o *CreateClientGatewayResponse) SetClientGateway(v ClientGateway) { + o.ClientGateway = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateClientGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateClientGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateClientGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateClientGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateClientGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClientGateway != nil { + toSerialize["ClientGateway"] = o.ClientGateway + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateClientGatewayResponse struct { + value *CreateClientGatewayResponse + isSet bool +} + +func (v NullableCreateClientGatewayResponse) Get() *CreateClientGatewayResponse { + return v.value +} + +func (v *NullableCreateClientGatewayResponse) Set(val *CreateClientGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateClientGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateClientGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateClientGatewayResponse(val *CreateClientGatewayResponse) *NullableCreateClientGatewayResponse { + return &NullableCreateClientGatewayResponse{value: val, isSet: true} +} + +func (v NullableCreateClientGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateClientGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go new file mode 100644 index 000000000..31127700a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDhcpOptionsRequest struct for CreateDhcpOptionsRequest +type CreateDhcpOptionsRequest struct { + // Specify a domain name (for example, MyCompany.com). You can specify only one domain name. + DomainName *string `json:"DomainName,omitempty"` + // The IP addresses of domain name servers. If no IP addresses are specified, the `OutscaleProvidedDNS` value is set by default. + DomainNameServers *[]string `json:"DomainNameServers,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The IP addresses of the Network Time Protocol (NTP) servers. + NtpServers *[]string `json:"NtpServers,omitempty"` +} + +// NewCreateDhcpOptionsRequest instantiates a new CreateDhcpOptionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDhcpOptionsRequest() *CreateDhcpOptionsRequest { + this := CreateDhcpOptionsRequest{} + return &this +} + +// NewCreateDhcpOptionsRequestWithDefaults instantiates a new CreateDhcpOptionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDhcpOptionsRequestWithDefaults() *CreateDhcpOptionsRequest { + this := CreateDhcpOptionsRequest{} + return &this +} + +// GetDomainName returns the DomainName field value if set, zero value otherwise. +func (o *CreateDhcpOptionsRequest) GetDomainName() string { + if o == nil || o.DomainName == nil { + var ret string + return ret + } + return *o.DomainName +} + +// GetDomainNameOk returns a tuple with the DomainName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsRequest) GetDomainNameOk() (*string, bool) { + if o == nil || o.DomainName == nil { + return nil, false + } + return o.DomainName, true +} + +// HasDomainName returns a boolean if a field has been set. +func (o *CreateDhcpOptionsRequest) HasDomainName() bool { + if o != nil && o.DomainName != nil { + return true + } + + return false +} + +// SetDomainName gets a reference to the given string and assigns it to the DomainName field. +func (o *CreateDhcpOptionsRequest) SetDomainName(v string) { + o.DomainName = &v +} + +// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. +func (o *CreateDhcpOptionsRequest) GetDomainNameServers() []string { + if o == nil || o.DomainNameServers == nil { + var ret []string + return ret + } + return *o.DomainNameServers +} + +// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsRequest) GetDomainNameServersOk() (*[]string, bool) { + if o == nil || o.DomainNameServers == nil { + return nil, false + } + return o.DomainNameServers, true +} + +// HasDomainNameServers returns a boolean if a field has been set. +func (o *CreateDhcpOptionsRequest) HasDomainNameServers() bool { + if o != nil && o.DomainNameServers != nil { + return true + } + + return false +} + +// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. +func (o *CreateDhcpOptionsRequest) SetDomainNameServers(v []string) { + o.DomainNameServers = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateDhcpOptionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateDhcpOptionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateDhcpOptionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNtpServers returns the NtpServers field value if set, zero value otherwise. +func (o *CreateDhcpOptionsRequest) GetNtpServers() []string { + if o == nil || o.NtpServers == nil { + var ret []string + return ret + } + return *o.NtpServers +} + +// GetNtpServersOk returns a tuple with the NtpServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsRequest) GetNtpServersOk() (*[]string, bool) { + if o == nil || o.NtpServers == nil { + return nil, false + } + return o.NtpServers, true +} + +// HasNtpServers returns a boolean if a field has been set. +func (o *CreateDhcpOptionsRequest) HasNtpServers() bool { + if o != nil && o.NtpServers != nil { + return true + } + + return false +} + +// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. +func (o *CreateDhcpOptionsRequest) SetNtpServers(v []string) { + o.NtpServers = &v +} + +func (o CreateDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DomainName != nil { + toSerialize["DomainName"] = o.DomainName + } + if o.DomainNameServers != nil { + toSerialize["DomainNameServers"] = o.DomainNameServers + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.NtpServers != nil { + toSerialize["NtpServers"] = o.NtpServers + } + return json.Marshal(toSerialize) +} + +type NullableCreateDhcpOptionsRequest struct { + value *CreateDhcpOptionsRequest + isSet bool +} + +func (v NullableCreateDhcpOptionsRequest) Get() *CreateDhcpOptionsRequest { + return v.value +} + +func (v *NullableCreateDhcpOptionsRequest) Set(val *CreateDhcpOptionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDhcpOptionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDhcpOptionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDhcpOptionsRequest(val *CreateDhcpOptionsRequest) *NullableCreateDhcpOptionsRequest { + return &NullableCreateDhcpOptionsRequest{value: val, isSet: true} +} + +func (v NullableCreateDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDhcpOptionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go new file mode 100644 index 000000000..63de11e25 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDhcpOptionsResponse struct for CreateDhcpOptionsResponse +type CreateDhcpOptionsResponse struct { + DhcpOptionsSet *DhcpOptionsSet `json:"DhcpOptionsSet,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateDhcpOptionsResponse instantiates a new CreateDhcpOptionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDhcpOptionsResponse() *CreateDhcpOptionsResponse { + this := CreateDhcpOptionsResponse{} + return &this +} + +// NewCreateDhcpOptionsResponseWithDefaults instantiates a new CreateDhcpOptionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDhcpOptionsResponseWithDefaults() *CreateDhcpOptionsResponse { + this := CreateDhcpOptionsResponse{} + return &this +} + +// GetDhcpOptionsSet returns the DhcpOptionsSet field value if set, zero value otherwise. +func (o *CreateDhcpOptionsResponse) GetDhcpOptionsSet() DhcpOptionsSet { + if o == nil || o.DhcpOptionsSet == nil { + var ret DhcpOptionsSet + return ret + } + return *o.DhcpOptionsSet +} + +// GetDhcpOptionsSetOk returns a tuple with the DhcpOptionsSet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsResponse) GetDhcpOptionsSetOk() (*DhcpOptionsSet, bool) { + if o == nil || o.DhcpOptionsSet == nil { + return nil, false + } + return o.DhcpOptionsSet, true +} + +// HasDhcpOptionsSet returns a boolean if a field has been set. +func (o *CreateDhcpOptionsResponse) HasDhcpOptionsSet() bool { + if o != nil && o.DhcpOptionsSet != nil { + return true + } + + return false +} + +// SetDhcpOptionsSet gets a reference to the given DhcpOptionsSet and assigns it to the DhcpOptionsSet field. +func (o *CreateDhcpOptionsResponse) SetDhcpOptionsSet(v DhcpOptionsSet) { + o.DhcpOptionsSet = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateDhcpOptionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDhcpOptionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateDhcpOptionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateDhcpOptionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DhcpOptionsSet != nil { + toSerialize["DhcpOptionsSet"] = o.DhcpOptionsSet + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateDhcpOptionsResponse struct { + value *CreateDhcpOptionsResponse + isSet bool +} + +func (v NullableCreateDhcpOptionsResponse) Get() *CreateDhcpOptionsResponse { + return v.value +} + +func (v *NullableCreateDhcpOptionsResponse) Set(val *CreateDhcpOptionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDhcpOptionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDhcpOptionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDhcpOptionsResponse(val *CreateDhcpOptionsResponse) *NullableCreateDhcpOptionsResponse { + return &NullableCreateDhcpOptionsResponse{value: val, isSet: true} +} + +func (v NullableCreateDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDhcpOptionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go new file mode 100644 index 000000000..910283c28 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go @@ -0,0 +1,176 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDirectLinkInterfaceRequest struct for CreateDirectLinkInterfaceRequest +type CreateDirectLinkInterfaceRequest struct { + // The ID of the existing DirectLink for which you want to create the DirectLink interface. + DirectLinkId string `json:"DirectLinkId"` + DirectLinkInterface DirectLinkInterface `json:"DirectLinkInterface"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewCreateDirectLinkInterfaceRequest instantiates a new CreateDirectLinkInterfaceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDirectLinkInterfaceRequest(directLinkId string, directLinkInterface DirectLinkInterface, ) *CreateDirectLinkInterfaceRequest { + this := CreateDirectLinkInterfaceRequest{} + this.DirectLinkId = directLinkId + this.DirectLinkInterface = directLinkInterface + return &this +} + +// NewCreateDirectLinkInterfaceRequestWithDefaults instantiates a new CreateDirectLinkInterfaceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDirectLinkInterfaceRequestWithDefaults() *CreateDirectLinkInterfaceRequest { + this := CreateDirectLinkInterfaceRequest{} + return &this +} + +// GetDirectLinkId returns the DirectLinkId field value +func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkId() string { + if o == nil { + var ret string + return ret + } + + return o.DirectLinkId +} + +// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkId, true +} + +// SetDirectLinkId sets field value +func (o *CreateDirectLinkInterfaceRequest) SetDirectLinkId(v string) { + o.DirectLinkId = v +} + +// GetDirectLinkInterface returns the DirectLinkInterface field value +func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkInterface() DirectLinkInterface { + if o == nil { + var ret DirectLinkInterface + return ret + } + + return o.DirectLinkInterface +} + +// GetDirectLinkInterfaceOk returns a tuple with the DirectLinkInterface field value +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkInterfaceOk() (*DirectLinkInterface, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkInterface, true +} + +// SetDirectLinkInterface sets field value +func (o *CreateDirectLinkInterfaceRequest) SetDirectLinkInterface(v DirectLinkInterface) { + o.DirectLinkInterface = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateDirectLinkInterfaceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkInterfaceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateDirectLinkInterfaceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateDirectLinkInterfaceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o CreateDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DirectLinkId"] = o.DirectLinkId + } + if true { + toSerialize["DirectLinkInterface"] = o.DirectLinkInterface + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableCreateDirectLinkInterfaceRequest struct { + value *CreateDirectLinkInterfaceRequest + isSet bool +} + +func (v NullableCreateDirectLinkInterfaceRequest) Get() *CreateDirectLinkInterfaceRequest { + return v.value +} + +func (v *NullableCreateDirectLinkInterfaceRequest) Set(val *CreateDirectLinkInterfaceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDirectLinkInterfaceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDirectLinkInterfaceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDirectLinkInterfaceRequest(val *CreateDirectLinkInterfaceRequest) *NullableCreateDirectLinkInterfaceRequest { + return &NullableCreateDirectLinkInterfaceRequest{value: val, isSet: true} +} + +func (v NullableCreateDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDirectLinkInterfaceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go new file mode 100644 index 000000000..ff7626f43 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDirectLinkInterfaceResponse struct for CreateDirectLinkInterfaceResponse +type CreateDirectLinkInterfaceResponse struct { + DirectLinkInterface *DirectLinkInterfaces `json:"DirectLinkInterface,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateDirectLinkInterfaceResponse instantiates a new CreateDirectLinkInterfaceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDirectLinkInterfaceResponse() *CreateDirectLinkInterfaceResponse { + this := CreateDirectLinkInterfaceResponse{} + return &this +} + +// NewCreateDirectLinkInterfaceResponseWithDefaults instantiates a new CreateDirectLinkInterfaceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDirectLinkInterfaceResponseWithDefaults() *CreateDirectLinkInterfaceResponse { + this := CreateDirectLinkInterfaceResponse{} + return &this +} + +// GetDirectLinkInterface returns the DirectLinkInterface field value if set, zero value otherwise. +func (o *CreateDirectLinkInterfaceResponse) GetDirectLinkInterface() DirectLinkInterfaces { + if o == nil || o.DirectLinkInterface == nil { + var ret DirectLinkInterfaces + return ret + } + return *o.DirectLinkInterface +} + +// GetDirectLinkInterfaceOk returns a tuple with the DirectLinkInterface field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkInterfaceResponse) GetDirectLinkInterfaceOk() (*DirectLinkInterfaces, bool) { + if o == nil || o.DirectLinkInterface == nil { + return nil, false + } + return o.DirectLinkInterface, true +} + +// HasDirectLinkInterface returns a boolean if a field has been set. +func (o *CreateDirectLinkInterfaceResponse) HasDirectLinkInterface() bool { + if o != nil && o.DirectLinkInterface != nil { + return true + } + + return false +} + +// SetDirectLinkInterface gets a reference to the given DirectLinkInterfaces and assigns it to the DirectLinkInterface field. +func (o *CreateDirectLinkInterfaceResponse) SetDirectLinkInterface(v DirectLinkInterfaces) { + o.DirectLinkInterface = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateDirectLinkInterfaceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkInterfaceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateDirectLinkInterfaceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateDirectLinkInterfaceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLinkInterface != nil { + toSerialize["DirectLinkInterface"] = o.DirectLinkInterface + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateDirectLinkInterfaceResponse struct { + value *CreateDirectLinkInterfaceResponse + isSet bool +} + +func (v NullableCreateDirectLinkInterfaceResponse) Get() *CreateDirectLinkInterfaceResponse { + return v.value +} + +func (v *NullableCreateDirectLinkInterfaceResponse) Set(val *CreateDirectLinkInterfaceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDirectLinkInterfaceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDirectLinkInterfaceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDirectLinkInterfaceResponse(val *CreateDirectLinkInterfaceResponse) *NullableCreateDirectLinkInterfaceResponse { + return &NullableCreateDirectLinkInterfaceResponse{value: val, isSet: true} +} + +func (v NullableCreateDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDirectLinkInterfaceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go new file mode 100644 index 000000000..110feb5b0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go @@ -0,0 +1,207 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDirectLinkRequest struct for CreateDirectLinkRequest +type CreateDirectLinkRequest struct { + // The bandwidth of the DirectLink (`1Gbps` \\| `10Gbps`). + Bandwidth string `json:"Bandwidth"` + // The name of the DirectLink. + DirectLinkName string `json:"DirectLinkName"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The code of the requested location for the DirectLink, returned by the [ReadLocations](#readlocations) method. + Location string `json:"Location"` +} + +// NewCreateDirectLinkRequest instantiates a new CreateDirectLinkRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDirectLinkRequest(bandwidth string, directLinkName string, location string, ) *CreateDirectLinkRequest { + this := CreateDirectLinkRequest{} + this.Bandwidth = bandwidth + this.DirectLinkName = directLinkName + this.Location = location + return &this +} + +// NewCreateDirectLinkRequestWithDefaults instantiates a new CreateDirectLinkRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDirectLinkRequestWithDefaults() *CreateDirectLinkRequest { + this := CreateDirectLinkRequest{} + return &this +} + +// GetBandwidth returns the Bandwidth field value +func (o *CreateDirectLinkRequest) GetBandwidth() string { + if o == nil { + var ret string + return ret + } + + return o.Bandwidth +} + +// GetBandwidthOk returns a tuple with the Bandwidth field value +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkRequest) GetBandwidthOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Bandwidth, true +} + +// SetBandwidth sets field value +func (o *CreateDirectLinkRequest) SetBandwidth(v string) { + o.Bandwidth = v +} + +// GetDirectLinkName returns the DirectLinkName field value +func (o *CreateDirectLinkRequest) GetDirectLinkName() string { + if o == nil { + var ret string + return ret + } + + return o.DirectLinkName +} + +// GetDirectLinkNameOk returns a tuple with the DirectLinkName field value +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkRequest) GetDirectLinkNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkName, true +} + +// SetDirectLinkName sets field value +func (o *CreateDirectLinkRequest) SetDirectLinkName(v string) { + o.DirectLinkName = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateDirectLinkRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateDirectLinkRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateDirectLinkRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLocation returns the Location field value +func (o *CreateDirectLinkRequest) GetLocation() string { + if o == nil { + var ret string + return ret + } + + return o.Location +} + +// GetLocationOk returns a tuple with the Location field value +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkRequest) GetLocationOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Location, true +} + +// SetLocation sets field value +func (o *CreateDirectLinkRequest) SetLocation(v string) { + o.Location = v +} + +func (o CreateDirectLinkRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["Bandwidth"] = o.Bandwidth + } + if true { + toSerialize["DirectLinkName"] = o.DirectLinkName + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Location"] = o.Location + } + return json.Marshal(toSerialize) +} + +type NullableCreateDirectLinkRequest struct { + value *CreateDirectLinkRequest + isSet bool +} + +func (v NullableCreateDirectLinkRequest) Get() *CreateDirectLinkRequest { + return v.value +} + +func (v *NullableCreateDirectLinkRequest) Set(val *CreateDirectLinkRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDirectLinkRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDirectLinkRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDirectLinkRequest(val *CreateDirectLinkRequest) *NullableCreateDirectLinkRequest { + return &NullableCreateDirectLinkRequest{value: val, isSet: true} +} + +func (v NullableCreateDirectLinkRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDirectLinkRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go new file mode 100644 index 000000000..f92105737 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateDirectLinkResponse struct for CreateDirectLinkResponse +type CreateDirectLinkResponse struct { + DirectLink *DirectLink `json:"DirectLink,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateDirectLinkResponse instantiates a new CreateDirectLinkResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateDirectLinkResponse() *CreateDirectLinkResponse { + this := CreateDirectLinkResponse{} + return &this +} + +// NewCreateDirectLinkResponseWithDefaults instantiates a new CreateDirectLinkResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateDirectLinkResponseWithDefaults() *CreateDirectLinkResponse { + this := CreateDirectLinkResponse{} + return &this +} + +// GetDirectLink returns the DirectLink field value if set, zero value otherwise. +func (o *CreateDirectLinkResponse) GetDirectLink() DirectLink { + if o == nil || o.DirectLink == nil { + var ret DirectLink + return ret + } + return *o.DirectLink +} + +// GetDirectLinkOk returns a tuple with the DirectLink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkResponse) GetDirectLinkOk() (*DirectLink, bool) { + if o == nil || o.DirectLink == nil { + return nil, false + } + return o.DirectLink, true +} + +// HasDirectLink returns a boolean if a field has been set. +func (o *CreateDirectLinkResponse) HasDirectLink() bool { + if o != nil && o.DirectLink != nil { + return true + } + + return false +} + +// SetDirectLink gets a reference to the given DirectLink and assigns it to the DirectLink field. +func (o *CreateDirectLinkResponse) SetDirectLink(v DirectLink) { + o.DirectLink = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateDirectLinkResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateDirectLinkResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateDirectLinkResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateDirectLinkResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateDirectLinkResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLink != nil { + toSerialize["DirectLink"] = o.DirectLink + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateDirectLinkResponse struct { + value *CreateDirectLinkResponse + isSet bool +} + +func (v NullableCreateDirectLinkResponse) Get() *CreateDirectLinkResponse { + return v.value +} + +func (v *NullableCreateDirectLinkResponse) Set(val *CreateDirectLinkResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateDirectLinkResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateDirectLinkResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateDirectLinkResponse(val *CreateDirectLinkResponse) *NullableCreateDirectLinkResponse { + return &NullableCreateDirectLinkResponse{value: val, isSet: true} +} + +func (v NullableCreateDirectLinkResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateDirectLinkResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go new file mode 100644 index 000000000..82e28082b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go @@ -0,0 +1,255 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateFlexibleGpuRequest struct for CreateFlexibleGpuRequest +type CreateFlexibleGpuRequest struct { + // If `true`, the fGPU is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The processor generation that the fGPU must be compatible with. If not specified, the oldest possible processor generation is selected (as provided by [ReadFlexibleGpuCatalog](#readflexiblegpucatalog) for the specified model of fGPU). + Generation *string `json:"Generation,omitempty"` + // The model of fGPU you want to allocate. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). + ModelName string `json:"ModelName"` + // The Subregion in which you want to create the fGPU. + SubregionName string `json:"SubregionName"` +} + +// NewCreateFlexibleGpuRequest instantiates a new CreateFlexibleGpuRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateFlexibleGpuRequest(modelName string, subregionName string, ) *CreateFlexibleGpuRequest { + this := CreateFlexibleGpuRequest{} + var deleteOnVmDeletion bool = false + this.DeleteOnVmDeletion = &deleteOnVmDeletion + this.ModelName = modelName + this.SubregionName = subregionName + return &this +} + +// NewCreateFlexibleGpuRequestWithDefaults instantiates a new CreateFlexibleGpuRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateFlexibleGpuRequestWithDefaults() *CreateFlexibleGpuRequest { + this := CreateFlexibleGpuRequest{} + var deleteOnVmDeletion bool = false + this.DeleteOnVmDeletion = &deleteOnVmDeletion + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *CreateFlexibleGpuRequest) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuRequest) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *CreateFlexibleGpuRequest) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *CreateFlexibleGpuRequest) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateFlexibleGpuRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateFlexibleGpuRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateFlexibleGpuRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetGeneration returns the Generation field value if set, zero value otherwise. +func (o *CreateFlexibleGpuRequest) GetGeneration() string { + if o == nil || o.Generation == nil { + var ret string + return ret + } + return *o.Generation +} + +// GetGenerationOk returns a tuple with the Generation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuRequest) GetGenerationOk() (*string, bool) { + if o == nil || o.Generation == nil { + return nil, false + } + return o.Generation, true +} + +// HasGeneration returns a boolean if a field has been set. +func (o *CreateFlexibleGpuRequest) HasGeneration() bool { + if o != nil && o.Generation != nil { + return true + } + + return false +} + +// SetGeneration gets a reference to the given string and assigns it to the Generation field. +func (o *CreateFlexibleGpuRequest) SetGeneration(v string) { + o.Generation = &v +} + +// GetModelName returns the ModelName field value +func (o *CreateFlexibleGpuRequest) GetModelName() string { + if o == nil { + var ret string + return ret + } + + return o.ModelName +} + +// GetModelNameOk returns a tuple with the ModelName field value +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuRequest) GetModelNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ModelName, true +} + +// SetModelName sets field value +func (o *CreateFlexibleGpuRequest) SetModelName(v string) { + o.ModelName = v +} + +// GetSubregionName returns the SubregionName field value +func (o *CreateFlexibleGpuRequest) GetSubregionName() string { + if o == nil { + var ret string + return ret + } + + return o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuRequest) GetSubregionNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubregionName, true +} + +// SetSubregionName sets field value +func (o *CreateFlexibleGpuRequest) SetSubregionName(v string) { + o.SubregionName = v +} + +func (o CreateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Generation != nil { + toSerialize["Generation"] = o.Generation + } + if true { + toSerialize["ModelName"] = o.ModelName + } + if true { + toSerialize["SubregionName"] = o.SubregionName + } + return json.Marshal(toSerialize) +} + +type NullableCreateFlexibleGpuRequest struct { + value *CreateFlexibleGpuRequest + isSet bool +} + +func (v NullableCreateFlexibleGpuRequest) Get() *CreateFlexibleGpuRequest { + return v.value +} + +func (v *NullableCreateFlexibleGpuRequest) Set(val *CreateFlexibleGpuRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateFlexibleGpuRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateFlexibleGpuRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateFlexibleGpuRequest(val *CreateFlexibleGpuRequest) *NullableCreateFlexibleGpuRequest { + return &NullableCreateFlexibleGpuRequest{value: val, isSet: true} +} + +func (v NullableCreateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateFlexibleGpuRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go new file mode 100644 index 000000000..e9e88e0f2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateFlexibleGpuResponse struct for CreateFlexibleGpuResponse +type CreateFlexibleGpuResponse struct { + FlexibleGpu *FlexibleGpu `json:"FlexibleGpu,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateFlexibleGpuResponse instantiates a new CreateFlexibleGpuResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateFlexibleGpuResponse() *CreateFlexibleGpuResponse { + this := CreateFlexibleGpuResponse{} + return &this +} + +// NewCreateFlexibleGpuResponseWithDefaults instantiates a new CreateFlexibleGpuResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateFlexibleGpuResponseWithDefaults() *CreateFlexibleGpuResponse { + this := CreateFlexibleGpuResponse{} + return &this +} + +// GetFlexibleGpu returns the FlexibleGpu field value if set, zero value otherwise. +func (o *CreateFlexibleGpuResponse) GetFlexibleGpu() FlexibleGpu { + if o == nil || o.FlexibleGpu == nil { + var ret FlexibleGpu + return ret + } + return *o.FlexibleGpu +} + +// GetFlexibleGpuOk returns a tuple with the FlexibleGpu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuResponse) GetFlexibleGpuOk() (*FlexibleGpu, bool) { + if o == nil || o.FlexibleGpu == nil { + return nil, false + } + return o.FlexibleGpu, true +} + +// HasFlexibleGpu returns a boolean if a field has been set. +func (o *CreateFlexibleGpuResponse) HasFlexibleGpu() bool { + if o != nil && o.FlexibleGpu != nil { + return true + } + + return false +} + +// SetFlexibleGpu gets a reference to the given FlexibleGpu and assigns it to the FlexibleGpu field. +func (o *CreateFlexibleGpuResponse) SetFlexibleGpu(v FlexibleGpu) { + o.FlexibleGpu = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateFlexibleGpuResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateFlexibleGpuResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateFlexibleGpuResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateFlexibleGpuResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.FlexibleGpu != nil { + toSerialize["FlexibleGpu"] = o.FlexibleGpu + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateFlexibleGpuResponse struct { + value *CreateFlexibleGpuResponse + isSet bool +} + +func (v NullableCreateFlexibleGpuResponse) Get() *CreateFlexibleGpuResponse { + return v.value +} + +func (v *NullableCreateFlexibleGpuResponse) Set(val *CreateFlexibleGpuResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateFlexibleGpuResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateFlexibleGpuResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateFlexibleGpuResponse(val *CreateFlexibleGpuResponse) *NullableCreateFlexibleGpuResponse { + return &NullableCreateFlexibleGpuResponse{value: val, isSet: true} +} + +func (v NullableCreateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateFlexibleGpuResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go new file mode 100644 index 000000000..f6b8253fa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go @@ -0,0 +1,176 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateImageExportTaskRequest struct for CreateImageExportTaskRequest +type CreateImageExportTaskRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the OMI to export. + ImageId string `json:"ImageId"` + OsuExport OsuExport `json:"OsuExport"` +} + +// NewCreateImageExportTaskRequest instantiates a new CreateImageExportTaskRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateImageExportTaskRequest(imageId string, osuExport OsuExport, ) *CreateImageExportTaskRequest { + this := CreateImageExportTaskRequest{} + this.ImageId = imageId + this.OsuExport = osuExport + return &this +} + +// NewCreateImageExportTaskRequestWithDefaults instantiates a new CreateImageExportTaskRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateImageExportTaskRequestWithDefaults() *CreateImageExportTaskRequest { + this := CreateImageExportTaskRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateImageExportTaskRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageExportTaskRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateImageExportTaskRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateImageExportTaskRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetImageId returns the ImageId field value +func (o *CreateImageExportTaskRequest) GetImageId() string { + if o == nil { + var ret string + return ret + } + + return o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value +// and a boolean to check if the value has been set. +func (o *CreateImageExportTaskRequest) GetImageIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ImageId, true +} + +// SetImageId sets field value +func (o *CreateImageExportTaskRequest) SetImageId(v string) { + o.ImageId = v +} + +// GetOsuExport returns the OsuExport field value +func (o *CreateImageExportTaskRequest) GetOsuExport() OsuExport { + if o == nil { + var ret OsuExport + return ret + } + + return o.OsuExport +} + +// GetOsuExportOk returns a tuple with the OsuExport field value +// and a boolean to check if the value has been set. +func (o *CreateImageExportTaskRequest) GetOsuExportOk() (*OsuExport, bool) { + if o == nil { + return nil, false + } + return &o.OsuExport, true +} + +// SetOsuExport sets field value +func (o *CreateImageExportTaskRequest) SetOsuExport(v OsuExport) { + o.OsuExport = v +} + +func (o CreateImageExportTaskRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ImageId"] = o.ImageId + } + if true { + toSerialize["OsuExport"] = o.OsuExport + } + return json.Marshal(toSerialize) +} + +type NullableCreateImageExportTaskRequest struct { + value *CreateImageExportTaskRequest + isSet bool +} + +func (v NullableCreateImageExportTaskRequest) Get() *CreateImageExportTaskRequest { + return v.value +} + +func (v *NullableCreateImageExportTaskRequest) Set(val *CreateImageExportTaskRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateImageExportTaskRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateImageExportTaskRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateImageExportTaskRequest(val *CreateImageExportTaskRequest) *NullableCreateImageExportTaskRequest { + return &NullableCreateImageExportTaskRequest{value: val, isSet: true} +} + +func (v NullableCreateImageExportTaskRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateImageExportTaskRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go new file mode 100644 index 000000000..97f4796e7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateImageExportTaskResponse struct for CreateImageExportTaskResponse +type CreateImageExportTaskResponse struct { + ImageExportTask *ImageExportTask `json:"ImageExportTask,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateImageExportTaskResponse instantiates a new CreateImageExportTaskResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateImageExportTaskResponse() *CreateImageExportTaskResponse { + this := CreateImageExportTaskResponse{} + return &this +} + +// NewCreateImageExportTaskResponseWithDefaults instantiates a new CreateImageExportTaskResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateImageExportTaskResponseWithDefaults() *CreateImageExportTaskResponse { + this := CreateImageExportTaskResponse{} + return &this +} + +// GetImageExportTask returns the ImageExportTask field value if set, zero value otherwise. +func (o *CreateImageExportTaskResponse) GetImageExportTask() ImageExportTask { + if o == nil || o.ImageExportTask == nil { + var ret ImageExportTask + return ret + } + return *o.ImageExportTask +} + +// GetImageExportTaskOk returns a tuple with the ImageExportTask field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageExportTaskResponse) GetImageExportTaskOk() (*ImageExportTask, bool) { + if o == nil || o.ImageExportTask == nil { + return nil, false + } + return o.ImageExportTask, true +} + +// HasImageExportTask returns a boolean if a field has been set. +func (o *CreateImageExportTaskResponse) HasImageExportTask() bool { + if o != nil && o.ImageExportTask != nil { + return true + } + + return false +} + +// SetImageExportTask gets a reference to the given ImageExportTask and assigns it to the ImageExportTask field. +func (o *CreateImageExportTaskResponse) SetImageExportTask(v ImageExportTask) { + o.ImageExportTask = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateImageExportTaskResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageExportTaskResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateImageExportTaskResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateImageExportTaskResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateImageExportTaskResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ImageExportTask != nil { + toSerialize["ImageExportTask"] = o.ImageExportTask + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateImageExportTaskResponse struct { + value *CreateImageExportTaskResponse + isSet bool +} + +func (v NullableCreateImageExportTaskResponse) Get() *CreateImageExportTaskResponse { + return v.value +} + +func (v *NullableCreateImageExportTaskResponse) Set(val *CreateImageExportTaskResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateImageExportTaskResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateImageExportTaskResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateImageExportTaskResponse(val *CreateImageExportTaskResponse) *NullableCreateImageExportTaskResponse { + return &NullableCreateImageExportTaskResponse{value: val, isSet: true} +} + +func (v NullableCreateImageExportTaskResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateImageExportTaskResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go new file mode 100644 index 000000000..f1652a73b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go @@ -0,0 +1,487 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateImageRequest struct for CreateImageRequest +type CreateImageRequest struct { + // The architecture of the OMI (by default, `i386`). + Architecture *string `json:"Architecture,omitempty"` + // One or more block device mappings. + BlockDeviceMappings *[]BlockDeviceMappingImage `json:"BlockDeviceMappings,omitempty"` + // A description for the new OMI. + Description *string `json:"Description,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The pre-signed URL of the OMI manifest file, or the full path to the OMI stored in an OSU bucket. If you specify this parameter, a copy of the OMI is created in your account. + FileLocation *string `json:"FileLocation,omitempty"` + // A unique name for the new OMI.
Constraints: 3-128 alphanumeric characters, underscores (_), spaces ( ), parentheses (()), slashes (/), periods (.), or dashes (-). + ImageName *string `json:"ImageName,omitempty"` + // If `false`, the VM shuts down before creating the OMI and then reboots. If `true`, the VM does not. + NoReboot *bool `json:"NoReboot,omitempty"` + // The name of the root device. + RootDeviceName *string `json:"RootDeviceName,omitempty"` + // The ID of the OMI you want to copy. + SourceImageId *string `json:"SourceImageId,omitempty"` + // The name of the source Region, which must be the same as the Region of your account. + SourceRegionName *string `json:"SourceRegionName,omitempty"` + // The ID of the VM from which you want to create the OMI. + VmId *string `json:"VmId,omitempty"` +} + +// NewCreateImageRequest instantiates a new CreateImageRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateImageRequest() *CreateImageRequest { + this := CreateImageRequest{} + return &this +} + +// NewCreateImageRequestWithDefaults instantiates a new CreateImageRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateImageRequestWithDefaults() *CreateImageRequest { + this := CreateImageRequest{} + return &this +} + +// GetArchitecture returns the Architecture field value if set, zero value otherwise. +func (o *CreateImageRequest) GetArchitecture() string { + if o == nil || o.Architecture == nil { + var ret string + return ret + } + return *o.Architecture +} + +// GetArchitectureOk returns a tuple with the Architecture field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetArchitectureOk() (*string, bool) { + if o == nil || o.Architecture == nil { + return nil, false + } + return o.Architecture, true +} + +// HasArchitecture returns a boolean if a field has been set. +func (o *CreateImageRequest) HasArchitecture() bool { + if o != nil && o.Architecture != nil { + return true + } + + return false +} + +// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. +func (o *CreateImageRequest) SetArchitecture(v string) { + o.Architecture = &v +} + +// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. +func (o *CreateImageRequest) GetBlockDeviceMappings() []BlockDeviceMappingImage { + if o == nil || o.BlockDeviceMappings == nil { + var ret []BlockDeviceMappingImage + return ret + } + return *o.BlockDeviceMappings +} + +// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetBlockDeviceMappingsOk() (*[]BlockDeviceMappingImage, bool) { + if o == nil || o.BlockDeviceMappings == nil { + return nil, false + } + return o.BlockDeviceMappings, true +} + +// HasBlockDeviceMappings returns a boolean if a field has been set. +func (o *CreateImageRequest) HasBlockDeviceMappings() bool { + if o != nil && o.BlockDeviceMappings != nil { + return true + } + + return false +} + +// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingImage and assigns it to the BlockDeviceMappings field. +func (o *CreateImageRequest) SetBlockDeviceMappings(v []BlockDeviceMappingImage) { + o.BlockDeviceMappings = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *CreateImageRequest) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *CreateImageRequest) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *CreateImageRequest) SetDescription(v string) { + o.Description = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateImageRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateImageRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateImageRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFileLocation returns the FileLocation field value if set, zero value otherwise. +func (o *CreateImageRequest) GetFileLocation() string { + if o == nil || o.FileLocation == nil { + var ret string + return ret + } + return *o.FileLocation +} + +// GetFileLocationOk returns a tuple with the FileLocation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetFileLocationOk() (*string, bool) { + if o == nil || o.FileLocation == nil { + return nil, false + } + return o.FileLocation, true +} + +// HasFileLocation returns a boolean if a field has been set. +func (o *CreateImageRequest) HasFileLocation() bool { + if o != nil && o.FileLocation != nil { + return true + } + + return false +} + +// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. +func (o *CreateImageRequest) SetFileLocation(v string) { + o.FileLocation = &v +} + +// GetImageName returns the ImageName field value if set, zero value otherwise. +func (o *CreateImageRequest) GetImageName() string { + if o == nil || o.ImageName == nil { + var ret string + return ret + } + return *o.ImageName +} + +// GetImageNameOk returns a tuple with the ImageName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetImageNameOk() (*string, bool) { + if o == nil || o.ImageName == nil { + return nil, false + } + return o.ImageName, true +} + +// HasImageName returns a boolean if a field has been set. +func (o *CreateImageRequest) HasImageName() bool { + if o != nil && o.ImageName != nil { + return true + } + + return false +} + +// SetImageName gets a reference to the given string and assigns it to the ImageName field. +func (o *CreateImageRequest) SetImageName(v string) { + o.ImageName = &v +} + +// GetNoReboot returns the NoReboot field value if set, zero value otherwise. +func (o *CreateImageRequest) GetNoReboot() bool { + if o == nil || o.NoReboot == nil { + var ret bool + return ret + } + return *o.NoReboot +} + +// GetNoRebootOk returns a tuple with the NoReboot field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetNoRebootOk() (*bool, bool) { + if o == nil || o.NoReboot == nil { + return nil, false + } + return o.NoReboot, true +} + +// HasNoReboot returns a boolean if a field has been set. +func (o *CreateImageRequest) HasNoReboot() bool { + if o != nil && o.NoReboot != nil { + return true + } + + return false +} + +// SetNoReboot gets a reference to the given bool and assigns it to the NoReboot field. +func (o *CreateImageRequest) SetNoReboot(v bool) { + o.NoReboot = &v +} + +// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. +func (o *CreateImageRequest) GetRootDeviceName() string { + if o == nil || o.RootDeviceName == nil { + var ret string + return ret + } + return *o.RootDeviceName +} + +// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetRootDeviceNameOk() (*string, bool) { + if o == nil || o.RootDeviceName == nil { + return nil, false + } + return o.RootDeviceName, true +} + +// HasRootDeviceName returns a boolean if a field has been set. +func (o *CreateImageRequest) HasRootDeviceName() bool { + if o != nil && o.RootDeviceName != nil { + return true + } + + return false +} + +// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. +func (o *CreateImageRequest) SetRootDeviceName(v string) { + o.RootDeviceName = &v +} + +// GetSourceImageId returns the SourceImageId field value if set, zero value otherwise. +func (o *CreateImageRequest) GetSourceImageId() string { + if o == nil || o.SourceImageId == nil { + var ret string + return ret + } + return *o.SourceImageId +} + +// GetSourceImageIdOk returns a tuple with the SourceImageId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetSourceImageIdOk() (*string, bool) { + if o == nil || o.SourceImageId == nil { + return nil, false + } + return o.SourceImageId, true +} + +// HasSourceImageId returns a boolean if a field has been set. +func (o *CreateImageRequest) HasSourceImageId() bool { + if o != nil && o.SourceImageId != nil { + return true + } + + return false +} + +// SetSourceImageId gets a reference to the given string and assigns it to the SourceImageId field. +func (o *CreateImageRequest) SetSourceImageId(v string) { + o.SourceImageId = &v +} + +// GetSourceRegionName returns the SourceRegionName field value if set, zero value otherwise. +func (o *CreateImageRequest) GetSourceRegionName() string { + if o == nil || o.SourceRegionName == nil { + var ret string + return ret + } + return *o.SourceRegionName +} + +// GetSourceRegionNameOk returns a tuple with the SourceRegionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetSourceRegionNameOk() (*string, bool) { + if o == nil || o.SourceRegionName == nil { + return nil, false + } + return o.SourceRegionName, true +} + +// HasSourceRegionName returns a boolean if a field has been set. +func (o *CreateImageRequest) HasSourceRegionName() bool { + if o != nil && o.SourceRegionName != nil { + return true + } + + return false +} + +// SetSourceRegionName gets a reference to the given string and assigns it to the SourceRegionName field. +func (o *CreateImageRequest) SetSourceRegionName(v string) { + o.SourceRegionName = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *CreateImageRequest) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageRequest) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *CreateImageRequest) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *CreateImageRequest) SetVmId(v string) { + o.VmId = &v +} + +func (o CreateImageRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Architecture != nil { + toSerialize["Architecture"] = o.Architecture + } + if o.BlockDeviceMappings != nil { + toSerialize["BlockDeviceMappings"] = o.BlockDeviceMappings + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.FileLocation != nil { + toSerialize["FileLocation"] = o.FileLocation + } + if o.ImageName != nil { + toSerialize["ImageName"] = o.ImageName + } + if o.NoReboot != nil { + toSerialize["NoReboot"] = o.NoReboot + } + if o.RootDeviceName != nil { + toSerialize["RootDeviceName"] = o.RootDeviceName + } + if o.SourceImageId != nil { + toSerialize["SourceImageId"] = o.SourceImageId + } + if o.SourceRegionName != nil { + toSerialize["SourceRegionName"] = o.SourceRegionName + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableCreateImageRequest struct { + value *CreateImageRequest + isSet bool +} + +func (v NullableCreateImageRequest) Get() *CreateImageRequest { + return v.value +} + +func (v *NullableCreateImageRequest) Set(val *CreateImageRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateImageRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateImageRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateImageRequest(val *CreateImageRequest) *NullableCreateImageRequest { + return &NullableCreateImageRequest{value: val, isSet: true} +} + +func (v NullableCreateImageRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateImageRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go new file mode 100644 index 000000000..819243635 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateImageResponse struct for CreateImageResponse +type CreateImageResponse struct { + Image *Image `json:"Image,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateImageResponse instantiates a new CreateImageResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateImageResponse() *CreateImageResponse { + this := CreateImageResponse{} + return &this +} + +// NewCreateImageResponseWithDefaults instantiates a new CreateImageResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateImageResponseWithDefaults() *CreateImageResponse { + this := CreateImageResponse{} + return &this +} + +// GetImage returns the Image field value if set, zero value otherwise. +func (o *CreateImageResponse) GetImage() Image { + if o == nil || o.Image == nil { + var ret Image + return ret + } + return *o.Image +} + +// GetImageOk returns a tuple with the Image field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageResponse) GetImageOk() (*Image, bool) { + if o == nil || o.Image == nil { + return nil, false + } + return o.Image, true +} + +// HasImage returns a boolean if a field has been set. +func (o *CreateImageResponse) HasImage() bool { + if o != nil && o.Image != nil { + return true + } + + return false +} + +// SetImage gets a reference to the given Image and assigns it to the Image field. +func (o *CreateImageResponse) SetImage(v Image) { + o.Image = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateImageResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateImageResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateImageResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateImageResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateImageResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Image != nil { + toSerialize["Image"] = o.Image + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateImageResponse struct { + value *CreateImageResponse + isSet bool +} + +func (v NullableCreateImageResponse) Get() *CreateImageResponse { + return v.value +} + +func (v *NullableCreateImageResponse) Set(val *CreateImageResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateImageResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateImageResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateImageResponse(val *CreateImageResponse) *NullableCreateImageResponse { + return &NullableCreateImageResponse{value: val, isSet: true} +} + +func (v NullableCreateImageResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateImageResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go new file mode 100644 index 000000000..2b52534b3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateInternetServiceRequest struct for CreateInternetServiceRequest +type CreateInternetServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewCreateInternetServiceRequest instantiates a new CreateInternetServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateInternetServiceRequest() *CreateInternetServiceRequest { + this := CreateInternetServiceRequest{} + return &this +} + +// NewCreateInternetServiceRequestWithDefaults instantiates a new CreateInternetServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateInternetServiceRequestWithDefaults() *CreateInternetServiceRequest { + this := CreateInternetServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateInternetServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateInternetServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateInternetServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateInternetServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o CreateInternetServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableCreateInternetServiceRequest struct { + value *CreateInternetServiceRequest + isSet bool +} + +func (v NullableCreateInternetServiceRequest) Get() *CreateInternetServiceRequest { + return v.value +} + +func (v *NullableCreateInternetServiceRequest) Set(val *CreateInternetServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateInternetServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateInternetServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateInternetServiceRequest(val *CreateInternetServiceRequest) *NullableCreateInternetServiceRequest { + return &NullableCreateInternetServiceRequest{value: val, isSet: true} +} + +func (v NullableCreateInternetServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateInternetServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go new file mode 100644 index 000000000..5290f8ce4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateInternetServiceResponse struct for CreateInternetServiceResponse +type CreateInternetServiceResponse struct { + InternetService *InternetService `json:"InternetService,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateInternetServiceResponse instantiates a new CreateInternetServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateInternetServiceResponse() *CreateInternetServiceResponse { + this := CreateInternetServiceResponse{} + return &this +} + +// NewCreateInternetServiceResponseWithDefaults instantiates a new CreateInternetServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateInternetServiceResponseWithDefaults() *CreateInternetServiceResponse { + this := CreateInternetServiceResponse{} + return &this +} + +// GetInternetService returns the InternetService field value if set, zero value otherwise. +func (o *CreateInternetServiceResponse) GetInternetService() InternetService { + if o == nil || o.InternetService == nil { + var ret InternetService + return ret + } + return *o.InternetService +} + +// GetInternetServiceOk returns a tuple with the InternetService field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateInternetServiceResponse) GetInternetServiceOk() (*InternetService, bool) { + if o == nil || o.InternetService == nil { + return nil, false + } + return o.InternetService, true +} + +// HasInternetService returns a boolean if a field has been set. +func (o *CreateInternetServiceResponse) HasInternetService() bool { + if o != nil && o.InternetService != nil { + return true + } + + return false +} + +// SetInternetService gets a reference to the given InternetService and assigns it to the InternetService field. +func (o *CreateInternetServiceResponse) SetInternetService(v InternetService) { + o.InternetService = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateInternetServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateInternetServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateInternetServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateInternetServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateInternetServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.InternetService != nil { + toSerialize["InternetService"] = o.InternetService + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateInternetServiceResponse struct { + value *CreateInternetServiceResponse + isSet bool +} + +func (v NullableCreateInternetServiceResponse) Get() *CreateInternetServiceResponse { + return v.value +} + +func (v *NullableCreateInternetServiceResponse) Set(val *CreateInternetServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateInternetServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateInternetServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateInternetServiceResponse(val *CreateInternetServiceResponse) *NullableCreateInternetServiceResponse { + return &NullableCreateInternetServiceResponse{value: val, isSet: true} +} + +func (v NullableCreateInternetServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateInternetServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go new file mode 100644 index 000000000..bded5bd2a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateKeypairRequest struct for CreateKeypairRequest +type CreateKeypairRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // A unique name for the keypair, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). + KeypairName string `json:"KeypairName"` + // The public key. It must be base64-encoded. + PublicKey *string `json:"PublicKey,omitempty"` +} + +// NewCreateKeypairRequest instantiates a new CreateKeypairRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateKeypairRequest(keypairName string, ) *CreateKeypairRequest { + this := CreateKeypairRequest{} + this.KeypairName = keypairName + return &this +} + +// NewCreateKeypairRequestWithDefaults instantiates a new CreateKeypairRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateKeypairRequestWithDefaults() *CreateKeypairRequest { + this := CreateKeypairRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateKeypairRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateKeypairRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateKeypairRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateKeypairRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetKeypairName returns the KeypairName field value +func (o *CreateKeypairRequest) GetKeypairName() string { + if o == nil { + var ret string + return ret + } + + return o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value +// and a boolean to check if the value has been set. +func (o *CreateKeypairRequest) GetKeypairNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.KeypairName, true +} + +// SetKeypairName sets field value +func (o *CreateKeypairRequest) SetKeypairName(v string) { + o.KeypairName = v +} + +// GetPublicKey returns the PublicKey field value if set, zero value otherwise. +func (o *CreateKeypairRequest) GetPublicKey() string { + if o == nil || o.PublicKey == nil { + var ret string + return ret + } + return *o.PublicKey +} + +// GetPublicKeyOk returns a tuple with the PublicKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateKeypairRequest) GetPublicKeyOk() (*string, bool) { + if o == nil || o.PublicKey == nil { + return nil, false + } + return o.PublicKey, true +} + +// HasPublicKey returns a boolean if a field has been set. +func (o *CreateKeypairRequest) HasPublicKey() bool { + if o != nil && o.PublicKey != nil { + return true + } + + return false +} + +// SetPublicKey gets a reference to the given string and assigns it to the PublicKey field. +func (o *CreateKeypairRequest) SetPublicKey(v string) { + o.PublicKey = &v +} + +func (o CreateKeypairRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["KeypairName"] = o.KeypairName + } + if o.PublicKey != nil { + toSerialize["PublicKey"] = o.PublicKey + } + return json.Marshal(toSerialize) +} + +type NullableCreateKeypairRequest struct { + value *CreateKeypairRequest + isSet bool +} + +func (v NullableCreateKeypairRequest) Get() *CreateKeypairRequest { + return v.value +} + +func (v *NullableCreateKeypairRequest) Set(val *CreateKeypairRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateKeypairRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateKeypairRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateKeypairRequest(val *CreateKeypairRequest) *NullableCreateKeypairRequest { + return &NullableCreateKeypairRequest{value: val, isSet: true} +} + +func (v NullableCreateKeypairRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateKeypairRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go new file mode 100644 index 000000000..66926ac56 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateKeypairResponse struct for CreateKeypairResponse +type CreateKeypairResponse struct { + Keypair *KeypairCreated `json:"Keypair,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateKeypairResponse instantiates a new CreateKeypairResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateKeypairResponse() *CreateKeypairResponse { + this := CreateKeypairResponse{} + return &this +} + +// NewCreateKeypairResponseWithDefaults instantiates a new CreateKeypairResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateKeypairResponseWithDefaults() *CreateKeypairResponse { + this := CreateKeypairResponse{} + return &this +} + +// GetKeypair returns the Keypair field value if set, zero value otherwise. +func (o *CreateKeypairResponse) GetKeypair() KeypairCreated { + if o == nil || o.Keypair == nil { + var ret KeypairCreated + return ret + } + return *o.Keypair +} + +// GetKeypairOk returns a tuple with the Keypair field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateKeypairResponse) GetKeypairOk() (*KeypairCreated, bool) { + if o == nil || o.Keypair == nil { + return nil, false + } + return o.Keypair, true +} + +// HasKeypair returns a boolean if a field has been set. +func (o *CreateKeypairResponse) HasKeypair() bool { + if o != nil && o.Keypair != nil { + return true + } + + return false +} + +// SetKeypair gets a reference to the given KeypairCreated and assigns it to the Keypair field. +func (o *CreateKeypairResponse) SetKeypair(v KeypairCreated) { + o.Keypair = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateKeypairResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateKeypairResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateKeypairResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateKeypairResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateKeypairResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Keypair != nil { + toSerialize["Keypair"] = o.Keypair + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateKeypairResponse struct { + value *CreateKeypairResponse + isSet bool +} + +func (v NullableCreateKeypairResponse) Get() *CreateKeypairResponse { + return v.value +} + +func (v *NullableCreateKeypairResponse) Set(val *CreateKeypairResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateKeypairResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateKeypairResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateKeypairResponse(val *CreateKeypairResponse) *NullableCreateKeypairResponse { + return &NullableCreateKeypairResponse{value: val, isSet: true} +} + +func (v NullableCreateKeypairResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateKeypairResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go new file mode 100644 index 000000000..9f9508b40 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go @@ -0,0 +1,205 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateListenerRuleRequest struct for CreateListenerRuleRequest +type CreateListenerRuleRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Listener LoadBalancerLight `json:"Listener"` + ListenerRule ListenerRuleForCreation `json:"ListenerRule"` + // The IDs of the backend VMs. + VmIds []string `json:"VmIds"` +} + +// NewCreateListenerRuleRequest instantiates a new CreateListenerRuleRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateListenerRuleRequest(listener LoadBalancerLight, listenerRule ListenerRuleForCreation, vmIds []string, ) *CreateListenerRuleRequest { + this := CreateListenerRuleRequest{} + this.Listener = listener + this.ListenerRule = listenerRule + this.VmIds = vmIds + return &this +} + +// NewCreateListenerRuleRequestWithDefaults instantiates a new CreateListenerRuleRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateListenerRuleRequestWithDefaults() *CreateListenerRuleRequest { + this := CreateListenerRuleRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateListenerRuleRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateListenerRuleRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateListenerRuleRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetListener returns the Listener field value +func (o *CreateListenerRuleRequest) GetListener() LoadBalancerLight { + if o == nil { + var ret LoadBalancerLight + return ret + } + + return o.Listener +} + +// GetListenerOk returns a tuple with the Listener field value +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleRequest) GetListenerOk() (*LoadBalancerLight, bool) { + if o == nil { + return nil, false + } + return &o.Listener, true +} + +// SetListener sets field value +func (o *CreateListenerRuleRequest) SetListener(v LoadBalancerLight) { + o.Listener = v +} + +// GetListenerRule returns the ListenerRule field value +func (o *CreateListenerRuleRequest) GetListenerRule() ListenerRuleForCreation { + if o == nil { + var ret ListenerRuleForCreation + return ret + } + + return o.ListenerRule +} + +// GetListenerRuleOk returns a tuple with the ListenerRule field value +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleRequest) GetListenerRuleOk() (*ListenerRuleForCreation, bool) { + if o == nil { + return nil, false + } + return &o.ListenerRule, true +} + +// SetListenerRule sets field value +func (o *CreateListenerRuleRequest) SetListenerRule(v ListenerRuleForCreation) { + o.ListenerRule = v +} + +// GetVmIds returns the VmIds field value +func (o *CreateListenerRuleRequest) GetVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleRequest) GetVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.VmIds, true +} + +// SetVmIds sets field value +func (o *CreateListenerRuleRequest) SetVmIds(v []string) { + o.VmIds = v +} + +func (o CreateListenerRuleRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Listener"] = o.Listener + } + if true { + toSerialize["ListenerRule"] = o.ListenerRule + } + if true { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableCreateListenerRuleRequest struct { + value *CreateListenerRuleRequest + isSet bool +} + +func (v NullableCreateListenerRuleRequest) Get() *CreateListenerRuleRequest { + return v.value +} + +func (v *NullableCreateListenerRuleRequest) Set(val *CreateListenerRuleRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateListenerRuleRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateListenerRuleRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateListenerRuleRequest(val *CreateListenerRuleRequest) *NullableCreateListenerRuleRequest { + return &NullableCreateListenerRuleRequest{value: val, isSet: true} +} + +func (v NullableCreateListenerRuleRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateListenerRuleRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go new file mode 100644 index 000000000..bd25863bd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateListenerRuleResponse struct for CreateListenerRuleResponse +type CreateListenerRuleResponse struct { + ListenerRule *ListenerRule `json:"ListenerRule,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateListenerRuleResponse instantiates a new CreateListenerRuleResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateListenerRuleResponse() *CreateListenerRuleResponse { + this := CreateListenerRuleResponse{} + return &this +} + +// NewCreateListenerRuleResponseWithDefaults instantiates a new CreateListenerRuleResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateListenerRuleResponseWithDefaults() *CreateListenerRuleResponse { + this := CreateListenerRuleResponse{} + return &this +} + +// GetListenerRule returns the ListenerRule field value if set, zero value otherwise. +func (o *CreateListenerRuleResponse) GetListenerRule() ListenerRule { + if o == nil || o.ListenerRule == nil { + var ret ListenerRule + return ret + } + return *o.ListenerRule +} + +// GetListenerRuleOk returns a tuple with the ListenerRule field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleResponse) GetListenerRuleOk() (*ListenerRule, bool) { + if o == nil || o.ListenerRule == nil { + return nil, false + } + return o.ListenerRule, true +} + +// HasListenerRule returns a boolean if a field has been set. +func (o *CreateListenerRuleResponse) HasListenerRule() bool { + if o != nil && o.ListenerRule != nil { + return true + } + + return false +} + +// SetListenerRule gets a reference to the given ListenerRule and assigns it to the ListenerRule field. +func (o *CreateListenerRuleResponse) SetListenerRule(v ListenerRule) { + o.ListenerRule = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateListenerRuleResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateListenerRuleResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateListenerRuleResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateListenerRuleResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateListenerRuleResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ListenerRule != nil { + toSerialize["ListenerRule"] = o.ListenerRule + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateListenerRuleResponse struct { + value *CreateListenerRuleResponse + isSet bool +} + +func (v NullableCreateListenerRuleResponse) Get() *CreateListenerRuleResponse { + return v.value +} + +func (v *NullableCreateListenerRuleResponse) Set(val *CreateListenerRuleResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateListenerRuleResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateListenerRuleResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateListenerRuleResponse(val *CreateListenerRuleResponse) *NullableCreateListenerRuleResponse { + return &NullableCreateListenerRuleResponse{value: val, isSet: true} +} + +func (v NullableCreateListenerRuleResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateListenerRuleResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go new file mode 100644 index 000000000..ae96ef2f4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerListenersRequest struct for CreateLoadBalancerListenersRequest +type CreateLoadBalancerListenersRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more listeners for the load balancer. + Listeners []ListenerForCreation `json:"Listeners"` + // The name of the load balancer for which you want to create listeners. + LoadBalancerName string `json:"LoadBalancerName"` +} + +// NewCreateLoadBalancerListenersRequest instantiates a new CreateLoadBalancerListenersRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerListenersRequest(listeners []ListenerForCreation, loadBalancerName string, ) *CreateLoadBalancerListenersRequest { + this := CreateLoadBalancerListenersRequest{} + this.Listeners = listeners + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewCreateLoadBalancerListenersRequestWithDefaults instantiates a new CreateLoadBalancerListenersRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerListenersRequestWithDefaults() *CreateLoadBalancerListenersRequest { + this := CreateLoadBalancerListenersRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateLoadBalancerListenersRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerListenersRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateLoadBalancerListenersRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateLoadBalancerListenersRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetListeners returns the Listeners field value +func (o *CreateLoadBalancerListenersRequest) GetListeners() []ListenerForCreation { + if o == nil { + var ret []ListenerForCreation + return ret + } + + return o.Listeners +} + +// GetListenersOk returns a tuple with the Listeners field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerListenersRequest) GetListenersOk() (*[]ListenerForCreation, bool) { + if o == nil { + return nil, false + } + return &o.Listeners, true +} + +// SetListeners sets field value +func (o *CreateLoadBalancerListenersRequest) SetListeners(v []ListenerForCreation) { + o.Listeners = v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *CreateLoadBalancerListenersRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerListenersRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *CreateLoadBalancerListenersRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +func (o CreateLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Listeners"] = o.Listeners + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerListenersRequest struct { + value *CreateLoadBalancerListenersRequest + isSet bool +} + +func (v NullableCreateLoadBalancerListenersRequest) Get() *CreateLoadBalancerListenersRequest { + return v.value +} + +func (v *NullableCreateLoadBalancerListenersRequest) Set(val *CreateLoadBalancerListenersRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerListenersRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerListenersRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerListenersRequest(val *CreateLoadBalancerListenersRequest) *NullableCreateLoadBalancerListenersRequest { + return &NullableCreateLoadBalancerListenersRequest{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerListenersRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go new file mode 100644 index 000000000..7501df03e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerListenersResponse struct for CreateLoadBalancerListenersResponse +type CreateLoadBalancerListenersResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateLoadBalancerListenersResponse instantiates a new CreateLoadBalancerListenersResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerListenersResponse() *CreateLoadBalancerListenersResponse { + this := CreateLoadBalancerListenersResponse{} + return &this +} + +// NewCreateLoadBalancerListenersResponseWithDefaults instantiates a new CreateLoadBalancerListenersResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerListenersResponseWithDefaults() *CreateLoadBalancerListenersResponse { + this := CreateLoadBalancerListenersResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *CreateLoadBalancerListenersResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerListenersResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *CreateLoadBalancerListenersResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *CreateLoadBalancerListenersResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateLoadBalancerListenersResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerListenersResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateLoadBalancerListenersResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateLoadBalancerListenersResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerListenersResponse struct { + value *CreateLoadBalancerListenersResponse + isSet bool +} + +func (v NullableCreateLoadBalancerListenersResponse) Get() *CreateLoadBalancerListenersResponse { + return v.value +} + +func (v *NullableCreateLoadBalancerListenersResponse) Set(val *CreateLoadBalancerListenersResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerListenersResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerListenersResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerListenersResponse(val *CreateLoadBalancerListenersResponse) *NullableCreateLoadBalancerListenersResponse { + return &NullableCreateLoadBalancerListenersResponse{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerListenersResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go new file mode 100644 index 000000000..60551c7d3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go @@ -0,0 +1,244 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerPolicyRequest struct for CreateLoadBalancerPolicyRequest +type CreateLoadBalancerPolicyRequest struct { + // The name of the application cookie used for stickiness. This parameter is required if you create a stickiness policy based on an application-generated cookie. + CookieName *string `json:"CookieName,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer for which you want to create a policy. + LoadBalancerName string `json:"LoadBalancerName"` + // The name of the policy. This name must be unique and consist of alphanumeric characters and dashes (-). + PolicyName string `json:"PolicyName"` + // The type of stickiness policy you want to create: `app` or `load_balancer`. + PolicyType string `json:"PolicyType"` +} + +// NewCreateLoadBalancerPolicyRequest instantiates a new CreateLoadBalancerPolicyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerPolicyRequest(loadBalancerName string, policyName string, policyType string, ) *CreateLoadBalancerPolicyRequest { + this := CreateLoadBalancerPolicyRequest{} + this.LoadBalancerName = loadBalancerName + this.PolicyName = policyName + this.PolicyType = policyType + return &this +} + +// NewCreateLoadBalancerPolicyRequestWithDefaults instantiates a new CreateLoadBalancerPolicyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerPolicyRequestWithDefaults() *CreateLoadBalancerPolicyRequest { + this := CreateLoadBalancerPolicyRequest{} + return &this +} + +// GetCookieName returns the CookieName field value if set, zero value otherwise. +func (o *CreateLoadBalancerPolicyRequest) GetCookieName() string { + if o == nil || o.CookieName == nil { + var ret string + return ret + } + return *o.CookieName +} + +// GetCookieNameOk returns a tuple with the CookieName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyRequest) GetCookieNameOk() (*string, bool) { + if o == nil || o.CookieName == nil { + return nil, false + } + return o.CookieName, true +} + +// HasCookieName returns a boolean if a field has been set. +func (o *CreateLoadBalancerPolicyRequest) HasCookieName() bool { + if o != nil && o.CookieName != nil { + return true + } + + return false +} + +// SetCookieName gets a reference to the given string and assigns it to the CookieName field. +func (o *CreateLoadBalancerPolicyRequest) SetCookieName(v string) { + o.CookieName = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateLoadBalancerPolicyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateLoadBalancerPolicyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateLoadBalancerPolicyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *CreateLoadBalancerPolicyRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *CreateLoadBalancerPolicyRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetPolicyName returns the PolicyName field value +func (o *CreateLoadBalancerPolicyRequest) GetPolicyName() string { + if o == nil { + var ret string + return ret + } + + return o.PolicyName +} + +// GetPolicyNameOk returns a tuple with the PolicyName field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyRequest) GetPolicyNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PolicyName, true +} + +// SetPolicyName sets field value +func (o *CreateLoadBalancerPolicyRequest) SetPolicyName(v string) { + o.PolicyName = v +} + +// GetPolicyType returns the PolicyType field value +func (o *CreateLoadBalancerPolicyRequest) GetPolicyType() string { + if o == nil { + var ret string + return ret + } + + return o.PolicyType +} + +// GetPolicyTypeOk returns a tuple with the PolicyType field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyRequest) GetPolicyTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PolicyType, true +} + +// SetPolicyType sets field value +func (o *CreateLoadBalancerPolicyRequest) SetPolicyType(v string) { + o.PolicyType = v +} + +func (o CreateLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.CookieName != nil { + toSerialize["CookieName"] = o.CookieName + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if true { + toSerialize["PolicyName"] = o.PolicyName + } + if true { + toSerialize["PolicyType"] = o.PolicyType + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerPolicyRequest struct { + value *CreateLoadBalancerPolicyRequest + isSet bool +} + +func (v NullableCreateLoadBalancerPolicyRequest) Get() *CreateLoadBalancerPolicyRequest { + return v.value +} + +func (v *NullableCreateLoadBalancerPolicyRequest) Set(val *CreateLoadBalancerPolicyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerPolicyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerPolicyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerPolicyRequest(val *CreateLoadBalancerPolicyRequest) *NullableCreateLoadBalancerPolicyRequest { + return &NullableCreateLoadBalancerPolicyRequest{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerPolicyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go new file mode 100644 index 000000000..dcaba659e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerPolicyResponse struct for CreateLoadBalancerPolicyResponse +type CreateLoadBalancerPolicyResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateLoadBalancerPolicyResponse instantiates a new CreateLoadBalancerPolicyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerPolicyResponse() *CreateLoadBalancerPolicyResponse { + this := CreateLoadBalancerPolicyResponse{} + return &this +} + +// NewCreateLoadBalancerPolicyResponseWithDefaults instantiates a new CreateLoadBalancerPolicyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerPolicyResponseWithDefaults() *CreateLoadBalancerPolicyResponse { + this := CreateLoadBalancerPolicyResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *CreateLoadBalancerPolicyResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *CreateLoadBalancerPolicyResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *CreateLoadBalancerPolicyResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateLoadBalancerPolicyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerPolicyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateLoadBalancerPolicyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateLoadBalancerPolicyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerPolicyResponse struct { + value *CreateLoadBalancerPolicyResponse + isSet bool +} + +func (v NullableCreateLoadBalancerPolicyResponse) Get() *CreateLoadBalancerPolicyResponse { + return v.value +} + +func (v *NullableCreateLoadBalancerPolicyResponse) Set(val *CreateLoadBalancerPolicyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerPolicyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerPolicyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerPolicyResponse(val *CreateLoadBalancerPolicyResponse) *NullableCreateLoadBalancerPolicyResponse { + return &NullableCreateLoadBalancerPolicyResponse{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerPolicyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go new file mode 100644 index 000000000..48a51d107 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go @@ -0,0 +1,362 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerRequest struct for CreateLoadBalancerRequest +type CreateLoadBalancerRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more listeners to create. + Listeners []ListenerForCreation `json:"Listeners"` + // The unique name of the load balancer (32 alphanumeric or hyphen characters maximum, but cannot start or end with a hyphen). + LoadBalancerName string `json:"LoadBalancerName"` + // The type of load balancer: `internet-facing` or `internal`. Use this parameter only for load balancers in a Net. + LoadBalancerType *string `json:"LoadBalancerType,omitempty"` + // (Net only) One or more IDs of security groups you want to assign to the load balancer. If not specified, the default security group of the Net is assigned to the load balancer. + SecurityGroups *[]string `json:"SecurityGroups,omitempty"` + // One or more IDs of Subnets in your Net that you want to attach to the load balancer. + Subnets *[]string `json:"Subnets,omitempty"` + // One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `LoadBalancerType` parameter. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // One or more tags assigned to the load balancer. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewCreateLoadBalancerRequest instantiates a new CreateLoadBalancerRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerRequest(listeners []ListenerForCreation, loadBalancerName string, ) *CreateLoadBalancerRequest { + this := CreateLoadBalancerRequest{} + this.Listeners = listeners + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewCreateLoadBalancerRequestWithDefaults instantiates a new CreateLoadBalancerRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerRequestWithDefaults() *CreateLoadBalancerRequest { + this := CreateLoadBalancerRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateLoadBalancerRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetListeners returns the Listeners field value +func (o *CreateLoadBalancerRequest) GetListeners() []ListenerForCreation { + if o == nil { + var ret []ListenerForCreation + return ret + } + + return o.Listeners +} + +// GetListenersOk returns a tuple with the Listeners field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetListenersOk() (*[]ListenerForCreation, bool) { + if o == nil { + return nil, false + } + return &o.Listeners, true +} + +// SetListeners sets field value +func (o *CreateLoadBalancerRequest) SetListeners(v []ListenerForCreation) { + o.Listeners = v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *CreateLoadBalancerRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *CreateLoadBalancerRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetLoadBalancerType returns the LoadBalancerType field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetLoadBalancerType() string { + if o == nil || o.LoadBalancerType == nil { + var ret string + return ret + } + return *o.LoadBalancerType +} + +// GetLoadBalancerTypeOk returns a tuple with the LoadBalancerType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetLoadBalancerTypeOk() (*string, bool) { + if o == nil || o.LoadBalancerType == nil { + return nil, false + } + return o.LoadBalancerType, true +} + +// HasLoadBalancerType returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasLoadBalancerType() bool { + if o != nil && o.LoadBalancerType != nil { + return true + } + + return false +} + +// SetLoadBalancerType gets a reference to the given string and assigns it to the LoadBalancerType field. +func (o *CreateLoadBalancerRequest) SetLoadBalancerType(v string) { + o.LoadBalancerType = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetSecurityGroups() []string { + if o == nil || o.SecurityGroups == nil { + var ret []string + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetSecurityGroupsOk() (*[]string, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. +func (o *CreateLoadBalancerRequest) SetSecurityGroups(v []string) { + o.SecurityGroups = &v +} + +// GetSubnets returns the Subnets field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetSubnets() []string { + if o == nil || o.Subnets == nil { + var ret []string + return ret + } + return *o.Subnets +} + +// GetSubnetsOk returns a tuple with the Subnets field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetSubnetsOk() (*[]string, bool) { + if o == nil || o.Subnets == nil { + return nil, false + } + return o.Subnets, true +} + +// HasSubnets returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasSubnets() bool { + if o != nil && o.Subnets != nil { + return true + } + + return false +} + +// SetSubnets gets a reference to the given []string and assigns it to the Subnets field. +func (o *CreateLoadBalancerRequest) SetSubnets(v []string) { + o.Subnets = &v +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *CreateLoadBalancerRequest) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *CreateLoadBalancerRequest) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerRequest) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *CreateLoadBalancerRequest) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *CreateLoadBalancerRequest) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o CreateLoadBalancerRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Listeners"] = o.Listeners + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if o.LoadBalancerType != nil { + toSerialize["LoadBalancerType"] = o.LoadBalancerType + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.Subnets != nil { + toSerialize["Subnets"] = o.Subnets + } + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerRequest struct { + value *CreateLoadBalancerRequest + isSet bool +} + +func (v NullableCreateLoadBalancerRequest) Get() *CreateLoadBalancerRequest { + return v.value +} + +func (v *NullableCreateLoadBalancerRequest) Set(val *CreateLoadBalancerRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerRequest(val *CreateLoadBalancerRequest) *NullableCreateLoadBalancerRequest { + return &NullableCreateLoadBalancerRequest{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go new file mode 100644 index 000000000..da425d8ee --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerResponse struct for CreateLoadBalancerResponse +type CreateLoadBalancerResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateLoadBalancerResponse instantiates a new CreateLoadBalancerResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerResponse() *CreateLoadBalancerResponse { + this := CreateLoadBalancerResponse{} + return &this +} + +// NewCreateLoadBalancerResponseWithDefaults instantiates a new CreateLoadBalancerResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerResponseWithDefaults() *CreateLoadBalancerResponse { + this := CreateLoadBalancerResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *CreateLoadBalancerResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *CreateLoadBalancerResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *CreateLoadBalancerResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateLoadBalancerResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateLoadBalancerResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateLoadBalancerResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateLoadBalancerResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerResponse struct { + value *CreateLoadBalancerResponse + isSet bool +} + +func (v NullableCreateLoadBalancerResponse) Get() *CreateLoadBalancerResponse { + return v.value +} + +func (v *NullableCreateLoadBalancerResponse) Set(val *CreateLoadBalancerResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerResponse(val *CreateLoadBalancerResponse) *NullableCreateLoadBalancerResponse { + return &NullableCreateLoadBalancerResponse{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go new file mode 100644 index 000000000..d733a986d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerTagsRequest struct for CreateLoadBalancerTagsRequest +type CreateLoadBalancerTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more load balancer names. + LoadBalancerNames []string `json:"LoadBalancerNames"` + // One or more tags to add to the specified load balancers. + Tags []ResourceTag `json:"Tags"` +} + +// NewCreateLoadBalancerTagsRequest instantiates a new CreateLoadBalancerTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerTagsRequest(loadBalancerNames []string, tags []ResourceTag, ) *CreateLoadBalancerTagsRequest { + this := CreateLoadBalancerTagsRequest{} + this.LoadBalancerNames = loadBalancerNames + this.Tags = tags + return &this +} + +// NewCreateLoadBalancerTagsRequestWithDefaults instantiates a new CreateLoadBalancerTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerTagsRequestWithDefaults() *CreateLoadBalancerTagsRequest { + this := CreateLoadBalancerTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateLoadBalancerTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateLoadBalancerTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateLoadBalancerTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerNames returns the LoadBalancerNames field value +func (o *CreateLoadBalancerTagsRequest) GetLoadBalancerNames() []string { + if o == nil { + var ret []string + return ret + } + + return o.LoadBalancerNames +} + +// GetLoadBalancerNamesOk returns a tuple with the LoadBalancerNames field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerTagsRequest) GetLoadBalancerNamesOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerNames, true +} + +// SetLoadBalancerNames sets field value +func (o *CreateLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { + o.LoadBalancerNames = v +} + +// GetTags returns the Tags field value +func (o *CreateLoadBalancerTagsRequest) GetTags() []ResourceTag { + if o == nil { + var ret []ResourceTag + return ret + } + + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerTagsRequest) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil { + return nil, false + } + return &o.Tags, true +} + +// SetTags sets field value +func (o *CreateLoadBalancerTagsRequest) SetTags(v []ResourceTag) { + o.Tags = v +} + +func (o CreateLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerNames"] = o.LoadBalancerNames + } + if true { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerTagsRequest struct { + value *CreateLoadBalancerTagsRequest + isSet bool +} + +func (v NullableCreateLoadBalancerTagsRequest) Get() *CreateLoadBalancerTagsRequest { + return v.value +} + +func (v *NullableCreateLoadBalancerTagsRequest) Set(val *CreateLoadBalancerTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerTagsRequest(val *CreateLoadBalancerTagsRequest) *NullableCreateLoadBalancerTagsRequest { + return &NullableCreateLoadBalancerTagsRequest{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go new file mode 100644 index 000000000..23b6044e9 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateLoadBalancerTagsResponse struct for CreateLoadBalancerTagsResponse +type CreateLoadBalancerTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateLoadBalancerTagsResponse instantiates a new CreateLoadBalancerTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateLoadBalancerTagsResponse() *CreateLoadBalancerTagsResponse { + this := CreateLoadBalancerTagsResponse{} + return &this +} + +// NewCreateLoadBalancerTagsResponseWithDefaults instantiates a new CreateLoadBalancerTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateLoadBalancerTagsResponseWithDefaults() *CreateLoadBalancerTagsResponse { + this := CreateLoadBalancerTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateLoadBalancerTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateLoadBalancerTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateLoadBalancerTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateLoadBalancerTagsResponse struct { + value *CreateLoadBalancerTagsResponse + isSet bool +} + +func (v NullableCreateLoadBalancerTagsResponse) Get() *CreateLoadBalancerTagsResponse { + return v.value +} + +func (v *NullableCreateLoadBalancerTagsResponse) Set(val *CreateLoadBalancerTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateLoadBalancerTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateLoadBalancerTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateLoadBalancerTagsResponse(val *CreateLoadBalancerTagsResponse) *NullableCreateLoadBalancerTagsResponse { + return &NullableCreateLoadBalancerTagsResponse{value: val, isSet: true} +} + +func (v NullableCreateLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go new file mode 100644 index 000000000..5845b3ba0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNatServiceRequest struct for CreateNatServiceRequest +type CreateNatServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The allocation ID of the EIP to associate with the NAT service.
If the EIP is already associated with another resource, you must first disassociate it. + PublicIpId string `json:"PublicIpId"` + // The ID of the Subnet in which you want to create the NAT service. + SubnetId string `json:"SubnetId"` +} + +// NewCreateNatServiceRequest instantiates a new CreateNatServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNatServiceRequest(publicIpId string, subnetId string, ) *CreateNatServiceRequest { + this := CreateNatServiceRequest{} + this.PublicIpId = publicIpId + this.SubnetId = subnetId + return &this +} + +// NewCreateNatServiceRequestWithDefaults instantiates a new CreateNatServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNatServiceRequestWithDefaults() *CreateNatServiceRequest { + this := CreateNatServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateNatServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNatServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateNatServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateNatServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPublicIpId returns the PublicIpId field value +func (o *CreateNatServiceRequest) GetPublicIpId() string { + if o == nil { + var ret string + return ret + } + + return o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value +// and a boolean to check if the value has been set. +func (o *CreateNatServiceRequest) GetPublicIpIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PublicIpId, true +} + +// SetPublicIpId sets field value +func (o *CreateNatServiceRequest) SetPublicIpId(v string) { + o.PublicIpId = v +} + +// GetSubnetId returns the SubnetId field value +func (o *CreateNatServiceRequest) GetSubnetId() string { + if o == nil { + var ret string + return ret + } + + return o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value +// and a boolean to check if the value has been set. +func (o *CreateNatServiceRequest) GetSubnetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubnetId, true +} + +// SetSubnetId sets field value +func (o *CreateNatServiceRequest) SetSubnetId(v string) { + o.SubnetId = v +} + +func (o CreateNatServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["PublicIpId"] = o.PublicIpId + } + if true { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableCreateNatServiceRequest struct { + value *CreateNatServiceRequest + isSet bool +} + +func (v NullableCreateNatServiceRequest) Get() *CreateNatServiceRequest { + return v.value +} + +func (v *NullableCreateNatServiceRequest) Set(val *CreateNatServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNatServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNatServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNatServiceRequest(val *CreateNatServiceRequest) *NullableCreateNatServiceRequest { + return &NullableCreateNatServiceRequest{value: val, isSet: true} +} + +func (v NullableCreateNatServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNatServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go new file mode 100644 index 000000000..7260dc59d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNatServiceResponse struct for CreateNatServiceResponse +type CreateNatServiceResponse struct { + NatService *NatService `json:"NatService,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateNatServiceResponse instantiates a new CreateNatServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNatServiceResponse() *CreateNatServiceResponse { + this := CreateNatServiceResponse{} + return &this +} + +// NewCreateNatServiceResponseWithDefaults instantiates a new CreateNatServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNatServiceResponseWithDefaults() *CreateNatServiceResponse { + this := CreateNatServiceResponse{} + return &this +} + +// GetNatService returns the NatService field value if set, zero value otherwise. +func (o *CreateNatServiceResponse) GetNatService() NatService { + if o == nil || o.NatService == nil { + var ret NatService + return ret + } + return *o.NatService +} + +// GetNatServiceOk returns a tuple with the NatService field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNatServiceResponse) GetNatServiceOk() (*NatService, bool) { + if o == nil || o.NatService == nil { + return nil, false + } + return o.NatService, true +} + +// HasNatService returns a boolean if a field has been set. +func (o *CreateNatServiceResponse) HasNatService() bool { + if o != nil && o.NatService != nil { + return true + } + + return false +} + +// SetNatService gets a reference to the given NatService and assigns it to the NatService field. +func (o *CreateNatServiceResponse) SetNatService(v NatService) { + o.NatService = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateNatServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNatServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateNatServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateNatServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateNatServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NatService != nil { + toSerialize["NatService"] = o.NatService + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateNatServiceResponse struct { + value *CreateNatServiceResponse + isSet bool +} + +func (v NullableCreateNatServiceResponse) Get() *CreateNatServiceResponse { + return v.value +} + +func (v *NullableCreateNatServiceResponse) Set(val *CreateNatServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNatServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNatServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNatServiceResponse(val *CreateNatServiceResponse) *NullableCreateNatServiceResponse { + return &NullableCreateNatServiceResponse{value: val, isSet: true} +} + +func (v NullableCreateNatServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNatServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go new file mode 100644 index 000000000..b7053320a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go @@ -0,0 +1,214 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetAccessPointRequest struct for CreateNetAccessPointRequest +type CreateNetAccessPointRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net. + NetId string `json:"NetId"` + // One or more IDs of route tables to use for the connection. + RouteTableIds *[]string `json:"RouteTableIds,omitempty"` + // The prefix list name corresponding to the service (for example, `com.outscale.eu-west-2.osu` for OSU). + ServiceName string `json:"ServiceName"` +} + +// NewCreateNetAccessPointRequest instantiates a new CreateNetAccessPointRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetAccessPointRequest(netId string, serviceName string, ) *CreateNetAccessPointRequest { + this := CreateNetAccessPointRequest{} + this.NetId = netId + this.ServiceName = serviceName + return &this +} + +// NewCreateNetAccessPointRequestWithDefaults instantiates a new CreateNetAccessPointRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetAccessPointRequestWithDefaults() *CreateNetAccessPointRequest { + this := CreateNetAccessPointRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateNetAccessPointRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateNetAccessPointRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateNetAccessPointRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *CreateNetAccessPointRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *CreateNetAccessPointRequest) SetNetId(v string) { + o.NetId = v +} + +// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. +func (o *CreateNetAccessPointRequest) GetRouteTableIds() []string { + if o == nil || o.RouteTableIds == nil { + var ret []string + return ret + } + return *o.RouteTableIds +} + +// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointRequest) GetRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.RouteTableIds == nil { + return nil, false + } + return o.RouteTableIds, true +} + +// HasRouteTableIds returns a boolean if a field has been set. +func (o *CreateNetAccessPointRequest) HasRouteTableIds() bool { + if o != nil && o.RouteTableIds != nil { + return true + } + + return false +} + +// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. +func (o *CreateNetAccessPointRequest) SetRouteTableIds(v []string) { + o.RouteTableIds = &v +} + +// GetServiceName returns the ServiceName field value +func (o *CreateNetAccessPointRequest) GetServiceName() string { + if o == nil { + var ret string + return ret + } + + return o.ServiceName +} + +// GetServiceNameOk returns a tuple with the ServiceName field value +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointRequest) GetServiceNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ServiceName, true +} + +// SetServiceName sets field value +func (o *CreateNetAccessPointRequest) SetServiceName(v string) { + o.ServiceName = v +} + +func (o CreateNetAccessPointRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + if o.RouteTableIds != nil { + toSerialize["RouteTableIds"] = o.RouteTableIds + } + if true { + toSerialize["ServiceName"] = o.ServiceName + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetAccessPointRequest struct { + value *CreateNetAccessPointRequest + isSet bool +} + +func (v NullableCreateNetAccessPointRequest) Get() *CreateNetAccessPointRequest { + return v.value +} + +func (v *NullableCreateNetAccessPointRequest) Set(val *CreateNetAccessPointRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetAccessPointRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetAccessPointRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetAccessPointRequest(val *CreateNetAccessPointRequest) *NullableCreateNetAccessPointRequest { + return &NullableCreateNetAccessPointRequest{value: val, isSet: true} +} + +func (v NullableCreateNetAccessPointRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetAccessPointRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go new file mode 100644 index 000000000..9ca9916d1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetAccessPointResponse struct for CreateNetAccessPointResponse +type CreateNetAccessPointResponse struct { + NetAccessPoint *NetAccessPoint `json:"NetAccessPoint,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateNetAccessPointResponse instantiates a new CreateNetAccessPointResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetAccessPointResponse() *CreateNetAccessPointResponse { + this := CreateNetAccessPointResponse{} + return &this +} + +// NewCreateNetAccessPointResponseWithDefaults instantiates a new CreateNetAccessPointResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetAccessPointResponseWithDefaults() *CreateNetAccessPointResponse { + this := CreateNetAccessPointResponse{} + return &this +} + +// GetNetAccessPoint returns the NetAccessPoint field value if set, zero value otherwise. +func (o *CreateNetAccessPointResponse) GetNetAccessPoint() NetAccessPoint { + if o == nil || o.NetAccessPoint == nil { + var ret NetAccessPoint + return ret + } + return *o.NetAccessPoint +} + +// GetNetAccessPointOk returns a tuple with the NetAccessPoint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointResponse) GetNetAccessPointOk() (*NetAccessPoint, bool) { + if o == nil || o.NetAccessPoint == nil { + return nil, false + } + return o.NetAccessPoint, true +} + +// HasNetAccessPoint returns a boolean if a field has been set. +func (o *CreateNetAccessPointResponse) HasNetAccessPoint() bool { + if o != nil && o.NetAccessPoint != nil { + return true + } + + return false +} + +// SetNetAccessPoint gets a reference to the given NetAccessPoint and assigns it to the NetAccessPoint field. +func (o *CreateNetAccessPointResponse) SetNetAccessPoint(v NetAccessPoint) { + o.NetAccessPoint = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateNetAccessPointResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetAccessPointResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateNetAccessPointResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateNetAccessPointResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateNetAccessPointResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetAccessPoint != nil { + toSerialize["NetAccessPoint"] = o.NetAccessPoint + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetAccessPointResponse struct { + value *CreateNetAccessPointResponse + isSet bool +} + +func (v NullableCreateNetAccessPointResponse) Get() *CreateNetAccessPointResponse { + return v.value +} + +func (v *NullableCreateNetAccessPointResponse) Set(val *CreateNetAccessPointResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetAccessPointResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetAccessPointResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetAccessPointResponse(val *CreateNetAccessPointResponse) *NullableCreateNetAccessPointResponse { + return &NullableCreateNetAccessPointResponse{value: val, isSet: true} +} + +func (v NullableCreateNetAccessPointResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetAccessPointResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go new file mode 100644 index 000000000..9f16649c7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetPeeringRequest struct for CreateNetPeeringRequest +type CreateNetPeeringRequest struct { + // The ID of the Net you want to connect with. + AccepterNetId string `json:"AccepterNetId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net you send the peering request from. + SourceNetId string `json:"SourceNetId"` +} + +// NewCreateNetPeeringRequest instantiates a new CreateNetPeeringRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetPeeringRequest(accepterNetId string, sourceNetId string, ) *CreateNetPeeringRequest { + this := CreateNetPeeringRequest{} + this.AccepterNetId = accepterNetId + this.SourceNetId = sourceNetId + return &this +} + +// NewCreateNetPeeringRequestWithDefaults instantiates a new CreateNetPeeringRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetPeeringRequestWithDefaults() *CreateNetPeeringRequest { + this := CreateNetPeeringRequest{} + return &this +} + +// GetAccepterNetId returns the AccepterNetId field value +func (o *CreateNetPeeringRequest) GetAccepterNetId() string { + if o == nil { + var ret string + return ret + } + + return o.AccepterNetId +} + +// GetAccepterNetIdOk returns a tuple with the AccepterNetId field value +// and a boolean to check if the value has been set. +func (o *CreateNetPeeringRequest) GetAccepterNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.AccepterNetId, true +} + +// SetAccepterNetId sets field value +func (o *CreateNetPeeringRequest) SetAccepterNetId(v string) { + o.AccepterNetId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateNetPeeringRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetPeeringRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateNetPeeringRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateNetPeeringRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetSourceNetId returns the SourceNetId field value +func (o *CreateNetPeeringRequest) GetSourceNetId() string { + if o == nil { + var ret string + return ret + } + + return o.SourceNetId +} + +// GetSourceNetIdOk returns a tuple with the SourceNetId field value +// and a boolean to check if the value has been set. +func (o *CreateNetPeeringRequest) GetSourceNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SourceNetId, true +} + +// SetSourceNetId sets field value +func (o *CreateNetPeeringRequest) SetSourceNetId(v string) { + o.SourceNetId = v +} + +func (o CreateNetPeeringRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["AccepterNetId"] = o.AccepterNetId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["SourceNetId"] = o.SourceNetId + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetPeeringRequest struct { + value *CreateNetPeeringRequest + isSet bool +} + +func (v NullableCreateNetPeeringRequest) Get() *CreateNetPeeringRequest { + return v.value +} + +func (v *NullableCreateNetPeeringRequest) Set(val *CreateNetPeeringRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetPeeringRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetPeeringRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetPeeringRequest(val *CreateNetPeeringRequest) *NullableCreateNetPeeringRequest { + return &NullableCreateNetPeeringRequest{value: val, isSet: true} +} + +func (v NullableCreateNetPeeringRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetPeeringRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go new file mode 100644 index 000000000..b9913eea0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetPeeringResponse struct for CreateNetPeeringResponse +type CreateNetPeeringResponse struct { + NetPeering *NetPeering `json:"NetPeering,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateNetPeeringResponse instantiates a new CreateNetPeeringResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetPeeringResponse() *CreateNetPeeringResponse { + this := CreateNetPeeringResponse{} + return &this +} + +// NewCreateNetPeeringResponseWithDefaults instantiates a new CreateNetPeeringResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetPeeringResponseWithDefaults() *CreateNetPeeringResponse { + this := CreateNetPeeringResponse{} + return &this +} + +// GetNetPeering returns the NetPeering field value if set, zero value otherwise. +func (o *CreateNetPeeringResponse) GetNetPeering() NetPeering { + if o == nil || o.NetPeering == nil { + var ret NetPeering + return ret + } + return *o.NetPeering +} + +// GetNetPeeringOk returns a tuple with the NetPeering field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetPeeringResponse) GetNetPeeringOk() (*NetPeering, bool) { + if o == nil || o.NetPeering == nil { + return nil, false + } + return o.NetPeering, true +} + +// HasNetPeering returns a boolean if a field has been set. +func (o *CreateNetPeeringResponse) HasNetPeering() bool { + if o != nil && o.NetPeering != nil { + return true + } + + return false +} + +// SetNetPeering gets a reference to the given NetPeering and assigns it to the NetPeering field. +func (o *CreateNetPeeringResponse) SetNetPeering(v NetPeering) { + o.NetPeering = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateNetPeeringResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetPeeringResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateNetPeeringResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateNetPeeringResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateNetPeeringResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetPeering != nil { + toSerialize["NetPeering"] = o.NetPeering + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetPeeringResponse struct { + value *CreateNetPeeringResponse + isSet bool +} + +func (v NullableCreateNetPeeringResponse) Get() *CreateNetPeeringResponse { + return v.value +} + +func (v *NullableCreateNetPeeringResponse) Set(val *CreateNetPeeringResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetPeeringResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetPeeringResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetPeeringResponse(val *CreateNetPeeringResponse) *NullableCreateNetPeeringResponse { + return &NullableCreateNetPeeringResponse{value: val, isSet: true} +} + +func (v NullableCreateNetPeeringResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetPeeringResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go new file mode 100644 index 000000000..5e5202721 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetRequest struct for CreateNetRequest +type CreateNetRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). + IpRange string `json:"IpRange"` + // The tenancy options for the VMs (`default` if a VM created in a Net can be launched with any tenancy, `dedicated` if it can be launched with dedicated tenancy VMs running on single-tenant hardware). + Tenancy *string `json:"Tenancy,omitempty"` +} + +// NewCreateNetRequest instantiates a new CreateNetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetRequest(ipRange string, ) *CreateNetRequest { + this := CreateNetRequest{} + this.IpRange = ipRange + return &this +} + +// NewCreateNetRequestWithDefaults instantiates a new CreateNetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetRequestWithDefaults() *CreateNetRequest { + this := CreateNetRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateNetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateNetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateNetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetIpRange returns the IpRange field value +func (o *CreateNetRequest) GetIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value +// and a boolean to check if the value has been set. +func (o *CreateNetRequest) GetIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.IpRange, true +} + +// SetIpRange sets field value +func (o *CreateNetRequest) SetIpRange(v string) { + o.IpRange = v +} + +// GetTenancy returns the Tenancy field value if set, zero value otherwise. +func (o *CreateNetRequest) GetTenancy() string { + if o == nil || o.Tenancy == nil { + var ret string + return ret + } + return *o.Tenancy +} + +// GetTenancyOk returns a tuple with the Tenancy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetRequest) GetTenancyOk() (*string, bool) { + if o == nil || o.Tenancy == nil { + return nil, false + } + return o.Tenancy, true +} + +// HasTenancy returns a boolean if a field has been set. +func (o *CreateNetRequest) HasTenancy() bool { + if o != nil && o.Tenancy != nil { + return true + } + + return false +} + +// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. +func (o *CreateNetRequest) SetTenancy(v string) { + o.Tenancy = &v +} + +func (o CreateNetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["IpRange"] = o.IpRange + } + if o.Tenancy != nil { + toSerialize["Tenancy"] = o.Tenancy + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetRequest struct { + value *CreateNetRequest + isSet bool +} + +func (v NullableCreateNetRequest) Get() *CreateNetRequest { + return v.value +} + +func (v *NullableCreateNetRequest) Set(val *CreateNetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetRequest(val *CreateNetRequest) *NullableCreateNetRequest { + return &NullableCreateNetRequest{value: val, isSet: true} +} + +func (v NullableCreateNetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go new file mode 100644 index 000000000..74131f17b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNetResponse struct for CreateNetResponse +type CreateNetResponse struct { + Net *Net `json:"Net,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateNetResponse instantiates a new CreateNetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNetResponse() *CreateNetResponse { + this := CreateNetResponse{} + return &this +} + +// NewCreateNetResponseWithDefaults instantiates a new CreateNetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNetResponseWithDefaults() *CreateNetResponse { + this := CreateNetResponse{} + return &this +} + +// GetNet returns the Net field value if set, zero value otherwise. +func (o *CreateNetResponse) GetNet() Net { + if o == nil || o.Net == nil { + var ret Net + return ret + } + return *o.Net +} + +// GetNetOk returns a tuple with the Net field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetResponse) GetNetOk() (*Net, bool) { + if o == nil || o.Net == nil { + return nil, false + } + return o.Net, true +} + +// HasNet returns a boolean if a field has been set. +func (o *CreateNetResponse) HasNet() bool { + if o != nil && o.Net != nil { + return true + } + + return false +} + +// SetNet gets a reference to the given Net and assigns it to the Net field. +func (o *CreateNetResponse) SetNet(v Net) { + o.Net = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateNetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateNetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateNetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateNetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Net != nil { + toSerialize["Net"] = o.Net + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateNetResponse struct { + value *CreateNetResponse + isSet bool +} + +func (v NullableCreateNetResponse) Get() *CreateNetResponse { + return v.value +} + +func (v *NullableCreateNetResponse) Set(val *CreateNetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNetResponse(val *CreateNetResponse) *NullableCreateNetResponse { + return &NullableCreateNetResponse{value: val, isSet: true} +} + +func (v NullableCreateNetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go new file mode 100644 index 000000000..be2425da3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go @@ -0,0 +1,258 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNicRequest struct for CreateNicRequest +type CreateNicRequest struct { + // A description for the NIC. + Description *string `json:"Description,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The primary private IP address for the NIC.

This IP address must be within the IP address range of the Subnet that you specify with the `SubnetId` attribute.
If you do not specify this attribute, a random private IP address is selected within the IP address range of the Subnet. + PrivateIps *[]PrivateIpLight `json:"PrivateIps,omitempty"` + // One or more IDs of security groups for the NIC. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` + // The ID of the Subnet in which you want to create the NIC. + SubnetId string `json:"SubnetId"` +} + +// NewCreateNicRequest instantiates a new CreateNicRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNicRequest(subnetId string, ) *CreateNicRequest { + this := CreateNicRequest{} + this.SubnetId = subnetId + return &this +} + +// NewCreateNicRequestWithDefaults instantiates a new CreateNicRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNicRequestWithDefaults() *CreateNicRequest { + this := CreateNicRequest{} + return &this +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *CreateNicRequest) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicRequest) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *CreateNicRequest) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *CreateNicRequest) SetDescription(v string) { + o.Description = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateNicRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateNicRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateNicRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *CreateNicRequest) GetPrivateIps() []PrivateIpLight { + if o == nil || o.PrivateIps == nil { + var ret []PrivateIpLight + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicRequest) GetPrivateIpsOk() (*[]PrivateIpLight, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *CreateNicRequest) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []PrivateIpLight and assigns it to the PrivateIps field. +func (o *CreateNicRequest) SetPrivateIps(v []PrivateIpLight) { + o.PrivateIps = &v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *CreateNicRequest) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicRequest) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *CreateNicRequest) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *CreateNicRequest) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +// GetSubnetId returns the SubnetId field value +func (o *CreateNicRequest) GetSubnetId() string { + if o == nil { + var ret string + return ret + } + + return o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value +// and a boolean to check if the value has been set. +func (o *CreateNicRequest) GetSubnetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubnetId, true +} + +// SetSubnetId sets field value +func (o *CreateNicRequest) SetSubnetId(v string) { + o.SubnetId = v +} + +func (o CreateNicRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + if true { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableCreateNicRequest struct { + value *CreateNicRequest + isSet bool +} + +func (v NullableCreateNicRequest) Get() *CreateNicRequest { + return v.value +} + +func (v *NullableCreateNicRequest) Set(val *CreateNicRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNicRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNicRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNicRequest(val *CreateNicRequest) *NullableCreateNicRequest { + return &NullableCreateNicRequest{value: val, isSet: true} +} + +func (v NullableCreateNicRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNicRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go new file mode 100644 index 000000000..370e671ba --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateNicResponse struct for CreateNicResponse +type CreateNicResponse struct { + Nic *Nic `json:"Nic,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateNicResponse instantiates a new CreateNicResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNicResponse() *CreateNicResponse { + this := CreateNicResponse{} + return &this +} + +// NewCreateNicResponseWithDefaults instantiates a new CreateNicResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNicResponseWithDefaults() *CreateNicResponse { + this := CreateNicResponse{} + return &this +} + +// GetNic returns the Nic field value if set, zero value otherwise. +func (o *CreateNicResponse) GetNic() Nic { + if o == nil || o.Nic == nil { + var ret Nic + return ret + } + return *o.Nic +} + +// GetNicOk returns a tuple with the Nic field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicResponse) GetNicOk() (*Nic, bool) { + if o == nil || o.Nic == nil { + return nil, false + } + return o.Nic, true +} + +// HasNic returns a boolean if a field has been set. +func (o *CreateNicResponse) HasNic() bool { + if o != nil && o.Nic != nil { + return true + } + + return false +} + +// SetNic gets a reference to the given Nic and assigns it to the Nic field. +func (o *CreateNicResponse) SetNic(v Nic) { + o.Nic = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateNicResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNicResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateNicResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateNicResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateNicResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Nic != nil { + toSerialize["Nic"] = o.Nic + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateNicResponse struct { + value *CreateNicResponse + isSet bool +} + +func (v NullableCreateNicResponse) Get() *CreateNicResponse { + return v.value +} + +func (v *NullableCreateNicResponse) Set(val *CreateNicResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNicResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNicResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNicResponse(val *CreateNicResponse) *NullableCreateNicResponse { + return &NullableCreateNicResponse{value: val, isSet: true} +} + +func (v NullableCreateNicResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNicResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go new file mode 100644 index 000000000..4a16c24f3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreatePublicIpRequest struct for CreatePublicIpRequest +type CreatePublicIpRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewCreatePublicIpRequest instantiates a new CreatePublicIpRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreatePublicIpRequest() *CreatePublicIpRequest { + this := CreatePublicIpRequest{} + return &this +} + +// NewCreatePublicIpRequestWithDefaults instantiates a new CreatePublicIpRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreatePublicIpRequestWithDefaults() *CreatePublicIpRequest { + this := CreatePublicIpRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreatePublicIpRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreatePublicIpRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreatePublicIpRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreatePublicIpRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o CreatePublicIpRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableCreatePublicIpRequest struct { + value *CreatePublicIpRequest + isSet bool +} + +func (v NullableCreatePublicIpRequest) Get() *CreatePublicIpRequest { + return v.value +} + +func (v *NullableCreatePublicIpRequest) Set(val *CreatePublicIpRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreatePublicIpRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreatePublicIpRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreatePublicIpRequest(val *CreatePublicIpRequest) *NullableCreatePublicIpRequest { + return &NullableCreatePublicIpRequest{value: val, isSet: true} +} + +func (v NullableCreatePublicIpRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreatePublicIpRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go new file mode 100644 index 000000000..09bc8eab1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreatePublicIpResponse struct for CreatePublicIpResponse +type CreatePublicIpResponse struct { + PublicIp *PublicIp `json:"PublicIp,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreatePublicIpResponse instantiates a new CreatePublicIpResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreatePublicIpResponse() *CreatePublicIpResponse { + this := CreatePublicIpResponse{} + return &this +} + +// NewCreatePublicIpResponseWithDefaults instantiates a new CreatePublicIpResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreatePublicIpResponseWithDefaults() *CreatePublicIpResponse { + this := CreatePublicIpResponse{} + return &this +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *CreatePublicIpResponse) GetPublicIp() PublicIp { + if o == nil || o.PublicIp == nil { + var ret PublicIp + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreatePublicIpResponse) GetPublicIpOk() (*PublicIp, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *CreatePublicIpResponse) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given PublicIp and assigns it to the PublicIp field. +func (o *CreatePublicIpResponse) SetPublicIp(v PublicIp) { + o.PublicIp = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreatePublicIpResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreatePublicIpResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreatePublicIpResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreatePublicIpResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreatePublicIpResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreatePublicIpResponse struct { + value *CreatePublicIpResponse + isSet bool +} + +func (v NullableCreatePublicIpResponse) Get() *CreatePublicIpResponse { + return v.value +} + +func (v *NullableCreatePublicIpResponse) Set(val *CreatePublicIpResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreatePublicIpResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreatePublicIpResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreatePublicIpResponse(val *CreatePublicIpResponse) *NullableCreatePublicIpResponse { + return &NullableCreatePublicIpResponse{value: val, isSet: true} +} + +func (v NullableCreatePublicIpResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreatePublicIpResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go new file mode 100644 index 000000000..a3e6db342 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go @@ -0,0 +1,362 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateRouteRequest struct for CreateRouteRequest +type CreateRouteRequest struct { + // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + DestinationIpRange string `json:"DestinationIpRange"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of an Internet service or virtual gateway attached to your Net. + GatewayId *string `json:"GatewayId,omitempty"` + // The ID of a NAT service. + NatServiceId *string `json:"NatServiceId,omitempty"` + // The ID of a Net peering connection. + NetPeeringId *string `json:"NetPeeringId,omitempty"` + // The ID of a NIC. + NicId *string `json:"NicId,omitempty"` + // The ID of the route table for which you want to create a route. + RouteTableId string `json:"RouteTableId"` + // The ID of a NAT VM in your Net (attached to exactly one NIC). + VmId *string `json:"VmId,omitempty"` +} + +// NewCreateRouteRequest instantiates a new CreateRouteRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateRouteRequest(destinationIpRange string, routeTableId string, ) *CreateRouteRequest { + this := CreateRouteRequest{} + this.DestinationIpRange = destinationIpRange + this.RouteTableId = routeTableId + return &this +} + +// NewCreateRouteRequestWithDefaults instantiates a new CreateRouteRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateRouteRequestWithDefaults() *CreateRouteRequest { + this := CreateRouteRequest{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value +func (o *CreateRouteRequest) GetDestinationIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetDestinationIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationIpRange, true +} + +// SetDestinationIpRange sets field value +func (o *CreateRouteRequest) SetDestinationIpRange(v string) { + o.DestinationIpRange = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateRouteRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetGatewayId returns the GatewayId field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetGatewayId() string { + if o == nil || o.GatewayId == nil { + var ret string + return ret + } + return *o.GatewayId +} + +// GetGatewayIdOk returns a tuple with the GatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetGatewayIdOk() (*string, bool) { + if o == nil || o.GatewayId == nil { + return nil, false + } + return o.GatewayId, true +} + +// HasGatewayId returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasGatewayId() bool { + if o != nil && o.GatewayId != nil { + return true + } + + return false +} + +// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. +func (o *CreateRouteRequest) SetGatewayId(v string) { + o.GatewayId = &v +} + +// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetNatServiceId() string { + if o == nil || o.NatServiceId == nil { + var ret string + return ret + } + return *o.NatServiceId +} + +// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetNatServiceIdOk() (*string, bool) { + if o == nil || o.NatServiceId == nil { + return nil, false + } + return o.NatServiceId, true +} + +// HasNatServiceId returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasNatServiceId() bool { + if o != nil && o.NatServiceId != nil { + return true + } + + return false +} + +// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. +func (o *CreateRouteRequest) SetNatServiceId(v string) { + o.NatServiceId = &v +} + +// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetNetPeeringId() string { + if o == nil || o.NetPeeringId == nil { + var ret string + return ret + } + return *o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetNetPeeringIdOk() (*string, bool) { + if o == nil || o.NetPeeringId == nil { + return nil, false + } + return o.NetPeeringId, true +} + +// HasNetPeeringId returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasNetPeeringId() bool { + if o != nil && o.NetPeeringId != nil { + return true + } + + return false +} + +// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. +func (o *CreateRouteRequest) SetNetPeeringId(v string) { + o.NetPeeringId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *CreateRouteRequest) SetNicId(v string) { + o.NicId = &v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *CreateRouteRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *CreateRouteRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *CreateRouteRequest) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteRequest) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *CreateRouteRequest) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *CreateRouteRequest) SetVmId(v string) { + o.VmId = &v +} + +func (o CreateRouteRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.GatewayId != nil { + toSerialize["GatewayId"] = o.GatewayId + } + if o.NatServiceId != nil { + toSerialize["NatServiceId"] = o.NatServiceId + } + if o.NetPeeringId != nil { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableCreateRouteRequest struct { + value *CreateRouteRequest + isSet bool +} + +func (v NullableCreateRouteRequest) Get() *CreateRouteRequest { + return v.value +} + +func (v *NullableCreateRouteRequest) Set(val *CreateRouteRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateRouteRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateRouteRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateRouteRequest(val *CreateRouteRequest) *NullableCreateRouteRequest { + return &NullableCreateRouteRequest{value: val, isSet: true} +} + +func (v NullableCreateRouteRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateRouteRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go new file mode 100644 index 000000000..83486505a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateRouteResponse struct for CreateRouteResponse +type CreateRouteResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + RouteTable *RouteTable `json:"RouteTable,omitempty"` +} + +// NewCreateRouteResponse instantiates a new CreateRouteResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateRouteResponse() *CreateRouteResponse { + this := CreateRouteResponse{} + return &this +} + +// NewCreateRouteResponseWithDefaults instantiates a new CreateRouteResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateRouteResponseWithDefaults() *CreateRouteResponse { + this := CreateRouteResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateRouteResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateRouteResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateRouteResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTable returns the RouteTable field value if set, zero value otherwise. +func (o *CreateRouteResponse) GetRouteTable() RouteTable { + if o == nil || o.RouteTable == nil { + var ret RouteTable + return ret + } + return *o.RouteTable +} + +// GetRouteTableOk returns a tuple with the RouteTable field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteResponse) GetRouteTableOk() (*RouteTable, bool) { + if o == nil || o.RouteTable == nil { + return nil, false + } + return o.RouteTable, true +} + +// HasRouteTable returns a boolean if a field has been set. +func (o *CreateRouteResponse) HasRouteTable() bool { + if o != nil && o.RouteTable != nil { + return true + } + + return false +} + +// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. +func (o *CreateRouteResponse) SetRouteTable(v RouteTable) { + o.RouteTable = &v +} + +func (o CreateRouteResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTable != nil { + toSerialize["RouteTable"] = o.RouteTable + } + return json.Marshal(toSerialize) +} + +type NullableCreateRouteResponse struct { + value *CreateRouteResponse + isSet bool +} + +func (v NullableCreateRouteResponse) Get() *CreateRouteResponse { + return v.value +} + +func (v *NullableCreateRouteResponse) Set(val *CreateRouteResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateRouteResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateRouteResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateRouteResponse(val *CreateRouteResponse) *NullableCreateRouteResponse { + return &NullableCreateRouteResponse{value: val, isSet: true} +} + +func (v NullableCreateRouteResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateRouteResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go new file mode 100644 index 000000000..4eb773706 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateRouteTableRequest struct for CreateRouteTableRequest +type CreateRouteTableRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net for which you want to create a route table. + NetId string `json:"NetId"` +} + +// NewCreateRouteTableRequest instantiates a new CreateRouteTableRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateRouteTableRequest(netId string, ) *CreateRouteTableRequest { + this := CreateRouteTableRequest{} + this.NetId = netId + return &this +} + +// NewCreateRouteTableRequestWithDefaults instantiates a new CreateRouteTableRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateRouteTableRequestWithDefaults() *CreateRouteTableRequest { + this := CreateRouteTableRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateRouteTableRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteTableRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateRouteTableRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateRouteTableRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *CreateRouteTableRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *CreateRouteTableRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *CreateRouteTableRequest) SetNetId(v string) { + o.NetId = v +} + +func (o CreateRouteTableRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableCreateRouteTableRequest struct { + value *CreateRouteTableRequest + isSet bool +} + +func (v NullableCreateRouteTableRequest) Get() *CreateRouteTableRequest { + return v.value +} + +func (v *NullableCreateRouteTableRequest) Set(val *CreateRouteTableRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateRouteTableRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateRouteTableRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateRouteTableRequest(val *CreateRouteTableRequest) *NullableCreateRouteTableRequest { + return &NullableCreateRouteTableRequest{value: val, isSet: true} +} + +func (v NullableCreateRouteTableRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateRouteTableRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go new file mode 100644 index 000000000..521cb3107 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateRouteTableResponse struct for CreateRouteTableResponse +type CreateRouteTableResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + RouteTable *RouteTable `json:"RouteTable,omitempty"` +} + +// NewCreateRouteTableResponse instantiates a new CreateRouteTableResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateRouteTableResponse() *CreateRouteTableResponse { + this := CreateRouteTableResponse{} + return &this +} + +// NewCreateRouteTableResponseWithDefaults instantiates a new CreateRouteTableResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateRouteTableResponseWithDefaults() *CreateRouteTableResponse { + this := CreateRouteTableResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateRouteTableResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteTableResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateRouteTableResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateRouteTableResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTable returns the RouteTable field value if set, zero value otherwise. +func (o *CreateRouteTableResponse) GetRouteTable() RouteTable { + if o == nil || o.RouteTable == nil { + var ret RouteTable + return ret + } + return *o.RouteTable +} + +// GetRouteTableOk returns a tuple with the RouteTable field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateRouteTableResponse) GetRouteTableOk() (*RouteTable, bool) { + if o == nil || o.RouteTable == nil { + return nil, false + } + return o.RouteTable, true +} + +// HasRouteTable returns a boolean if a field has been set. +func (o *CreateRouteTableResponse) HasRouteTable() bool { + if o != nil && o.RouteTable != nil { + return true + } + + return false +} + +// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. +func (o *CreateRouteTableResponse) SetRouteTable(v RouteTable) { + o.RouteTable = &v +} + +func (o CreateRouteTableResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTable != nil { + toSerialize["RouteTable"] = o.RouteTable + } + return json.Marshal(toSerialize) +} + +type NullableCreateRouteTableResponse struct { + value *CreateRouteTableResponse + isSet bool +} + +func (v NullableCreateRouteTableResponse) Get() *CreateRouteTableResponse { + return v.value +} + +func (v *NullableCreateRouteTableResponse) Set(val *CreateRouteTableResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateRouteTableResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateRouteTableResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateRouteTableResponse(val *CreateRouteTableResponse) *NullableCreateRouteTableResponse { + return &NullableCreateRouteTableResponse{value: val, isSet: true} +} + +func (v NullableCreateRouteTableResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateRouteTableResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go new file mode 100644 index 000000000..618a5acb3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go @@ -0,0 +1,214 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSecurityGroupRequest struct for CreateSecurityGroupRequest +type CreateSecurityGroupRequest struct { + // A description for the security group, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). + Description string `json:"Description"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net for the security group. + NetId *string `json:"NetId,omitempty"` + // The name of the security group.
This name must not start with `sg-`.
This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed. + SecurityGroupName string `json:"SecurityGroupName"` +} + +// NewCreateSecurityGroupRequest instantiates a new CreateSecurityGroupRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSecurityGroupRequest(description string, securityGroupName string, ) *CreateSecurityGroupRequest { + this := CreateSecurityGroupRequest{} + this.Description = description + this.SecurityGroupName = securityGroupName + return &this +} + +// NewCreateSecurityGroupRequestWithDefaults instantiates a new CreateSecurityGroupRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSecurityGroupRequestWithDefaults() *CreateSecurityGroupRequest { + this := CreateSecurityGroupRequest{} + return &this +} + +// GetDescription returns the Description field value +func (o *CreateSecurityGroupRequest) GetDescription() string { + if o == nil { + var ret string + return ret + } + + return o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRequest) GetDescriptionOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Description, true +} + +// SetDescription sets field value +func (o *CreateSecurityGroupRequest) SetDescription(v string) { + o.Description = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateSecurityGroupRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateSecurityGroupRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateSecurityGroupRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *CreateSecurityGroupRequest) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRequest) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *CreateSecurityGroupRequest) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *CreateSecurityGroupRequest) SetNetId(v string) { + o.NetId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value +func (o *CreateSecurityGroupRequest) GetSecurityGroupName() string { + if o == nil { + var ret string + return ret + } + + return o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRequest) GetSecurityGroupNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SecurityGroupName, true +} + +// SetSecurityGroupName sets field value +func (o *CreateSecurityGroupRequest) SetSecurityGroupName(v string) { + o.SecurityGroupName = v +} + +func (o CreateSecurityGroupRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["Description"] = o.Description + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if true { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + return json.Marshal(toSerialize) +} + +type NullableCreateSecurityGroupRequest struct { + value *CreateSecurityGroupRequest + isSet bool +} + +func (v NullableCreateSecurityGroupRequest) Get() *CreateSecurityGroupRequest { + return v.value +} + +func (v *NullableCreateSecurityGroupRequest) Set(val *CreateSecurityGroupRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSecurityGroupRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSecurityGroupRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSecurityGroupRequest(val *CreateSecurityGroupRequest) *NullableCreateSecurityGroupRequest { + return &NullableCreateSecurityGroupRequest{value: val, isSet: true} +} + +func (v NullableCreateSecurityGroupRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSecurityGroupRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go new file mode 100644 index 000000000..abd80299e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSecurityGroupResponse struct for CreateSecurityGroupResponse +type CreateSecurityGroupResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` +} + +// NewCreateSecurityGroupResponse instantiates a new CreateSecurityGroupResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSecurityGroupResponse() *CreateSecurityGroupResponse { + this := CreateSecurityGroupResponse{} + return &this +} + +// NewCreateSecurityGroupResponseWithDefaults instantiates a new CreateSecurityGroupResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSecurityGroupResponseWithDefaults() *CreateSecurityGroupResponse { + this := CreateSecurityGroupResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateSecurityGroupResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateSecurityGroupResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateSecurityGroupResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. +func (o *CreateSecurityGroupResponse) GetSecurityGroup() SecurityGroup { + if o == nil || o.SecurityGroup == nil { + var ret SecurityGroup + return ret + } + return *o.SecurityGroup +} + +// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupResponse) GetSecurityGroupOk() (*SecurityGroup, bool) { + if o == nil || o.SecurityGroup == nil { + return nil, false + } + return o.SecurityGroup, true +} + +// HasSecurityGroup returns a boolean if a field has been set. +func (o *CreateSecurityGroupResponse) HasSecurityGroup() bool { + if o != nil && o.SecurityGroup != nil { + return true + } + + return false +} + +// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. +func (o *CreateSecurityGroupResponse) SetSecurityGroup(v SecurityGroup) { + o.SecurityGroup = &v +} + +func (o CreateSecurityGroupResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SecurityGroup != nil { + toSerialize["SecurityGroup"] = o.SecurityGroup + } + return json.Marshal(toSerialize) +} + +type NullableCreateSecurityGroupResponse struct { + value *CreateSecurityGroupResponse + isSet bool +} + +func (v NullableCreateSecurityGroupResponse) Get() *CreateSecurityGroupResponse { + return v.value +} + +func (v *NullableCreateSecurityGroupResponse) Set(val *CreateSecurityGroupResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSecurityGroupResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSecurityGroupResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSecurityGroupResponse(val *CreateSecurityGroupResponse) *NullableCreateSecurityGroupResponse { + return &NullableCreateSecurityGroupResponse{value: val, isSet: true} +} + +func (v NullableCreateSecurityGroupResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSecurityGroupResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go new file mode 100644 index 000000000..9832f8d14 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go @@ -0,0 +1,436 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSecurityGroupRuleRequest struct for CreateSecurityGroupRuleRequest +type CreateSecurityGroupRuleRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. + Flow string `json:"Flow"` + // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + FromPortRange *int32 `json:"FromPortRange,omitempty"` + // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + IpProtocol *string `json:"IpProtocol,omitempty"` + // The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // Information about the security group rule to create. + Rules *[]SecurityGroupRule `json:"Rules,omitempty"` + // The account ID of the owner of the security group for which you want to create a rule. + SecurityGroupAccountIdToLink *string `json:"SecurityGroupAccountIdToLink,omitempty"` + // The ID of the security group for which you want to create a rule. + SecurityGroupId string `json:"SecurityGroupId"` + // The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. + SecurityGroupNameToLink *string `json:"SecurityGroupNameToLink,omitempty"` + // The end of the port range for the TCP and UDP protocols, or an ICMP type number. + ToPortRange *int32 `json:"ToPortRange,omitempty"` +} + +// NewCreateSecurityGroupRuleRequest instantiates a new CreateSecurityGroupRuleRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSecurityGroupRuleRequest(flow string, securityGroupId string, ) *CreateSecurityGroupRuleRequest { + this := CreateSecurityGroupRuleRequest{} + this.Flow = flow + this.SecurityGroupId = securityGroupId + return &this +} + +// NewCreateSecurityGroupRuleRequestWithDefaults instantiates a new CreateSecurityGroupRuleRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSecurityGroupRuleRequestWithDefaults() *CreateSecurityGroupRuleRequest { + this := CreateSecurityGroupRuleRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateSecurityGroupRuleRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlow returns the Flow field value +func (o *CreateSecurityGroupRuleRequest) GetFlow() string { + if o == nil { + var ret string + return ret + } + + return o.Flow +} + +// GetFlowOk returns a tuple with the Flow field value +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetFlowOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Flow, true +} + +// SetFlow sets field value +func (o *CreateSecurityGroupRuleRequest) SetFlow(v string) { + o.Flow = v +} + +// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetFromPortRange() int32 { + if o == nil || o.FromPortRange == nil { + var ret int32 + return ret + } + return *o.FromPortRange +} + +// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetFromPortRangeOk() (*int32, bool) { + if o == nil || o.FromPortRange == nil { + return nil, false + } + return o.FromPortRange, true +} + +// HasFromPortRange returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasFromPortRange() bool { + if o != nil && o.FromPortRange != nil { + return true + } + + return false +} + +// SetFromPortRange gets a reference to the given int32 and assigns it to the FromPortRange field. +func (o *CreateSecurityGroupRuleRequest) SetFromPortRange(v int32) { + o.FromPortRange = &v +} + +// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetIpProtocol() string { + if o == nil || o.IpProtocol == nil { + var ret string + return ret + } + return *o.IpProtocol +} + +// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetIpProtocolOk() (*string, bool) { + if o == nil || o.IpProtocol == nil { + return nil, false + } + return o.IpProtocol, true +} + +// HasIpProtocol returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasIpProtocol() bool { + if o != nil && o.IpProtocol != nil { + return true + } + + return false +} + +// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. +func (o *CreateSecurityGroupRuleRequest) SetIpProtocol(v string) { + o.IpProtocol = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *CreateSecurityGroupRuleRequest) SetIpRange(v string) { + o.IpRange = &v +} + +// GetRules returns the Rules field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetRules() []SecurityGroupRule { + if o == nil || o.Rules == nil { + var ret []SecurityGroupRule + return ret + } + return *o.Rules +} + +// GetRulesOk returns a tuple with the Rules field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetRulesOk() (*[]SecurityGroupRule, bool) { + if o == nil || o.Rules == nil { + return nil, false + } + return o.Rules, true +} + +// HasRules returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasRules() bool { + if o != nil && o.Rules != nil { + return true + } + + return false +} + +// SetRules gets a reference to the given []SecurityGroupRule and assigns it to the Rules field. +func (o *CreateSecurityGroupRuleRequest) SetRules(v []SecurityGroupRule) { + o.Rules = &v +} + +// GetSecurityGroupAccountIdToLink returns the SecurityGroupAccountIdToLink field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupAccountIdToLink() string { + if o == nil || o.SecurityGroupAccountIdToLink == nil { + var ret string + return ret + } + return *o.SecurityGroupAccountIdToLink +} + +// GetSecurityGroupAccountIdToLinkOk returns a tuple with the SecurityGroupAccountIdToLink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupAccountIdToLinkOk() (*string, bool) { + if o == nil || o.SecurityGroupAccountIdToLink == nil { + return nil, false + } + return o.SecurityGroupAccountIdToLink, true +} + +// HasSecurityGroupAccountIdToLink returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasSecurityGroupAccountIdToLink() bool { + if o != nil && o.SecurityGroupAccountIdToLink != nil { + return true + } + + return false +} + +// SetSecurityGroupAccountIdToLink gets a reference to the given string and assigns it to the SecurityGroupAccountIdToLink field. +func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupAccountIdToLink(v string) { + o.SecurityGroupAccountIdToLink = &v +} + +// GetSecurityGroupId returns the SecurityGroupId field value +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupId() string { + if o == nil { + var ret string + return ret + } + + return o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SecurityGroupId, true +} + +// SetSecurityGroupId sets field value +func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupId(v string) { + o.SecurityGroupId = v +} + +// GetSecurityGroupNameToLink returns the SecurityGroupNameToLink field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupNameToLink() string { + if o == nil || o.SecurityGroupNameToLink == nil { + var ret string + return ret + } + return *o.SecurityGroupNameToLink +} + +// GetSecurityGroupNameToLinkOk returns a tuple with the SecurityGroupNameToLink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupNameToLinkOk() (*string, bool) { + if o == nil || o.SecurityGroupNameToLink == nil { + return nil, false + } + return o.SecurityGroupNameToLink, true +} + +// HasSecurityGroupNameToLink returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasSecurityGroupNameToLink() bool { + if o != nil && o.SecurityGroupNameToLink != nil { + return true + } + + return false +} + +// SetSecurityGroupNameToLink gets a reference to the given string and assigns it to the SecurityGroupNameToLink field. +func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupNameToLink(v string) { + o.SecurityGroupNameToLink = &v +} + +// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleRequest) GetToPortRange() int32 { + if o == nil || o.ToPortRange == nil { + var ret int32 + return ret + } + return *o.ToPortRange +} + +// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleRequest) GetToPortRangeOk() (*int32, bool) { + if o == nil || o.ToPortRange == nil { + return nil, false + } + return o.ToPortRange, true +} + +// HasToPortRange returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleRequest) HasToPortRange() bool { + if o != nil && o.ToPortRange != nil { + return true + } + + return false +} + +// SetToPortRange gets a reference to the given int32 and assigns it to the ToPortRange field. +func (o *CreateSecurityGroupRuleRequest) SetToPortRange(v int32) { + o.ToPortRange = &v +} + +func (o CreateSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Flow"] = o.Flow + } + if o.FromPortRange != nil { + toSerialize["FromPortRange"] = o.FromPortRange + } + if o.IpProtocol != nil { + toSerialize["IpProtocol"] = o.IpProtocol + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.Rules != nil { + toSerialize["Rules"] = o.Rules + } + if o.SecurityGroupAccountIdToLink != nil { + toSerialize["SecurityGroupAccountIdToLink"] = o.SecurityGroupAccountIdToLink + } + if true { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupNameToLink != nil { + toSerialize["SecurityGroupNameToLink"] = o.SecurityGroupNameToLink + } + if o.ToPortRange != nil { + toSerialize["ToPortRange"] = o.ToPortRange + } + return json.Marshal(toSerialize) +} + +type NullableCreateSecurityGroupRuleRequest struct { + value *CreateSecurityGroupRuleRequest + isSet bool +} + +func (v NullableCreateSecurityGroupRuleRequest) Get() *CreateSecurityGroupRuleRequest { + return v.value +} + +func (v *NullableCreateSecurityGroupRuleRequest) Set(val *CreateSecurityGroupRuleRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSecurityGroupRuleRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSecurityGroupRuleRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSecurityGroupRuleRequest(val *CreateSecurityGroupRuleRequest) *NullableCreateSecurityGroupRuleRequest { + return &NullableCreateSecurityGroupRuleRequest{value: val, isSet: true} +} + +func (v NullableCreateSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSecurityGroupRuleRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go new file mode 100644 index 000000000..cc9371e11 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSecurityGroupRuleResponse struct for CreateSecurityGroupRuleResponse +type CreateSecurityGroupRuleResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` +} + +// NewCreateSecurityGroupRuleResponse instantiates a new CreateSecurityGroupRuleResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSecurityGroupRuleResponse() *CreateSecurityGroupRuleResponse { + this := CreateSecurityGroupRuleResponse{} + return &this +} + +// NewCreateSecurityGroupRuleResponseWithDefaults instantiates a new CreateSecurityGroupRuleResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSecurityGroupRuleResponseWithDefaults() *CreateSecurityGroupRuleResponse { + this := CreateSecurityGroupRuleResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateSecurityGroupRuleResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. +func (o *CreateSecurityGroupRuleResponse) GetSecurityGroup() SecurityGroup { + if o == nil || o.SecurityGroup == nil { + var ret SecurityGroup + return ret + } + return *o.SecurityGroup +} + +// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSecurityGroupRuleResponse) GetSecurityGroupOk() (*SecurityGroup, bool) { + if o == nil || o.SecurityGroup == nil { + return nil, false + } + return o.SecurityGroup, true +} + +// HasSecurityGroup returns a boolean if a field has been set. +func (o *CreateSecurityGroupRuleResponse) HasSecurityGroup() bool { + if o != nil && o.SecurityGroup != nil { + return true + } + + return false +} + +// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. +func (o *CreateSecurityGroupRuleResponse) SetSecurityGroup(v SecurityGroup) { + o.SecurityGroup = &v +} + +func (o CreateSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SecurityGroup != nil { + toSerialize["SecurityGroup"] = o.SecurityGroup + } + return json.Marshal(toSerialize) +} + +type NullableCreateSecurityGroupRuleResponse struct { + value *CreateSecurityGroupRuleResponse + isSet bool +} + +func (v NullableCreateSecurityGroupRuleResponse) Get() *CreateSecurityGroupRuleResponse { + return v.value +} + +func (v *NullableCreateSecurityGroupRuleResponse) Set(val *CreateSecurityGroupRuleResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSecurityGroupRuleResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSecurityGroupRuleResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSecurityGroupRuleResponse(val *CreateSecurityGroupRuleResponse) *NullableCreateSecurityGroupRuleResponse { + return &NullableCreateSecurityGroupRuleResponse{value: val, isSet: true} +} + +func (v NullableCreateSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSecurityGroupRuleResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go new file mode 100644 index 000000000..541a87650 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go @@ -0,0 +1,281 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateServerCertificateRequest struct for CreateServerCertificateRequest +type CreateServerCertificateRequest struct { + // The PEM-encoded X509 certificate. + Body string `json:"Body"` + // The PEM-encoded intermediate certification authorities. + Chain *string `json:"Chain,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // A unique name for the certificate. Constraints: 1-128 alphanumeric characters, pluses (+), equals (=), commas (,), periods (.), at signs (@), minuses (-), or underscores (_). + Name string `json:"Name"` + // The path to the server certificate, set to a slash (/) if not specified. + Path *string `json:"Path,omitempty"` + // The PEM-encoded private key matching the certificate. + PrivateKey string `json:"PrivateKey"` +} + +// NewCreateServerCertificateRequest instantiates a new CreateServerCertificateRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateServerCertificateRequest(body string, name string, privateKey string, ) *CreateServerCertificateRequest { + this := CreateServerCertificateRequest{} + this.Body = body + this.Name = name + this.PrivateKey = privateKey + return &this +} + +// NewCreateServerCertificateRequestWithDefaults instantiates a new CreateServerCertificateRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateServerCertificateRequestWithDefaults() *CreateServerCertificateRequest { + this := CreateServerCertificateRequest{} + return &this +} + +// GetBody returns the Body field value +func (o *CreateServerCertificateRequest) GetBody() string { + if o == nil { + var ret string + return ret + } + + return o.Body +} + +// GetBodyOk returns a tuple with the Body field value +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetBodyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Body, true +} + +// SetBody sets field value +func (o *CreateServerCertificateRequest) SetBody(v string) { + o.Body = v +} + +// GetChain returns the Chain field value if set, zero value otherwise. +func (o *CreateServerCertificateRequest) GetChain() string { + if o == nil || o.Chain == nil { + var ret string + return ret + } + return *o.Chain +} + +// GetChainOk returns a tuple with the Chain field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetChainOk() (*string, bool) { + if o == nil || o.Chain == nil { + return nil, false + } + return o.Chain, true +} + +// HasChain returns a boolean if a field has been set. +func (o *CreateServerCertificateRequest) HasChain() bool { + if o != nil && o.Chain != nil { + return true + } + + return false +} + +// SetChain gets a reference to the given string and assigns it to the Chain field. +func (o *CreateServerCertificateRequest) SetChain(v string) { + o.Chain = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateServerCertificateRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateServerCertificateRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateServerCertificateRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetName returns the Name field value +func (o *CreateServerCertificateRequest) GetName() string { + if o == nil { + var ret string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Name, true +} + +// SetName sets field value +func (o *CreateServerCertificateRequest) SetName(v string) { + o.Name = v +} + +// GetPath returns the Path field value if set, zero value otherwise. +func (o *CreateServerCertificateRequest) GetPath() string { + if o == nil || o.Path == nil { + var ret string + return ret + } + return *o.Path +} + +// GetPathOk returns a tuple with the Path field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetPathOk() (*string, bool) { + if o == nil || o.Path == nil { + return nil, false + } + return o.Path, true +} + +// HasPath returns a boolean if a field has been set. +func (o *CreateServerCertificateRequest) HasPath() bool { + if o != nil && o.Path != nil { + return true + } + + return false +} + +// SetPath gets a reference to the given string and assigns it to the Path field. +func (o *CreateServerCertificateRequest) SetPath(v string) { + o.Path = &v +} + +// GetPrivateKey returns the PrivateKey field value +func (o *CreateServerCertificateRequest) GetPrivateKey() string { + if o == nil { + var ret string + return ret + } + + return o.PrivateKey +} + +// GetPrivateKeyOk returns a tuple with the PrivateKey field value +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateRequest) GetPrivateKeyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PrivateKey, true +} + +// SetPrivateKey sets field value +func (o *CreateServerCertificateRequest) SetPrivateKey(v string) { + o.PrivateKey = v +} + +func (o CreateServerCertificateRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["Body"] = o.Body + } + if o.Chain != nil { + toSerialize["Chain"] = o.Chain + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Name"] = o.Name + } + if o.Path != nil { + toSerialize["Path"] = o.Path + } + if true { + toSerialize["PrivateKey"] = o.PrivateKey + } + return json.Marshal(toSerialize) +} + +type NullableCreateServerCertificateRequest struct { + value *CreateServerCertificateRequest + isSet bool +} + +func (v NullableCreateServerCertificateRequest) Get() *CreateServerCertificateRequest { + return v.value +} + +func (v *NullableCreateServerCertificateRequest) Set(val *CreateServerCertificateRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateServerCertificateRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateServerCertificateRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateServerCertificateRequest(val *CreateServerCertificateRequest) *NullableCreateServerCertificateRequest { + return &NullableCreateServerCertificateRequest{value: val, isSet: true} +} + +func (v NullableCreateServerCertificateRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateServerCertificateRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go new file mode 100644 index 000000000..8b8362705 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateServerCertificateResponse struct for CreateServerCertificateResponse +type CreateServerCertificateResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + ServerCertificate *ServerCertificate `json:"ServerCertificate,omitempty"` +} + +// NewCreateServerCertificateResponse instantiates a new CreateServerCertificateResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateServerCertificateResponse() *CreateServerCertificateResponse { + this := CreateServerCertificateResponse{} + return &this +} + +// NewCreateServerCertificateResponseWithDefaults instantiates a new CreateServerCertificateResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateServerCertificateResponseWithDefaults() *CreateServerCertificateResponse { + this := CreateServerCertificateResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateServerCertificateResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateServerCertificateResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateServerCertificateResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetServerCertificate returns the ServerCertificate field value if set, zero value otherwise. +func (o *CreateServerCertificateResponse) GetServerCertificate() ServerCertificate { + if o == nil || o.ServerCertificate == nil { + var ret ServerCertificate + return ret + } + return *o.ServerCertificate +} + +// GetServerCertificateOk returns a tuple with the ServerCertificate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateServerCertificateResponse) GetServerCertificateOk() (*ServerCertificate, bool) { + if o == nil || o.ServerCertificate == nil { + return nil, false + } + return o.ServerCertificate, true +} + +// HasServerCertificate returns a boolean if a field has been set. +func (o *CreateServerCertificateResponse) HasServerCertificate() bool { + if o != nil && o.ServerCertificate != nil { + return true + } + + return false +} + +// SetServerCertificate gets a reference to the given ServerCertificate and assigns it to the ServerCertificate field. +func (o *CreateServerCertificateResponse) SetServerCertificate(v ServerCertificate) { + o.ServerCertificate = &v +} + +func (o CreateServerCertificateResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.ServerCertificate != nil { + toSerialize["ServerCertificate"] = o.ServerCertificate + } + return json.Marshal(toSerialize) +} + +type NullableCreateServerCertificateResponse struct { + value *CreateServerCertificateResponse + isSet bool +} + +func (v NullableCreateServerCertificateResponse) Get() *CreateServerCertificateResponse { + return v.value +} + +func (v *NullableCreateServerCertificateResponse) Set(val *CreateServerCertificateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateServerCertificateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateServerCertificateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateServerCertificateResponse(val *CreateServerCertificateResponse) *NullableCreateServerCertificateResponse { + return &NullableCreateServerCertificateResponse{value: val, isSet: true} +} + +func (v NullableCreateServerCertificateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateServerCertificateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go new file mode 100644 index 000000000..e4862fcbb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go @@ -0,0 +1,176 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSnapshotExportTaskRequest struct for CreateSnapshotExportTaskRequest +type CreateSnapshotExportTaskRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + OsuExport OsuExport `json:"OsuExport"` + // The ID of the snapshot to export. + SnapshotId string `json:"SnapshotId"` +} + +// NewCreateSnapshotExportTaskRequest instantiates a new CreateSnapshotExportTaskRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSnapshotExportTaskRequest(osuExport OsuExport, snapshotId string, ) *CreateSnapshotExportTaskRequest { + this := CreateSnapshotExportTaskRequest{} + this.OsuExport = osuExport + this.SnapshotId = snapshotId + return &this +} + +// NewCreateSnapshotExportTaskRequestWithDefaults instantiates a new CreateSnapshotExportTaskRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSnapshotExportTaskRequestWithDefaults() *CreateSnapshotExportTaskRequest { + this := CreateSnapshotExportTaskRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateSnapshotExportTaskRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotExportTaskRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateSnapshotExportTaskRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateSnapshotExportTaskRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetOsuExport returns the OsuExport field value +func (o *CreateSnapshotExportTaskRequest) GetOsuExport() OsuExport { + if o == nil { + var ret OsuExport + return ret + } + + return o.OsuExport +} + +// GetOsuExportOk returns a tuple with the OsuExport field value +// and a boolean to check if the value has been set. +func (o *CreateSnapshotExportTaskRequest) GetOsuExportOk() (*OsuExport, bool) { + if o == nil { + return nil, false + } + return &o.OsuExport, true +} + +// SetOsuExport sets field value +func (o *CreateSnapshotExportTaskRequest) SetOsuExport(v OsuExport) { + o.OsuExport = v +} + +// GetSnapshotId returns the SnapshotId field value +func (o *CreateSnapshotExportTaskRequest) GetSnapshotId() string { + if o == nil { + var ret string + return ret + } + + return o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value +// and a boolean to check if the value has been set. +func (o *CreateSnapshotExportTaskRequest) GetSnapshotIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SnapshotId, true +} + +// SetSnapshotId sets field value +func (o *CreateSnapshotExportTaskRequest) SetSnapshotId(v string) { + o.SnapshotId = v +} + +func (o CreateSnapshotExportTaskRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["OsuExport"] = o.OsuExport + } + if true { + toSerialize["SnapshotId"] = o.SnapshotId + } + return json.Marshal(toSerialize) +} + +type NullableCreateSnapshotExportTaskRequest struct { + value *CreateSnapshotExportTaskRequest + isSet bool +} + +func (v NullableCreateSnapshotExportTaskRequest) Get() *CreateSnapshotExportTaskRequest { + return v.value +} + +func (v *NullableCreateSnapshotExportTaskRequest) Set(val *CreateSnapshotExportTaskRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSnapshotExportTaskRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSnapshotExportTaskRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSnapshotExportTaskRequest(val *CreateSnapshotExportTaskRequest) *NullableCreateSnapshotExportTaskRequest { + return &NullableCreateSnapshotExportTaskRequest{value: val, isSet: true} +} + +func (v NullableCreateSnapshotExportTaskRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSnapshotExportTaskRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go new file mode 100644 index 000000000..97b7fe280 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSnapshotExportTaskResponse struct for CreateSnapshotExportTaskResponse +type CreateSnapshotExportTaskResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + SnapshotExportTask *SnapshotExportTask `json:"SnapshotExportTask,omitempty"` +} + +// NewCreateSnapshotExportTaskResponse instantiates a new CreateSnapshotExportTaskResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSnapshotExportTaskResponse() *CreateSnapshotExportTaskResponse { + this := CreateSnapshotExportTaskResponse{} + return &this +} + +// NewCreateSnapshotExportTaskResponseWithDefaults instantiates a new CreateSnapshotExportTaskResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSnapshotExportTaskResponseWithDefaults() *CreateSnapshotExportTaskResponse { + this := CreateSnapshotExportTaskResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateSnapshotExportTaskResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotExportTaskResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateSnapshotExportTaskResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateSnapshotExportTaskResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSnapshotExportTask returns the SnapshotExportTask field value if set, zero value otherwise. +func (o *CreateSnapshotExportTaskResponse) GetSnapshotExportTask() SnapshotExportTask { + if o == nil || o.SnapshotExportTask == nil { + var ret SnapshotExportTask + return ret + } + return *o.SnapshotExportTask +} + +// GetSnapshotExportTaskOk returns a tuple with the SnapshotExportTask field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotExportTaskResponse) GetSnapshotExportTaskOk() (*SnapshotExportTask, bool) { + if o == nil || o.SnapshotExportTask == nil { + return nil, false + } + return o.SnapshotExportTask, true +} + +// HasSnapshotExportTask returns a boolean if a field has been set. +func (o *CreateSnapshotExportTaskResponse) HasSnapshotExportTask() bool { + if o != nil && o.SnapshotExportTask != nil { + return true + } + + return false +} + +// SetSnapshotExportTask gets a reference to the given SnapshotExportTask and assigns it to the SnapshotExportTask field. +func (o *CreateSnapshotExportTaskResponse) SetSnapshotExportTask(v SnapshotExportTask) { + o.SnapshotExportTask = &v +} + +func (o CreateSnapshotExportTaskResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SnapshotExportTask != nil { + toSerialize["SnapshotExportTask"] = o.SnapshotExportTask + } + return json.Marshal(toSerialize) +} + +type NullableCreateSnapshotExportTaskResponse struct { + value *CreateSnapshotExportTaskResponse + isSet bool +} + +func (v NullableCreateSnapshotExportTaskResponse) Get() *CreateSnapshotExportTaskResponse { + return v.value +} + +func (v *NullableCreateSnapshotExportTaskResponse) Set(val *CreateSnapshotExportTaskResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSnapshotExportTaskResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSnapshotExportTaskResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSnapshotExportTaskResponse(val *CreateSnapshotExportTaskResponse) *NullableCreateSnapshotExportTaskResponse { + return &NullableCreateSnapshotExportTaskResponse{value: val, isSet: true} +} + +func (v NullableCreateSnapshotExportTaskResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSnapshotExportTaskResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go new file mode 100644 index 000000000..6bf90d6ab --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSnapshotRequest struct for CreateSnapshotRequest +type CreateSnapshotRequest struct { + // A description for the snapshot. + Description *string `json:"Description,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The pre-signed URL of the snapshot you want to import from the OSU bucket. + FileLocation *string `json:"FileLocation,omitempty"` + // The size of the snapshot created in your account, in bytes. This size must be exactly the same as the source snapshot one. + SnapshotSize *int64 `json:"SnapshotSize,omitempty"` + // The name of the source Region, which must be the same as the Region of your account. + SourceRegionName *string `json:"SourceRegionName,omitempty"` + // The ID of the snapshot you want to copy. + SourceSnapshotId *string `json:"SourceSnapshotId,omitempty"` + // The ID of the volume you want to create a snapshot of. + VolumeId *string `json:"VolumeId,omitempty"` +} + +// NewCreateSnapshotRequest instantiates a new CreateSnapshotRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSnapshotRequest() *CreateSnapshotRequest { + this := CreateSnapshotRequest{} + return &this +} + +// NewCreateSnapshotRequestWithDefaults instantiates a new CreateSnapshotRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSnapshotRequestWithDefaults() *CreateSnapshotRequest { + this := CreateSnapshotRequest{} + return &this +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *CreateSnapshotRequest) SetDescription(v string) { + o.Description = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateSnapshotRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFileLocation returns the FileLocation field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetFileLocation() string { + if o == nil || o.FileLocation == nil { + var ret string + return ret + } + return *o.FileLocation +} + +// GetFileLocationOk returns a tuple with the FileLocation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetFileLocationOk() (*string, bool) { + if o == nil || o.FileLocation == nil { + return nil, false + } + return o.FileLocation, true +} + +// HasFileLocation returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasFileLocation() bool { + if o != nil && o.FileLocation != nil { + return true + } + + return false +} + +// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. +func (o *CreateSnapshotRequest) SetFileLocation(v string) { + o.FileLocation = &v +} + +// GetSnapshotSize returns the SnapshotSize field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetSnapshotSize() int64 { + if o == nil || o.SnapshotSize == nil { + var ret int64 + return ret + } + return *o.SnapshotSize +} + +// GetSnapshotSizeOk returns a tuple with the SnapshotSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetSnapshotSizeOk() (*int64, bool) { + if o == nil || o.SnapshotSize == nil { + return nil, false + } + return o.SnapshotSize, true +} + +// HasSnapshotSize returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasSnapshotSize() bool { + if o != nil && o.SnapshotSize != nil { + return true + } + + return false +} + +// SetSnapshotSize gets a reference to the given int64 and assigns it to the SnapshotSize field. +func (o *CreateSnapshotRequest) SetSnapshotSize(v int64) { + o.SnapshotSize = &v +} + +// GetSourceRegionName returns the SourceRegionName field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetSourceRegionName() string { + if o == nil || o.SourceRegionName == nil { + var ret string + return ret + } + return *o.SourceRegionName +} + +// GetSourceRegionNameOk returns a tuple with the SourceRegionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetSourceRegionNameOk() (*string, bool) { + if o == nil || o.SourceRegionName == nil { + return nil, false + } + return o.SourceRegionName, true +} + +// HasSourceRegionName returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasSourceRegionName() bool { + if o != nil && o.SourceRegionName != nil { + return true + } + + return false +} + +// SetSourceRegionName gets a reference to the given string and assigns it to the SourceRegionName field. +func (o *CreateSnapshotRequest) SetSourceRegionName(v string) { + o.SourceRegionName = &v +} + +// GetSourceSnapshotId returns the SourceSnapshotId field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetSourceSnapshotId() string { + if o == nil || o.SourceSnapshotId == nil { + var ret string + return ret + } + return *o.SourceSnapshotId +} + +// GetSourceSnapshotIdOk returns a tuple with the SourceSnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetSourceSnapshotIdOk() (*string, bool) { + if o == nil || o.SourceSnapshotId == nil { + return nil, false + } + return o.SourceSnapshotId, true +} + +// HasSourceSnapshotId returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasSourceSnapshotId() bool { + if o != nil && o.SourceSnapshotId != nil { + return true + } + + return false +} + +// SetSourceSnapshotId gets a reference to the given string and assigns it to the SourceSnapshotId field. +func (o *CreateSnapshotRequest) SetSourceSnapshotId(v string) { + o.SourceSnapshotId = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *CreateSnapshotRequest) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotRequest) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *CreateSnapshotRequest) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *CreateSnapshotRequest) SetVolumeId(v string) { + o.VolumeId = &v +} + +func (o CreateSnapshotRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.FileLocation != nil { + toSerialize["FileLocation"] = o.FileLocation + } + if o.SnapshotSize != nil { + toSerialize["SnapshotSize"] = o.SnapshotSize + } + if o.SourceRegionName != nil { + toSerialize["SourceRegionName"] = o.SourceRegionName + } + if o.SourceSnapshotId != nil { + toSerialize["SourceSnapshotId"] = o.SourceSnapshotId + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableCreateSnapshotRequest struct { + value *CreateSnapshotRequest + isSet bool +} + +func (v NullableCreateSnapshotRequest) Get() *CreateSnapshotRequest { + return v.value +} + +func (v *NullableCreateSnapshotRequest) Set(val *CreateSnapshotRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSnapshotRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSnapshotRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSnapshotRequest(val *CreateSnapshotRequest) *NullableCreateSnapshotRequest { + return &NullableCreateSnapshotRequest{value: val, isSet: true} +} + +func (v NullableCreateSnapshotRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSnapshotRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go new file mode 100644 index 000000000..f70f95ab7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSnapshotResponse struct for CreateSnapshotResponse +type CreateSnapshotResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Snapshot *Snapshot `json:"Snapshot,omitempty"` +} + +// NewCreateSnapshotResponse instantiates a new CreateSnapshotResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSnapshotResponse() *CreateSnapshotResponse { + this := CreateSnapshotResponse{} + return &this +} + +// NewCreateSnapshotResponseWithDefaults instantiates a new CreateSnapshotResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSnapshotResponseWithDefaults() *CreateSnapshotResponse { + this := CreateSnapshotResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateSnapshotResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateSnapshotResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateSnapshotResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSnapshot returns the Snapshot field value if set, zero value otherwise. +func (o *CreateSnapshotResponse) GetSnapshot() Snapshot { + if o == nil || o.Snapshot == nil { + var ret Snapshot + return ret + } + return *o.Snapshot +} + +// GetSnapshotOk returns a tuple with the Snapshot field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSnapshotResponse) GetSnapshotOk() (*Snapshot, bool) { + if o == nil || o.Snapshot == nil { + return nil, false + } + return o.Snapshot, true +} + +// HasSnapshot returns a boolean if a field has been set. +func (o *CreateSnapshotResponse) HasSnapshot() bool { + if o != nil && o.Snapshot != nil { + return true + } + + return false +} + +// SetSnapshot gets a reference to the given Snapshot and assigns it to the Snapshot field. +func (o *CreateSnapshotResponse) SetSnapshot(v Snapshot) { + o.Snapshot = &v +} + +func (o CreateSnapshotResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Snapshot != nil { + toSerialize["Snapshot"] = o.Snapshot + } + return json.Marshal(toSerialize) +} + +type NullableCreateSnapshotResponse struct { + value *CreateSnapshotResponse + isSet bool +} + +func (v NullableCreateSnapshotResponse) Get() *CreateSnapshotResponse { + return v.value +} + +func (v *NullableCreateSnapshotResponse) Set(val *CreateSnapshotResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSnapshotResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSnapshotResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSnapshotResponse(val *CreateSnapshotResponse) *NullableCreateSnapshotResponse { + return &NullableCreateSnapshotResponse{value: val, isSet: true} +} + +func (v NullableCreateSnapshotResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSnapshotResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go new file mode 100644 index 000000000..dacf6602b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go @@ -0,0 +1,214 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSubnetRequest struct for CreateSubnetRequest +type CreateSubnetRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). + IpRange string `json:"IpRange"` + // The ID of the Net for which you want to create a Subnet. + NetId string `json:"NetId"` + // The name of the Subregion in which you want to create the Subnet. + SubregionName *string `json:"SubregionName,omitempty"` +} + +// NewCreateSubnetRequest instantiates a new CreateSubnetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSubnetRequest(ipRange string, netId string, ) *CreateSubnetRequest { + this := CreateSubnetRequest{} + this.IpRange = ipRange + this.NetId = netId + return &this +} + +// NewCreateSubnetRequestWithDefaults instantiates a new CreateSubnetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSubnetRequestWithDefaults() *CreateSubnetRequest { + this := CreateSubnetRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateSubnetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSubnetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateSubnetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateSubnetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetIpRange returns the IpRange field value +func (o *CreateSubnetRequest) GetIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value +// and a boolean to check if the value has been set. +func (o *CreateSubnetRequest) GetIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.IpRange, true +} + +// SetIpRange sets field value +func (o *CreateSubnetRequest) SetIpRange(v string) { + o.IpRange = v +} + +// GetNetId returns the NetId field value +func (o *CreateSubnetRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *CreateSubnetRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *CreateSubnetRequest) SetNetId(v string) { + o.NetId = v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *CreateSubnetRequest) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSubnetRequest) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *CreateSubnetRequest) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *CreateSubnetRequest) SetSubregionName(v string) { + o.SubregionName = &v +} + +func (o CreateSubnetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["IpRange"] = o.IpRange + } + if true { + toSerialize["NetId"] = o.NetId + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + return json.Marshal(toSerialize) +} + +type NullableCreateSubnetRequest struct { + value *CreateSubnetRequest + isSet bool +} + +func (v NullableCreateSubnetRequest) Get() *CreateSubnetRequest { + return v.value +} + +func (v *NullableCreateSubnetRequest) Set(val *CreateSubnetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSubnetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSubnetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSubnetRequest(val *CreateSubnetRequest) *NullableCreateSubnetRequest { + return &NullableCreateSubnetRequest{value: val, isSet: true} +} + +func (v NullableCreateSubnetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSubnetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go new file mode 100644 index 000000000..31c79f0ad --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateSubnetResponse struct for CreateSubnetResponse +type CreateSubnetResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Subnet *Subnet `json:"Subnet,omitempty"` +} + +// NewCreateSubnetResponse instantiates a new CreateSubnetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSubnetResponse() *CreateSubnetResponse { + this := CreateSubnetResponse{} + return &this +} + +// NewCreateSubnetResponseWithDefaults instantiates a new CreateSubnetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSubnetResponseWithDefaults() *CreateSubnetResponse { + this := CreateSubnetResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateSubnetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSubnetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateSubnetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateSubnetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSubnet returns the Subnet field value if set, zero value otherwise. +func (o *CreateSubnetResponse) GetSubnet() Subnet { + if o == nil || o.Subnet == nil { + var ret Subnet + return ret + } + return *o.Subnet +} + +// GetSubnetOk returns a tuple with the Subnet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSubnetResponse) GetSubnetOk() (*Subnet, bool) { + if o == nil || o.Subnet == nil { + return nil, false + } + return o.Subnet, true +} + +// HasSubnet returns a boolean if a field has been set. +func (o *CreateSubnetResponse) HasSubnet() bool { + if o != nil && o.Subnet != nil { + return true + } + + return false +} + +// SetSubnet gets a reference to the given Subnet and assigns it to the Subnet field. +func (o *CreateSubnetResponse) SetSubnet(v Subnet) { + o.Subnet = &v +} + +func (o CreateSubnetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Subnet != nil { + toSerialize["Subnet"] = o.Subnet + } + return json.Marshal(toSerialize) +} + +type NullableCreateSubnetResponse struct { + value *CreateSubnetResponse + isSet bool +} + +func (v NullableCreateSubnetResponse) Get() *CreateSubnetResponse { + return v.value +} + +func (v *NullableCreateSubnetResponse) Set(val *CreateSubnetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSubnetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSubnetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSubnetResponse(val *CreateSubnetResponse) *NullableCreateSubnetResponse { + return &NullableCreateSubnetResponse{value: val, isSet: true} +} + +func (v NullableCreateSubnetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSubnetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go new file mode 100644 index 000000000..71e56ac9a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateTagsRequest struct for CreateTagsRequest +type CreateTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more resource IDs. + ResourceIds []string `json:"ResourceIds"` + // One or more tags to add to the specified resources. + Tags []ResourceTag `json:"Tags"` +} + +// NewCreateTagsRequest instantiates a new CreateTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateTagsRequest(resourceIds []string, tags []ResourceTag, ) *CreateTagsRequest { + this := CreateTagsRequest{} + this.ResourceIds = resourceIds + this.Tags = tags + return &this +} + +// NewCreateTagsRequestWithDefaults instantiates a new CreateTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateTagsRequestWithDefaults() *CreateTagsRequest { + this := CreateTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetResourceIds returns the ResourceIds field value +func (o *CreateTagsRequest) GetResourceIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.ResourceIds +} + +// GetResourceIdsOk returns a tuple with the ResourceIds field value +// and a boolean to check if the value has been set. +func (o *CreateTagsRequest) GetResourceIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.ResourceIds, true +} + +// SetResourceIds sets field value +func (o *CreateTagsRequest) SetResourceIds(v []string) { + o.ResourceIds = v +} + +// GetTags returns the Tags field value +func (o *CreateTagsRequest) GetTags() []ResourceTag { + if o == nil { + var ret []ResourceTag + return ret + } + + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value +// and a boolean to check if the value has been set. +func (o *CreateTagsRequest) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil { + return nil, false + } + return &o.Tags, true +} + +// SetTags sets field value +func (o *CreateTagsRequest) SetTags(v []ResourceTag) { + o.Tags = v +} + +func (o CreateTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ResourceIds"] = o.ResourceIds + } + if true { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableCreateTagsRequest struct { + value *CreateTagsRequest + isSet bool +} + +func (v NullableCreateTagsRequest) Get() *CreateTagsRequest { + return v.value +} + +func (v *NullableCreateTagsRequest) Set(val *CreateTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateTagsRequest(val *CreateTagsRequest) *NullableCreateTagsRequest { + return &NullableCreateTagsRequest{value: val, isSet: true} +} + +func (v NullableCreateTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go new file mode 100644 index 000000000..55618b8ea --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateTagsResponse struct for CreateTagsResponse +type CreateTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateTagsResponse instantiates a new CreateTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateTagsResponse() *CreateTagsResponse { + this := CreateTagsResponse{} + return &this +} + +// NewCreateTagsResponseWithDefaults instantiates a new CreateTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateTagsResponseWithDefaults() *CreateTagsResponse { + this := CreateTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateTagsResponse struct { + value *CreateTagsResponse + isSet bool +} + +func (v NullableCreateTagsResponse) Get() *CreateTagsResponse { + return v.value +} + +func (v *NullableCreateTagsResponse) Set(val *CreateTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateTagsResponse(val *CreateTagsResponse) *NullableCreateTagsResponse { + return &NullableCreateTagsResponse{value: val, isSet: true} +} + +func (v NullableCreateTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go new file mode 100644 index 000000000..b393d6bd6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVirtualGatewayRequest struct for CreateVirtualGatewayRequest +type CreateVirtualGatewayRequest struct { + // The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). + ConnectionType string `json:"ConnectionType"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewCreateVirtualGatewayRequest instantiates a new CreateVirtualGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVirtualGatewayRequest(connectionType string, ) *CreateVirtualGatewayRequest { + this := CreateVirtualGatewayRequest{} + this.ConnectionType = connectionType + return &this +} + +// NewCreateVirtualGatewayRequestWithDefaults instantiates a new CreateVirtualGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVirtualGatewayRequestWithDefaults() *CreateVirtualGatewayRequest { + this := CreateVirtualGatewayRequest{} + return &this +} + +// GetConnectionType returns the ConnectionType field value +func (o *CreateVirtualGatewayRequest) GetConnectionType() string { + if o == nil { + var ret string + return ret + } + + return o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value +// and a boolean to check if the value has been set. +func (o *CreateVirtualGatewayRequest) GetConnectionTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ConnectionType, true +} + +// SetConnectionType sets field value +func (o *CreateVirtualGatewayRequest) SetConnectionType(v string) { + o.ConnectionType = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateVirtualGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVirtualGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateVirtualGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateVirtualGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o CreateVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableCreateVirtualGatewayRequest struct { + value *CreateVirtualGatewayRequest + isSet bool +} + +func (v NullableCreateVirtualGatewayRequest) Get() *CreateVirtualGatewayRequest { + return v.value +} + +func (v *NullableCreateVirtualGatewayRequest) Set(val *CreateVirtualGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVirtualGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVirtualGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVirtualGatewayRequest(val *CreateVirtualGatewayRequest) *NullableCreateVirtualGatewayRequest { + return &NullableCreateVirtualGatewayRequest{value: val, isSet: true} +} + +func (v NullableCreateVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVirtualGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go new file mode 100644 index 000000000..15b037e89 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVirtualGatewayResponse struct for CreateVirtualGatewayResponse +type CreateVirtualGatewayResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + VirtualGateway *VirtualGateway `json:"VirtualGateway,omitempty"` +} + +// NewCreateVirtualGatewayResponse instantiates a new CreateVirtualGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVirtualGatewayResponse() *CreateVirtualGatewayResponse { + this := CreateVirtualGatewayResponse{} + return &this +} + +// NewCreateVirtualGatewayResponseWithDefaults instantiates a new CreateVirtualGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVirtualGatewayResponseWithDefaults() *CreateVirtualGatewayResponse { + this := CreateVirtualGatewayResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateVirtualGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVirtualGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateVirtualGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateVirtualGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVirtualGateway returns the VirtualGateway field value if set, zero value otherwise. +func (o *CreateVirtualGatewayResponse) GetVirtualGateway() VirtualGateway { + if o == nil || o.VirtualGateway == nil { + var ret VirtualGateway + return ret + } + return *o.VirtualGateway +} + +// GetVirtualGatewayOk returns a tuple with the VirtualGateway field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVirtualGatewayResponse) GetVirtualGatewayOk() (*VirtualGateway, bool) { + if o == nil || o.VirtualGateway == nil { + return nil, false + } + return o.VirtualGateway, true +} + +// HasVirtualGateway returns a boolean if a field has been set. +func (o *CreateVirtualGatewayResponse) HasVirtualGateway() bool { + if o != nil && o.VirtualGateway != nil { + return true + } + + return false +} + +// SetVirtualGateway gets a reference to the given VirtualGateway and assigns it to the VirtualGateway field. +func (o *CreateVirtualGatewayResponse) SetVirtualGateway(v VirtualGateway) { + o.VirtualGateway = &v +} + +func (o CreateVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VirtualGateway != nil { + toSerialize["VirtualGateway"] = o.VirtualGateway + } + return json.Marshal(toSerialize) +} + +type NullableCreateVirtualGatewayResponse struct { + value *CreateVirtualGatewayResponse + isSet bool +} + +func (v NullableCreateVirtualGatewayResponse) Get() *CreateVirtualGatewayResponse { + return v.value +} + +func (v *NullableCreateVirtualGatewayResponse) Set(val *CreateVirtualGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVirtualGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVirtualGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVirtualGatewayResponse(val *CreateVirtualGatewayResponse) *NullableCreateVirtualGatewayResponse { + return &NullableCreateVirtualGatewayResponse{value: val, isSet: true} +} + +func (v NullableCreateVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVirtualGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go new file mode 100644 index 000000000..a40deeecb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go @@ -0,0 +1,816 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVmsRequest struct for CreateVmsRequest +type CreateVmsRequest struct { + // One or more block device mappings. + BlockDeviceMappings *[]BlockDeviceMappingVmCreation `json:"BlockDeviceMappings,omitempty"` + // By default or if `true`, the VM is started on creation. If `false`, the VM is stopped on creation. + BootOnCreation *bool `json:"BootOnCreation,omitempty"` + // If `true`, the VM is created with optimized BSU I/O. + BsuOptimized *bool `json:"BsuOptimized,omitempty"` + // A unique identifier which enables you to manage the idempotency. + ClientToken *string `json:"ClientToken,omitempty"` + // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. + DeletionProtection *bool `json:"DeletionProtection,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the OMI used to create the VM. You can find the list of OMIs by calling the [ReadImages](#readimages) method. + ImageId string `json:"ImageId"` + // The name of the keypair. + KeypairName *string `json:"KeypairName,omitempty"` + // The maximum number of VMs you want to create. If all the VMs cannot be created, the largest possible number of VMs above MinVmsCount is created. + MaxVmsCount *int32 `json:"MaxVmsCount,omitempty"` + // The minimum number of VMs you want to create. If this number of VMs cannot be created, no VMs are created. + MinVmsCount *int32 `json:"MinVmsCount,omitempty"` + // One or more NICs. If you specify this parameter, you must define one NIC as the primary network interface of the VM with `0` as its device number. + Nics *[]NicForVmCreation `json:"Nics,omitempty"` + // The performance of the VM (`standard` \\| `high` \\| `highest`). + Performance *string `json:"Performance,omitempty"` + Placement *Placement `json:"Placement,omitempty"` + // One or more private IP addresses of the VM. + PrivateIps *[]string `json:"PrivateIps,omitempty"` + // One or more IDs of security group for the VMs. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` + // One or more names of security groups for the VMs. + SecurityGroups *[]string `json:"SecurityGroups,omitempty"` + // The ID of the Subnet in which you want to create the VM. + SubnetId *string `json:"SubnetId,omitempty"` + // Data or script used to add a specific configuration to the VM. It must be base64-encoded. + UserData *string `json:"UserData,omitempty"` + // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. + VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` + // The type of VM (`t2.small` by default).
For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). + VmType *string `json:"VmType,omitempty"` +} + +// NewCreateVmsRequest instantiates a new CreateVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVmsRequest(imageId string, ) *CreateVmsRequest { + this := CreateVmsRequest{} + this.ImageId = imageId + var performance string = "high" + this.Performance = &performance + return &this +} + +// NewCreateVmsRequestWithDefaults instantiates a new CreateVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVmsRequestWithDefaults() *CreateVmsRequest { + this := CreateVmsRequest{} + var performance string = "high" + this.Performance = &performance + return &this +} + +// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetBlockDeviceMappings() []BlockDeviceMappingVmCreation { + if o == nil || o.BlockDeviceMappings == nil { + var ret []BlockDeviceMappingVmCreation + return ret + } + return *o.BlockDeviceMappings +} + +// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetBlockDeviceMappingsOk() (*[]BlockDeviceMappingVmCreation, bool) { + if o == nil || o.BlockDeviceMappings == nil { + return nil, false + } + return o.BlockDeviceMappings, true +} + +// HasBlockDeviceMappings returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasBlockDeviceMappings() bool { + if o != nil && o.BlockDeviceMappings != nil { + return true + } + + return false +} + +// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingVmCreation and assigns it to the BlockDeviceMappings field. +func (o *CreateVmsRequest) SetBlockDeviceMappings(v []BlockDeviceMappingVmCreation) { + o.BlockDeviceMappings = &v +} + +// GetBootOnCreation returns the BootOnCreation field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetBootOnCreation() bool { + if o == nil || o.BootOnCreation == nil { + var ret bool + return ret + } + return *o.BootOnCreation +} + +// GetBootOnCreationOk returns a tuple with the BootOnCreation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetBootOnCreationOk() (*bool, bool) { + if o == nil || o.BootOnCreation == nil { + return nil, false + } + return o.BootOnCreation, true +} + +// HasBootOnCreation returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasBootOnCreation() bool { + if o != nil && o.BootOnCreation != nil { + return true + } + + return false +} + +// SetBootOnCreation gets a reference to the given bool and assigns it to the BootOnCreation field. +func (o *CreateVmsRequest) SetBootOnCreation(v bool) { + o.BootOnCreation = &v +} + +// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetBsuOptimized() bool { + if o == nil || o.BsuOptimized == nil { + var ret bool + return ret + } + return *o.BsuOptimized +} + +// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetBsuOptimizedOk() (*bool, bool) { + if o == nil || o.BsuOptimized == nil { + return nil, false + } + return o.BsuOptimized, true +} + +// HasBsuOptimized returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasBsuOptimized() bool { + if o != nil && o.BsuOptimized != nil { + return true + } + + return false +} + +// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. +func (o *CreateVmsRequest) SetBsuOptimized(v bool) { + o.BsuOptimized = &v +} + +// GetClientToken returns the ClientToken field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetClientToken() string { + if o == nil || o.ClientToken == nil { + var ret string + return ret + } + return *o.ClientToken +} + +// GetClientTokenOk returns a tuple with the ClientToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetClientTokenOk() (*string, bool) { + if o == nil || o.ClientToken == nil { + return nil, false + } + return o.ClientToken, true +} + +// HasClientToken returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasClientToken() bool { + if o != nil && o.ClientToken != nil { + return true + } + + return false +} + +// SetClientToken gets a reference to the given string and assigns it to the ClientToken field. +func (o *CreateVmsRequest) SetClientToken(v string) { + o.ClientToken = &v +} + +// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetDeletionProtection() bool { + if o == nil || o.DeletionProtection == nil { + var ret bool + return ret + } + return *o.DeletionProtection +} + +// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetDeletionProtectionOk() (*bool, bool) { + if o == nil || o.DeletionProtection == nil { + return nil, false + } + return o.DeletionProtection, true +} + +// HasDeletionProtection returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasDeletionProtection() bool { + if o != nil && o.DeletionProtection != nil { + return true + } + + return false +} + +// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. +func (o *CreateVmsRequest) SetDeletionProtection(v bool) { + o.DeletionProtection = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetImageId returns the ImageId field value +func (o *CreateVmsRequest) GetImageId() string { + if o == nil { + var ret string + return ret + } + + return o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetImageIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ImageId, true +} + +// SetImageId sets field value +func (o *CreateVmsRequest) SetImageId(v string) { + o.ImageId = v +} + +// GetKeypairName returns the KeypairName field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetKeypairName() string { + if o == nil || o.KeypairName == nil { + var ret string + return ret + } + return *o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetKeypairNameOk() (*string, bool) { + if o == nil || o.KeypairName == nil { + return nil, false + } + return o.KeypairName, true +} + +// HasKeypairName returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasKeypairName() bool { + if o != nil && o.KeypairName != nil { + return true + } + + return false +} + +// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. +func (o *CreateVmsRequest) SetKeypairName(v string) { + o.KeypairName = &v +} + +// GetMaxVmsCount returns the MaxVmsCount field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetMaxVmsCount() int32 { + if o == nil || o.MaxVmsCount == nil { + var ret int32 + return ret + } + return *o.MaxVmsCount +} + +// GetMaxVmsCountOk returns a tuple with the MaxVmsCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetMaxVmsCountOk() (*int32, bool) { + if o == nil || o.MaxVmsCount == nil { + return nil, false + } + return o.MaxVmsCount, true +} + +// HasMaxVmsCount returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasMaxVmsCount() bool { + if o != nil && o.MaxVmsCount != nil { + return true + } + + return false +} + +// SetMaxVmsCount gets a reference to the given int32 and assigns it to the MaxVmsCount field. +func (o *CreateVmsRequest) SetMaxVmsCount(v int32) { + o.MaxVmsCount = &v +} + +// GetMinVmsCount returns the MinVmsCount field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetMinVmsCount() int32 { + if o == nil || o.MinVmsCount == nil { + var ret int32 + return ret + } + return *o.MinVmsCount +} + +// GetMinVmsCountOk returns a tuple with the MinVmsCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetMinVmsCountOk() (*int32, bool) { + if o == nil || o.MinVmsCount == nil { + return nil, false + } + return o.MinVmsCount, true +} + +// HasMinVmsCount returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasMinVmsCount() bool { + if o != nil && o.MinVmsCount != nil { + return true + } + + return false +} + +// SetMinVmsCount gets a reference to the given int32 and assigns it to the MinVmsCount field. +func (o *CreateVmsRequest) SetMinVmsCount(v int32) { + o.MinVmsCount = &v +} + +// GetNics returns the Nics field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetNics() []NicForVmCreation { + if o == nil || o.Nics == nil { + var ret []NicForVmCreation + return ret + } + return *o.Nics +} + +// GetNicsOk returns a tuple with the Nics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetNicsOk() (*[]NicForVmCreation, bool) { + if o == nil || o.Nics == nil { + return nil, false + } + return o.Nics, true +} + +// HasNics returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasNics() bool { + if o != nil && o.Nics != nil { + return true + } + + return false +} + +// SetNics gets a reference to the given []NicForVmCreation and assigns it to the Nics field. +func (o *CreateVmsRequest) SetNics(v []NicForVmCreation) { + o.Nics = &v +} + +// GetPerformance returns the Performance field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetPerformance() string { + if o == nil || o.Performance == nil { + var ret string + return ret + } + return *o.Performance +} + +// GetPerformanceOk returns a tuple with the Performance field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetPerformanceOk() (*string, bool) { + if o == nil || o.Performance == nil { + return nil, false + } + return o.Performance, true +} + +// HasPerformance returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasPerformance() bool { + if o != nil && o.Performance != nil { + return true + } + + return false +} + +// SetPerformance gets a reference to the given string and assigns it to the Performance field. +func (o *CreateVmsRequest) SetPerformance(v string) { + o.Performance = &v +} + +// GetPlacement returns the Placement field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetPlacement() Placement { + if o == nil || o.Placement == nil { + var ret Placement + return ret + } + return *o.Placement +} + +// GetPlacementOk returns a tuple with the Placement field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetPlacementOk() (*Placement, bool) { + if o == nil || o.Placement == nil { + return nil, false + } + return o.Placement, true +} + +// HasPlacement returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasPlacement() bool { + if o != nil && o.Placement != nil { + return true + } + + return false +} + +// SetPlacement gets a reference to the given Placement and assigns it to the Placement field. +func (o *CreateVmsRequest) SetPlacement(v Placement) { + o.Placement = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetPrivateIps() []string { + if o == nil || o.PrivateIps == nil { + var ret []string + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetPrivateIpsOk() (*[]string, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. +func (o *CreateVmsRequest) SetPrivateIps(v []string) { + o.PrivateIps = &v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *CreateVmsRequest) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetSecurityGroups() []string { + if o == nil || o.SecurityGroups == nil { + var ret []string + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetSecurityGroupsOk() (*[]string, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. +func (o *CreateVmsRequest) SetSecurityGroups(v []string) { + o.SecurityGroups = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *CreateVmsRequest) SetSubnetId(v string) { + o.SubnetId = &v +} + +// GetUserData returns the UserData field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetUserData() string { + if o == nil || o.UserData == nil { + var ret string + return ret + } + return *o.UserData +} + +// GetUserDataOk returns a tuple with the UserData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetUserDataOk() (*string, bool) { + if o == nil || o.UserData == nil { + return nil, false + } + return o.UserData, true +} + +// HasUserData returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasUserData() bool { + if o != nil && o.UserData != nil { + return true + } + + return false +} + +// SetUserData gets a reference to the given string and assigns it to the UserData field. +func (o *CreateVmsRequest) SetUserData(v string) { + o.UserData = &v +} + +// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetVmInitiatedShutdownBehavior() string { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + var ret string + return ret + } + return *o.VmInitiatedShutdownBehavior +} + +// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetVmInitiatedShutdownBehaviorOk() (*string, bool) { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + return nil, false + } + return o.VmInitiatedShutdownBehavior, true +} + +// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasVmInitiatedShutdownBehavior() bool { + if o != nil && o.VmInitiatedShutdownBehavior != nil { + return true + } + + return false +} + +// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. +func (o *CreateVmsRequest) SetVmInitiatedShutdownBehavior(v string) { + o.VmInitiatedShutdownBehavior = &v +} + +// GetVmType returns the VmType field value if set, zero value otherwise. +func (o *CreateVmsRequest) GetVmType() string { + if o == nil || o.VmType == nil { + var ret string + return ret + } + return *o.VmType +} + +// GetVmTypeOk returns a tuple with the VmType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsRequest) GetVmTypeOk() (*string, bool) { + if o == nil || o.VmType == nil { + return nil, false + } + return o.VmType, true +} + +// HasVmType returns a boolean if a field has been set. +func (o *CreateVmsRequest) HasVmType() bool { + if o != nil && o.VmType != nil { + return true + } + + return false +} + +// SetVmType gets a reference to the given string and assigns it to the VmType field. +func (o *CreateVmsRequest) SetVmType(v string) { + o.VmType = &v +} + +func (o CreateVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BlockDeviceMappings != nil { + toSerialize["BlockDeviceMappings"] = o.BlockDeviceMappings + } + if o.BootOnCreation != nil { + toSerialize["BootOnCreation"] = o.BootOnCreation + } + if o.BsuOptimized != nil { + toSerialize["BsuOptimized"] = o.BsuOptimized + } + if o.ClientToken != nil { + toSerialize["ClientToken"] = o.ClientToken + } + if o.DeletionProtection != nil { + toSerialize["DeletionProtection"] = o.DeletionProtection + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ImageId"] = o.ImageId + } + if o.KeypairName != nil { + toSerialize["KeypairName"] = o.KeypairName + } + if o.MaxVmsCount != nil { + toSerialize["MaxVmsCount"] = o.MaxVmsCount + } + if o.MinVmsCount != nil { + toSerialize["MinVmsCount"] = o.MinVmsCount + } + if o.Nics != nil { + toSerialize["Nics"] = o.Nics + } + if o.Performance != nil { + toSerialize["Performance"] = o.Performance + } + if o.Placement != nil { + toSerialize["Placement"] = o.Placement + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + if o.UserData != nil { + toSerialize["UserData"] = o.UserData + } + if o.VmInitiatedShutdownBehavior != nil { + toSerialize["VmInitiatedShutdownBehavior"] = o.VmInitiatedShutdownBehavior + } + if o.VmType != nil { + toSerialize["VmType"] = o.VmType + } + return json.Marshal(toSerialize) +} + +type NullableCreateVmsRequest struct { + value *CreateVmsRequest + isSet bool +} + +func (v NullableCreateVmsRequest) Get() *CreateVmsRequest { + return v.value +} + +func (v *NullableCreateVmsRequest) Set(val *CreateVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVmsRequest(val *CreateVmsRequest) *NullableCreateVmsRequest { + return &NullableCreateVmsRequest{value: val, isSet: true} +} + +func (v NullableCreateVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go new file mode 100644 index 000000000..7a2c37ff2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVmsResponse struct for CreateVmsResponse +type CreateVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more created VMs. + Vms *[]Vm `json:"Vms,omitempty"` +} + +// NewCreateVmsResponse instantiates a new CreateVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVmsResponse() *CreateVmsResponse { + this := CreateVmsResponse{} + return &this +} + +// NewCreateVmsResponseWithDefaults instantiates a new CreateVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVmsResponseWithDefaults() *CreateVmsResponse { + this := CreateVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVms returns the Vms field value if set, zero value otherwise. +func (o *CreateVmsResponse) GetVms() []Vm { + if o == nil || o.Vms == nil { + var ret []Vm + return ret + } + return *o.Vms +} + +// GetVmsOk returns a tuple with the Vms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVmsResponse) GetVmsOk() (*[]Vm, bool) { + if o == nil || o.Vms == nil { + return nil, false + } + return o.Vms, true +} + +// HasVms returns a boolean if a field has been set. +func (o *CreateVmsResponse) HasVms() bool { + if o != nil && o.Vms != nil { + return true + } + + return false +} + +// SetVms gets a reference to the given []Vm and assigns it to the Vms field. +func (o *CreateVmsResponse) SetVms(v []Vm) { + o.Vms = &v +} + +func (o CreateVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vms != nil { + toSerialize["Vms"] = o.Vms + } + return json.Marshal(toSerialize) +} + +type NullableCreateVmsResponse struct { + value *CreateVmsResponse + isSet bool +} + +func (v NullableCreateVmsResponse) Get() *CreateVmsResponse { + return v.value +} + +func (v *NullableCreateVmsResponse) Set(val *CreateVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVmsResponse(val *CreateVmsResponse) *NullableCreateVmsResponse { + return &NullableCreateVmsResponse{value: val, isSet: true} +} + +func (v NullableCreateVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go new file mode 100644 index 000000000..1e27b9b59 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go @@ -0,0 +1,295 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVolumeRequest struct for CreateVolumeRequest +type CreateVolumeRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + Iops *int32 `json:"Iops,omitempty"` + // The size of the volume, in gibibytes (GiB). The maximum allowed size for a volume is 14,901 GiB. This parameter is required if the volume is not created from a snapshot (`SnapshotId` unspecified). + Size *int32 `json:"Size,omitempty"` + // The ID of the snapshot from which you want to create the volume. + SnapshotId *string `json:"SnapshotId,omitempty"` + // The Subregion in which you want to create the volume. + SubregionName string `json:"SubregionName"` + // The type of volume you want to create (`io1` \\| `gp2` \\| `standard`). If not specified, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). + VolumeType *string `json:"VolumeType,omitempty"` +} + +// NewCreateVolumeRequest instantiates a new CreateVolumeRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVolumeRequest(subregionName string, ) *CreateVolumeRequest { + this := CreateVolumeRequest{} + this.SubregionName = subregionName + return &this +} + +// NewCreateVolumeRequestWithDefaults instantiates a new CreateVolumeRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVolumeRequestWithDefaults() *CreateVolumeRequest { + this := CreateVolumeRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateVolumeRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateVolumeRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateVolumeRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetIops returns the Iops field value if set, zero value otherwise. +func (o *CreateVolumeRequest) GetIops() int32 { + if o == nil || o.Iops == nil { + var ret int32 + return ret + } + return *o.Iops +} + +// GetIopsOk returns a tuple with the Iops field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetIopsOk() (*int32, bool) { + if o == nil || o.Iops == nil { + return nil, false + } + return o.Iops, true +} + +// HasIops returns a boolean if a field has been set. +func (o *CreateVolumeRequest) HasIops() bool { + if o != nil && o.Iops != nil { + return true + } + + return false +} + +// SetIops gets a reference to the given int32 and assigns it to the Iops field. +func (o *CreateVolumeRequest) SetIops(v int32) { + o.Iops = &v +} + +// GetSize returns the Size field value if set, zero value otherwise. +func (o *CreateVolumeRequest) GetSize() int32 { + if o == nil || o.Size == nil { + var ret int32 + return ret + } + return *o.Size +} + +// GetSizeOk returns a tuple with the Size field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetSizeOk() (*int32, bool) { + if o == nil || o.Size == nil { + return nil, false + } + return o.Size, true +} + +// HasSize returns a boolean if a field has been set. +func (o *CreateVolumeRequest) HasSize() bool { + if o != nil && o.Size != nil { + return true + } + + return false +} + +// SetSize gets a reference to the given int32 and assigns it to the Size field. +func (o *CreateVolumeRequest) SetSize(v int32) { + o.Size = &v +} + +// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. +func (o *CreateVolumeRequest) GetSnapshotId() string { + if o == nil || o.SnapshotId == nil { + var ret string + return ret + } + return *o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetSnapshotIdOk() (*string, bool) { + if o == nil || o.SnapshotId == nil { + return nil, false + } + return o.SnapshotId, true +} + +// HasSnapshotId returns a boolean if a field has been set. +func (o *CreateVolumeRequest) HasSnapshotId() bool { + if o != nil && o.SnapshotId != nil { + return true + } + + return false +} + +// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. +func (o *CreateVolumeRequest) SetSnapshotId(v string) { + o.SnapshotId = &v +} + +// GetSubregionName returns the SubregionName field value +func (o *CreateVolumeRequest) GetSubregionName() string { + if o == nil { + var ret string + return ret + } + + return o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetSubregionNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubregionName, true +} + +// SetSubregionName sets field value +func (o *CreateVolumeRequest) SetSubregionName(v string) { + o.SubregionName = v +} + +// GetVolumeType returns the VolumeType field value if set, zero value otherwise. +func (o *CreateVolumeRequest) GetVolumeType() string { + if o == nil || o.VolumeType == nil { + var ret string + return ret + } + return *o.VolumeType +} + +// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeRequest) GetVolumeTypeOk() (*string, bool) { + if o == nil || o.VolumeType == nil { + return nil, false + } + return o.VolumeType, true +} + +// HasVolumeType returns a boolean if a field has been set. +func (o *CreateVolumeRequest) HasVolumeType() bool { + if o != nil && o.VolumeType != nil { + return true + } + + return false +} + +// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. +func (o *CreateVolumeRequest) SetVolumeType(v string) { + o.VolumeType = &v +} + +func (o CreateVolumeRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Iops != nil { + toSerialize["Iops"] = o.Iops + } + if o.Size != nil { + toSerialize["Size"] = o.Size + } + if o.SnapshotId != nil { + toSerialize["SnapshotId"] = o.SnapshotId + } + if true { + toSerialize["SubregionName"] = o.SubregionName + } + if o.VolumeType != nil { + toSerialize["VolumeType"] = o.VolumeType + } + return json.Marshal(toSerialize) +} + +type NullableCreateVolumeRequest struct { + value *CreateVolumeRequest + isSet bool +} + +func (v NullableCreateVolumeRequest) Get() *CreateVolumeRequest { + return v.value +} + +func (v *NullableCreateVolumeRequest) Set(val *CreateVolumeRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVolumeRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVolumeRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVolumeRequest(val *CreateVolumeRequest) *NullableCreateVolumeRequest { + return &NullableCreateVolumeRequest{value: val, isSet: true} +} + +func (v NullableCreateVolumeRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVolumeRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go new file mode 100644 index 000000000..64e527d45 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVolumeResponse struct for CreateVolumeResponse +type CreateVolumeResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Volume *Volume `json:"Volume,omitempty"` +} + +// NewCreateVolumeResponse instantiates a new CreateVolumeResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVolumeResponse() *CreateVolumeResponse { + this := CreateVolumeResponse{} + return &this +} + +// NewCreateVolumeResponseWithDefaults instantiates a new CreateVolumeResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVolumeResponseWithDefaults() *CreateVolumeResponse { + this := CreateVolumeResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateVolumeResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateVolumeResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateVolumeResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVolume returns the Volume field value if set, zero value otherwise. +func (o *CreateVolumeResponse) GetVolume() Volume { + if o == nil || o.Volume == nil { + var ret Volume + return ret + } + return *o.Volume +} + +// GetVolumeOk returns a tuple with the Volume field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVolumeResponse) GetVolumeOk() (*Volume, bool) { + if o == nil || o.Volume == nil { + return nil, false + } + return o.Volume, true +} + +// HasVolume returns a boolean if a field has been set. +func (o *CreateVolumeResponse) HasVolume() bool { + if o != nil && o.Volume != nil { + return true + } + + return false +} + +// SetVolume gets a reference to the given Volume and assigns it to the Volume field. +func (o *CreateVolumeResponse) SetVolume(v Volume) { + o.Volume = &v +} + +func (o CreateVolumeResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Volume != nil { + toSerialize["Volume"] = o.Volume + } + return json.Marshal(toSerialize) +} + +type NullableCreateVolumeResponse struct { + value *CreateVolumeResponse + isSet bool +} + +func (v NullableCreateVolumeResponse) Get() *CreateVolumeResponse { + return v.value +} + +func (v *NullableCreateVolumeResponse) Set(val *CreateVolumeResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVolumeResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVolumeResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVolumeResponse(val *CreateVolumeResponse) *NullableCreateVolumeResponse { + return &NullableCreateVolumeResponse{value: val, isSet: true} +} + +func (v NullableCreateVolumeResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVolumeResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go new file mode 100644 index 000000000..017c8d830 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go @@ -0,0 +1,244 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVpnConnectionRequest struct for CreateVpnConnectionRequest +type CreateVpnConnectionRequest struct { + // The ID of the client gateway. + ClientGatewayId string `json:"ClientGatewayId"` + // The type of VPN connection (only `ipsec.1` is supported). + ConnectionType string `json:"ConnectionType"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). + StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` + // The ID of the virtual gateway. + VirtualGatewayId string `json:"VirtualGatewayId"` +} + +// NewCreateVpnConnectionRequest instantiates a new CreateVpnConnectionRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVpnConnectionRequest(clientGatewayId string, connectionType string, virtualGatewayId string, ) *CreateVpnConnectionRequest { + this := CreateVpnConnectionRequest{} + this.ClientGatewayId = clientGatewayId + this.ConnectionType = connectionType + this.VirtualGatewayId = virtualGatewayId + return &this +} + +// NewCreateVpnConnectionRequestWithDefaults instantiates a new CreateVpnConnectionRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVpnConnectionRequestWithDefaults() *CreateVpnConnectionRequest { + this := CreateVpnConnectionRequest{} + return &this +} + +// GetClientGatewayId returns the ClientGatewayId field value +func (o *CreateVpnConnectionRequest) GetClientGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.ClientGatewayId +} + +// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRequest) GetClientGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ClientGatewayId, true +} + +// SetClientGatewayId sets field value +func (o *CreateVpnConnectionRequest) SetClientGatewayId(v string) { + o.ClientGatewayId = v +} + +// GetConnectionType returns the ConnectionType field value +func (o *CreateVpnConnectionRequest) GetConnectionType() string { + if o == nil { + var ret string + return ret + } + + return o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRequest) GetConnectionTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ConnectionType, true +} + +// SetConnectionType sets field value +func (o *CreateVpnConnectionRequest) SetConnectionType(v string) { + o.ConnectionType = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateVpnConnectionRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateVpnConnectionRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateVpnConnectionRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. +func (o *CreateVpnConnectionRequest) GetStaticRoutesOnly() bool { + if o == nil || o.StaticRoutesOnly == nil { + var ret bool + return ret + } + return *o.StaticRoutesOnly +} + +// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRequest) GetStaticRoutesOnlyOk() (*bool, bool) { + if o == nil || o.StaticRoutesOnly == nil { + return nil, false + } + return o.StaticRoutesOnly, true +} + +// HasStaticRoutesOnly returns a boolean if a field has been set. +func (o *CreateVpnConnectionRequest) HasStaticRoutesOnly() bool { + if o != nil && o.StaticRoutesOnly != nil { + return true + } + + return false +} + +// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. +func (o *CreateVpnConnectionRequest) SetStaticRoutesOnly(v bool) { + o.StaticRoutesOnly = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *CreateVpnConnectionRequest) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRequest) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *CreateVpnConnectionRequest) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +func (o CreateVpnConnectionRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["ClientGatewayId"] = o.ClientGatewayId + } + if true { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.StaticRoutesOnly != nil { + toSerialize["StaticRoutesOnly"] = o.StaticRoutesOnly + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableCreateVpnConnectionRequest struct { + value *CreateVpnConnectionRequest + isSet bool +} + +func (v NullableCreateVpnConnectionRequest) Get() *CreateVpnConnectionRequest { + return v.value +} + +func (v *NullableCreateVpnConnectionRequest) Set(val *CreateVpnConnectionRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVpnConnectionRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVpnConnectionRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVpnConnectionRequest(val *CreateVpnConnectionRequest) *NullableCreateVpnConnectionRequest { + return &NullableCreateVpnConnectionRequest{value: val, isSet: true} +} + +func (v NullableCreateVpnConnectionRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVpnConnectionRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go new file mode 100644 index 000000000..1d2519375 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVpnConnectionResponse struct for CreateVpnConnectionResponse +type CreateVpnConnectionResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + VpnConnection *VpnConnection `json:"VpnConnection,omitempty"` +} + +// NewCreateVpnConnectionResponse instantiates a new CreateVpnConnectionResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVpnConnectionResponse() *CreateVpnConnectionResponse { + this := CreateVpnConnectionResponse{} + return &this +} + +// NewCreateVpnConnectionResponseWithDefaults instantiates a new CreateVpnConnectionResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVpnConnectionResponseWithDefaults() *CreateVpnConnectionResponse { + this := CreateVpnConnectionResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateVpnConnectionResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateVpnConnectionResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateVpnConnectionResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVpnConnection returns the VpnConnection field value if set, zero value otherwise. +func (o *CreateVpnConnectionResponse) GetVpnConnection() VpnConnection { + if o == nil || o.VpnConnection == nil { + var ret VpnConnection + return ret + } + return *o.VpnConnection +} + +// GetVpnConnectionOk returns a tuple with the VpnConnection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionResponse) GetVpnConnectionOk() (*VpnConnection, bool) { + if o == nil || o.VpnConnection == nil { + return nil, false + } + return o.VpnConnection, true +} + +// HasVpnConnection returns a boolean if a field has been set. +func (o *CreateVpnConnectionResponse) HasVpnConnection() bool { + if o != nil && o.VpnConnection != nil { + return true + } + + return false +} + +// SetVpnConnection gets a reference to the given VpnConnection and assigns it to the VpnConnection field. +func (o *CreateVpnConnectionResponse) SetVpnConnection(v VpnConnection) { + o.VpnConnection = &v +} + +func (o CreateVpnConnectionResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VpnConnection != nil { + toSerialize["VpnConnection"] = o.VpnConnection + } + return json.Marshal(toSerialize) +} + +type NullableCreateVpnConnectionResponse struct { + value *CreateVpnConnectionResponse + isSet bool +} + +func (v NullableCreateVpnConnectionResponse) Get() *CreateVpnConnectionResponse { + return v.value +} + +func (v *NullableCreateVpnConnectionResponse) Set(val *CreateVpnConnectionResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVpnConnectionResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVpnConnectionResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVpnConnectionResponse(val *CreateVpnConnectionResponse) *NullableCreateVpnConnectionResponse { + return &NullableCreateVpnConnectionResponse{value: val, isSet: true} +} + +func (v NullableCreateVpnConnectionResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVpnConnectionResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go new file mode 100644 index 000000000..e4a95a066 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVpnConnectionRouteRequest struct for CreateVpnConnectionRouteRequest +type CreateVpnConnectionRouteRequest struct { + // The network prefix of the route, in CIDR notation (for example, 10.12.0.0/16). + DestinationIpRange string `json:"DestinationIpRange"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the target VPN connection of the static route. + VpnConnectionId string `json:"VpnConnectionId"` +} + +// NewCreateVpnConnectionRouteRequest instantiates a new CreateVpnConnectionRouteRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVpnConnectionRouteRequest(destinationIpRange string, vpnConnectionId string, ) *CreateVpnConnectionRouteRequest { + this := CreateVpnConnectionRouteRequest{} + this.DestinationIpRange = destinationIpRange + this.VpnConnectionId = vpnConnectionId + return &this +} + +// NewCreateVpnConnectionRouteRequestWithDefaults instantiates a new CreateVpnConnectionRouteRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVpnConnectionRouteRequestWithDefaults() *CreateVpnConnectionRouteRequest { + this := CreateVpnConnectionRouteRequest{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value +func (o *CreateVpnConnectionRouteRequest) GetDestinationIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRouteRequest) GetDestinationIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationIpRange, true +} + +// SetDestinationIpRange sets field value +func (o *CreateVpnConnectionRouteRequest) SetDestinationIpRange(v string) { + o.DestinationIpRange = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *CreateVpnConnectionRouteRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRouteRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *CreateVpnConnectionRouteRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *CreateVpnConnectionRouteRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVpnConnectionId returns the VpnConnectionId field value +func (o *CreateVpnConnectionRouteRequest) GetVpnConnectionId() string { + if o == nil { + var ret string + return ret + } + + return o.VpnConnectionId +} + +// GetVpnConnectionIdOk returns a tuple with the VpnConnectionId field value +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRouteRequest) GetVpnConnectionIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VpnConnectionId, true +} + +// SetVpnConnectionId sets field value +func (o *CreateVpnConnectionRouteRequest) SetVpnConnectionId(v string) { + o.VpnConnectionId = v +} + +func (o CreateVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VpnConnectionId"] = o.VpnConnectionId + } + return json.Marshal(toSerialize) +} + +type NullableCreateVpnConnectionRouteRequest struct { + value *CreateVpnConnectionRouteRequest + isSet bool +} + +func (v NullableCreateVpnConnectionRouteRequest) Get() *CreateVpnConnectionRouteRequest { + return v.value +} + +func (v *NullableCreateVpnConnectionRouteRequest) Set(val *CreateVpnConnectionRouteRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVpnConnectionRouteRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVpnConnectionRouteRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVpnConnectionRouteRequest(val *CreateVpnConnectionRouteRequest) *NullableCreateVpnConnectionRouteRequest { + return &NullableCreateVpnConnectionRouteRequest{value: val, isSet: true} +} + +func (v NullableCreateVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVpnConnectionRouteRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go new file mode 100644 index 000000000..4a19d8633 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// CreateVpnConnectionRouteResponse struct for CreateVpnConnectionRouteResponse +type CreateVpnConnectionRouteResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewCreateVpnConnectionRouteResponse instantiates a new CreateVpnConnectionRouteResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateVpnConnectionRouteResponse() *CreateVpnConnectionRouteResponse { + this := CreateVpnConnectionRouteResponse{} + return &this +} + +// NewCreateVpnConnectionRouteResponseWithDefaults instantiates a new CreateVpnConnectionRouteResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateVpnConnectionRouteResponseWithDefaults() *CreateVpnConnectionRouteResponse { + this := CreateVpnConnectionRouteResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *CreateVpnConnectionRouteResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateVpnConnectionRouteResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *CreateVpnConnectionRouteResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *CreateVpnConnectionRouteResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o CreateVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableCreateVpnConnectionRouteResponse struct { + value *CreateVpnConnectionRouteResponse + isSet bool +} + +func (v NullableCreateVpnConnectionRouteResponse) Get() *CreateVpnConnectionRouteResponse { + return v.value +} + +func (v *NullableCreateVpnConnectionRouteResponse) Set(val *CreateVpnConnectionRouteResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateVpnConnectionRouteResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateVpnConnectionRouteResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateVpnConnectionRouteResponse(val *CreateVpnConnectionRouteResponse) *NullableCreateVpnConnectionRouteResponse { + return &NullableCreateVpnConnectionRouteResponse{value: val, isSet: true} +} + +func (v NullableCreateVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateVpnConnectionRouteResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go new file mode 100644 index 000000000..1f3f145a1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteAccessKeyRequest struct for DeleteAccessKeyRequest +type DeleteAccessKeyRequest struct { + // The ID of the access key you want to delete. + AccessKeyId string `json:"AccessKeyId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewDeleteAccessKeyRequest instantiates a new DeleteAccessKeyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteAccessKeyRequest(accessKeyId string, ) *DeleteAccessKeyRequest { + this := DeleteAccessKeyRequest{} + this.AccessKeyId = accessKeyId + return &this +} + +// NewDeleteAccessKeyRequestWithDefaults instantiates a new DeleteAccessKeyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteAccessKeyRequestWithDefaults() *DeleteAccessKeyRequest { + this := DeleteAccessKeyRequest{} + return &this +} + +// GetAccessKeyId returns the AccessKeyId field value +func (o *DeleteAccessKeyRequest) GetAccessKeyId() string { + if o == nil { + var ret string + return ret + } + + return o.AccessKeyId +} + +// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value +// and a boolean to check if the value has been set. +func (o *DeleteAccessKeyRequest) GetAccessKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.AccessKeyId, true +} + +// SetAccessKeyId sets field value +func (o *DeleteAccessKeyRequest) SetAccessKeyId(v string) { + o.AccessKeyId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteAccessKeyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteAccessKeyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteAccessKeyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteAccessKeyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o DeleteAccessKeyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["AccessKeyId"] = o.AccessKeyId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableDeleteAccessKeyRequest struct { + value *DeleteAccessKeyRequest + isSet bool +} + +func (v NullableDeleteAccessKeyRequest) Get() *DeleteAccessKeyRequest { + return v.value +} + +func (v *NullableDeleteAccessKeyRequest) Set(val *DeleteAccessKeyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteAccessKeyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteAccessKeyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteAccessKeyRequest(val *DeleteAccessKeyRequest) *NullableDeleteAccessKeyRequest { + return &NullableDeleteAccessKeyRequest{value: val, isSet: true} +} + +func (v NullableDeleteAccessKeyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteAccessKeyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go new file mode 100644 index 000000000..79266dc2a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteAccessKeyResponse struct for DeleteAccessKeyResponse +type DeleteAccessKeyResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteAccessKeyResponse instantiates a new DeleteAccessKeyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteAccessKeyResponse() *DeleteAccessKeyResponse { + this := DeleteAccessKeyResponse{} + return &this +} + +// NewDeleteAccessKeyResponseWithDefaults instantiates a new DeleteAccessKeyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteAccessKeyResponseWithDefaults() *DeleteAccessKeyResponse { + this := DeleteAccessKeyResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteAccessKeyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteAccessKeyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteAccessKeyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteAccessKeyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteAccessKeyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteAccessKeyResponse struct { + value *DeleteAccessKeyResponse + isSet bool +} + +func (v NullableDeleteAccessKeyResponse) Get() *DeleteAccessKeyResponse { + return v.value +} + +func (v *NullableDeleteAccessKeyResponse) Set(val *DeleteAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteAccessKeyResponse(val *DeleteAccessKeyResponse) *NullableDeleteAccessKeyResponse { + return &NullableDeleteAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableDeleteAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go new file mode 100644 index 000000000..42e37093a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteClientGatewayRequest struct for DeleteClientGatewayRequest +type DeleteClientGatewayRequest struct { + // The ID of the client gateway you want to delete. + ClientGatewayId string `json:"ClientGatewayId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewDeleteClientGatewayRequest instantiates a new DeleteClientGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteClientGatewayRequest(clientGatewayId string, ) *DeleteClientGatewayRequest { + this := DeleteClientGatewayRequest{} + this.ClientGatewayId = clientGatewayId + return &this +} + +// NewDeleteClientGatewayRequestWithDefaults instantiates a new DeleteClientGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteClientGatewayRequestWithDefaults() *DeleteClientGatewayRequest { + this := DeleteClientGatewayRequest{} + return &this +} + +// GetClientGatewayId returns the ClientGatewayId field value +func (o *DeleteClientGatewayRequest) GetClientGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.ClientGatewayId +} + +// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value +// and a boolean to check if the value has been set. +func (o *DeleteClientGatewayRequest) GetClientGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ClientGatewayId, true +} + +// SetClientGatewayId sets field value +func (o *DeleteClientGatewayRequest) SetClientGatewayId(v string) { + o.ClientGatewayId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteClientGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteClientGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteClientGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteClientGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o DeleteClientGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["ClientGatewayId"] = o.ClientGatewayId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableDeleteClientGatewayRequest struct { + value *DeleteClientGatewayRequest + isSet bool +} + +func (v NullableDeleteClientGatewayRequest) Get() *DeleteClientGatewayRequest { + return v.value +} + +func (v *NullableDeleteClientGatewayRequest) Set(val *DeleteClientGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteClientGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteClientGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteClientGatewayRequest(val *DeleteClientGatewayRequest) *NullableDeleteClientGatewayRequest { + return &NullableDeleteClientGatewayRequest{value: val, isSet: true} +} + +func (v NullableDeleteClientGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteClientGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go new file mode 100644 index 000000000..af6fc0be6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteClientGatewayResponse struct for DeleteClientGatewayResponse +type DeleteClientGatewayResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteClientGatewayResponse instantiates a new DeleteClientGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteClientGatewayResponse() *DeleteClientGatewayResponse { + this := DeleteClientGatewayResponse{} + return &this +} + +// NewDeleteClientGatewayResponseWithDefaults instantiates a new DeleteClientGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteClientGatewayResponseWithDefaults() *DeleteClientGatewayResponse { + this := DeleteClientGatewayResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteClientGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteClientGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteClientGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteClientGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteClientGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteClientGatewayResponse struct { + value *DeleteClientGatewayResponse + isSet bool +} + +func (v NullableDeleteClientGatewayResponse) Get() *DeleteClientGatewayResponse { + return v.value +} + +func (v *NullableDeleteClientGatewayResponse) Set(val *DeleteClientGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteClientGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteClientGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteClientGatewayResponse(val *DeleteClientGatewayResponse) *NullableDeleteClientGatewayResponse { + return &NullableDeleteClientGatewayResponse{value: val, isSet: true} +} + +func (v NullableDeleteClientGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteClientGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go new file mode 100644 index 000000000..e20242c15 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDhcpOptionsRequest struct for DeleteDhcpOptionsRequest +type DeleteDhcpOptionsRequest struct { + // The ID of the DHCP options set you want to delete. + DhcpOptionsSetId string `json:"DhcpOptionsSetId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewDeleteDhcpOptionsRequest instantiates a new DeleteDhcpOptionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDhcpOptionsRequest(dhcpOptionsSetId string, ) *DeleteDhcpOptionsRequest { + this := DeleteDhcpOptionsRequest{} + this.DhcpOptionsSetId = dhcpOptionsSetId + return &this +} + +// NewDeleteDhcpOptionsRequestWithDefaults instantiates a new DeleteDhcpOptionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDhcpOptionsRequestWithDefaults() *DeleteDhcpOptionsRequest { + this := DeleteDhcpOptionsRequest{} + return &this +} + +// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value +func (o *DeleteDhcpOptionsRequest) GetDhcpOptionsSetId() string { + if o == nil { + var ret string + return ret + } + + return o.DhcpOptionsSetId +} + +// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value +// and a boolean to check if the value has been set. +func (o *DeleteDhcpOptionsRequest) GetDhcpOptionsSetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DhcpOptionsSetId, true +} + +// SetDhcpOptionsSetId sets field value +func (o *DeleteDhcpOptionsRequest) SetDhcpOptionsSetId(v string) { + o.DhcpOptionsSetId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteDhcpOptionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDhcpOptionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteDhcpOptionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteDhcpOptionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o DeleteDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DhcpOptionsSetId"] = o.DhcpOptionsSetId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDhcpOptionsRequest struct { + value *DeleteDhcpOptionsRequest + isSet bool +} + +func (v NullableDeleteDhcpOptionsRequest) Get() *DeleteDhcpOptionsRequest { + return v.value +} + +func (v *NullableDeleteDhcpOptionsRequest) Set(val *DeleteDhcpOptionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDhcpOptionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDhcpOptionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDhcpOptionsRequest(val *DeleteDhcpOptionsRequest) *NullableDeleteDhcpOptionsRequest { + return &NullableDeleteDhcpOptionsRequest{value: val, isSet: true} +} + +func (v NullableDeleteDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDhcpOptionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go new file mode 100644 index 000000000..d5cb60ca7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDhcpOptionsResponse struct for DeleteDhcpOptionsResponse +type DeleteDhcpOptionsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteDhcpOptionsResponse instantiates a new DeleteDhcpOptionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDhcpOptionsResponse() *DeleteDhcpOptionsResponse { + this := DeleteDhcpOptionsResponse{} + return &this +} + +// NewDeleteDhcpOptionsResponseWithDefaults instantiates a new DeleteDhcpOptionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDhcpOptionsResponseWithDefaults() *DeleteDhcpOptionsResponse { + this := DeleteDhcpOptionsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteDhcpOptionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDhcpOptionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteDhcpOptionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteDhcpOptionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDhcpOptionsResponse struct { + value *DeleteDhcpOptionsResponse + isSet bool +} + +func (v NullableDeleteDhcpOptionsResponse) Get() *DeleteDhcpOptionsResponse { + return v.value +} + +func (v *NullableDeleteDhcpOptionsResponse) Set(val *DeleteDhcpOptionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDhcpOptionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDhcpOptionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDhcpOptionsResponse(val *DeleteDhcpOptionsResponse) *NullableDeleteDhcpOptionsResponse { + return &NullableDeleteDhcpOptionsResponse{value: val, isSet: true} +} + +func (v NullableDeleteDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDhcpOptionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go new file mode 100644 index 000000000..587cc0481 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDirectLinkInterfaceRequest struct for DeleteDirectLinkInterfaceRequest +type DeleteDirectLinkInterfaceRequest struct { + // The ID of the DirectLink interface you want to delete. + DirectLinkInterfaceId string `json:"DirectLinkInterfaceId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewDeleteDirectLinkInterfaceRequest instantiates a new DeleteDirectLinkInterfaceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDirectLinkInterfaceRequest(directLinkInterfaceId string, ) *DeleteDirectLinkInterfaceRequest { + this := DeleteDirectLinkInterfaceRequest{} + this.DirectLinkInterfaceId = directLinkInterfaceId + return &this +} + +// NewDeleteDirectLinkInterfaceRequestWithDefaults instantiates a new DeleteDirectLinkInterfaceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDirectLinkInterfaceRequestWithDefaults() *DeleteDirectLinkInterfaceRequest { + this := DeleteDirectLinkInterfaceRequest{} + return &this +} + +// GetDirectLinkInterfaceId returns the DirectLinkInterfaceId field value +func (o *DeleteDirectLinkInterfaceRequest) GetDirectLinkInterfaceId() string { + if o == nil { + var ret string + return ret + } + + return o.DirectLinkInterfaceId +} + +// GetDirectLinkInterfaceIdOk returns a tuple with the DirectLinkInterfaceId field value +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkInterfaceRequest) GetDirectLinkInterfaceIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkInterfaceId, true +} + +// SetDirectLinkInterfaceId sets field value +func (o *DeleteDirectLinkInterfaceRequest) SetDirectLinkInterfaceId(v string) { + o.DirectLinkInterfaceId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteDirectLinkInterfaceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkInterfaceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteDirectLinkInterfaceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteDirectLinkInterfaceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o DeleteDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DirectLinkInterfaceId"] = o.DirectLinkInterfaceId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDirectLinkInterfaceRequest struct { + value *DeleteDirectLinkInterfaceRequest + isSet bool +} + +func (v NullableDeleteDirectLinkInterfaceRequest) Get() *DeleteDirectLinkInterfaceRequest { + return v.value +} + +func (v *NullableDeleteDirectLinkInterfaceRequest) Set(val *DeleteDirectLinkInterfaceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDirectLinkInterfaceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDirectLinkInterfaceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDirectLinkInterfaceRequest(val *DeleteDirectLinkInterfaceRequest) *NullableDeleteDirectLinkInterfaceRequest { + return &NullableDeleteDirectLinkInterfaceRequest{value: val, isSet: true} +} + +func (v NullableDeleteDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDirectLinkInterfaceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go new file mode 100644 index 000000000..0915d622a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDirectLinkInterfaceResponse struct for DeleteDirectLinkInterfaceResponse +type DeleteDirectLinkInterfaceResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteDirectLinkInterfaceResponse instantiates a new DeleteDirectLinkInterfaceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDirectLinkInterfaceResponse() *DeleteDirectLinkInterfaceResponse { + this := DeleteDirectLinkInterfaceResponse{} + return &this +} + +// NewDeleteDirectLinkInterfaceResponseWithDefaults instantiates a new DeleteDirectLinkInterfaceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDirectLinkInterfaceResponseWithDefaults() *DeleteDirectLinkInterfaceResponse { + this := DeleteDirectLinkInterfaceResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteDirectLinkInterfaceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkInterfaceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteDirectLinkInterfaceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteDirectLinkInterfaceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDirectLinkInterfaceResponse struct { + value *DeleteDirectLinkInterfaceResponse + isSet bool +} + +func (v NullableDeleteDirectLinkInterfaceResponse) Get() *DeleteDirectLinkInterfaceResponse { + return v.value +} + +func (v *NullableDeleteDirectLinkInterfaceResponse) Set(val *DeleteDirectLinkInterfaceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDirectLinkInterfaceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDirectLinkInterfaceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDirectLinkInterfaceResponse(val *DeleteDirectLinkInterfaceResponse) *NullableDeleteDirectLinkInterfaceResponse { + return &NullableDeleteDirectLinkInterfaceResponse{value: val, isSet: true} +} + +func (v NullableDeleteDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDirectLinkInterfaceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go new file mode 100644 index 000000000..cda1962aa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDirectLinkRequest struct for DeleteDirectLinkRequest +type DeleteDirectLinkRequest struct { + // The ID of the DirectLink you want to delete. + DirectLinkId string `json:"DirectLinkId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewDeleteDirectLinkRequest instantiates a new DeleteDirectLinkRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDirectLinkRequest(directLinkId string, ) *DeleteDirectLinkRequest { + this := DeleteDirectLinkRequest{} + this.DirectLinkId = directLinkId + return &this +} + +// NewDeleteDirectLinkRequestWithDefaults instantiates a new DeleteDirectLinkRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDirectLinkRequestWithDefaults() *DeleteDirectLinkRequest { + this := DeleteDirectLinkRequest{} + return &this +} + +// GetDirectLinkId returns the DirectLinkId field value +func (o *DeleteDirectLinkRequest) GetDirectLinkId() string { + if o == nil { + var ret string + return ret + } + + return o.DirectLinkId +} + +// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkRequest) GetDirectLinkIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkId, true +} + +// SetDirectLinkId sets field value +func (o *DeleteDirectLinkRequest) SetDirectLinkId(v string) { + o.DirectLinkId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteDirectLinkRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteDirectLinkRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteDirectLinkRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o DeleteDirectLinkRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DirectLinkId"] = o.DirectLinkId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDirectLinkRequest struct { + value *DeleteDirectLinkRequest + isSet bool +} + +func (v NullableDeleteDirectLinkRequest) Get() *DeleteDirectLinkRequest { + return v.value +} + +func (v *NullableDeleteDirectLinkRequest) Set(val *DeleteDirectLinkRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDirectLinkRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDirectLinkRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDirectLinkRequest(val *DeleteDirectLinkRequest) *NullableDeleteDirectLinkRequest { + return &NullableDeleteDirectLinkRequest{value: val, isSet: true} +} + +func (v NullableDeleteDirectLinkRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDirectLinkRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go new file mode 100644 index 000000000..dfb0acaf6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteDirectLinkResponse struct for DeleteDirectLinkResponse +type DeleteDirectLinkResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteDirectLinkResponse instantiates a new DeleteDirectLinkResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteDirectLinkResponse() *DeleteDirectLinkResponse { + this := DeleteDirectLinkResponse{} + return &this +} + +// NewDeleteDirectLinkResponseWithDefaults instantiates a new DeleteDirectLinkResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteDirectLinkResponseWithDefaults() *DeleteDirectLinkResponse { + this := DeleteDirectLinkResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteDirectLinkResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteDirectLinkResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteDirectLinkResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteDirectLinkResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteDirectLinkResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteDirectLinkResponse struct { + value *DeleteDirectLinkResponse + isSet bool +} + +func (v NullableDeleteDirectLinkResponse) Get() *DeleteDirectLinkResponse { + return v.value +} + +func (v *NullableDeleteDirectLinkResponse) Set(val *DeleteDirectLinkResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteDirectLinkResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteDirectLinkResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteDirectLinkResponse(val *DeleteDirectLinkResponse) *NullableDeleteDirectLinkResponse { + return &NullableDeleteDirectLinkResponse{value: val, isSet: true} +} + +func (v NullableDeleteDirectLinkResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteDirectLinkResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go new file mode 100644 index 000000000..dab872188 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteExportTaskRequest struct for DeleteExportTaskRequest +type DeleteExportTaskRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the export task to delete. + ExportTaskId string `json:"ExportTaskId"` +} + +// NewDeleteExportTaskRequest instantiates a new DeleteExportTaskRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteExportTaskRequest(exportTaskId string, ) *DeleteExportTaskRequest { + this := DeleteExportTaskRequest{} + this.ExportTaskId = exportTaskId + return &this +} + +// NewDeleteExportTaskRequestWithDefaults instantiates a new DeleteExportTaskRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteExportTaskRequestWithDefaults() *DeleteExportTaskRequest { + this := DeleteExportTaskRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteExportTaskRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteExportTaskRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteExportTaskRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteExportTaskRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetExportTaskId returns the ExportTaskId field value +func (o *DeleteExportTaskRequest) GetExportTaskId() string { + if o == nil { + var ret string + return ret + } + + return o.ExportTaskId +} + +// GetExportTaskIdOk returns a tuple with the ExportTaskId field value +// and a boolean to check if the value has been set. +func (o *DeleteExportTaskRequest) GetExportTaskIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ExportTaskId, true +} + +// SetExportTaskId sets field value +func (o *DeleteExportTaskRequest) SetExportTaskId(v string) { + o.ExportTaskId = v +} + +func (o DeleteExportTaskRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ExportTaskId"] = o.ExportTaskId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteExportTaskRequest struct { + value *DeleteExportTaskRequest + isSet bool +} + +func (v NullableDeleteExportTaskRequest) Get() *DeleteExportTaskRequest { + return v.value +} + +func (v *NullableDeleteExportTaskRequest) Set(val *DeleteExportTaskRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteExportTaskRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteExportTaskRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteExportTaskRequest(val *DeleteExportTaskRequest) *NullableDeleteExportTaskRequest { + return &NullableDeleteExportTaskRequest{value: val, isSet: true} +} + +func (v NullableDeleteExportTaskRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteExportTaskRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go new file mode 100644 index 000000000..b1f00bf3e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteExportTaskResponse struct for DeleteExportTaskResponse +type DeleteExportTaskResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteExportTaskResponse instantiates a new DeleteExportTaskResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteExportTaskResponse() *DeleteExportTaskResponse { + this := DeleteExportTaskResponse{} + return &this +} + +// NewDeleteExportTaskResponseWithDefaults instantiates a new DeleteExportTaskResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteExportTaskResponseWithDefaults() *DeleteExportTaskResponse { + this := DeleteExportTaskResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteExportTaskResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteExportTaskResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteExportTaskResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteExportTaskResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteExportTaskResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteExportTaskResponse struct { + value *DeleteExportTaskResponse + isSet bool +} + +func (v NullableDeleteExportTaskResponse) Get() *DeleteExportTaskResponse { + return v.value +} + +func (v *NullableDeleteExportTaskResponse) Set(val *DeleteExportTaskResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteExportTaskResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteExportTaskResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteExportTaskResponse(val *DeleteExportTaskResponse) *NullableDeleteExportTaskResponse { + return &NullableDeleteExportTaskResponse{value: val, isSet: true} +} + +func (v NullableDeleteExportTaskResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteExportTaskResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go new file mode 100644 index 000000000..3a7e27bca --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteFlexibleGpuRequest struct for DeleteFlexibleGpuRequest +type DeleteFlexibleGpuRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the fGPU you want to delete. + FlexibleGpuId string `json:"FlexibleGpuId"` +} + +// NewDeleteFlexibleGpuRequest instantiates a new DeleteFlexibleGpuRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteFlexibleGpuRequest(flexibleGpuId string, ) *DeleteFlexibleGpuRequest { + this := DeleteFlexibleGpuRequest{} + this.FlexibleGpuId = flexibleGpuId + return &this +} + +// NewDeleteFlexibleGpuRequestWithDefaults instantiates a new DeleteFlexibleGpuRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteFlexibleGpuRequestWithDefaults() *DeleteFlexibleGpuRequest { + this := DeleteFlexibleGpuRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteFlexibleGpuRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteFlexibleGpuRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteFlexibleGpuRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteFlexibleGpuRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlexibleGpuId returns the FlexibleGpuId field value +func (o *DeleteFlexibleGpuRequest) GetFlexibleGpuId() string { + if o == nil { + var ret string + return ret + } + + return o.FlexibleGpuId +} + +// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value +// and a boolean to check if the value has been set. +func (o *DeleteFlexibleGpuRequest) GetFlexibleGpuIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FlexibleGpuId, true +} + +// SetFlexibleGpuId sets field value +func (o *DeleteFlexibleGpuRequest) SetFlexibleGpuId(v string) { + o.FlexibleGpuId = v +} + +func (o DeleteFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["FlexibleGpuId"] = o.FlexibleGpuId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteFlexibleGpuRequest struct { + value *DeleteFlexibleGpuRequest + isSet bool +} + +func (v NullableDeleteFlexibleGpuRequest) Get() *DeleteFlexibleGpuRequest { + return v.value +} + +func (v *NullableDeleteFlexibleGpuRequest) Set(val *DeleteFlexibleGpuRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteFlexibleGpuRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteFlexibleGpuRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteFlexibleGpuRequest(val *DeleteFlexibleGpuRequest) *NullableDeleteFlexibleGpuRequest { + return &NullableDeleteFlexibleGpuRequest{value: val, isSet: true} +} + +func (v NullableDeleteFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteFlexibleGpuRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go new file mode 100644 index 000000000..3b5d3e1b5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteFlexibleGpuResponse struct for DeleteFlexibleGpuResponse +type DeleteFlexibleGpuResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteFlexibleGpuResponse instantiates a new DeleteFlexibleGpuResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteFlexibleGpuResponse() *DeleteFlexibleGpuResponse { + this := DeleteFlexibleGpuResponse{} + return &this +} + +// NewDeleteFlexibleGpuResponseWithDefaults instantiates a new DeleteFlexibleGpuResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteFlexibleGpuResponseWithDefaults() *DeleteFlexibleGpuResponse { + this := DeleteFlexibleGpuResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteFlexibleGpuResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteFlexibleGpuResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteFlexibleGpuResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteFlexibleGpuResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteFlexibleGpuResponse struct { + value *DeleteFlexibleGpuResponse + isSet bool +} + +func (v NullableDeleteFlexibleGpuResponse) Get() *DeleteFlexibleGpuResponse { + return v.value +} + +func (v *NullableDeleteFlexibleGpuResponse) Set(val *DeleteFlexibleGpuResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteFlexibleGpuResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteFlexibleGpuResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteFlexibleGpuResponse(val *DeleteFlexibleGpuResponse) *NullableDeleteFlexibleGpuResponse { + return &NullableDeleteFlexibleGpuResponse{value: val, isSet: true} +} + +func (v NullableDeleteFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteFlexibleGpuResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go new file mode 100644 index 000000000..71e0d2d0b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteImageRequest struct for DeleteImageRequest +type DeleteImageRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the OMI you want to delete. + ImageId string `json:"ImageId"` +} + +// NewDeleteImageRequest instantiates a new DeleteImageRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteImageRequest(imageId string, ) *DeleteImageRequest { + this := DeleteImageRequest{} + this.ImageId = imageId + return &this +} + +// NewDeleteImageRequestWithDefaults instantiates a new DeleteImageRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteImageRequestWithDefaults() *DeleteImageRequest { + this := DeleteImageRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteImageRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteImageRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteImageRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteImageRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetImageId returns the ImageId field value +func (o *DeleteImageRequest) GetImageId() string { + if o == nil { + var ret string + return ret + } + + return o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value +// and a boolean to check if the value has been set. +func (o *DeleteImageRequest) GetImageIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ImageId, true +} + +// SetImageId sets field value +func (o *DeleteImageRequest) SetImageId(v string) { + o.ImageId = v +} + +func (o DeleteImageRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ImageId"] = o.ImageId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteImageRequest struct { + value *DeleteImageRequest + isSet bool +} + +func (v NullableDeleteImageRequest) Get() *DeleteImageRequest { + return v.value +} + +func (v *NullableDeleteImageRequest) Set(val *DeleteImageRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteImageRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteImageRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteImageRequest(val *DeleteImageRequest) *NullableDeleteImageRequest { + return &NullableDeleteImageRequest{value: val, isSet: true} +} + +func (v NullableDeleteImageRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteImageRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go new file mode 100644 index 000000000..aac8817f8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteImageResponse struct for DeleteImageResponse +type DeleteImageResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteImageResponse instantiates a new DeleteImageResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteImageResponse() *DeleteImageResponse { + this := DeleteImageResponse{} + return &this +} + +// NewDeleteImageResponseWithDefaults instantiates a new DeleteImageResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteImageResponseWithDefaults() *DeleteImageResponse { + this := DeleteImageResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteImageResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteImageResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteImageResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteImageResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteImageResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteImageResponse struct { + value *DeleteImageResponse + isSet bool +} + +func (v NullableDeleteImageResponse) Get() *DeleteImageResponse { + return v.value +} + +func (v *NullableDeleteImageResponse) Set(val *DeleteImageResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteImageResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteImageResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteImageResponse(val *DeleteImageResponse) *NullableDeleteImageResponse { + return &NullableDeleteImageResponse{value: val, isSet: true} +} + +func (v NullableDeleteImageResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteImageResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go new file mode 100644 index 000000000..69d943e6b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteInternetServiceRequest struct for DeleteInternetServiceRequest +type DeleteInternetServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Internet service you want to delete. + InternetServiceId string `json:"InternetServiceId"` +} + +// NewDeleteInternetServiceRequest instantiates a new DeleteInternetServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteInternetServiceRequest(internetServiceId string, ) *DeleteInternetServiceRequest { + this := DeleteInternetServiceRequest{} + this.InternetServiceId = internetServiceId + return &this +} + +// NewDeleteInternetServiceRequestWithDefaults instantiates a new DeleteInternetServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteInternetServiceRequestWithDefaults() *DeleteInternetServiceRequest { + this := DeleteInternetServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteInternetServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteInternetServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteInternetServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteInternetServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetInternetServiceId returns the InternetServiceId field value +func (o *DeleteInternetServiceRequest) GetInternetServiceId() string { + if o == nil { + var ret string + return ret + } + + return o.InternetServiceId +} + +// GetInternetServiceIdOk returns a tuple with the InternetServiceId field value +// and a boolean to check if the value has been set. +func (o *DeleteInternetServiceRequest) GetInternetServiceIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.InternetServiceId, true +} + +// SetInternetServiceId sets field value +func (o *DeleteInternetServiceRequest) SetInternetServiceId(v string) { + o.InternetServiceId = v +} + +func (o DeleteInternetServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["InternetServiceId"] = o.InternetServiceId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteInternetServiceRequest struct { + value *DeleteInternetServiceRequest + isSet bool +} + +func (v NullableDeleteInternetServiceRequest) Get() *DeleteInternetServiceRequest { + return v.value +} + +func (v *NullableDeleteInternetServiceRequest) Set(val *DeleteInternetServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteInternetServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteInternetServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteInternetServiceRequest(val *DeleteInternetServiceRequest) *NullableDeleteInternetServiceRequest { + return &NullableDeleteInternetServiceRequest{value: val, isSet: true} +} + +func (v NullableDeleteInternetServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteInternetServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go new file mode 100644 index 000000000..8a97311b2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteInternetServiceResponse struct for DeleteInternetServiceResponse +type DeleteInternetServiceResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteInternetServiceResponse instantiates a new DeleteInternetServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteInternetServiceResponse() *DeleteInternetServiceResponse { + this := DeleteInternetServiceResponse{} + return &this +} + +// NewDeleteInternetServiceResponseWithDefaults instantiates a new DeleteInternetServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteInternetServiceResponseWithDefaults() *DeleteInternetServiceResponse { + this := DeleteInternetServiceResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteInternetServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteInternetServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteInternetServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteInternetServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteInternetServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteInternetServiceResponse struct { + value *DeleteInternetServiceResponse + isSet bool +} + +func (v NullableDeleteInternetServiceResponse) Get() *DeleteInternetServiceResponse { + return v.value +} + +func (v *NullableDeleteInternetServiceResponse) Set(val *DeleteInternetServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteInternetServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteInternetServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteInternetServiceResponse(val *DeleteInternetServiceResponse) *NullableDeleteInternetServiceResponse { + return &NullableDeleteInternetServiceResponse{value: val, isSet: true} +} + +func (v NullableDeleteInternetServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteInternetServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go new file mode 100644 index 000000000..80db45937 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteKeypairRequest struct for DeleteKeypairRequest +type DeleteKeypairRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the keypair you want to delete. + KeypairName string `json:"KeypairName"` +} + +// NewDeleteKeypairRequest instantiates a new DeleteKeypairRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteKeypairRequest(keypairName string, ) *DeleteKeypairRequest { + this := DeleteKeypairRequest{} + this.KeypairName = keypairName + return &this +} + +// NewDeleteKeypairRequestWithDefaults instantiates a new DeleteKeypairRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteKeypairRequestWithDefaults() *DeleteKeypairRequest { + this := DeleteKeypairRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteKeypairRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteKeypairRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteKeypairRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteKeypairRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetKeypairName returns the KeypairName field value +func (o *DeleteKeypairRequest) GetKeypairName() string { + if o == nil { + var ret string + return ret + } + + return o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value +// and a boolean to check if the value has been set. +func (o *DeleteKeypairRequest) GetKeypairNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.KeypairName, true +} + +// SetKeypairName sets field value +func (o *DeleteKeypairRequest) SetKeypairName(v string) { + o.KeypairName = v +} + +func (o DeleteKeypairRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["KeypairName"] = o.KeypairName + } + return json.Marshal(toSerialize) +} + +type NullableDeleteKeypairRequest struct { + value *DeleteKeypairRequest + isSet bool +} + +func (v NullableDeleteKeypairRequest) Get() *DeleteKeypairRequest { + return v.value +} + +func (v *NullableDeleteKeypairRequest) Set(val *DeleteKeypairRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteKeypairRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteKeypairRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteKeypairRequest(val *DeleteKeypairRequest) *NullableDeleteKeypairRequest { + return &NullableDeleteKeypairRequest{value: val, isSet: true} +} + +func (v NullableDeleteKeypairRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteKeypairRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go new file mode 100644 index 000000000..a4aa5367a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteKeypairResponse struct for DeleteKeypairResponse +type DeleteKeypairResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteKeypairResponse instantiates a new DeleteKeypairResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteKeypairResponse() *DeleteKeypairResponse { + this := DeleteKeypairResponse{} + return &this +} + +// NewDeleteKeypairResponseWithDefaults instantiates a new DeleteKeypairResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteKeypairResponseWithDefaults() *DeleteKeypairResponse { + this := DeleteKeypairResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteKeypairResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteKeypairResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteKeypairResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteKeypairResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteKeypairResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteKeypairResponse struct { + value *DeleteKeypairResponse + isSet bool +} + +func (v NullableDeleteKeypairResponse) Get() *DeleteKeypairResponse { + return v.value +} + +func (v *NullableDeleteKeypairResponse) Set(val *DeleteKeypairResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteKeypairResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteKeypairResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteKeypairResponse(val *DeleteKeypairResponse) *NullableDeleteKeypairResponse { + return &NullableDeleteKeypairResponse{value: val, isSet: true} +} + +func (v NullableDeleteKeypairResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteKeypairResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go new file mode 100644 index 000000000..03d303cf2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteListenerRuleRequest struct for DeleteListenerRuleRequest +type DeleteListenerRuleRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the rule you want to delete. + ListenerRuleName string `json:"ListenerRuleName"` +} + +// NewDeleteListenerRuleRequest instantiates a new DeleteListenerRuleRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteListenerRuleRequest(listenerRuleName string, ) *DeleteListenerRuleRequest { + this := DeleteListenerRuleRequest{} + this.ListenerRuleName = listenerRuleName + return &this +} + +// NewDeleteListenerRuleRequestWithDefaults instantiates a new DeleteListenerRuleRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteListenerRuleRequestWithDefaults() *DeleteListenerRuleRequest { + this := DeleteListenerRuleRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteListenerRuleRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteListenerRuleRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteListenerRuleRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteListenerRuleRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetListenerRuleName returns the ListenerRuleName field value +func (o *DeleteListenerRuleRequest) GetListenerRuleName() string { + if o == nil { + var ret string + return ret + } + + return o.ListenerRuleName +} + +// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value +// and a boolean to check if the value has been set. +func (o *DeleteListenerRuleRequest) GetListenerRuleNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ListenerRuleName, true +} + +// SetListenerRuleName sets field value +func (o *DeleteListenerRuleRequest) SetListenerRuleName(v string) { + o.ListenerRuleName = v +} + +func (o DeleteListenerRuleRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ListenerRuleName"] = o.ListenerRuleName + } + return json.Marshal(toSerialize) +} + +type NullableDeleteListenerRuleRequest struct { + value *DeleteListenerRuleRequest + isSet bool +} + +func (v NullableDeleteListenerRuleRequest) Get() *DeleteListenerRuleRequest { + return v.value +} + +func (v *NullableDeleteListenerRuleRequest) Set(val *DeleteListenerRuleRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteListenerRuleRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteListenerRuleRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteListenerRuleRequest(val *DeleteListenerRuleRequest) *NullableDeleteListenerRuleRequest { + return &NullableDeleteListenerRuleRequest{value: val, isSet: true} +} + +func (v NullableDeleteListenerRuleRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteListenerRuleRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go new file mode 100644 index 000000000..07095ae17 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteListenerRuleResponse struct for DeleteListenerRuleResponse +type DeleteListenerRuleResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteListenerRuleResponse instantiates a new DeleteListenerRuleResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteListenerRuleResponse() *DeleteListenerRuleResponse { + this := DeleteListenerRuleResponse{} + return &this +} + +// NewDeleteListenerRuleResponseWithDefaults instantiates a new DeleteListenerRuleResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteListenerRuleResponseWithDefaults() *DeleteListenerRuleResponse { + this := DeleteListenerRuleResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteListenerRuleResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteListenerRuleResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteListenerRuleResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteListenerRuleResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteListenerRuleResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteListenerRuleResponse struct { + value *DeleteListenerRuleResponse + isSet bool +} + +func (v NullableDeleteListenerRuleResponse) Get() *DeleteListenerRuleResponse { + return v.value +} + +func (v *NullableDeleteListenerRuleResponse) Set(val *DeleteListenerRuleResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteListenerRuleResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteListenerRuleResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteListenerRuleResponse(val *DeleteListenerRuleResponse) *NullableDeleteListenerRuleResponse { + return &NullableDeleteListenerRuleResponse{value: val, isSet: true} +} + +func (v NullableDeleteListenerRuleResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteListenerRuleResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go new file mode 100644 index 000000000..b624d38a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerListenersRequest struct for DeleteLoadBalancerListenersRequest +type DeleteLoadBalancerListenersRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer for which you want to delete listeners. + LoadBalancerName string `json:"LoadBalancerName"` + // One or more port numbers of the listeners you want to delete. + LoadBalancerPorts []int32 `json:"LoadBalancerPorts"` +} + +// NewDeleteLoadBalancerListenersRequest instantiates a new DeleteLoadBalancerListenersRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerListenersRequest(loadBalancerName string, loadBalancerPorts []int32, ) *DeleteLoadBalancerListenersRequest { + this := DeleteLoadBalancerListenersRequest{} + this.LoadBalancerName = loadBalancerName + this.LoadBalancerPorts = loadBalancerPorts + return &this +} + +// NewDeleteLoadBalancerListenersRequestWithDefaults instantiates a new DeleteLoadBalancerListenersRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerListenersRequestWithDefaults() *DeleteLoadBalancerListenersRequest { + this := DeleteLoadBalancerListenersRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteLoadBalancerListenersRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerListenersRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteLoadBalancerListenersRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteLoadBalancerListenersRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *DeleteLoadBalancerListenersRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetLoadBalancerPorts returns the LoadBalancerPorts field value +func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerPorts() []int32 { + if o == nil { + var ret []int32 + return ret + } + + return o.LoadBalancerPorts +} + +// GetLoadBalancerPortsOk returns a tuple with the LoadBalancerPorts field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerPortsOk() (*[]int32, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerPorts, true +} + +// SetLoadBalancerPorts sets field value +func (o *DeleteLoadBalancerListenersRequest) SetLoadBalancerPorts(v []int32) { + o.LoadBalancerPorts = v +} + +func (o DeleteLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if true { + toSerialize["LoadBalancerPorts"] = o.LoadBalancerPorts + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerListenersRequest struct { + value *DeleteLoadBalancerListenersRequest + isSet bool +} + +func (v NullableDeleteLoadBalancerListenersRequest) Get() *DeleteLoadBalancerListenersRequest { + return v.value +} + +func (v *NullableDeleteLoadBalancerListenersRequest) Set(val *DeleteLoadBalancerListenersRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerListenersRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerListenersRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerListenersRequest(val *DeleteLoadBalancerListenersRequest) *NullableDeleteLoadBalancerListenersRequest { + return &NullableDeleteLoadBalancerListenersRequest{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerListenersRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go new file mode 100644 index 000000000..c8b2549ab --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerListenersResponse struct for DeleteLoadBalancerListenersResponse +type DeleteLoadBalancerListenersResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteLoadBalancerListenersResponse instantiates a new DeleteLoadBalancerListenersResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerListenersResponse() *DeleteLoadBalancerListenersResponse { + this := DeleteLoadBalancerListenersResponse{} + return &this +} + +// NewDeleteLoadBalancerListenersResponseWithDefaults instantiates a new DeleteLoadBalancerListenersResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerListenersResponseWithDefaults() *DeleteLoadBalancerListenersResponse { + this := DeleteLoadBalancerListenersResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *DeleteLoadBalancerListenersResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerListenersResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *DeleteLoadBalancerListenersResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *DeleteLoadBalancerListenersResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteLoadBalancerListenersResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerListenersResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteLoadBalancerListenersResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteLoadBalancerListenersResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerListenersResponse struct { + value *DeleteLoadBalancerListenersResponse + isSet bool +} + +func (v NullableDeleteLoadBalancerListenersResponse) Get() *DeleteLoadBalancerListenersResponse { + return v.value +} + +func (v *NullableDeleteLoadBalancerListenersResponse) Set(val *DeleteLoadBalancerListenersResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerListenersResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerListenersResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerListenersResponse(val *DeleteLoadBalancerListenersResponse) *NullableDeleteLoadBalancerListenersResponse { + return &NullableDeleteLoadBalancerListenersResponse{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerListenersResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go new file mode 100644 index 000000000..fc3d7e011 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerPolicyRequest struct for DeleteLoadBalancerPolicyRequest +type DeleteLoadBalancerPolicyRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer for which you want to delete a policy. + LoadBalancerName string `json:"LoadBalancerName"` + // The name of the policy you want to delete. + PolicyName string `json:"PolicyName"` +} + +// NewDeleteLoadBalancerPolicyRequest instantiates a new DeleteLoadBalancerPolicyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerPolicyRequest(loadBalancerName string, policyName string, ) *DeleteLoadBalancerPolicyRequest { + this := DeleteLoadBalancerPolicyRequest{} + this.LoadBalancerName = loadBalancerName + this.PolicyName = policyName + return &this +} + +// NewDeleteLoadBalancerPolicyRequestWithDefaults instantiates a new DeleteLoadBalancerPolicyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerPolicyRequestWithDefaults() *DeleteLoadBalancerPolicyRequest { + this := DeleteLoadBalancerPolicyRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteLoadBalancerPolicyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerPolicyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteLoadBalancerPolicyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteLoadBalancerPolicyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *DeleteLoadBalancerPolicyRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerPolicyRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *DeleteLoadBalancerPolicyRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetPolicyName returns the PolicyName field value +func (o *DeleteLoadBalancerPolicyRequest) GetPolicyName() string { + if o == nil { + var ret string + return ret + } + + return o.PolicyName +} + +// GetPolicyNameOk returns a tuple with the PolicyName field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerPolicyRequest) GetPolicyNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PolicyName, true +} + +// SetPolicyName sets field value +func (o *DeleteLoadBalancerPolicyRequest) SetPolicyName(v string) { + o.PolicyName = v +} + +func (o DeleteLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if true { + toSerialize["PolicyName"] = o.PolicyName + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerPolicyRequest struct { + value *DeleteLoadBalancerPolicyRequest + isSet bool +} + +func (v NullableDeleteLoadBalancerPolicyRequest) Get() *DeleteLoadBalancerPolicyRequest { + return v.value +} + +func (v *NullableDeleteLoadBalancerPolicyRequest) Set(val *DeleteLoadBalancerPolicyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerPolicyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerPolicyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerPolicyRequest(val *DeleteLoadBalancerPolicyRequest) *NullableDeleteLoadBalancerPolicyRequest { + return &NullableDeleteLoadBalancerPolicyRequest{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerPolicyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go new file mode 100644 index 000000000..3a29ed42e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerPolicyResponse struct for DeleteLoadBalancerPolicyResponse +type DeleteLoadBalancerPolicyResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteLoadBalancerPolicyResponse instantiates a new DeleteLoadBalancerPolicyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerPolicyResponse() *DeleteLoadBalancerPolicyResponse { + this := DeleteLoadBalancerPolicyResponse{} + return &this +} + +// NewDeleteLoadBalancerPolicyResponseWithDefaults instantiates a new DeleteLoadBalancerPolicyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerPolicyResponseWithDefaults() *DeleteLoadBalancerPolicyResponse { + this := DeleteLoadBalancerPolicyResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *DeleteLoadBalancerPolicyResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerPolicyResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *DeleteLoadBalancerPolicyResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *DeleteLoadBalancerPolicyResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteLoadBalancerPolicyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerPolicyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteLoadBalancerPolicyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteLoadBalancerPolicyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerPolicyResponse struct { + value *DeleteLoadBalancerPolicyResponse + isSet bool +} + +func (v NullableDeleteLoadBalancerPolicyResponse) Get() *DeleteLoadBalancerPolicyResponse { + return v.value +} + +func (v *NullableDeleteLoadBalancerPolicyResponse) Set(val *DeleteLoadBalancerPolicyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerPolicyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerPolicyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerPolicyResponse(val *DeleteLoadBalancerPolicyResponse) *NullableDeleteLoadBalancerPolicyResponse { + return &NullableDeleteLoadBalancerPolicyResponse{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerPolicyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go new file mode 100644 index 000000000..1b85ccdfa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerRequest struct for DeleteLoadBalancerRequest +type DeleteLoadBalancerRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer you want to delete. + LoadBalancerName string `json:"LoadBalancerName"` +} + +// NewDeleteLoadBalancerRequest instantiates a new DeleteLoadBalancerRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerRequest(loadBalancerName string, ) *DeleteLoadBalancerRequest { + this := DeleteLoadBalancerRequest{} + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewDeleteLoadBalancerRequestWithDefaults instantiates a new DeleteLoadBalancerRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerRequestWithDefaults() *DeleteLoadBalancerRequest { + this := DeleteLoadBalancerRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteLoadBalancerRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteLoadBalancerRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteLoadBalancerRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *DeleteLoadBalancerRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *DeleteLoadBalancerRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +func (o DeleteLoadBalancerRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerRequest struct { + value *DeleteLoadBalancerRequest + isSet bool +} + +func (v NullableDeleteLoadBalancerRequest) Get() *DeleteLoadBalancerRequest { + return v.value +} + +func (v *NullableDeleteLoadBalancerRequest) Set(val *DeleteLoadBalancerRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerRequest(val *DeleteLoadBalancerRequest) *NullableDeleteLoadBalancerRequest { + return &NullableDeleteLoadBalancerRequest{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go new file mode 100644 index 000000000..8c4ee1dba --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerResponse struct for DeleteLoadBalancerResponse +type DeleteLoadBalancerResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteLoadBalancerResponse instantiates a new DeleteLoadBalancerResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerResponse() *DeleteLoadBalancerResponse { + this := DeleteLoadBalancerResponse{} + return &this +} + +// NewDeleteLoadBalancerResponseWithDefaults instantiates a new DeleteLoadBalancerResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerResponseWithDefaults() *DeleteLoadBalancerResponse { + this := DeleteLoadBalancerResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteLoadBalancerResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteLoadBalancerResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteLoadBalancerResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteLoadBalancerResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerResponse struct { + value *DeleteLoadBalancerResponse + isSet bool +} + +func (v NullableDeleteLoadBalancerResponse) Get() *DeleteLoadBalancerResponse { + return v.value +} + +func (v *NullableDeleteLoadBalancerResponse) Set(val *DeleteLoadBalancerResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerResponse(val *DeleteLoadBalancerResponse) *NullableDeleteLoadBalancerResponse { + return &NullableDeleteLoadBalancerResponse{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go new file mode 100644 index 000000000..9b5226d68 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerTagsRequest struct for DeleteLoadBalancerTagsRequest +type DeleteLoadBalancerTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more load balancer names. + LoadBalancerNames []string `json:"LoadBalancerNames"` + // One or more tags to delete from the load balancers. + Tags []ResourceLoadBalancerTag `json:"Tags"` +} + +// NewDeleteLoadBalancerTagsRequest instantiates a new DeleteLoadBalancerTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerTagsRequest(loadBalancerNames []string, tags []ResourceLoadBalancerTag, ) *DeleteLoadBalancerTagsRequest { + this := DeleteLoadBalancerTagsRequest{} + this.LoadBalancerNames = loadBalancerNames + this.Tags = tags + return &this +} + +// NewDeleteLoadBalancerTagsRequestWithDefaults instantiates a new DeleteLoadBalancerTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerTagsRequestWithDefaults() *DeleteLoadBalancerTagsRequest { + this := DeleteLoadBalancerTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteLoadBalancerTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteLoadBalancerTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteLoadBalancerTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerNames returns the LoadBalancerNames field value +func (o *DeleteLoadBalancerTagsRequest) GetLoadBalancerNames() []string { + if o == nil { + var ret []string + return ret + } + + return o.LoadBalancerNames +} + +// GetLoadBalancerNamesOk returns a tuple with the LoadBalancerNames field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerTagsRequest) GetLoadBalancerNamesOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerNames, true +} + +// SetLoadBalancerNames sets field value +func (o *DeleteLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { + o.LoadBalancerNames = v +} + +// GetTags returns the Tags field value +func (o *DeleteLoadBalancerTagsRequest) GetTags() []ResourceLoadBalancerTag { + if o == nil { + var ret []ResourceLoadBalancerTag + return ret + } + + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerTagsRequest) GetTagsOk() (*[]ResourceLoadBalancerTag, bool) { + if o == nil { + return nil, false + } + return &o.Tags, true +} + +// SetTags sets field value +func (o *DeleteLoadBalancerTagsRequest) SetTags(v []ResourceLoadBalancerTag) { + o.Tags = v +} + +func (o DeleteLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerNames"] = o.LoadBalancerNames + } + if true { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerTagsRequest struct { + value *DeleteLoadBalancerTagsRequest + isSet bool +} + +func (v NullableDeleteLoadBalancerTagsRequest) Get() *DeleteLoadBalancerTagsRequest { + return v.value +} + +func (v *NullableDeleteLoadBalancerTagsRequest) Set(val *DeleteLoadBalancerTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerTagsRequest(val *DeleteLoadBalancerTagsRequest) *NullableDeleteLoadBalancerTagsRequest { + return &NullableDeleteLoadBalancerTagsRequest{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go new file mode 100644 index 000000000..21bef0ce0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteLoadBalancerTagsResponse struct for DeleteLoadBalancerTagsResponse +type DeleteLoadBalancerTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteLoadBalancerTagsResponse instantiates a new DeleteLoadBalancerTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteLoadBalancerTagsResponse() *DeleteLoadBalancerTagsResponse { + this := DeleteLoadBalancerTagsResponse{} + return &this +} + +// NewDeleteLoadBalancerTagsResponseWithDefaults instantiates a new DeleteLoadBalancerTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteLoadBalancerTagsResponseWithDefaults() *DeleteLoadBalancerTagsResponse { + this := DeleteLoadBalancerTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteLoadBalancerTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteLoadBalancerTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteLoadBalancerTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteLoadBalancerTagsResponse struct { + value *DeleteLoadBalancerTagsResponse + isSet bool +} + +func (v NullableDeleteLoadBalancerTagsResponse) Get() *DeleteLoadBalancerTagsResponse { + return v.value +} + +func (v *NullableDeleteLoadBalancerTagsResponse) Set(val *DeleteLoadBalancerTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteLoadBalancerTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteLoadBalancerTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteLoadBalancerTagsResponse(val *DeleteLoadBalancerTagsResponse) *NullableDeleteLoadBalancerTagsResponse { + return &NullableDeleteLoadBalancerTagsResponse{value: val, isSet: true} +} + +func (v NullableDeleteLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go new file mode 100644 index 000000000..4f32a45e8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNatServiceRequest struct for DeleteNatServiceRequest +type DeleteNatServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the NAT service you want to delete. + NatServiceId string `json:"NatServiceId"` +} + +// NewDeleteNatServiceRequest instantiates a new DeleteNatServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNatServiceRequest(natServiceId string, ) *DeleteNatServiceRequest { + this := DeleteNatServiceRequest{} + this.NatServiceId = natServiceId + return &this +} + +// NewDeleteNatServiceRequestWithDefaults instantiates a new DeleteNatServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNatServiceRequestWithDefaults() *DeleteNatServiceRequest { + this := DeleteNatServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteNatServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNatServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteNatServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteNatServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNatServiceId returns the NatServiceId field value +func (o *DeleteNatServiceRequest) GetNatServiceId() string { + if o == nil { + var ret string + return ret + } + + return o.NatServiceId +} + +// GetNatServiceIdOk returns a tuple with the NatServiceId field value +// and a boolean to check if the value has been set. +func (o *DeleteNatServiceRequest) GetNatServiceIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NatServiceId, true +} + +// SetNatServiceId sets field value +func (o *DeleteNatServiceRequest) SetNatServiceId(v string) { + o.NatServiceId = v +} + +func (o DeleteNatServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NatServiceId"] = o.NatServiceId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNatServiceRequest struct { + value *DeleteNatServiceRequest + isSet bool +} + +func (v NullableDeleteNatServiceRequest) Get() *DeleteNatServiceRequest { + return v.value +} + +func (v *NullableDeleteNatServiceRequest) Set(val *DeleteNatServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNatServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNatServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNatServiceRequest(val *DeleteNatServiceRequest) *NullableDeleteNatServiceRequest { + return &NullableDeleteNatServiceRequest{value: val, isSet: true} +} + +func (v NullableDeleteNatServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNatServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go new file mode 100644 index 000000000..34e9add70 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNatServiceResponse struct for DeleteNatServiceResponse +type DeleteNatServiceResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteNatServiceResponse instantiates a new DeleteNatServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNatServiceResponse() *DeleteNatServiceResponse { + this := DeleteNatServiceResponse{} + return &this +} + +// NewDeleteNatServiceResponseWithDefaults instantiates a new DeleteNatServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNatServiceResponseWithDefaults() *DeleteNatServiceResponse { + this := DeleteNatServiceResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteNatServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNatServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteNatServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteNatServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteNatServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNatServiceResponse struct { + value *DeleteNatServiceResponse + isSet bool +} + +func (v NullableDeleteNatServiceResponse) Get() *DeleteNatServiceResponse { + return v.value +} + +func (v *NullableDeleteNatServiceResponse) Set(val *DeleteNatServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNatServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNatServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNatServiceResponse(val *DeleteNatServiceResponse) *NullableDeleteNatServiceResponse { + return &NullableDeleteNatServiceResponse{value: val, isSet: true} +} + +func (v NullableDeleteNatServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNatServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go new file mode 100644 index 000000000..ba3175e3a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetAccessPointRequest struct for DeleteNetAccessPointRequest +type DeleteNetAccessPointRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net access point. + NetAccessPointId string `json:"NetAccessPointId"` +} + +// NewDeleteNetAccessPointRequest instantiates a new DeleteNetAccessPointRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetAccessPointRequest(netAccessPointId string, ) *DeleteNetAccessPointRequest { + this := DeleteNetAccessPointRequest{} + this.NetAccessPointId = netAccessPointId + return &this +} + +// NewDeleteNetAccessPointRequestWithDefaults instantiates a new DeleteNetAccessPointRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetAccessPointRequestWithDefaults() *DeleteNetAccessPointRequest { + this := DeleteNetAccessPointRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteNetAccessPointRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetAccessPointRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteNetAccessPointRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteNetAccessPointRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetAccessPointId returns the NetAccessPointId field value +func (o *DeleteNetAccessPointRequest) GetNetAccessPointId() string { + if o == nil { + var ret string + return ret + } + + return o.NetAccessPointId +} + +// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value +// and a boolean to check if the value has been set. +func (o *DeleteNetAccessPointRequest) GetNetAccessPointIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetAccessPointId, true +} + +// SetNetAccessPointId sets field value +func (o *DeleteNetAccessPointRequest) SetNetAccessPointId(v string) { + o.NetAccessPointId = v +} + +func (o DeleteNetAccessPointRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetAccessPointId"] = o.NetAccessPointId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetAccessPointRequest struct { + value *DeleteNetAccessPointRequest + isSet bool +} + +func (v NullableDeleteNetAccessPointRequest) Get() *DeleteNetAccessPointRequest { + return v.value +} + +func (v *NullableDeleteNetAccessPointRequest) Set(val *DeleteNetAccessPointRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetAccessPointRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetAccessPointRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetAccessPointRequest(val *DeleteNetAccessPointRequest) *NullableDeleteNetAccessPointRequest { + return &NullableDeleteNetAccessPointRequest{value: val, isSet: true} +} + +func (v NullableDeleteNetAccessPointRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetAccessPointRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go new file mode 100644 index 000000000..2845b91d6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetAccessPointResponse struct for DeleteNetAccessPointResponse +type DeleteNetAccessPointResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteNetAccessPointResponse instantiates a new DeleteNetAccessPointResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetAccessPointResponse() *DeleteNetAccessPointResponse { + this := DeleteNetAccessPointResponse{} + return &this +} + +// NewDeleteNetAccessPointResponseWithDefaults instantiates a new DeleteNetAccessPointResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetAccessPointResponseWithDefaults() *DeleteNetAccessPointResponse { + this := DeleteNetAccessPointResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteNetAccessPointResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetAccessPointResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteNetAccessPointResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteNetAccessPointResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteNetAccessPointResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetAccessPointResponse struct { + value *DeleteNetAccessPointResponse + isSet bool +} + +func (v NullableDeleteNetAccessPointResponse) Get() *DeleteNetAccessPointResponse { + return v.value +} + +func (v *NullableDeleteNetAccessPointResponse) Set(val *DeleteNetAccessPointResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetAccessPointResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetAccessPointResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetAccessPointResponse(val *DeleteNetAccessPointResponse) *NullableDeleteNetAccessPointResponse { + return &NullableDeleteNetAccessPointResponse{value: val, isSet: true} +} + +func (v NullableDeleteNetAccessPointResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetAccessPointResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go new file mode 100644 index 000000000..b11cd8bf5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetPeeringRequest struct for DeleteNetPeeringRequest +type DeleteNetPeeringRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net peering connection you want to delete. + NetPeeringId string `json:"NetPeeringId"` +} + +// NewDeleteNetPeeringRequest instantiates a new DeleteNetPeeringRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetPeeringRequest(netPeeringId string, ) *DeleteNetPeeringRequest { + this := DeleteNetPeeringRequest{} + this.NetPeeringId = netPeeringId + return &this +} + +// NewDeleteNetPeeringRequestWithDefaults instantiates a new DeleteNetPeeringRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetPeeringRequestWithDefaults() *DeleteNetPeeringRequest { + this := DeleteNetPeeringRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteNetPeeringRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetPeeringRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteNetPeeringRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteNetPeeringRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetPeeringId returns the NetPeeringId field value +func (o *DeleteNetPeeringRequest) GetNetPeeringId() string { + if o == nil { + var ret string + return ret + } + + return o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value +// and a boolean to check if the value has been set. +func (o *DeleteNetPeeringRequest) GetNetPeeringIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetPeeringId, true +} + +// SetNetPeeringId sets field value +func (o *DeleteNetPeeringRequest) SetNetPeeringId(v string) { + o.NetPeeringId = v +} + +func (o DeleteNetPeeringRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetPeeringRequest struct { + value *DeleteNetPeeringRequest + isSet bool +} + +func (v NullableDeleteNetPeeringRequest) Get() *DeleteNetPeeringRequest { + return v.value +} + +func (v *NullableDeleteNetPeeringRequest) Set(val *DeleteNetPeeringRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetPeeringRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetPeeringRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetPeeringRequest(val *DeleteNetPeeringRequest) *NullableDeleteNetPeeringRequest { + return &NullableDeleteNetPeeringRequest{value: val, isSet: true} +} + +func (v NullableDeleteNetPeeringRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetPeeringRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go new file mode 100644 index 000000000..8a01aa155 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetPeeringResponse struct for DeleteNetPeeringResponse +type DeleteNetPeeringResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteNetPeeringResponse instantiates a new DeleteNetPeeringResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetPeeringResponse() *DeleteNetPeeringResponse { + this := DeleteNetPeeringResponse{} + return &this +} + +// NewDeleteNetPeeringResponseWithDefaults instantiates a new DeleteNetPeeringResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetPeeringResponseWithDefaults() *DeleteNetPeeringResponse { + this := DeleteNetPeeringResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteNetPeeringResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetPeeringResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteNetPeeringResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteNetPeeringResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteNetPeeringResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetPeeringResponse struct { + value *DeleteNetPeeringResponse + isSet bool +} + +func (v NullableDeleteNetPeeringResponse) Get() *DeleteNetPeeringResponse { + return v.value +} + +func (v *NullableDeleteNetPeeringResponse) Set(val *DeleteNetPeeringResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetPeeringResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetPeeringResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetPeeringResponse(val *DeleteNetPeeringResponse) *NullableDeleteNetPeeringResponse { + return &NullableDeleteNetPeeringResponse{value: val, isSet: true} +} + +func (v NullableDeleteNetPeeringResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetPeeringResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go new file mode 100644 index 000000000..b0acd78c6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetRequest struct for DeleteNetRequest +type DeleteNetRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net you want to delete. + NetId string `json:"NetId"` +} + +// NewDeleteNetRequest instantiates a new DeleteNetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetRequest(netId string, ) *DeleteNetRequest { + this := DeleteNetRequest{} + this.NetId = netId + return &this +} + +// NewDeleteNetRequestWithDefaults instantiates a new DeleteNetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetRequestWithDefaults() *DeleteNetRequest { + this := DeleteNetRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteNetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteNetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteNetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *DeleteNetRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *DeleteNetRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *DeleteNetRequest) SetNetId(v string) { + o.NetId = v +} + +func (o DeleteNetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetRequest struct { + value *DeleteNetRequest + isSet bool +} + +func (v NullableDeleteNetRequest) Get() *DeleteNetRequest { + return v.value +} + +func (v *NullableDeleteNetRequest) Set(val *DeleteNetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetRequest(val *DeleteNetRequest) *NullableDeleteNetRequest { + return &NullableDeleteNetRequest{value: val, isSet: true} +} + +func (v NullableDeleteNetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go new file mode 100644 index 000000000..2b3780f52 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNetResponse struct for DeleteNetResponse +type DeleteNetResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteNetResponse instantiates a new DeleteNetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNetResponse() *DeleteNetResponse { + this := DeleteNetResponse{} + return &this +} + +// NewDeleteNetResponseWithDefaults instantiates a new DeleteNetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNetResponseWithDefaults() *DeleteNetResponse { + this := DeleteNetResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteNetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteNetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteNetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteNetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNetResponse struct { + value *DeleteNetResponse + isSet bool +} + +func (v NullableDeleteNetResponse) Get() *DeleteNetResponse { + return v.value +} + +func (v *NullableDeleteNetResponse) Set(val *DeleteNetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNetResponse(val *DeleteNetResponse) *NullableDeleteNetResponse { + return &NullableDeleteNetResponse{value: val, isSet: true} +} + +func (v NullableDeleteNetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go new file mode 100644 index 000000000..4114e415f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNicRequest struct for DeleteNicRequest +type DeleteNicRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the NIC you want to delete. + NicId string `json:"NicId"` +} + +// NewDeleteNicRequest instantiates a new DeleteNicRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNicRequest(nicId string, ) *DeleteNicRequest { + this := DeleteNicRequest{} + this.NicId = nicId + return &this +} + +// NewDeleteNicRequestWithDefaults instantiates a new DeleteNicRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNicRequestWithDefaults() *DeleteNicRequest { + this := DeleteNicRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteNicRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNicRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteNicRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteNicRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNicId returns the NicId field value +func (o *DeleteNicRequest) GetNicId() string { + if o == nil { + var ret string + return ret + } + + return o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value +// and a boolean to check if the value has been set. +func (o *DeleteNicRequest) GetNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NicId, true +} + +// SetNicId sets field value +func (o *DeleteNicRequest) SetNicId(v string) { + o.NicId = v +} + +func (o DeleteNicRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NicId"] = o.NicId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNicRequest struct { + value *DeleteNicRequest + isSet bool +} + +func (v NullableDeleteNicRequest) Get() *DeleteNicRequest { + return v.value +} + +func (v *NullableDeleteNicRequest) Set(val *DeleteNicRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNicRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNicRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNicRequest(val *DeleteNicRequest) *NullableDeleteNicRequest { + return &NullableDeleteNicRequest{value: val, isSet: true} +} + +func (v NullableDeleteNicRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNicRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go new file mode 100644 index 000000000..5fb84e07a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteNicResponse struct for DeleteNicResponse +type DeleteNicResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteNicResponse instantiates a new DeleteNicResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteNicResponse() *DeleteNicResponse { + this := DeleteNicResponse{} + return &this +} + +// NewDeleteNicResponseWithDefaults instantiates a new DeleteNicResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteNicResponseWithDefaults() *DeleteNicResponse { + this := DeleteNicResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteNicResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteNicResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteNicResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteNicResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteNicResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteNicResponse struct { + value *DeleteNicResponse + isSet bool +} + +func (v NullableDeleteNicResponse) Get() *DeleteNicResponse { + return v.value +} + +func (v *NullableDeleteNicResponse) Set(val *DeleteNicResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteNicResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteNicResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteNicResponse(val *DeleteNicResponse) *NullableDeleteNicResponse { + return &NullableDeleteNicResponse{value: val, isSet: true} +} + +func (v NullableDeleteNicResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteNicResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go new file mode 100644 index 000000000..6d0831b33 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeletePublicIpRequest struct for DeletePublicIpRequest +type DeletePublicIpRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The EIP. In the public Cloud, this parameter is required. + PublicIp *string `json:"PublicIp,omitempty"` + // The ID representing the association of the EIP with the VM or the NIC. In a Net, this parameter is required. + PublicIpId *string `json:"PublicIpId,omitempty"` +} + +// NewDeletePublicIpRequest instantiates a new DeletePublicIpRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeletePublicIpRequest() *DeletePublicIpRequest { + this := DeletePublicIpRequest{} + return &this +} + +// NewDeletePublicIpRequestWithDefaults instantiates a new DeletePublicIpRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeletePublicIpRequestWithDefaults() *DeletePublicIpRequest { + this := DeletePublicIpRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeletePublicIpRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeletePublicIpRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeletePublicIpRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeletePublicIpRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *DeletePublicIpRequest) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeletePublicIpRequest) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *DeletePublicIpRequest) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *DeletePublicIpRequest) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. +func (o *DeletePublicIpRequest) GetPublicIpId() string { + if o == nil || o.PublicIpId == nil { + var ret string + return ret + } + return *o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeletePublicIpRequest) GetPublicIpIdOk() (*string, bool) { + if o == nil || o.PublicIpId == nil { + return nil, false + } + return o.PublicIpId, true +} + +// HasPublicIpId returns a boolean if a field has been set. +func (o *DeletePublicIpRequest) HasPublicIpId() bool { + if o != nil && o.PublicIpId != nil { + return true + } + + return false +} + +// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. +func (o *DeletePublicIpRequest) SetPublicIpId(v string) { + o.PublicIpId = &v +} + +func (o DeletePublicIpRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpId != nil { + toSerialize["PublicIpId"] = o.PublicIpId + } + return json.Marshal(toSerialize) +} + +type NullableDeletePublicIpRequest struct { + value *DeletePublicIpRequest + isSet bool +} + +func (v NullableDeletePublicIpRequest) Get() *DeletePublicIpRequest { + return v.value +} + +func (v *NullableDeletePublicIpRequest) Set(val *DeletePublicIpRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeletePublicIpRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeletePublicIpRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeletePublicIpRequest(val *DeletePublicIpRequest) *NullableDeletePublicIpRequest { + return &NullableDeletePublicIpRequest{value: val, isSet: true} +} + +func (v NullableDeletePublicIpRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeletePublicIpRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go new file mode 100644 index 000000000..b434b074f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeletePublicIpResponse struct for DeletePublicIpResponse +type DeletePublicIpResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeletePublicIpResponse instantiates a new DeletePublicIpResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeletePublicIpResponse() *DeletePublicIpResponse { + this := DeletePublicIpResponse{} + return &this +} + +// NewDeletePublicIpResponseWithDefaults instantiates a new DeletePublicIpResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeletePublicIpResponseWithDefaults() *DeletePublicIpResponse { + this := DeletePublicIpResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeletePublicIpResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeletePublicIpResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeletePublicIpResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeletePublicIpResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeletePublicIpResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeletePublicIpResponse struct { + value *DeletePublicIpResponse + isSet bool +} + +func (v NullableDeletePublicIpResponse) Get() *DeletePublicIpResponse { + return v.value +} + +func (v *NullableDeletePublicIpResponse) Set(val *DeletePublicIpResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeletePublicIpResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeletePublicIpResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeletePublicIpResponse(val *DeletePublicIpResponse) *NullableDeletePublicIpResponse { + return &NullableDeletePublicIpResponse{value: val, isSet: true} +} + +func (v NullableDeletePublicIpResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeletePublicIpResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go new file mode 100644 index 000000000..a62a65437 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteRouteRequest struct for DeleteRouteRequest +type DeleteRouteRequest struct { + // The exact IP range for the route. + DestinationIpRange string `json:"DestinationIpRange"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the route table from which you want to delete a route. + RouteTableId string `json:"RouteTableId"` +} + +// NewDeleteRouteRequest instantiates a new DeleteRouteRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteRouteRequest(destinationIpRange string, routeTableId string, ) *DeleteRouteRequest { + this := DeleteRouteRequest{} + this.DestinationIpRange = destinationIpRange + this.RouteTableId = routeTableId + return &this +} + +// NewDeleteRouteRequestWithDefaults instantiates a new DeleteRouteRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteRouteRequestWithDefaults() *DeleteRouteRequest { + this := DeleteRouteRequest{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value +func (o *DeleteRouteRequest) GetDestinationIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value +// and a boolean to check if the value has been set. +func (o *DeleteRouteRequest) GetDestinationIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationIpRange, true +} + +// SetDestinationIpRange sets field value +func (o *DeleteRouteRequest) SetDestinationIpRange(v string) { + o.DestinationIpRange = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteRouteRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteRouteRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteRouteRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteRouteRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *DeleteRouteRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *DeleteRouteRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *DeleteRouteRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +func (o DeleteRouteRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteRouteRequest struct { + value *DeleteRouteRequest + isSet bool +} + +func (v NullableDeleteRouteRequest) Get() *DeleteRouteRequest { + return v.value +} + +func (v *NullableDeleteRouteRequest) Set(val *DeleteRouteRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteRouteRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteRouteRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteRouteRequest(val *DeleteRouteRequest) *NullableDeleteRouteRequest { + return &NullableDeleteRouteRequest{value: val, isSet: true} +} + +func (v NullableDeleteRouteRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteRouteRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go new file mode 100644 index 000000000..30b21d4e0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteRouteResponse struct for DeleteRouteResponse +type DeleteRouteResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + RouteTable *RouteTable `json:"RouteTable,omitempty"` +} + +// NewDeleteRouteResponse instantiates a new DeleteRouteResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteRouteResponse() *DeleteRouteResponse { + this := DeleteRouteResponse{} + return &this +} + +// NewDeleteRouteResponseWithDefaults instantiates a new DeleteRouteResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteRouteResponseWithDefaults() *DeleteRouteResponse { + this := DeleteRouteResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteRouteResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteRouteResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteRouteResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteRouteResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTable returns the RouteTable field value if set, zero value otherwise. +func (o *DeleteRouteResponse) GetRouteTable() RouteTable { + if o == nil || o.RouteTable == nil { + var ret RouteTable + return ret + } + return *o.RouteTable +} + +// GetRouteTableOk returns a tuple with the RouteTable field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteRouteResponse) GetRouteTableOk() (*RouteTable, bool) { + if o == nil || o.RouteTable == nil { + return nil, false + } + return o.RouteTable, true +} + +// HasRouteTable returns a boolean if a field has been set. +func (o *DeleteRouteResponse) HasRouteTable() bool { + if o != nil && o.RouteTable != nil { + return true + } + + return false +} + +// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. +func (o *DeleteRouteResponse) SetRouteTable(v RouteTable) { + o.RouteTable = &v +} + +func (o DeleteRouteResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTable != nil { + toSerialize["RouteTable"] = o.RouteTable + } + return json.Marshal(toSerialize) +} + +type NullableDeleteRouteResponse struct { + value *DeleteRouteResponse + isSet bool +} + +func (v NullableDeleteRouteResponse) Get() *DeleteRouteResponse { + return v.value +} + +func (v *NullableDeleteRouteResponse) Set(val *DeleteRouteResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteRouteResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteRouteResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteRouteResponse(val *DeleteRouteResponse) *NullableDeleteRouteResponse { + return &NullableDeleteRouteResponse{value: val, isSet: true} +} + +func (v NullableDeleteRouteResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteRouteResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go new file mode 100644 index 000000000..c595a05be --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteRouteTableRequest struct for DeleteRouteTableRequest +type DeleteRouteTableRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the route table you want to delete. + RouteTableId string `json:"RouteTableId"` +} + +// NewDeleteRouteTableRequest instantiates a new DeleteRouteTableRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteRouteTableRequest(routeTableId string, ) *DeleteRouteTableRequest { + this := DeleteRouteTableRequest{} + this.RouteTableId = routeTableId + return &this +} + +// NewDeleteRouteTableRequestWithDefaults instantiates a new DeleteRouteTableRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteRouteTableRequestWithDefaults() *DeleteRouteTableRequest { + this := DeleteRouteTableRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteRouteTableRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteRouteTableRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteRouteTableRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteRouteTableRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *DeleteRouteTableRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *DeleteRouteTableRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *DeleteRouteTableRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +func (o DeleteRouteTableRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteRouteTableRequest struct { + value *DeleteRouteTableRequest + isSet bool +} + +func (v NullableDeleteRouteTableRequest) Get() *DeleteRouteTableRequest { + return v.value +} + +func (v *NullableDeleteRouteTableRequest) Set(val *DeleteRouteTableRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteRouteTableRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteRouteTableRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteRouteTableRequest(val *DeleteRouteTableRequest) *NullableDeleteRouteTableRequest { + return &NullableDeleteRouteTableRequest{value: val, isSet: true} +} + +func (v NullableDeleteRouteTableRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteRouteTableRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go new file mode 100644 index 000000000..9c92a0f4e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteRouteTableResponse struct for DeleteRouteTableResponse +type DeleteRouteTableResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteRouteTableResponse instantiates a new DeleteRouteTableResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteRouteTableResponse() *DeleteRouteTableResponse { + this := DeleteRouteTableResponse{} + return &this +} + +// NewDeleteRouteTableResponseWithDefaults instantiates a new DeleteRouteTableResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteRouteTableResponseWithDefaults() *DeleteRouteTableResponse { + this := DeleteRouteTableResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteRouteTableResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteRouteTableResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteRouteTableResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteRouteTableResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteRouteTableResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteRouteTableResponse struct { + value *DeleteRouteTableResponse + isSet bool +} + +func (v NullableDeleteRouteTableResponse) Get() *DeleteRouteTableResponse { + return v.value +} + +func (v *NullableDeleteRouteTableResponse) Set(val *DeleteRouteTableResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteRouteTableResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteRouteTableResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteRouteTableResponse(val *DeleteRouteTableResponse) *NullableDeleteRouteTableResponse { + return &NullableDeleteRouteTableResponse{value: val, isSet: true} +} + +func (v NullableDeleteRouteTableResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteRouteTableResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go new file mode 100644 index 000000000..5777ee03a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSecurityGroupRequest struct for DeleteSecurityGroupRequest +type DeleteSecurityGroupRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the security group you want to delete. + SecurityGroupId *string `json:"SecurityGroupId,omitempty"` + // The name of the security group. + SecurityGroupName *string `json:"SecurityGroupName,omitempty"` +} + +// NewDeleteSecurityGroupRequest instantiates a new DeleteSecurityGroupRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSecurityGroupRequest() *DeleteSecurityGroupRequest { + this := DeleteSecurityGroupRequest{} + return &this +} + +// NewDeleteSecurityGroupRequestWithDefaults instantiates a new DeleteSecurityGroupRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSecurityGroupRequestWithDefaults() *DeleteSecurityGroupRequest { + this := DeleteSecurityGroupRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteSecurityGroupRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRequest) GetSecurityGroupId() string { + if o == nil || o.SecurityGroupId == nil { + var ret string + return ret + } + return *o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRequest) GetSecurityGroupIdOk() (*string, bool) { + if o == nil || o.SecurityGroupId == nil { + return nil, false + } + return o.SecurityGroupId, true +} + +// HasSecurityGroupId returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRequest) HasSecurityGroupId() bool { + if o != nil && o.SecurityGroupId != nil { + return true + } + + return false +} + +// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. +func (o *DeleteSecurityGroupRequest) SetSecurityGroupId(v string) { + o.SecurityGroupId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRequest) GetSecurityGroupName() string { + if o == nil || o.SecurityGroupName == nil { + var ret string + return ret + } + return *o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRequest) GetSecurityGroupNameOk() (*string, bool) { + if o == nil || o.SecurityGroupName == nil { + return nil, false + } + return o.SecurityGroupName, true +} + +// HasSecurityGroupName returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRequest) HasSecurityGroupName() bool { + if o != nil && o.SecurityGroupName != nil { + return true + } + + return false +} + +// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. +func (o *DeleteSecurityGroupRequest) SetSecurityGroupName(v string) { + o.SecurityGroupName = &v +} + +func (o DeleteSecurityGroupRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.SecurityGroupId != nil { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupName != nil { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSecurityGroupRequest struct { + value *DeleteSecurityGroupRequest + isSet bool +} + +func (v NullableDeleteSecurityGroupRequest) Get() *DeleteSecurityGroupRequest { + return v.value +} + +func (v *NullableDeleteSecurityGroupRequest) Set(val *DeleteSecurityGroupRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSecurityGroupRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSecurityGroupRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSecurityGroupRequest(val *DeleteSecurityGroupRequest) *NullableDeleteSecurityGroupRequest { + return &NullableDeleteSecurityGroupRequest{value: val, isSet: true} +} + +func (v NullableDeleteSecurityGroupRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSecurityGroupRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go new file mode 100644 index 000000000..f6a9294f1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSecurityGroupResponse struct for DeleteSecurityGroupResponse +type DeleteSecurityGroupResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteSecurityGroupResponse instantiates a new DeleteSecurityGroupResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSecurityGroupResponse() *DeleteSecurityGroupResponse { + this := DeleteSecurityGroupResponse{} + return &this +} + +// NewDeleteSecurityGroupResponseWithDefaults instantiates a new DeleteSecurityGroupResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSecurityGroupResponseWithDefaults() *DeleteSecurityGroupResponse { + this := DeleteSecurityGroupResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteSecurityGroupResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteSecurityGroupResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteSecurityGroupResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteSecurityGroupResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSecurityGroupResponse struct { + value *DeleteSecurityGroupResponse + isSet bool +} + +func (v NullableDeleteSecurityGroupResponse) Get() *DeleteSecurityGroupResponse { + return v.value +} + +func (v *NullableDeleteSecurityGroupResponse) Set(val *DeleteSecurityGroupResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSecurityGroupResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSecurityGroupResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSecurityGroupResponse(val *DeleteSecurityGroupResponse) *NullableDeleteSecurityGroupResponse { + return &NullableDeleteSecurityGroupResponse{value: val, isSet: true} +} + +func (v NullableDeleteSecurityGroupResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSecurityGroupResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go new file mode 100644 index 000000000..5e5bb542c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go @@ -0,0 +1,436 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSecurityGroupRuleRequest struct for DeleteSecurityGroupRuleRequest +type DeleteSecurityGroupRuleRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. + Flow string `json:"Flow"` + // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + FromPortRange *int32 `json:"FromPortRange,omitempty"` + // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + IpProtocol *string `json:"IpProtocol,omitempty"` + // The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // One or more rules you want to delete from the security group. + Rules *[]SecurityGroupRule `json:"Rules,omitempty"` + // The account ID of the owner of the security group you want to delete a rule from. + SecurityGroupAccountIdToUnlink *string `json:"SecurityGroupAccountIdToUnlink,omitempty"` + // The ID of the security group you want to delete a rule from. + SecurityGroupId string `json:"SecurityGroupId"` + // The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. + SecurityGroupNameToUnlink *string `json:"SecurityGroupNameToUnlink,omitempty"` + // The end of the port range for the TCP and UDP protocols, or an ICMP type number. + ToPortRange *int32 `json:"ToPortRange,omitempty"` +} + +// NewDeleteSecurityGroupRuleRequest instantiates a new DeleteSecurityGroupRuleRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSecurityGroupRuleRequest(flow string, securityGroupId string, ) *DeleteSecurityGroupRuleRequest { + this := DeleteSecurityGroupRuleRequest{} + this.Flow = flow + this.SecurityGroupId = securityGroupId + return &this +} + +// NewDeleteSecurityGroupRuleRequestWithDefaults instantiates a new DeleteSecurityGroupRuleRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSecurityGroupRuleRequestWithDefaults() *DeleteSecurityGroupRuleRequest { + this := DeleteSecurityGroupRuleRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteSecurityGroupRuleRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlow returns the Flow field value +func (o *DeleteSecurityGroupRuleRequest) GetFlow() string { + if o == nil { + var ret string + return ret + } + + return o.Flow +} + +// GetFlowOk returns a tuple with the Flow field value +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetFlowOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Flow, true +} + +// SetFlow sets field value +func (o *DeleteSecurityGroupRuleRequest) SetFlow(v string) { + o.Flow = v +} + +// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetFromPortRange() int32 { + if o == nil || o.FromPortRange == nil { + var ret int32 + return ret + } + return *o.FromPortRange +} + +// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetFromPortRangeOk() (*int32, bool) { + if o == nil || o.FromPortRange == nil { + return nil, false + } + return o.FromPortRange, true +} + +// HasFromPortRange returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasFromPortRange() bool { + if o != nil && o.FromPortRange != nil { + return true + } + + return false +} + +// SetFromPortRange gets a reference to the given int32 and assigns it to the FromPortRange field. +func (o *DeleteSecurityGroupRuleRequest) SetFromPortRange(v int32) { + o.FromPortRange = &v +} + +// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetIpProtocol() string { + if o == nil || o.IpProtocol == nil { + var ret string + return ret + } + return *o.IpProtocol +} + +// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetIpProtocolOk() (*string, bool) { + if o == nil || o.IpProtocol == nil { + return nil, false + } + return o.IpProtocol, true +} + +// HasIpProtocol returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasIpProtocol() bool { + if o != nil && o.IpProtocol != nil { + return true + } + + return false +} + +// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. +func (o *DeleteSecurityGroupRuleRequest) SetIpProtocol(v string) { + o.IpProtocol = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *DeleteSecurityGroupRuleRequest) SetIpRange(v string) { + o.IpRange = &v +} + +// GetRules returns the Rules field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetRules() []SecurityGroupRule { + if o == nil || o.Rules == nil { + var ret []SecurityGroupRule + return ret + } + return *o.Rules +} + +// GetRulesOk returns a tuple with the Rules field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetRulesOk() (*[]SecurityGroupRule, bool) { + if o == nil || o.Rules == nil { + return nil, false + } + return o.Rules, true +} + +// HasRules returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasRules() bool { + if o != nil && o.Rules != nil { + return true + } + + return false +} + +// SetRules gets a reference to the given []SecurityGroupRule and assigns it to the Rules field. +func (o *DeleteSecurityGroupRuleRequest) SetRules(v []SecurityGroupRule) { + o.Rules = &v +} + +// GetSecurityGroupAccountIdToUnlink returns the SecurityGroupAccountIdToUnlink field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupAccountIdToUnlink() string { + if o == nil || o.SecurityGroupAccountIdToUnlink == nil { + var ret string + return ret + } + return *o.SecurityGroupAccountIdToUnlink +} + +// GetSecurityGroupAccountIdToUnlinkOk returns a tuple with the SecurityGroupAccountIdToUnlink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupAccountIdToUnlinkOk() (*string, bool) { + if o == nil || o.SecurityGroupAccountIdToUnlink == nil { + return nil, false + } + return o.SecurityGroupAccountIdToUnlink, true +} + +// HasSecurityGroupAccountIdToUnlink returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasSecurityGroupAccountIdToUnlink() bool { + if o != nil && o.SecurityGroupAccountIdToUnlink != nil { + return true + } + + return false +} + +// SetSecurityGroupAccountIdToUnlink gets a reference to the given string and assigns it to the SecurityGroupAccountIdToUnlink field. +func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupAccountIdToUnlink(v string) { + o.SecurityGroupAccountIdToUnlink = &v +} + +// GetSecurityGroupId returns the SecurityGroupId field value +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupId() string { + if o == nil { + var ret string + return ret + } + + return o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SecurityGroupId, true +} + +// SetSecurityGroupId sets field value +func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupId(v string) { + o.SecurityGroupId = v +} + +// GetSecurityGroupNameToUnlink returns the SecurityGroupNameToUnlink field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupNameToUnlink() string { + if o == nil || o.SecurityGroupNameToUnlink == nil { + var ret string + return ret + } + return *o.SecurityGroupNameToUnlink +} + +// GetSecurityGroupNameToUnlinkOk returns a tuple with the SecurityGroupNameToUnlink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupNameToUnlinkOk() (*string, bool) { + if o == nil || o.SecurityGroupNameToUnlink == nil { + return nil, false + } + return o.SecurityGroupNameToUnlink, true +} + +// HasSecurityGroupNameToUnlink returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasSecurityGroupNameToUnlink() bool { + if o != nil && o.SecurityGroupNameToUnlink != nil { + return true + } + + return false +} + +// SetSecurityGroupNameToUnlink gets a reference to the given string and assigns it to the SecurityGroupNameToUnlink field. +func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupNameToUnlink(v string) { + o.SecurityGroupNameToUnlink = &v +} + +// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleRequest) GetToPortRange() int32 { + if o == nil || o.ToPortRange == nil { + var ret int32 + return ret + } + return *o.ToPortRange +} + +// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleRequest) GetToPortRangeOk() (*int32, bool) { + if o == nil || o.ToPortRange == nil { + return nil, false + } + return o.ToPortRange, true +} + +// HasToPortRange returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleRequest) HasToPortRange() bool { + if o != nil && o.ToPortRange != nil { + return true + } + + return false +} + +// SetToPortRange gets a reference to the given int32 and assigns it to the ToPortRange field. +func (o *DeleteSecurityGroupRuleRequest) SetToPortRange(v int32) { + o.ToPortRange = &v +} + +func (o DeleteSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Flow"] = o.Flow + } + if o.FromPortRange != nil { + toSerialize["FromPortRange"] = o.FromPortRange + } + if o.IpProtocol != nil { + toSerialize["IpProtocol"] = o.IpProtocol + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.Rules != nil { + toSerialize["Rules"] = o.Rules + } + if o.SecurityGroupAccountIdToUnlink != nil { + toSerialize["SecurityGroupAccountIdToUnlink"] = o.SecurityGroupAccountIdToUnlink + } + if true { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupNameToUnlink != nil { + toSerialize["SecurityGroupNameToUnlink"] = o.SecurityGroupNameToUnlink + } + if o.ToPortRange != nil { + toSerialize["ToPortRange"] = o.ToPortRange + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSecurityGroupRuleRequest struct { + value *DeleteSecurityGroupRuleRequest + isSet bool +} + +func (v NullableDeleteSecurityGroupRuleRequest) Get() *DeleteSecurityGroupRuleRequest { + return v.value +} + +func (v *NullableDeleteSecurityGroupRuleRequest) Set(val *DeleteSecurityGroupRuleRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSecurityGroupRuleRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSecurityGroupRuleRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSecurityGroupRuleRequest(val *DeleteSecurityGroupRuleRequest) *NullableDeleteSecurityGroupRuleRequest { + return &NullableDeleteSecurityGroupRuleRequest{value: val, isSet: true} +} + +func (v NullableDeleteSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSecurityGroupRuleRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go new file mode 100644 index 000000000..e85cd92d3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSecurityGroupRuleResponse struct for DeleteSecurityGroupRuleResponse +type DeleteSecurityGroupRuleResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` +} + +// NewDeleteSecurityGroupRuleResponse instantiates a new DeleteSecurityGroupRuleResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSecurityGroupRuleResponse() *DeleteSecurityGroupRuleResponse { + this := DeleteSecurityGroupRuleResponse{} + return &this +} + +// NewDeleteSecurityGroupRuleResponseWithDefaults instantiates a new DeleteSecurityGroupRuleResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSecurityGroupRuleResponseWithDefaults() *DeleteSecurityGroupRuleResponse { + this := DeleteSecurityGroupRuleResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteSecurityGroupRuleResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. +func (o *DeleteSecurityGroupRuleResponse) GetSecurityGroup() SecurityGroup { + if o == nil || o.SecurityGroup == nil { + var ret SecurityGroup + return ret + } + return *o.SecurityGroup +} + +// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSecurityGroupRuleResponse) GetSecurityGroupOk() (*SecurityGroup, bool) { + if o == nil || o.SecurityGroup == nil { + return nil, false + } + return o.SecurityGroup, true +} + +// HasSecurityGroup returns a boolean if a field has been set. +func (o *DeleteSecurityGroupRuleResponse) HasSecurityGroup() bool { + if o != nil && o.SecurityGroup != nil { + return true + } + + return false +} + +// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. +func (o *DeleteSecurityGroupRuleResponse) SetSecurityGroup(v SecurityGroup) { + o.SecurityGroup = &v +} + +func (o DeleteSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SecurityGroup != nil { + toSerialize["SecurityGroup"] = o.SecurityGroup + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSecurityGroupRuleResponse struct { + value *DeleteSecurityGroupRuleResponse + isSet bool +} + +func (v NullableDeleteSecurityGroupRuleResponse) Get() *DeleteSecurityGroupRuleResponse { + return v.value +} + +func (v *NullableDeleteSecurityGroupRuleResponse) Set(val *DeleteSecurityGroupRuleResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSecurityGroupRuleResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSecurityGroupRuleResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSecurityGroupRuleResponse(val *DeleteSecurityGroupRuleResponse) *NullableDeleteSecurityGroupRuleResponse { + return &NullableDeleteSecurityGroupRuleResponse{value: val, isSet: true} +} + +func (v NullableDeleteSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSecurityGroupRuleResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go new file mode 100644 index 000000000..37fb65eac --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteServerCertificateRequest struct for DeleteServerCertificateRequest +type DeleteServerCertificateRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the server certificate you want to delete. + Name string `json:"Name"` +} + +// NewDeleteServerCertificateRequest instantiates a new DeleteServerCertificateRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteServerCertificateRequest(name string, ) *DeleteServerCertificateRequest { + this := DeleteServerCertificateRequest{} + this.Name = name + return &this +} + +// NewDeleteServerCertificateRequestWithDefaults instantiates a new DeleteServerCertificateRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteServerCertificateRequestWithDefaults() *DeleteServerCertificateRequest { + this := DeleteServerCertificateRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteServerCertificateRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteServerCertificateRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteServerCertificateRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteServerCertificateRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetName returns the Name field value +func (o *DeleteServerCertificateRequest) GetName() string { + if o == nil { + var ret string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *DeleteServerCertificateRequest) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Name, true +} + +// SetName sets field value +func (o *DeleteServerCertificateRequest) SetName(v string) { + o.Name = v +} + +func (o DeleteServerCertificateRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Name"] = o.Name + } + return json.Marshal(toSerialize) +} + +type NullableDeleteServerCertificateRequest struct { + value *DeleteServerCertificateRequest + isSet bool +} + +func (v NullableDeleteServerCertificateRequest) Get() *DeleteServerCertificateRequest { + return v.value +} + +func (v *NullableDeleteServerCertificateRequest) Set(val *DeleteServerCertificateRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteServerCertificateRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteServerCertificateRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteServerCertificateRequest(val *DeleteServerCertificateRequest) *NullableDeleteServerCertificateRequest { + return &NullableDeleteServerCertificateRequest{value: val, isSet: true} +} + +func (v NullableDeleteServerCertificateRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteServerCertificateRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go new file mode 100644 index 000000000..dca75fae3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteServerCertificateResponse struct for DeleteServerCertificateResponse +type DeleteServerCertificateResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteServerCertificateResponse instantiates a new DeleteServerCertificateResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteServerCertificateResponse() *DeleteServerCertificateResponse { + this := DeleteServerCertificateResponse{} + return &this +} + +// NewDeleteServerCertificateResponseWithDefaults instantiates a new DeleteServerCertificateResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteServerCertificateResponseWithDefaults() *DeleteServerCertificateResponse { + this := DeleteServerCertificateResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteServerCertificateResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteServerCertificateResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteServerCertificateResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteServerCertificateResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteServerCertificateResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteServerCertificateResponse struct { + value *DeleteServerCertificateResponse + isSet bool +} + +func (v NullableDeleteServerCertificateResponse) Get() *DeleteServerCertificateResponse { + return v.value +} + +func (v *NullableDeleteServerCertificateResponse) Set(val *DeleteServerCertificateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteServerCertificateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteServerCertificateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteServerCertificateResponse(val *DeleteServerCertificateResponse) *NullableDeleteServerCertificateResponse { + return &NullableDeleteServerCertificateResponse{value: val, isSet: true} +} + +func (v NullableDeleteServerCertificateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteServerCertificateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go new file mode 100644 index 000000000..4d532c972 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSnapshotRequest struct for DeleteSnapshotRequest +type DeleteSnapshotRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the snapshot you want to delete. + SnapshotId string `json:"SnapshotId"` +} + +// NewDeleteSnapshotRequest instantiates a new DeleteSnapshotRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSnapshotRequest(snapshotId string, ) *DeleteSnapshotRequest { + this := DeleteSnapshotRequest{} + this.SnapshotId = snapshotId + return &this +} + +// NewDeleteSnapshotRequestWithDefaults instantiates a new DeleteSnapshotRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSnapshotRequestWithDefaults() *DeleteSnapshotRequest { + this := DeleteSnapshotRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteSnapshotRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSnapshotRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteSnapshotRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteSnapshotRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetSnapshotId returns the SnapshotId field value +func (o *DeleteSnapshotRequest) GetSnapshotId() string { + if o == nil { + var ret string + return ret + } + + return o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value +// and a boolean to check if the value has been set. +func (o *DeleteSnapshotRequest) GetSnapshotIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SnapshotId, true +} + +// SetSnapshotId sets field value +func (o *DeleteSnapshotRequest) SetSnapshotId(v string) { + o.SnapshotId = v +} + +func (o DeleteSnapshotRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["SnapshotId"] = o.SnapshotId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSnapshotRequest struct { + value *DeleteSnapshotRequest + isSet bool +} + +func (v NullableDeleteSnapshotRequest) Get() *DeleteSnapshotRequest { + return v.value +} + +func (v *NullableDeleteSnapshotRequest) Set(val *DeleteSnapshotRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSnapshotRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSnapshotRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSnapshotRequest(val *DeleteSnapshotRequest) *NullableDeleteSnapshotRequest { + return &NullableDeleteSnapshotRequest{value: val, isSet: true} +} + +func (v NullableDeleteSnapshotRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSnapshotRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go new file mode 100644 index 000000000..849dae470 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSnapshotResponse struct for DeleteSnapshotResponse +type DeleteSnapshotResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteSnapshotResponse instantiates a new DeleteSnapshotResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSnapshotResponse() *DeleteSnapshotResponse { + this := DeleteSnapshotResponse{} + return &this +} + +// NewDeleteSnapshotResponseWithDefaults instantiates a new DeleteSnapshotResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSnapshotResponseWithDefaults() *DeleteSnapshotResponse { + this := DeleteSnapshotResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteSnapshotResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSnapshotResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteSnapshotResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteSnapshotResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteSnapshotResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSnapshotResponse struct { + value *DeleteSnapshotResponse + isSet bool +} + +func (v NullableDeleteSnapshotResponse) Get() *DeleteSnapshotResponse { + return v.value +} + +func (v *NullableDeleteSnapshotResponse) Set(val *DeleteSnapshotResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSnapshotResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSnapshotResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSnapshotResponse(val *DeleteSnapshotResponse) *NullableDeleteSnapshotResponse { + return &NullableDeleteSnapshotResponse{value: val, isSet: true} +} + +func (v NullableDeleteSnapshotResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSnapshotResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go new file mode 100644 index 000000000..2d0c6fb57 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSubnetRequest struct for DeleteSubnetRequest +type DeleteSubnetRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Subnet you want to delete. + SubnetId string `json:"SubnetId"` +} + +// NewDeleteSubnetRequest instantiates a new DeleteSubnetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSubnetRequest(subnetId string, ) *DeleteSubnetRequest { + this := DeleteSubnetRequest{} + this.SubnetId = subnetId + return &this +} + +// NewDeleteSubnetRequestWithDefaults instantiates a new DeleteSubnetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSubnetRequestWithDefaults() *DeleteSubnetRequest { + this := DeleteSubnetRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteSubnetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSubnetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteSubnetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteSubnetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetSubnetId returns the SubnetId field value +func (o *DeleteSubnetRequest) GetSubnetId() string { + if o == nil { + var ret string + return ret + } + + return o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value +// and a boolean to check if the value has been set. +func (o *DeleteSubnetRequest) GetSubnetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubnetId, true +} + +// SetSubnetId sets field value +func (o *DeleteSubnetRequest) SetSubnetId(v string) { + o.SubnetId = v +} + +func (o DeleteSubnetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSubnetRequest struct { + value *DeleteSubnetRequest + isSet bool +} + +func (v NullableDeleteSubnetRequest) Get() *DeleteSubnetRequest { + return v.value +} + +func (v *NullableDeleteSubnetRequest) Set(val *DeleteSubnetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSubnetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSubnetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSubnetRequest(val *DeleteSubnetRequest) *NullableDeleteSubnetRequest { + return &NullableDeleteSubnetRequest{value: val, isSet: true} +} + +func (v NullableDeleteSubnetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSubnetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go new file mode 100644 index 000000000..7fba3f2c6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteSubnetResponse struct for DeleteSubnetResponse +type DeleteSubnetResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteSubnetResponse instantiates a new DeleteSubnetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSubnetResponse() *DeleteSubnetResponse { + this := DeleteSubnetResponse{} + return &this +} + +// NewDeleteSubnetResponseWithDefaults instantiates a new DeleteSubnetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSubnetResponseWithDefaults() *DeleteSubnetResponse { + this := DeleteSubnetResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteSubnetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSubnetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteSubnetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteSubnetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteSubnetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteSubnetResponse struct { + value *DeleteSubnetResponse + isSet bool +} + +func (v NullableDeleteSubnetResponse) Get() *DeleteSubnetResponse { + return v.value +} + +func (v *NullableDeleteSubnetResponse) Set(val *DeleteSubnetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSubnetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSubnetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSubnetResponse(val *DeleteSubnetResponse) *NullableDeleteSubnetResponse { + return &NullableDeleteSubnetResponse{value: val, isSet: true} +} + +func (v NullableDeleteSubnetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSubnetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go new file mode 100644 index 000000000..e279f16aa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteTagsRequest struct for DeleteTagsRequest +type DeleteTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more resource IDs. + ResourceIds []string `json:"ResourceIds"` + // One or more tags to delete (if you set a tag value, only the tags matching exactly this value are deleted). + Tags []ResourceTag `json:"Tags"` +} + +// NewDeleteTagsRequest instantiates a new DeleteTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteTagsRequest(resourceIds []string, tags []ResourceTag, ) *DeleteTagsRequest { + this := DeleteTagsRequest{} + this.ResourceIds = resourceIds + this.Tags = tags + return &this +} + +// NewDeleteTagsRequestWithDefaults instantiates a new DeleteTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteTagsRequestWithDefaults() *DeleteTagsRequest { + this := DeleteTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetResourceIds returns the ResourceIds field value +func (o *DeleteTagsRequest) GetResourceIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.ResourceIds +} + +// GetResourceIdsOk returns a tuple with the ResourceIds field value +// and a boolean to check if the value has been set. +func (o *DeleteTagsRequest) GetResourceIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.ResourceIds, true +} + +// SetResourceIds sets field value +func (o *DeleteTagsRequest) SetResourceIds(v []string) { + o.ResourceIds = v +} + +// GetTags returns the Tags field value +func (o *DeleteTagsRequest) GetTags() []ResourceTag { + if o == nil { + var ret []ResourceTag + return ret + } + + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value +// and a boolean to check if the value has been set. +func (o *DeleteTagsRequest) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil { + return nil, false + } + return &o.Tags, true +} + +// SetTags sets field value +func (o *DeleteTagsRequest) SetTags(v []ResourceTag) { + o.Tags = v +} + +func (o DeleteTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ResourceIds"] = o.ResourceIds + } + if true { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableDeleteTagsRequest struct { + value *DeleteTagsRequest + isSet bool +} + +func (v NullableDeleteTagsRequest) Get() *DeleteTagsRequest { + return v.value +} + +func (v *NullableDeleteTagsRequest) Set(val *DeleteTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteTagsRequest(val *DeleteTagsRequest) *NullableDeleteTagsRequest { + return &NullableDeleteTagsRequest{value: val, isSet: true} +} + +func (v NullableDeleteTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go new file mode 100644 index 000000000..102c29005 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteTagsResponse struct for DeleteTagsResponse +type DeleteTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteTagsResponse instantiates a new DeleteTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteTagsResponse() *DeleteTagsResponse { + this := DeleteTagsResponse{} + return &this +} + +// NewDeleteTagsResponseWithDefaults instantiates a new DeleteTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteTagsResponseWithDefaults() *DeleteTagsResponse { + this := DeleteTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteTagsResponse struct { + value *DeleteTagsResponse + isSet bool +} + +func (v NullableDeleteTagsResponse) Get() *DeleteTagsResponse { + return v.value +} + +func (v *NullableDeleteTagsResponse) Set(val *DeleteTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteTagsResponse(val *DeleteTagsResponse) *NullableDeleteTagsResponse { + return &NullableDeleteTagsResponse{value: val, isSet: true} +} + +func (v NullableDeleteTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go new file mode 100644 index 000000000..f9df71653 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVirtualGatewayRequest struct for DeleteVirtualGatewayRequest +type DeleteVirtualGatewayRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the virtual gateway you want to delete. + VirtualGatewayId string `json:"VirtualGatewayId"` +} + +// NewDeleteVirtualGatewayRequest instantiates a new DeleteVirtualGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVirtualGatewayRequest(virtualGatewayId string, ) *DeleteVirtualGatewayRequest { + this := DeleteVirtualGatewayRequest{} + this.VirtualGatewayId = virtualGatewayId + return &this +} + +// NewDeleteVirtualGatewayRequestWithDefaults instantiates a new DeleteVirtualGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVirtualGatewayRequestWithDefaults() *DeleteVirtualGatewayRequest { + this := DeleteVirtualGatewayRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteVirtualGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVirtualGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteVirtualGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteVirtualGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *DeleteVirtualGatewayRequest) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *DeleteVirtualGatewayRequest) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *DeleteVirtualGatewayRequest) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +func (o DeleteVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVirtualGatewayRequest struct { + value *DeleteVirtualGatewayRequest + isSet bool +} + +func (v NullableDeleteVirtualGatewayRequest) Get() *DeleteVirtualGatewayRequest { + return v.value +} + +func (v *NullableDeleteVirtualGatewayRequest) Set(val *DeleteVirtualGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVirtualGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVirtualGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVirtualGatewayRequest(val *DeleteVirtualGatewayRequest) *NullableDeleteVirtualGatewayRequest { + return &NullableDeleteVirtualGatewayRequest{value: val, isSet: true} +} + +func (v NullableDeleteVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVirtualGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go new file mode 100644 index 000000000..1b543a9c4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVirtualGatewayResponse struct for DeleteVirtualGatewayResponse +type DeleteVirtualGatewayResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteVirtualGatewayResponse instantiates a new DeleteVirtualGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVirtualGatewayResponse() *DeleteVirtualGatewayResponse { + this := DeleteVirtualGatewayResponse{} + return &this +} + +// NewDeleteVirtualGatewayResponseWithDefaults instantiates a new DeleteVirtualGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVirtualGatewayResponseWithDefaults() *DeleteVirtualGatewayResponse { + this := DeleteVirtualGatewayResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteVirtualGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVirtualGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteVirtualGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteVirtualGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVirtualGatewayResponse struct { + value *DeleteVirtualGatewayResponse + isSet bool +} + +func (v NullableDeleteVirtualGatewayResponse) Get() *DeleteVirtualGatewayResponse { + return v.value +} + +func (v *NullableDeleteVirtualGatewayResponse) Set(val *DeleteVirtualGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVirtualGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVirtualGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVirtualGatewayResponse(val *DeleteVirtualGatewayResponse) *NullableDeleteVirtualGatewayResponse { + return &NullableDeleteVirtualGatewayResponse{value: val, isSet: true} +} + +func (v NullableDeleteVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVirtualGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go new file mode 100644 index 000000000..8655440ef --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVmsRequest struct for DeleteVmsRequest +type DeleteVmsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more IDs of VMs. + VmIds []string `json:"VmIds"` +} + +// NewDeleteVmsRequest instantiates a new DeleteVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVmsRequest(vmIds []string, ) *DeleteVmsRequest { + this := DeleteVmsRequest{} + this.VmIds = vmIds + return &this +} + +// NewDeleteVmsRequestWithDefaults instantiates a new DeleteVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVmsRequestWithDefaults() *DeleteVmsRequest { + this := DeleteVmsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmIds returns the VmIds field value +func (o *DeleteVmsRequest) GetVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value +// and a boolean to check if the value has been set. +func (o *DeleteVmsRequest) GetVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.VmIds, true +} + +// SetVmIds sets field value +func (o *DeleteVmsRequest) SetVmIds(v []string) { + o.VmIds = v +} + +func (o DeleteVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVmsRequest struct { + value *DeleteVmsRequest + isSet bool +} + +func (v NullableDeleteVmsRequest) Get() *DeleteVmsRequest { + return v.value +} + +func (v *NullableDeleteVmsRequest) Set(val *DeleteVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVmsRequest(val *DeleteVmsRequest) *NullableDeleteVmsRequest { + return &NullableDeleteVmsRequest{value: val, isSet: true} +} + +func (v NullableDeleteVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go new file mode 100644 index 000000000..a9eb9985b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVmsResponse struct for DeleteVmsResponse +type DeleteVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more terminated VMs. + Vms *[]VmState `json:"Vms,omitempty"` +} + +// NewDeleteVmsResponse instantiates a new DeleteVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVmsResponse() *DeleteVmsResponse { + this := DeleteVmsResponse{} + return &this +} + +// NewDeleteVmsResponseWithDefaults instantiates a new DeleteVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVmsResponseWithDefaults() *DeleteVmsResponse { + this := DeleteVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVms returns the Vms field value if set, zero value otherwise. +func (o *DeleteVmsResponse) GetVms() []VmState { + if o == nil || o.Vms == nil { + var ret []VmState + return ret + } + return *o.Vms +} + +// GetVmsOk returns a tuple with the Vms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVmsResponse) GetVmsOk() (*[]VmState, bool) { + if o == nil || o.Vms == nil { + return nil, false + } + return o.Vms, true +} + +// HasVms returns a boolean if a field has been set. +func (o *DeleteVmsResponse) HasVms() bool { + if o != nil && o.Vms != nil { + return true + } + + return false +} + +// SetVms gets a reference to the given []VmState and assigns it to the Vms field. +func (o *DeleteVmsResponse) SetVms(v []VmState) { + o.Vms = &v +} + +func (o DeleteVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vms != nil { + toSerialize["Vms"] = o.Vms + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVmsResponse struct { + value *DeleteVmsResponse + isSet bool +} + +func (v NullableDeleteVmsResponse) Get() *DeleteVmsResponse { + return v.value +} + +func (v *NullableDeleteVmsResponse) Set(val *DeleteVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVmsResponse(val *DeleteVmsResponse) *NullableDeleteVmsResponse { + return &NullableDeleteVmsResponse{value: val, isSet: true} +} + +func (v NullableDeleteVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go new file mode 100644 index 000000000..fa7bb8a5d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVolumeRequest struct for DeleteVolumeRequest +type DeleteVolumeRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the volume you want to delete. + VolumeId string `json:"VolumeId"` +} + +// NewDeleteVolumeRequest instantiates a new DeleteVolumeRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVolumeRequest(volumeId string, ) *DeleteVolumeRequest { + this := DeleteVolumeRequest{} + this.VolumeId = volumeId + return &this +} + +// NewDeleteVolumeRequestWithDefaults instantiates a new DeleteVolumeRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVolumeRequestWithDefaults() *DeleteVolumeRequest { + this := DeleteVolumeRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteVolumeRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVolumeRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteVolumeRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteVolumeRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVolumeId returns the VolumeId field value +func (o *DeleteVolumeRequest) GetVolumeId() string { + if o == nil { + var ret string + return ret + } + + return o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value +// and a boolean to check if the value has been set. +func (o *DeleteVolumeRequest) GetVolumeIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VolumeId, true +} + +// SetVolumeId sets field value +func (o *DeleteVolumeRequest) SetVolumeId(v string) { + o.VolumeId = v +} + +func (o DeleteVolumeRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVolumeRequest struct { + value *DeleteVolumeRequest + isSet bool +} + +func (v NullableDeleteVolumeRequest) Get() *DeleteVolumeRequest { + return v.value +} + +func (v *NullableDeleteVolumeRequest) Set(val *DeleteVolumeRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVolumeRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVolumeRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVolumeRequest(val *DeleteVolumeRequest) *NullableDeleteVolumeRequest { + return &NullableDeleteVolumeRequest{value: val, isSet: true} +} + +func (v NullableDeleteVolumeRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVolumeRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go new file mode 100644 index 000000000..828b46fdb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVolumeResponse struct for DeleteVolumeResponse +type DeleteVolumeResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteVolumeResponse instantiates a new DeleteVolumeResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVolumeResponse() *DeleteVolumeResponse { + this := DeleteVolumeResponse{} + return &this +} + +// NewDeleteVolumeResponseWithDefaults instantiates a new DeleteVolumeResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVolumeResponseWithDefaults() *DeleteVolumeResponse { + this := DeleteVolumeResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteVolumeResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVolumeResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteVolumeResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteVolumeResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteVolumeResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVolumeResponse struct { + value *DeleteVolumeResponse + isSet bool +} + +func (v NullableDeleteVolumeResponse) Get() *DeleteVolumeResponse { + return v.value +} + +func (v *NullableDeleteVolumeResponse) Set(val *DeleteVolumeResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVolumeResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVolumeResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVolumeResponse(val *DeleteVolumeResponse) *NullableDeleteVolumeResponse { + return &NullableDeleteVolumeResponse{value: val, isSet: true} +} + +func (v NullableDeleteVolumeResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVolumeResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go new file mode 100644 index 000000000..b9b25df60 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVpnConnectionRequest struct for DeleteVpnConnectionRequest +type DeleteVpnConnectionRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the VPN connection you want to delete. + VpnConnectionId string `json:"VpnConnectionId"` +} + +// NewDeleteVpnConnectionRequest instantiates a new DeleteVpnConnectionRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVpnConnectionRequest(vpnConnectionId string, ) *DeleteVpnConnectionRequest { + this := DeleteVpnConnectionRequest{} + this.VpnConnectionId = vpnConnectionId + return &this +} + +// NewDeleteVpnConnectionRequestWithDefaults instantiates a new DeleteVpnConnectionRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVpnConnectionRequestWithDefaults() *DeleteVpnConnectionRequest { + this := DeleteVpnConnectionRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteVpnConnectionRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteVpnConnectionRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteVpnConnectionRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVpnConnectionId returns the VpnConnectionId field value +func (o *DeleteVpnConnectionRequest) GetVpnConnectionId() string { + if o == nil { + var ret string + return ret + } + + return o.VpnConnectionId +} + +// GetVpnConnectionIdOk returns a tuple with the VpnConnectionId field value +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRequest) GetVpnConnectionIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VpnConnectionId, true +} + +// SetVpnConnectionId sets field value +func (o *DeleteVpnConnectionRequest) SetVpnConnectionId(v string) { + o.VpnConnectionId = v +} + +func (o DeleteVpnConnectionRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VpnConnectionId"] = o.VpnConnectionId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVpnConnectionRequest struct { + value *DeleteVpnConnectionRequest + isSet bool +} + +func (v NullableDeleteVpnConnectionRequest) Get() *DeleteVpnConnectionRequest { + return v.value +} + +func (v *NullableDeleteVpnConnectionRequest) Set(val *DeleteVpnConnectionRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVpnConnectionRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVpnConnectionRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVpnConnectionRequest(val *DeleteVpnConnectionRequest) *NullableDeleteVpnConnectionRequest { + return &NullableDeleteVpnConnectionRequest{value: val, isSet: true} +} + +func (v NullableDeleteVpnConnectionRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVpnConnectionRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go new file mode 100644 index 000000000..5c46b6879 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVpnConnectionResponse struct for DeleteVpnConnectionResponse +type DeleteVpnConnectionResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteVpnConnectionResponse instantiates a new DeleteVpnConnectionResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVpnConnectionResponse() *DeleteVpnConnectionResponse { + this := DeleteVpnConnectionResponse{} + return &this +} + +// NewDeleteVpnConnectionResponseWithDefaults instantiates a new DeleteVpnConnectionResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVpnConnectionResponseWithDefaults() *DeleteVpnConnectionResponse { + this := DeleteVpnConnectionResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteVpnConnectionResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteVpnConnectionResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteVpnConnectionResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteVpnConnectionResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVpnConnectionResponse struct { + value *DeleteVpnConnectionResponse + isSet bool +} + +func (v NullableDeleteVpnConnectionResponse) Get() *DeleteVpnConnectionResponse { + return v.value +} + +func (v *NullableDeleteVpnConnectionResponse) Set(val *DeleteVpnConnectionResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVpnConnectionResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVpnConnectionResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVpnConnectionResponse(val *DeleteVpnConnectionResponse) *NullableDeleteVpnConnectionResponse { + return &NullableDeleteVpnConnectionResponse{value: val, isSet: true} +} + +func (v NullableDeleteVpnConnectionResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVpnConnectionResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go new file mode 100644 index 000000000..dda8b4c1e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVpnConnectionRouteRequest struct for DeleteVpnConnectionRouteRequest +type DeleteVpnConnectionRouteRequest struct { + // The network prefix of the route to delete, in CIDR notation (for example, 10.12.0.0/16). + DestinationIpRange string `json:"DestinationIpRange"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the target VPN connection of the static route to delete. + VpnConnectionId string `json:"VpnConnectionId"` +} + +// NewDeleteVpnConnectionRouteRequest instantiates a new DeleteVpnConnectionRouteRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVpnConnectionRouteRequest(destinationIpRange string, vpnConnectionId string, ) *DeleteVpnConnectionRouteRequest { + this := DeleteVpnConnectionRouteRequest{} + this.DestinationIpRange = destinationIpRange + this.VpnConnectionId = vpnConnectionId + return &this +} + +// NewDeleteVpnConnectionRouteRequestWithDefaults instantiates a new DeleteVpnConnectionRouteRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVpnConnectionRouteRequestWithDefaults() *DeleteVpnConnectionRouteRequest { + this := DeleteVpnConnectionRouteRequest{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value +func (o *DeleteVpnConnectionRouteRequest) GetDestinationIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRouteRequest) GetDestinationIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationIpRange, true +} + +// SetDestinationIpRange sets field value +func (o *DeleteVpnConnectionRouteRequest) SetDestinationIpRange(v string) { + o.DestinationIpRange = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeleteVpnConnectionRouteRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRouteRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeleteVpnConnectionRouteRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeleteVpnConnectionRouteRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVpnConnectionId returns the VpnConnectionId field value +func (o *DeleteVpnConnectionRouteRequest) GetVpnConnectionId() string { + if o == nil { + var ret string + return ret + } + + return o.VpnConnectionId +} + +// GetVpnConnectionIdOk returns a tuple with the VpnConnectionId field value +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRouteRequest) GetVpnConnectionIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VpnConnectionId, true +} + +// SetVpnConnectionId sets field value +func (o *DeleteVpnConnectionRouteRequest) SetVpnConnectionId(v string) { + o.VpnConnectionId = v +} + +func (o DeleteVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VpnConnectionId"] = o.VpnConnectionId + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVpnConnectionRouteRequest struct { + value *DeleteVpnConnectionRouteRequest + isSet bool +} + +func (v NullableDeleteVpnConnectionRouteRequest) Get() *DeleteVpnConnectionRouteRequest { + return v.value +} + +func (v *NullableDeleteVpnConnectionRouteRequest) Set(val *DeleteVpnConnectionRouteRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVpnConnectionRouteRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVpnConnectionRouteRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVpnConnectionRouteRequest(val *DeleteVpnConnectionRouteRequest) *NullableDeleteVpnConnectionRouteRequest { + return &NullableDeleteVpnConnectionRouteRequest{value: val, isSet: true} +} + +func (v NullableDeleteVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVpnConnectionRouteRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go new file mode 100644 index 000000000..fff3bb85f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeleteVpnConnectionRouteResponse struct for DeleteVpnConnectionRouteResponse +type DeleteVpnConnectionRouteResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeleteVpnConnectionRouteResponse instantiates a new DeleteVpnConnectionRouteResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteVpnConnectionRouteResponse() *DeleteVpnConnectionRouteResponse { + this := DeleteVpnConnectionRouteResponse{} + return &this +} + +// NewDeleteVpnConnectionRouteResponseWithDefaults instantiates a new DeleteVpnConnectionRouteResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteVpnConnectionRouteResponseWithDefaults() *DeleteVpnConnectionRouteResponse { + this := DeleteVpnConnectionRouteResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeleteVpnConnectionRouteResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteVpnConnectionRouteResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeleteVpnConnectionRouteResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeleteVpnConnectionRouteResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeleteVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeleteVpnConnectionRouteResponse struct { + value *DeleteVpnConnectionRouteResponse + isSet bool +} + +func (v NullableDeleteVpnConnectionRouteResponse) Get() *DeleteVpnConnectionRouteResponse { + return v.value +} + +func (v *NullableDeleteVpnConnectionRouteResponse) Set(val *DeleteVpnConnectionRouteResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteVpnConnectionRouteResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteVpnConnectionRouteResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteVpnConnectionRouteResponse(val *DeleteVpnConnectionRouteResponse) *NullableDeleteVpnConnectionRouteResponse { + return &NullableDeleteVpnConnectionRouteResponse{value: val, isSet: true} +} + +func (v NullableDeleteVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteVpnConnectionRouteResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go new file mode 100644 index 000000000..2371f93d6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeregisterVmsInLoadBalancerRequest struct for DeregisterVmsInLoadBalancerRequest +type DeregisterVmsInLoadBalancerRequest struct { + // One or more IDs of back-end VMs. + BackendVmIds []string `json:"BackendVmIds"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer. + LoadBalancerName string `json:"LoadBalancerName"` +} + +// NewDeregisterVmsInLoadBalancerRequest instantiates a new DeregisterVmsInLoadBalancerRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeregisterVmsInLoadBalancerRequest(backendVmIds []string, loadBalancerName string, ) *DeregisterVmsInLoadBalancerRequest { + this := DeregisterVmsInLoadBalancerRequest{} + this.BackendVmIds = backendVmIds + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewDeregisterVmsInLoadBalancerRequestWithDefaults instantiates a new DeregisterVmsInLoadBalancerRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeregisterVmsInLoadBalancerRequestWithDefaults() *DeregisterVmsInLoadBalancerRequest { + this := DeregisterVmsInLoadBalancerRequest{} + return &this +} + +// GetBackendVmIds returns the BackendVmIds field value +func (o *DeregisterVmsInLoadBalancerRequest) GetBackendVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.BackendVmIds +} + +// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value +// and a boolean to check if the value has been set. +func (o *DeregisterVmsInLoadBalancerRequest) GetBackendVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.BackendVmIds, true +} + +// SetBackendVmIds sets field value +func (o *DeregisterVmsInLoadBalancerRequest) SetBackendVmIds(v []string) { + o.BackendVmIds = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *DeregisterVmsInLoadBalancerRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeregisterVmsInLoadBalancerRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *DeregisterVmsInLoadBalancerRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *DeregisterVmsInLoadBalancerRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *DeregisterVmsInLoadBalancerRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *DeregisterVmsInLoadBalancerRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *DeregisterVmsInLoadBalancerRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +func (o DeregisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["BackendVmIds"] = o.BackendVmIds + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + return json.Marshal(toSerialize) +} + +type NullableDeregisterVmsInLoadBalancerRequest struct { + value *DeregisterVmsInLoadBalancerRequest + isSet bool +} + +func (v NullableDeregisterVmsInLoadBalancerRequest) Get() *DeregisterVmsInLoadBalancerRequest { + return v.value +} + +func (v *NullableDeregisterVmsInLoadBalancerRequest) Set(val *DeregisterVmsInLoadBalancerRequest) { + v.value = val + v.isSet = true +} + +func (v NullableDeregisterVmsInLoadBalancerRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableDeregisterVmsInLoadBalancerRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeregisterVmsInLoadBalancerRequest(val *DeregisterVmsInLoadBalancerRequest) *NullableDeregisterVmsInLoadBalancerRequest { + return &NullableDeregisterVmsInLoadBalancerRequest{value: val, isSet: true} +} + +func (v NullableDeregisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeregisterVmsInLoadBalancerRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go new file mode 100644 index 000000000..1f068d3e5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DeregisterVmsInLoadBalancerResponse struct for DeregisterVmsInLoadBalancerResponse +type DeregisterVmsInLoadBalancerResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewDeregisterVmsInLoadBalancerResponse instantiates a new DeregisterVmsInLoadBalancerResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeregisterVmsInLoadBalancerResponse() *DeregisterVmsInLoadBalancerResponse { + this := DeregisterVmsInLoadBalancerResponse{} + return &this +} + +// NewDeregisterVmsInLoadBalancerResponseWithDefaults instantiates a new DeregisterVmsInLoadBalancerResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeregisterVmsInLoadBalancerResponseWithDefaults() *DeregisterVmsInLoadBalancerResponse { + this := DeregisterVmsInLoadBalancerResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *DeregisterVmsInLoadBalancerResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeregisterVmsInLoadBalancerResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *DeregisterVmsInLoadBalancerResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *DeregisterVmsInLoadBalancerResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o DeregisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableDeregisterVmsInLoadBalancerResponse struct { + value *DeregisterVmsInLoadBalancerResponse + isSet bool +} + +func (v NullableDeregisterVmsInLoadBalancerResponse) Get() *DeregisterVmsInLoadBalancerResponse { + return v.value +} + +func (v *NullableDeregisterVmsInLoadBalancerResponse) Set(val *DeregisterVmsInLoadBalancerResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeregisterVmsInLoadBalancerResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeregisterVmsInLoadBalancerResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeregisterVmsInLoadBalancerResponse(val *DeregisterVmsInLoadBalancerResponse) *NullableDeregisterVmsInLoadBalancerResponse { + return &NullableDeregisterVmsInLoadBalancerResponse{value: val, isSet: true} +} + +func (v NullableDeregisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeregisterVmsInLoadBalancerResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go new file mode 100644 index 000000000..3220ff2d1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DhcpOptionsSet Information about the DHCP options set. +type DhcpOptionsSet struct { + // If `true`, the DHCP options set is a default one. If `false`, it is not. + Default *bool `json:"Default,omitempty"` + // The name of the DHCP options set. + DhcpOptionsName *string `json:"DhcpOptionsName,omitempty"` + // The ID of the DHCP options set. + DhcpOptionsSetId *string `json:"DhcpOptionsSetId,omitempty"` + // The domain name. + DomainName *string `json:"DomainName,omitempty"` + // One or more IP addresses for the domain name servers. + DomainNameServers *[]string `json:"DomainNameServers,omitempty"` + // One or more IP addresses for the NTP servers. + NtpServers *[]string `json:"NtpServers,omitempty"` + // One or more tags associated with the DHCP options set. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewDhcpOptionsSet instantiates a new DhcpOptionsSet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDhcpOptionsSet() *DhcpOptionsSet { + this := DhcpOptionsSet{} + return &this +} + +// NewDhcpOptionsSetWithDefaults instantiates a new DhcpOptionsSet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDhcpOptionsSetWithDefaults() *DhcpOptionsSet { + this := DhcpOptionsSet{} + return &this +} + +// GetDefault returns the Default field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetDefault() bool { + if o == nil || o.Default == nil { + var ret bool + return ret + } + return *o.Default +} + +// GetDefaultOk returns a tuple with the Default field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetDefaultOk() (*bool, bool) { + if o == nil || o.Default == nil { + return nil, false + } + return o.Default, true +} + +// HasDefault returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasDefault() bool { + if o != nil && o.Default != nil { + return true + } + + return false +} + +// SetDefault gets a reference to the given bool and assigns it to the Default field. +func (o *DhcpOptionsSet) SetDefault(v bool) { + o.Default = &v +} + +// GetDhcpOptionsName returns the DhcpOptionsName field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetDhcpOptionsName() string { + if o == nil || o.DhcpOptionsName == nil { + var ret string + return ret + } + return *o.DhcpOptionsName +} + +// GetDhcpOptionsNameOk returns a tuple with the DhcpOptionsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetDhcpOptionsNameOk() (*string, bool) { + if o == nil || o.DhcpOptionsName == nil { + return nil, false + } + return o.DhcpOptionsName, true +} + +// HasDhcpOptionsName returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasDhcpOptionsName() bool { + if o != nil && o.DhcpOptionsName != nil { + return true + } + + return false +} + +// SetDhcpOptionsName gets a reference to the given string and assigns it to the DhcpOptionsName field. +func (o *DhcpOptionsSet) SetDhcpOptionsName(v string) { + o.DhcpOptionsName = &v +} + +// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetDhcpOptionsSetId() string { + if o == nil || o.DhcpOptionsSetId == nil { + var ret string + return ret + } + return *o.DhcpOptionsSetId +} + +// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetDhcpOptionsSetIdOk() (*string, bool) { + if o == nil || o.DhcpOptionsSetId == nil { + return nil, false + } + return o.DhcpOptionsSetId, true +} + +// HasDhcpOptionsSetId returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasDhcpOptionsSetId() bool { + if o != nil && o.DhcpOptionsSetId != nil { + return true + } + + return false +} + +// SetDhcpOptionsSetId gets a reference to the given string and assigns it to the DhcpOptionsSetId field. +func (o *DhcpOptionsSet) SetDhcpOptionsSetId(v string) { + o.DhcpOptionsSetId = &v +} + +// GetDomainName returns the DomainName field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetDomainName() string { + if o == nil || o.DomainName == nil { + var ret string + return ret + } + return *o.DomainName +} + +// GetDomainNameOk returns a tuple with the DomainName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetDomainNameOk() (*string, bool) { + if o == nil || o.DomainName == nil { + return nil, false + } + return o.DomainName, true +} + +// HasDomainName returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasDomainName() bool { + if o != nil && o.DomainName != nil { + return true + } + + return false +} + +// SetDomainName gets a reference to the given string and assigns it to the DomainName field. +func (o *DhcpOptionsSet) SetDomainName(v string) { + o.DomainName = &v +} + +// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetDomainNameServers() []string { + if o == nil || o.DomainNameServers == nil { + var ret []string + return ret + } + return *o.DomainNameServers +} + +// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetDomainNameServersOk() (*[]string, bool) { + if o == nil || o.DomainNameServers == nil { + return nil, false + } + return o.DomainNameServers, true +} + +// HasDomainNameServers returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasDomainNameServers() bool { + if o != nil && o.DomainNameServers != nil { + return true + } + + return false +} + +// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. +func (o *DhcpOptionsSet) SetDomainNameServers(v []string) { + o.DomainNameServers = &v +} + +// GetNtpServers returns the NtpServers field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetNtpServers() []string { + if o == nil || o.NtpServers == nil { + var ret []string + return ret + } + return *o.NtpServers +} + +// GetNtpServersOk returns a tuple with the NtpServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetNtpServersOk() (*[]string, bool) { + if o == nil || o.NtpServers == nil { + return nil, false + } + return o.NtpServers, true +} + +// HasNtpServers returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasNtpServers() bool { + if o != nil && o.NtpServers != nil { + return true + } + + return false +} + +// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. +func (o *DhcpOptionsSet) SetNtpServers(v []string) { + o.NtpServers = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *DhcpOptionsSet) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DhcpOptionsSet) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *DhcpOptionsSet) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *DhcpOptionsSet) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o DhcpOptionsSet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Default != nil { + toSerialize["Default"] = o.Default + } + if o.DhcpOptionsName != nil { + toSerialize["DhcpOptionsName"] = o.DhcpOptionsName + } + if o.DhcpOptionsSetId != nil { + toSerialize["DhcpOptionsSetId"] = o.DhcpOptionsSetId + } + if o.DomainName != nil { + toSerialize["DomainName"] = o.DomainName + } + if o.DomainNameServers != nil { + toSerialize["DomainNameServers"] = o.DomainNameServers + } + if o.NtpServers != nil { + toSerialize["NtpServers"] = o.NtpServers + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableDhcpOptionsSet struct { + value *DhcpOptionsSet + isSet bool +} + +func (v NullableDhcpOptionsSet) Get() *DhcpOptionsSet { + return v.value +} + +func (v *NullableDhcpOptionsSet) Set(val *DhcpOptionsSet) { + v.value = val + v.isSet = true +} + +func (v NullableDhcpOptionsSet) IsSet() bool { + return v.isSet +} + +func (v *NullableDhcpOptionsSet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDhcpOptionsSet(val *DhcpOptionsSet) *NullableDhcpOptionsSet { + return &NullableDhcpOptionsSet{value: val, isSet: true} +} + +func (v NullableDhcpOptionsSet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDhcpOptionsSet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go new file mode 100644 index 000000000..4aaeabe69 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DirectLink Information about the DirectLink. +type DirectLink struct { + // The account ID of the owner of the DirectLink. + AccountId *string `json:"AccountId,omitempty"` + // The physical link bandwidth (either 1 Gbps or 10 Gbps). + Bandwidth *string `json:"Bandwidth,omitempty"` + // The ID of the DirectLink (for example, dxcon-xxxxxxxx). + DirectLinkId *string `json:"DirectLinkId,omitempty"` + // The name of the DirectLink. + DirectLinkName *string `json:"DirectLinkName,omitempty"` + // The datacenter where the DirectLink is located. + Location *string `json:"Location,omitempty"` + // The Region in which the DirectLink has been created. + RegionName *string `json:"RegionName,omitempty"` + // The state of the DirectLink.
* `requested`: The DirectLink is requested but the request has not been validated yet.
* `pending`: The DirectLink request has been validated. It remains in the `pending` state until you establish the physical link.
* `available`: The physical link is established and the connection is ready to use.
* `deleting`: The deletion process is in progress.
* `deleted`: The DirectLink is deleted. + State *string `json:"State,omitempty"` +} + +// NewDirectLink instantiates a new DirectLink object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDirectLink() *DirectLink { + this := DirectLink{} + return &this +} + +// NewDirectLinkWithDefaults instantiates a new DirectLink object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDirectLinkWithDefaults() *DirectLink { + this := DirectLink{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *DirectLink) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *DirectLink) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *DirectLink) SetAccountId(v string) { + o.AccountId = &v +} + +// GetBandwidth returns the Bandwidth field value if set, zero value otherwise. +func (o *DirectLink) GetBandwidth() string { + if o == nil || o.Bandwidth == nil { + var ret string + return ret + } + return *o.Bandwidth +} + +// GetBandwidthOk returns a tuple with the Bandwidth field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetBandwidthOk() (*string, bool) { + if o == nil || o.Bandwidth == nil { + return nil, false + } + return o.Bandwidth, true +} + +// HasBandwidth returns a boolean if a field has been set. +func (o *DirectLink) HasBandwidth() bool { + if o != nil && o.Bandwidth != nil { + return true + } + + return false +} + +// SetBandwidth gets a reference to the given string and assigns it to the Bandwidth field. +func (o *DirectLink) SetBandwidth(v string) { + o.Bandwidth = &v +} + +// GetDirectLinkId returns the DirectLinkId field value if set, zero value otherwise. +func (o *DirectLink) GetDirectLinkId() string { + if o == nil || o.DirectLinkId == nil { + var ret string + return ret + } + return *o.DirectLinkId +} + +// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetDirectLinkIdOk() (*string, bool) { + if o == nil || o.DirectLinkId == nil { + return nil, false + } + return o.DirectLinkId, true +} + +// HasDirectLinkId returns a boolean if a field has been set. +func (o *DirectLink) HasDirectLinkId() bool { + if o != nil && o.DirectLinkId != nil { + return true + } + + return false +} + +// SetDirectLinkId gets a reference to the given string and assigns it to the DirectLinkId field. +func (o *DirectLink) SetDirectLinkId(v string) { + o.DirectLinkId = &v +} + +// GetDirectLinkName returns the DirectLinkName field value if set, zero value otherwise. +func (o *DirectLink) GetDirectLinkName() string { + if o == nil || o.DirectLinkName == nil { + var ret string + return ret + } + return *o.DirectLinkName +} + +// GetDirectLinkNameOk returns a tuple with the DirectLinkName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetDirectLinkNameOk() (*string, bool) { + if o == nil || o.DirectLinkName == nil { + return nil, false + } + return o.DirectLinkName, true +} + +// HasDirectLinkName returns a boolean if a field has been set. +func (o *DirectLink) HasDirectLinkName() bool { + if o != nil && o.DirectLinkName != nil { + return true + } + + return false +} + +// SetDirectLinkName gets a reference to the given string and assigns it to the DirectLinkName field. +func (o *DirectLink) SetDirectLinkName(v string) { + o.DirectLinkName = &v +} + +// GetLocation returns the Location field value if set, zero value otherwise. +func (o *DirectLink) GetLocation() string { + if o == nil || o.Location == nil { + var ret string + return ret + } + return *o.Location +} + +// GetLocationOk returns a tuple with the Location field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetLocationOk() (*string, bool) { + if o == nil || o.Location == nil { + return nil, false + } + return o.Location, true +} + +// HasLocation returns a boolean if a field has been set. +func (o *DirectLink) HasLocation() bool { + if o != nil && o.Location != nil { + return true + } + + return false +} + +// SetLocation gets a reference to the given string and assigns it to the Location field. +func (o *DirectLink) SetLocation(v string) { + o.Location = &v +} + +// GetRegionName returns the RegionName field value if set, zero value otherwise. +func (o *DirectLink) GetRegionName() string { + if o == nil || o.RegionName == nil { + var ret string + return ret + } + return *o.RegionName +} + +// GetRegionNameOk returns a tuple with the RegionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetRegionNameOk() (*string, bool) { + if o == nil || o.RegionName == nil { + return nil, false + } + return o.RegionName, true +} + +// HasRegionName returns a boolean if a field has been set. +func (o *DirectLink) HasRegionName() bool { + if o != nil && o.RegionName != nil { + return true + } + + return false +} + +// SetRegionName gets a reference to the given string and assigns it to the RegionName field. +func (o *DirectLink) SetRegionName(v string) { + o.RegionName = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *DirectLink) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLink) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *DirectLink) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *DirectLink) SetState(v string) { + o.State = &v +} + +func (o DirectLink) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Bandwidth != nil { + toSerialize["Bandwidth"] = o.Bandwidth + } + if o.DirectLinkId != nil { + toSerialize["DirectLinkId"] = o.DirectLinkId + } + if o.DirectLinkName != nil { + toSerialize["DirectLinkName"] = o.DirectLinkName + } + if o.Location != nil { + toSerialize["Location"] = o.Location + } + if o.RegionName != nil { + toSerialize["RegionName"] = o.RegionName + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableDirectLink struct { + value *DirectLink + isSet bool +} + +func (v NullableDirectLink) Get() *DirectLink { + return v.value +} + +func (v *NullableDirectLink) Set(val *DirectLink) { + v.value = val + v.isSet = true +} + +func (v NullableDirectLink) IsSet() bool { + return v.isSet +} + +func (v *NullableDirectLink) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDirectLink(val *DirectLink) *NullableDirectLink { + return &NullableDirectLink{value: val, isSet: true} +} + +func (v NullableDirectLink) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDirectLink) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go new file mode 100644 index 000000000..5b2c87815 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go @@ -0,0 +1,311 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DirectLinkInterface Information about the DirectLink interface. +type DirectLinkInterface struct { + // The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. + BgpAsn int32 `json:"BgpAsn"` + // The BGP authentication key. + BgpKey *string `json:"BgpKey,omitempty"` + // The IP address on the customer's side of the DirectLink interface. + ClientPrivateIp *string `json:"ClientPrivateIp,omitempty"` + // The name of the DirectLink interface. + DirectLinkInterfaceName string `json:"DirectLinkInterfaceName"` + // The IP address on 3DS OUTSCALE's side of the DirectLink interface. + OutscalePrivateIp *string `json:"OutscalePrivateIp,omitempty"` + // The ID of the target virtual gateway. + VirtualGatewayId string `json:"VirtualGatewayId"` + // The VLAN number associated with the DirectLink interface. + Vlan int32 `json:"Vlan"` +} + +// NewDirectLinkInterface instantiates a new DirectLinkInterface object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDirectLinkInterface(bgpAsn int32, directLinkInterfaceName string, virtualGatewayId string, vlan int32, ) *DirectLinkInterface { + this := DirectLinkInterface{} + this.BgpAsn = bgpAsn + this.DirectLinkInterfaceName = directLinkInterfaceName + this.VirtualGatewayId = virtualGatewayId + this.Vlan = vlan + return &this +} + +// NewDirectLinkInterfaceWithDefaults instantiates a new DirectLinkInterface object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDirectLinkInterfaceWithDefaults() *DirectLinkInterface { + this := DirectLinkInterface{} + return &this +} + +// GetBgpAsn returns the BgpAsn field value +func (o *DirectLinkInterface) GetBgpAsn() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.BgpAsn +} + +// GetBgpAsnOk returns a tuple with the BgpAsn field value +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetBgpAsnOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.BgpAsn, true +} + +// SetBgpAsn sets field value +func (o *DirectLinkInterface) SetBgpAsn(v int32) { + o.BgpAsn = v +} + +// GetBgpKey returns the BgpKey field value if set, zero value otherwise. +func (o *DirectLinkInterface) GetBgpKey() string { + if o == nil || o.BgpKey == nil { + var ret string + return ret + } + return *o.BgpKey +} + +// GetBgpKeyOk returns a tuple with the BgpKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetBgpKeyOk() (*string, bool) { + if o == nil || o.BgpKey == nil { + return nil, false + } + return o.BgpKey, true +} + +// HasBgpKey returns a boolean if a field has been set. +func (o *DirectLinkInterface) HasBgpKey() bool { + if o != nil && o.BgpKey != nil { + return true + } + + return false +} + +// SetBgpKey gets a reference to the given string and assigns it to the BgpKey field. +func (o *DirectLinkInterface) SetBgpKey(v string) { + o.BgpKey = &v +} + +// GetClientPrivateIp returns the ClientPrivateIp field value if set, zero value otherwise. +func (o *DirectLinkInterface) GetClientPrivateIp() string { + if o == nil || o.ClientPrivateIp == nil { + var ret string + return ret + } + return *o.ClientPrivateIp +} + +// GetClientPrivateIpOk returns a tuple with the ClientPrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetClientPrivateIpOk() (*string, bool) { + if o == nil || o.ClientPrivateIp == nil { + return nil, false + } + return o.ClientPrivateIp, true +} + +// HasClientPrivateIp returns a boolean if a field has been set. +func (o *DirectLinkInterface) HasClientPrivateIp() bool { + if o != nil && o.ClientPrivateIp != nil { + return true + } + + return false +} + +// SetClientPrivateIp gets a reference to the given string and assigns it to the ClientPrivateIp field. +func (o *DirectLinkInterface) SetClientPrivateIp(v string) { + o.ClientPrivateIp = &v +} + +// GetDirectLinkInterfaceName returns the DirectLinkInterfaceName field value +func (o *DirectLinkInterface) GetDirectLinkInterfaceName() string { + if o == nil { + var ret string + return ret + } + + return o.DirectLinkInterfaceName +} + +// GetDirectLinkInterfaceNameOk returns a tuple with the DirectLinkInterfaceName field value +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetDirectLinkInterfaceNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DirectLinkInterfaceName, true +} + +// SetDirectLinkInterfaceName sets field value +func (o *DirectLinkInterface) SetDirectLinkInterfaceName(v string) { + o.DirectLinkInterfaceName = v +} + +// GetOutscalePrivateIp returns the OutscalePrivateIp field value if set, zero value otherwise. +func (o *DirectLinkInterface) GetOutscalePrivateIp() string { + if o == nil || o.OutscalePrivateIp == nil { + var ret string + return ret + } + return *o.OutscalePrivateIp +} + +// GetOutscalePrivateIpOk returns a tuple with the OutscalePrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetOutscalePrivateIpOk() (*string, bool) { + if o == nil || o.OutscalePrivateIp == nil { + return nil, false + } + return o.OutscalePrivateIp, true +} + +// HasOutscalePrivateIp returns a boolean if a field has been set. +func (o *DirectLinkInterface) HasOutscalePrivateIp() bool { + if o != nil && o.OutscalePrivateIp != nil { + return true + } + + return false +} + +// SetOutscalePrivateIp gets a reference to the given string and assigns it to the OutscalePrivateIp field. +func (o *DirectLinkInterface) SetOutscalePrivateIp(v string) { + o.OutscalePrivateIp = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *DirectLinkInterface) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *DirectLinkInterface) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +// GetVlan returns the Vlan field value +func (o *DirectLinkInterface) GetVlan() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Vlan +} + +// GetVlanOk returns a tuple with the Vlan field value +// and a boolean to check if the value has been set. +func (o *DirectLinkInterface) GetVlanOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Vlan, true +} + +// SetVlan sets field value +func (o *DirectLinkInterface) SetVlan(v int32) { + o.Vlan = v +} + +func (o DirectLinkInterface) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["BgpAsn"] = o.BgpAsn + } + if o.BgpKey != nil { + toSerialize["BgpKey"] = o.BgpKey + } + if o.ClientPrivateIp != nil { + toSerialize["ClientPrivateIp"] = o.ClientPrivateIp + } + if true { + toSerialize["DirectLinkInterfaceName"] = o.DirectLinkInterfaceName + } + if o.OutscalePrivateIp != nil { + toSerialize["OutscalePrivateIp"] = o.OutscalePrivateIp + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + if true { + toSerialize["Vlan"] = o.Vlan + } + return json.Marshal(toSerialize) +} + +type NullableDirectLinkInterface struct { + value *DirectLinkInterface + isSet bool +} + +func (v NullableDirectLinkInterface) Get() *DirectLinkInterface { + return v.value +} + +func (v *NullableDirectLinkInterface) Set(val *DirectLinkInterface) { + v.value = val + v.isSet = true +} + +func (v NullableDirectLinkInterface) IsSet() bool { + return v.isSet +} + +func (v *NullableDirectLinkInterface) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDirectLinkInterface(val *DirectLinkInterface) *NullableDirectLinkInterface { + return &NullableDirectLinkInterface{value: val, isSet: true} +} + +func (v NullableDirectLinkInterface) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDirectLinkInterface) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go new file mode 100644 index 000000000..0ca4c33c6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go @@ -0,0 +1,561 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// DirectLinkInterfaces Information about the DirectLink interfaces. +type DirectLinkInterfaces struct { + // The account ID of the owner of the DirectLink interface. + AccountId *string `json:"AccountId,omitempty"` + // The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. + BgpAsn *int32 `json:"BgpAsn,omitempty"` + // The BGP authentication key. + BgpKey *string `json:"BgpKey,omitempty"` + // The IP address on the customer's side of the DirectLink interface. + ClientPrivateIp *string `json:"ClientPrivateIp,omitempty"` + // The ID of the DirectLink. + DirectLinkId *string `json:"DirectLinkId,omitempty"` + // The ID of the DirectLink interface. + DirectLinkInterfaceId *string `json:"DirectLinkInterfaceId,omitempty"` + // The name of the DirectLink interface. + DirectLinkInterfaceName *string `json:"DirectLinkInterfaceName,omitempty"` + // The type of the DirectLink interface (always `private`). + InterfaceType *string `json:"InterfaceType,omitempty"` + // The datacenter where the DirectLink interface is located. + Location *string `json:"Location,omitempty"` + // The IP address on 3DS OUTSCALE's side of the DirectLink interface. + OutscalePrivateIp *string `json:"OutscalePrivateIp,omitempty"` + // The state of the DirectLink interface (`pending` \\| `available` \\| `deleting` \\| `deleted` \\| `confirming` \\| `rejected` \\| `expired`). + State *string `json:"State,omitempty"` + // The ID of the target virtual gateway. + VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` + // The VLAN number associated with the DirectLink interface. + Vlan *int32 `json:"Vlan,omitempty"` +} + +// NewDirectLinkInterfaces instantiates a new DirectLinkInterfaces object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDirectLinkInterfaces() *DirectLinkInterfaces { + this := DirectLinkInterfaces{} + return &this +} + +// NewDirectLinkInterfacesWithDefaults instantiates a new DirectLinkInterfaces object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDirectLinkInterfacesWithDefaults() *DirectLinkInterfaces { + this := DirectLinkInterfaces{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *DirectLinkInterfaces) SetAccountId(v string) { + o.AccountId = &v +} + +// GetBgpAsn returns the BgpAsn field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetBgpAsn() int32 { + if o == nil || o.BgpAsn == nil { + var ret int32 + return ret + } + return *o.BgpAsn +} + +// GetBgpAsnOk returns a tuple with the BgpAsn field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetBgpAsnOk() (*int32, bool) { + if o == nil || o.BgpAsn == nil { + return nil, false + } + return o.BgpAsn, true +} + +// HasBgpAsn returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasBgpAsn() bool { + if o != nil && o.BgpAsn != nil { + return true + } + + return false +} + +// SetBgpAsn gets a reference to the given int32 and assigns it to the BgpAsn field. +func (o *DirectLinkInterfaces) SetBgpAsn(v int32) { + o.BgpAsn = &v +} + +// GetBgpKey returns the BgpKey field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetBgpKey() string { + if o == nil || o.BgpKey == nil { + var ret string + return ret + } + return *o.BgpKey +} + +// GetBgpKeyOk returns a tuple with the BgpKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetBgpKeyOk() (*string, bool) { + if o == nil || o.BgpKey == nil { + return nil, false + } + return o.BgpKey, true +} + +// HasBgpKey returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasBgpKey() bool { + if o != nil && o.BgpKey != nil { + return true + } + + return false +} + +// SetBgpKey gets a reference to the given string and assigns it to the BgpKey field. +func (o *DirectLinkInterfaces) SetBgpKey(v string) { + o.BgpKey = &v +} + +// GetClientPrivateIp returns the ClientPrivateIp field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetClientPrivateIp() string { + if o == nil || o.ClientPrivateIp == nil { + var ret string + return ret + } + return *o.ClientPrivateIp +} + +// GetClientPrivateIpOk returns a tuple with the ClientPrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetClientPrivateIpOk() (*string, bool) { + if o == nil || o.ClientPrivateIp == nil { + return nil, false + } + return o.ClientPrivateIp, true +} + +// HasClientPrivateIp returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasClientPrivateIp() bool { + if o != nil && o.ClientPrivateIp != nil { + return true + } + + return false +} + +// SetClientPrivateIp gets a reference to the given string and assigns it to the ClientPrivateIp field. +func (o *DirectLinkInterfaces) SetClientPrivateIp(v string) { + o.ClientPrivateIp = &v +} + +// GetDirectLinkId returns the DirectLinkId field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetDirectLinkId() string { + if o == nil || o.DirectLinkId == nil { + var ret string + return ret + } + return *o.DirectLinkId +} + +// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetDirectLinkIdOk() (*string, bool) { + if o == nil || o.DirectLinkId == nil { + return nil, false + } + return o.DirectLinkId, true +} + +// HasDirectLinkId returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasDirectLinkId() bool { + if o != nil && o.DirectLinkId != nil { + return true + } + + return false +} + +// SetDirectLinkId gets a reference to the given string and assigns it to the DirectLinkId field. +func (o *DirectLinkInterfaces) SetDirectLinkId(v string) { + o.DirectLinkId = &v +} + +// GetDirectLinkInterfaceId returns the DirectLinkInterfaceId field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetDirectLinkInterfaceId() string { + if o == nil || o.DirectLinkInterfaceId == nil { + var ret string + return ret + } + return *o.DirectLinkInterfaceId +} + +// GetDirectLinkInterfaceIdOk returns a tuple with the DirectLinkInterfaceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetDirectLinkInterfaceIdOk() (*string, bool) { + if o == nil || o.DirectLinkInterfaceId == nil { + return nil, false + } + return o.DirectLinkInterfaceId, true +} + +// HasDirectLinkInterfaceId returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasDirectLinkInterfaceId() bool { + if o != nil && o.DirectLinkInterfaceId != nil { + return true + } + + return false +} + +// SetDirectLinkInterfaceId gets a reference to the given string and assigns it to the DirectLinkInterfaceId field. +func (o *DirectLinkInterfaces) SetDirectLinkInterfaceId(v string) { + o.DirectLinkInterfaceId = &v +} + +// GetDirectLinkInterfaceName returns the DirectLinkInterfaceName field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetDirectLinkInterfaceName() string { + if o == nil || o.DirectLinkInterfaceName == nil { + var ret string + return ret + } + return *o.DirectLinkInterfaceName +} + +// GetDirectLinkInterfaceNameOk returns a tuple with the DirectLinkInterfaceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetDirectLinkInterfaceNameOk() (*string, bool) { + if o == nil || o.DirectLinkInterfaceName == nil { + return nil, false + } + return o.DirectLinkInterfaceName, true +} + +// HasDirectLinkInterfaceName returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasDirectLinkInterfaceName() bool { + if o != nil && o.DirectLinkInterfaceName != nil { + return true + } + + return false +} + +// SetDirectLinkInterfaceName gets a reference to the given string and assigns it to the DirectLinkInterfaceName field. +func (o *DirectLinkInterfaces) SetDirectLinkInterfaceName(v string) { + o.DirectLinkInterfaceName = &v +} + +// GetInterfaceType returns the InterfaceType field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetInterfaceType() string { + if o == nil || o.InterfaceType == nil { + var ret string + return ret + } + return *o.InterfaceType +} + +// GetInterfaceTypeOk returns a tuple with the InterfaceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetInterfaceTypeOk() (*string, bool) { + if o == nil || o.InterfaceType == nil { + return nil, false + } + return o.InterfaceType, true +} + +// HasInterfaceType returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasInterfaceType() bool { + if o != nil && o.InterfaceType != nil { + return true + } + + return false +} + +// SetInterfaceType gets a reference to the given string and assigns it to the InterfaceType field. +func (o *DirectLinkInterfaces) SetInterfaceType(v string) { + o.InterfaceType = &v +} + +// GetLocation returns the Location field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetLocation() string { + if o == nil || o.Location == nil { + var ret string + return ret + } + return *o.Location +} + +// GetLocationOk returns a tuple with the Location field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetLocationOk() (*string, bool) { + if o == nil || o.Location == nil { + return nil, false + } + return o.Location, true +} + +// HasLocation returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasLocation() bool { + if o != nil && o.Location != nil { + return true + } + + return false +} + +// SetLocation gets a reference to the given string and assigns it to the Location field. +func (o *DirectLinkInterfaces) SetLocation(v string) { + o.Location = &v +} + +// GetOutscalePrivateIp returns the OutscalePrivateIp field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetOutscalePrivateIp() string { + if o == nil || o.OutscalePrivateIp == nil { + var ret string + return ret + } + return *o.OutscalePrivateIp +} + +// GetOutscalePrivateIpOk returns a tuple with the OutscalePrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetOutscalePrivateIpOk() (*string, bool) { + if o == nil || o.OutscalePrivateIp == nil { + return nil, false + } + return o.OutscalePrivateIp, true +} + +// HasOutscalePrivateIp returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasOutscalePrivateIp() bool { + if o != nil && o.OutscalePrivateIp != nil { + return true + } + + return false +} + +// SetOutscalePrivateIp gets a reference to the given string and assigns it to the OutscalePrivateIp field. +func (o *DirectLinkInterfaces) SetOutscalePrivateIp(v string) { + o.OutscalePrivateIp = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *DirectLinkInterfaces) SetState(v string) { + o.State = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetVirtualGatewayId() string { + if o == nil || o.VirtualGatewayId == nil { + var ret string + return ret + } + return *o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil || o.VirtualGatewayId == nil { + return nil, false + } + return o.VirtualGatewayId, true +} + +// HasVirtualGatewayId returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasVirtualGatewayId() bool { + if o != nil && o.VirtualGatewayId != nil { + return true + } + + return false +} + +// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. +func (o *DirectLinkInterfaces) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = &v +} + +// GetVlan returns the Vlan field value if set, zero value otherwise. +func (o *DirectLinkInterfaces) GetVlan() int32 { + if o == nil || o.Vlan == nil { + var ret int32 + return ret + } + return *o.Vlan +} + +// GetVlanOk returns a tuple with the Vlan field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DirectLinkInterfaces) GetVlanOk() (*int32, bool) { + if o == nil || o.Vlan == nil { + return nil, false + } + return o.Vlan, true +} + +// HasVlan returns a boolean if a field has been set. +func (o *DirectLinkInterfaces) HasVlan() bool { + if o != nil && o.Vlan != nil { + return true + } + + return false +} + +// SetVlan gets a reference to the given int32 and assigns it to the Vlan field. +func (o *DirectLinkInterfaces) SetVlan(v int32) { + o.Vlan = &v +} + +func (o DirectLinkInterfaces) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.BgpAsn != nil { + toSerialize["BgpAsn"] = o.BgpAsn + } + if o.BgpKey != nil { + toSerialize["BgpKey"] = o.BgpKey + } + if o.ClientPrivateIp != nil { + toSerialize["ClientPrivateIp"] = o.ClientPrivateIp + } + if o.DirectLinkId != nil { + toSerialize["DirectLinkId"] = o.DirectLinkId + } + if o.DirectLinkInterfaceId != nil { + toSerialize["DirectLinkInterfaceId"] = o.DirectLinkInterfaceId + } + if o.DirectLinkInterfaceName != nil { + toSerialize["DirectLinkInterfaceName"] = o.DirectLinkInterfaceName + } + if o.InterfaceType != nil { + toSerialize["InterfaceType"] = o.InterfaceType + } + if o.Location != nil { + toSerialize["Location"] = o.Location + } + if o.OutscalePrivateIp != nil { + toSerialize["OutscalePrivateIp"] = o.OutscalePrivateIp + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.VirtualGatewayId != nil { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + if o.Vlan != nil { + toSerialize["Vlan"] = o.Vlan + } + return json.Marshal(toSerialize) +} + +type NullableDirectLinkInterfaces struct { + value *DirectLinkInterfaces + isSet bool +} + +func (v NullableDirectLinkInterfaces) Get() *DirectLinkInterfaces { + return v.value +} + +func (v *NullableDirectLinkInterfaces) Set(val *DirectLinkInterfaces) { + v.value = val + v.isSet = true +} + +func (v NullableDirectLinkInterfaces) IsSet() bool { + return v.isSet +} + +func (v *NullableDirectLinkInterfaces) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDirectLinkInterfaces(val *DirectLinkInterfaces) *NullableDirectLinkInterfaces { + return &NullableDirectLinkInterfaces{value: val, isSet: true} +} + +func (v NullableDirectLinkInterfaces) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDirectLinkInterfaces) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go new file mode 100644 index 000000000..3ee98d8b5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ErrorResponse struct for ErrorResponse +type ErrorResponse struct { + // One or more errors. + Errors *[]Errors `json:"Errors,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewErrorResponse instantiates a new ErrorResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewErrorResponse() *ErrorResponse { + this := ErrorResponse{} + return &this +} + +// NewErrorResponseWithDefaults instantiates a new ErrorResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewErrorResponseWithDefaults() *ErrorResponse { + this := ErrorResponse{} + return &this +} + +// GetErrors returns the Errors field value if set, zero value otherwise. +func (o *ErrorResponse) GetErrors() []Errors { + if o == nil || o.Errors == nil { + var ret []Errors + return ret + } + return *o.Errors +} + +// GetErrorsOk returns a tuple with the Errors field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ErrorResponse) GetErrorsOk() (*[]Errors, bool) { + if o == nil || o.Errors == nil { + return nil, false + } + return o.Errors, true +} + +// HasErrors returns a boolean if a field has been set. +func (o *ErrorResponse) HasErrors() bool { + if o != nil && o.Errors != nil { + return true + } + + return false +} + +// SetErrors gets a reference to the given []Errors and assigns it to the Errors field. +func (o *ErrorResponse) SetErrors(v []Errors) { + o.Errors = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ErrorResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ErrorResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ErrorResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ErrorResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ErrorResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Errors != nil { + toSerialize["Errors"] = o.Errors + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableErrorResponse struct { + value *ErrorResponse + isSet bool +} + +func (v NullableErrorResponse) Get() *ErrorResponse { + return v.value +} + +func (v *NullableErrorResponse) Set(val *ErrorResponse) { + v.value = val + v.isSet = true +} + +func (v NullableErrorResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableErrorResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableErrorResponse(val *ErrorResponse) *NullableErrorResponse { + return &NullableErrorResponse{value: val, isSet: true} +} + +func (v NullableErrorResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableErrorResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go new file mode 100644 index 000000000..31dde1053 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Errors Information about the errors. +type Errors struct { + // The code of the error. + Code *string `json:"Code,omitempty"` + // The details of the error. + Details *string `json:"Details,omitempty"` + // The type of the error. + Type *string `json:"Type,omitempty"` +} + +// NewErrors instantiates a new Errors object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewErrors() *Errors { + this := Errors{} + return &this +} + +// NewErrorsWithDefaults instantiates a new Errors object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewErrorsWithDefaults() *Errors { + this := Errors{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *Errors) GetCode() string { + if o == nil || o.Code == nil { + var ret string + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Errors) GetCodeOk() (*string, bool) { + if o == nil || o.Code == nil { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *Errors) HasCode() bool { + if o != nil && o.Code != nil { + return true + } + + return false +} + +// SetCode gets a reference to the given string and assigns it to the Code field. +func (o *Errors) SetCode(v string) { + o.Code = &v +} + +// GetDetails returns the Details field value if set, zero value otherwise. +func (o *Errors) GetDetails() string { + if o == nil || o.Details == nil { + var ret string + return ret + } + return *o.Details +} + +// GetDetailsOk returns a tuple with the Details field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Errors) GetDetailsOk() (*string, bool) { + if o == nil || o.Details == nil { + return nil, false + } + return o.Details, true +} + +// HasDetails returns a boolean if a field has been set. +func (o *Errors) HasDetails() bool { + if o != nil && o.Details != nil { + return true + } + + return false +} + +// SetDetails gets a reference to the given string and assigns it to the Details field. +func (o *Errors) SetDetails(v string) { + o.Details = &v +} + +// GetType returns the Type field value if set, zero value otherwise. +func (o *Errors) GetType() string { + if o == nil || o.Type == nil { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Errors) GetTypeOk() (*string, bool) { + if o == nil || o.Type == nil { + return nil, false + } + return o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *Errors) HasType() bool { + if o != nil && o.Type != nil { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *Errors) SetType(v string) { + o.Type = &v +} + +func (o Errors) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Code != nil { + toSerialize["Code"] = o.Code + } + if o.Details != nil { + toSerialize["Details"] = o.Details + } + if o.Type != nil { + toSerialize["Type"] = o.Type + } + return json.Marshal(toSerialize) +} + +type NullableErrors struct { + value *Errors + isSet bool +} + +func (v NullableErrors) Get() *Errors { + return v.value +} + +func (v *NullableErrors) Set(val *Errors) { + v.value = val + v.isSet = true +} + +func (v NullableErrors) IsSet() bool { + return v.isSet +} + +func (v *NullableErrors) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableErrors(val *Errors) *NullableErrors { + return &NullableErrors{value: val, isSet: true} +} + +func (v NullableErrors) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableErrors) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go new file mode 100644 index 000000000..13b08e328 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersAccessKeys One or more filters. +type FiltersAccessKeys struct { + // The IDs of the access keys. + AccessKeyIds *[]string `json:"AccessKeyIds,omitempty"` + // The states of the access keys (`ACTIVE` \\| `INACTIVE`). + States *[]string `json:"States,omitempty"` +} + +// NewFiltersAccessKeys instantiates a new FiltersAccessKeys object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersAccessKeys() *FiltersAccessKeys { + this := FiltersAccessKeys{} + return &this +} + +// NewFiltersAccessKeysWithDefaults instantiates a new FiltersAccessKeys object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersAccessKeysWithDefaults() *FiltersAccessKeys { + this := FiltersAccessKeys{} + return &this +} + +// GetAccessKeyIds returns the AccessKeyIds field value if set, zero value otherwise. +func (o *FiltersAccessKeys) GetAccessKeyIds() []string { + if o == nil || o.AccessKeyIds == nil { + var ret []string + return ret + } + return *o.AccessKeyIds +} + +// GetAccessKeyIdsOk returns a tuple with the AccessKeyIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersAccessKeys) GetAccessKeyIdsOk() (*[]string, bool) { + if o == nil || o.AccessKeyIds == nil { + return nil, false + } + return o.AccessKeyIds, true +} + +// HasAccessKeyIds returns a boolean if a field has been set. +func (o *FiltersAccessKeys) HasAccessKeyIds() bool { + if o != nil && o.AccessKeyIds != nil { + return true + } + + return false +} + +// SetAccessKeyIds gets a reference to the given []string and assigns it to the AccessKeyIds field. +func (o *FiltersAccessKeys) SetAccessKeyIds(v []string) { + o.AccessKeyIds = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersAccessKeys) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersAccessKeys) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersAccessKeys) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersAccessKeys) SetStates(v []string) { + o.States = &v +} + +func (o FiltersAccessKeys) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKeyIds != nil { + toSerialize["AccessKeyIds"] = o.AccessKeyIds + } + if o.States != nil { + toSerialize["States"] = o.States + } + return json.Marshal(toSerialize) +} + +type NullableFiltersAccessKeys struct { + value *FiltersAccessKeys + isSet bool +} + +func (v NullableFiltersAccessKeys) Get() *FiltersAccessKeys { + return v.value +} + +func (v *NullableFiltersAccessKeys) Set(val *FiltersAccessKeys) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersAccessKeys) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersAccessKeys) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersAccessKeys(val *FiltersAccessKeys) *NullableFiltersAccessKeys { + return &NullableFiltersAccessKeys{value: val, isSet: true} +} + +func (v NullableFiltersAccessKeys) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersAccessKeys) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go new file mode 100644 index 000000000..182b10bac --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go @@ -0,0 +1,413 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersApiLog One or more filters. +type FiltersApiLog struct { + // One or more API keys used for the query. + QueryAccessKeys *[]string `json:"QueryAccessKeys,omitempty"` + // The name of one or more API services used for the query. + QueryApiNames *[]string `json:"QueryApiNames,omitempty"` + // The name of one or more calls. + QueryCallNames *[]string `json:"QueryCallNames,omitempty"` + // The logs of the queries made after the date you specify, in ISO 8601 format (for example, `2017-06-14`). + QueryDateAfter *string `json:"QueryDateAfter,omitempty"` + // The logs of the queries made before the date you specify, in ISO 8601 format (for example, `2017-06-14`). + QueryDateBefore *string `json:"QueryDateBefore,omitempty"` + // One or more IP addresses used for the query. + QueryIpAddresses *[]string `json:"QueryIpAddresses,omitempty"` + // One or more user agents used for the HTTP request. + QueryUserAgents *[]string `json:"QueryUserAgents,omitempty"` + // One or more request IDs. + RequestIds *[]string `json:"RequestIds,omitempty"` + // One or more HTTP codes provided by the responses. + ResponseStatusCodes *[]int32 `json:"ResponseStatusCodes,omitempty"` +} + +// NewFiltersApiLog instantiates a new FiltersApiLog object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersApiLog() *FiltersApiLog { + this := FiltersApiLog{} + return &this +} + +// NewFiltersApiLogWithDefaults instantiates a new FiltersApiLog object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersApiLogWithDefaults() *FiltersApiLog { + this := FiltersApiLog{} + return &this +} + +// GetQueryAccessKeys returns the QueryAccessKeys field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryAccessKeys() []string { + if o == nil || o.QueryAccessKeys == nil { + var ret []string + return ret + } + return *o.QueryAccessKeys +} + +// GetQueryAccessKeysOk returns a tuple with the QueryAccessKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryAccessKeysOk() (*[]string, bool) { + if o == nil || o.QueryAccessKeys == nil { + return nil, false + } + return o.QueryAccessKeys, true +} + +// HasQueryAccessKeys returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryAccessKeys() bool { + if o != nil && o.QueryAccessKeys != nil { + return true + } + + return false +} + +// SetQueryAccessKeys gets a reference to the given []string and assigns it to the QueryAccessKeys field. +func (o *FiltersApiLog) SetQueryAccessKeys(v []string) { + o.QueryAccessKeys = &v +} + +// GetQueryApiNames returns the QueryApiNames field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryApiNames() []string { + if o == nil || o.QueryApiNames == nil { + var ret []string + return ret + } + return *o.QueryApiNames +} + +// GetQueryApiNamesOk returns a tuple with the QueryApiNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryApiNamesOk() (*[]string, bool) { + if o == nil || o.QueryApiNames == nil { + return nil, false + } + return o.QueryApiNames, true +} + +// HasQueryApiNames returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryApiNames() bool { + if o != nil && o.QueryApiNames != nil { + return true + } + + return false +} + +// SetQueryApiNames gets a reference to the given []string and assigns it to the QueryApiNames field. +func (o *FiltersApiLog) SetQueryApiNames(v []string) { + o.QueryApiNames = &v +} + +// GetQueryCallNames returns the QueryCallNames field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryCallNames() []string { + if o == nil || o.QueryCallNames == nil { + var ret []string + return ret + } + return *o.QueryCallNames +} + +// GetQueryCallNamesOk returns a tuple with the QueryCallNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryCallNamesOk() (*[]string, bool) { + if o == nil || o.QueryCallNames == nil { + return nil, false + } + return o.QueryCallNames, true +} + +// HasQueryCallNames returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryCallNames() bool { + if o != nil && o.QueryCallNames != nil { + return true + } + + return false +} + +// SetQueryCallNames gets a reference to the given []string and assigns it to the QueryCallNames field. +func (o *FiltersApiLog) SetQueryCallNames(v []string) { + o.QueryCallNames = &v +} + +// GetQueryDateAfter returns the QueryDateAfter field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryDateAfter() string { + if o == nil || o.QueryDateAfter == nil { + var ret string + return ret + } + return *o.QueryDateAfter +} + +// GetQueryDateAfterOk returns a tuple with the QueryDateAfter field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryDateAfterOk() (*string, bool) { + if o == nil || o.QueryDateAfter == nil { + return nil, false + } + return o.QueryDateAfter, true +} + +// HasQueryDateAfter returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryDateAfter() bool { + if o != nil && o.QueryDateAfter != nil { + return true + } + + return false +} + +// SetQueryDateAfter gets a reference to the given string and assigns it to the QueryDateAfter field. +func (o *FiltersApiLog) SetQueryDateAfter(v string) { + o.QueryDateAfter = &v +} + +// GetQueryDateBefore returns the QueryDateBefore field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryDateBefore() string { + if o == nil || o.QueryDateBefore == nil { + var ret string + return ret + } + return *o.QueryDateBefore +} + +// GetQueryDateBeforeOk returns a tuple with the QueryDateBefore field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryDateBeforeOk() (*string, bool) { + if o == nil || o.QueryDateBefore == nil { + return nil, false + } + return o.QueryDateBefore, true +} + +// HasQueryDateBefore returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryDateBefore() bool { + if o != nil && o.QueryDateBefore != nil { + return true + } + + return false +} + +// SetQueryDateBefore gets a reference to the given string and assigns it to the QueryDateBefore field. +func (o *FiltersApiLog) SetQueryDateBefore(v string) { + o.QueryDateBefore = &v +} + +// GetQueryIpAddresses returns the QueryIpAddresses field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryIpAddresses() []string { + if o == nil || o.QueryIpAddresses == nil { + var ret []string + return ret + } + return *o.QueryIpAddresses +} + +// GetQueryIpAddressesOk returns a tuple with the QueryIpAddresses field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryIpAddressesOk() (*[]string, bool) { + if o == nil || o.QueryIpAddresses == nil { + return nil, false + } + return o.QueryIpAddresses, true +} + +// HasQueryIpAddresses returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryIpAddresses() bool { + if o != nil && o.QueryIpAddresses != nil { + return true + } + + return false +} + +// SetQueryIpAddresses gets a reference to the given []string and assigns it to the QueryIpAddresses field. +func (o *FiltersApiLog) SetQueryIpAddresses(v []string) { + o.QueryIpAddresses = &v +} + +// GetQueryUserAgents returns the QueryUserAgents field value if set, zero value otherwise. +func (o *FiltersApiLog) GetQueryUserAgents() []string { + if o == nil || o.QueryUserAgents == nil { + var ret []string + return ret + } + return *o.QueryUserAgents +} + +// GetQueryUserAgentsOk returns a tuple with the QueryUserAgents field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetQueryUserAgentsOk() (*[]string, bool) { + if o == nil || o.QueryUserAgents == nil { + return nil, false + } + return o.QueryUserAgents, true +} + +// HasQueryUserAgents returns a boolean if a field has been set. +func (o *FiltersApiLog) HasQueryUserAgents() bool { + if o != nil && o.QueryUserAgents != nil { + return true + } + + return false +} + +// SetQueryUserAgents gets a reference to the given []string and assigns it to the QueryUserAgents field. +func (o *FiltersApiLog) SetQueryUserAgents(v []string) { + o.QueryUserAgents = &v +} + +// GetRequestIds returns the RequestIds field value if set, zero value otherwise. +func (o *FiltersApiLog) GetRequestIds() []string { + if o == nil || o.RequestIds == nil { + var ret []string + return ret + } + return *o.RequestIds +} + +// GetRequestIdsOk returns a tuple with the RequestIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetRequestIdsOk() (*[]string, bool) { + if o == nil || o.RequestIds == nil { + return nil, false + } + return o.RequestIds, true +} + +// HasRequestIds returns a boolean if a field has been set. +func (o *FiltersApiLog) HasRequestIds() bool { + if o != nil && o.RequestIds != nil { + return true + } + + return false +} + +// SetRequestIds gets a reference to the given []string and assigns it to the RequestIds field. +func (o *FiltersApiLog) SetRequestIds(v []string) { + o.RequestIds = &v +} + +// GetResponseStatusCodes returns the ResponseStatusCodes field value if set, zero value otherwise. +func (o *FiltersApiLog) GetResponseStatusCodes() []int32 { + if o == nil || o.ResponseStatusCodes == nil { + var ret []int32 + return ret + } + return *o.ResponseStatusCodes +} + +// GetResponseStatusCodesOk returns a tuple with the ResponseStatusCodes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersApiLog) GetResponseStatusCodesOk() (*[]int32, bool) { + if o == nil || o.ResponseStatusCodes == nil { + return nil, false + } + return o.ResponseStatusCodes, true +} + +// HasResponseStatusCodes returns a boolean if a field has been set. +func (o *FiltersApiLog) HasResponseStatusCodes() bool { + if o != nil && o.ResponseStatusCodes != nil { + return true + } + + return false +} + +// SetResponseStatusCodes gets a reference to the given []int32 and assigns it to the ResponseStatusCodes field. +func (o *FiltersApiLog) SetResponseStatusCodes(v []int32) { + o.ResponseStatusCodes = &v +} + +func (o FiltersApiLog) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.QueryAccessKeys != nil { + toSerialize["QueryAccessKeys"] = o.QueryAccessKeys + } + if o.QueryApiNames != nil { + toSerialize["QueryApiNames"] = o.QueryApiNames + } + if o.QueryCallNames != nil { + toSerialize["QueryCallNames"] = o.QueryCallNames + } + if o.QueryDateAfter != nil { + toSerialize["QueryDateAfter"] = o.QueryDateAfter + } + if o.QueryDateBefore != nil { + toSerialize["QueryDateBefore"] = o.QueryDateBefore + } + if o.QueryIpAddresses != nil { + toSerialize["QueryIpAddresses"] = o.QueryIpAddresses + } + if o.QueryUserAgents != nil { + toSerialize["QueryUserAgents"] = o.QueryUserAgents + } + if o.RequestIds != nil { + toSerialize["RequestIds"] = o.RequestIds + } + if o.ResponseStatusCodes != nil { + toSerialize["ResponseStatusCodes"] = o.ResponseStatusCodes + } + return json.Marshal(toSerialize) +} + +type NullableFiltersApiLog struct { + value *FiltersApiLog + isSet bool +} + +func (v NullableFiltersApiLog) Get() *FiltersApiLog { + return v.value +} + +func (v *NullableFiltersApiLog) Set(val *FiltersApiLog) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersApiLog) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersApiLog) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersApiLog(val *FiltersApiLog) *NullableFiltersApiLog { + return &NullableFiltersApiLog{value: val, isSet: true} +} + +func (v NullableFiltersApiLog) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersApiLog) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go new file mode 100644 index 000000000..2dbd1bb33 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersClientGateway One or more filters. +type FiltersClientGateway struct { + // The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. + BgpAsns *[]int32 `json:"BgpAsns,omitempty"` + // The IDs of the client gateways. + ClientGatewayIds *[]string `json:"ClientGatewayIds,omitempty"` + // The types of communication tunnels used by the client gateways (only `ipsec.1` is supported). + ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` + // The public IPv4 addresses of the client gateways. + PublicIps *[]string `json:"PublicIps,omitempty"` + // The states of the client gateways (`pending` \\| `available` \\| `deleting` \\| `deleted`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the client gateways. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the client gateways. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the client gateways, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersClientGateway instantiates a new FiltersClientGateway object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersClientGateway() *FiltersClientGateway { + this := FiltersClientGateway{} + return &this +} + +// NewFiltersClientGatewayWithDefaults instantiates a new FiltersClientGateway object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersClientGatewayWithDefaults() *FiltersClientGateway { + this := FiltersClientGateway{} + return &this +} + +// GetBgpAsns returns the BgpAsns field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetBgpAsns() []int32 { + if o == nil || o.BgpAsns == nil { + var ret []int32 + return ret + } + return *o.BgpAsns +} + +// GetBgpAsnsOk returns a tuple with the BgpAsns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetBgpAsnsOk() (*[]int32, bool) { + if o == nil || o.BgpAsns == nil { + return nil, false + } + return o.BgpAsns, true +} + +// HasBgpAsns returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasBgpAsns() bool { + if o != nil && o.BgpAsns != nil { + return true + } + + return false +} + +// SetBgpAsns gets a reference to the given []int32 and assigns it to the BgpAsns field. +func (o *FiltersClientGateway) SetBgpAsns(v []int32) { + o.BgpAsns = &v +} + +// GetClientGatewayIds returns the ClientGatewayIds field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetClientGatewayIds() []string { + if o == nil || o.ClientGatewayIds == nil { + var ret []string + return ret + } + return *o.ClientGatewayIds +} + +// GetClientGatewayIdsOk returns a tuple with the ClientGatewayIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetClientGatewayIdsOk() (*[]string, bool) { + if o == nil || o.ClientGatewayIds == nil { + return nil, false + } + return o.ClientGatewayIds, true +} + +// HasClientGatewayIds returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasClientGatewayIds() bool { + if o != nil && o.ClientGatewayIds != nil { + return true + } + + return false +} + +// SetClientGatewayIds gets a reference to the given []string and assigns it to the ClientGatewayIds field. +func (o *FiltersClientGateway) SetClientGatewayIds(v []string) { + o.ClientGatewayIds = &v +} + +// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetConnectionTypes() []string { + if o == nil || o.ConnectionTypes == nil { + var ret []string + return ret + } + return *o.ConnectionTypes +} + +// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetConnectionTypesOk() (*[]string, bool) { + if o == nil || o.ConnectionTypes == nil { + return nil, false + } + return o.ConnectionTypes, true +} + +// HasConnectionTypes returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasConnectionTypes() bool { + if o != nil && o.ConnectionTypes != nil { + return true + } + + return false +} + +// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. +func (o *FiltersClientGateway) SetConnectionTypes(v []string) { + o.ConnectionTypes = &v +} + +// GetPublicIps returns the PublicIps field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetPublicIps() []string { + if o == nil || o.PublicIps == nil { + var ret []string + return ret + } + return *o.PublicIps +} + +// GetPublicIpsOk returns a tuple with the PublicIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetPublicIpsOk() (*[]string, bool) { + if o == nil || o.PublicIps == nil { + return nil, false + } + return o.PublicIps, true +} + +// HasPublicIps returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasPublicIps() bool { + if o != nil && o.PublicIps != nil { + return true + } + + return false +} + +// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. +func (o *FiltersClientGateway) SetPublicIps(v []string) { + o.PublicIps = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersClientGateway) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersClientGateway) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersClientGateway) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersClientGateway) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersClientGateway) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersClientGateway) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersClientGateway) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersClientGateway) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BgpAsns != nil { + toSerialize["BgpAsns"] = o.BgpAsns + } + if o.ClientGatewayIds != nil { + toSerialize["ClientGatewayIds"] = o.ClientGatewayIds + } + if o.ConnectionTypes != nil { + toSerialize["ConnectionTypes"] = o.ConnectionTypes + } + if o.PublicIps != nil { + toSerialize["PublicIps"] = o.PublicIps + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersClientGateway struct { + value *FiltersClientGateway + isSet bool +} + +func (v NullableFiltersClientGateway) Get() *FiltersClientGateway { + return v.value +} + +func (v *NullableFiltersClientGateway) Set(val *FiltersClientGateway) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersClientGateway) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersClientGateway) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersClientGateway(val *FiltersClientGateway) *NullableFiltersClientGateway { + return &NullableFiltersClientGateway{value: val, isSet: true} +} + +func (v NullableFiltersClientGateway) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersClientGateway) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go new file mode 100644 index 000000000..9465740d9 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersDhcpOptions One or more filters. +type FiltersDhcpOptions struct { + // If `true`, lists all default DHCP options set. If `false`, lists all non-default DHCP options set. + Default *bool `json:"Default,omitempty"` + // The IDs of the DHCP options sets. + DhcpOptionsSetIds *[]string `json:"DhcpOptionsSetIds,omitempty"` + // The domain name servers used for the DHCP options sets. + DomainNameServers *[]string `json:"DomainNameServers,omitempty"` + // The domain names used for the DHCP options sets. + DomainNames *[]string `json:"DomainNames,omitempty"` + // The Network Time Protocol (NTP) servers used for the DHCP options sets. + NtpServers *[]string `json:"NtpServers,omitempty"` + // The keys of the tags associated with the DHCP options sets. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the DHCP options sets. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the DHCP options sets, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersDhcpOptions instantiates a new FiltersDhcpOptions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersDhcpOptions() *FiltersDhcpOptions { + this := FiltersDhcpOptions{} + return &this +} + +// NewFiltersDhcpOptionsWithDefaults instantiates a new FiltersDhcpOptions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersDhcpOptionsWithDefaults() *FiltersDhcpOptions { + this := FiltersDhcpOptions{} + return &this +} + +// GetDefault returns the Default field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetDefault() bool { + if o == nil || o.Default == nil { + var ret bool + return ret + } + return *o.Default +} + +// GetDefaultOk returns a tuple with the Default field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetDefaultOk() (*bool, bool) { + if o == nil || o.Default == nil { + return nil, false + } + return o.Default, true +} + +// HasDefault returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasDefault() bool { + if o != nil && o.Default != nil { + return true + } + + return false +} + +// SetDefault gets a reference to the given bool and assigns it to the Default field. +func (o *FiltersDhcpOptions) SetDefault(v bool) { + o.Default = &v +} + +// GetDhcpOptionsSetIds returns the DhcpOptionsSetIds field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetDhcpOptionsSetIds() []string { + if o == nil || o.DhcpOptionsSetIds == nil { + var ret []string + return ret + } + return *o.DhcpOptionsSetIds +} + +// GetDhcpOptionsSetIdsOk returns a tuple with the DhcpOptionsSetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetDhcpOptionsSetIdsOk() (*[]string, bool) { + if o == nil || o.DhcpOptionsSetIds == nil { + return nil, false + } + return o.DhcpOptionsSetIds, true +} + +// HasDhcpOptionsSetIds returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasDhcpOptionsSetIds() bool { + if o != nil && o.DhcpOptionsSetIds != nil { + return true + } + + return false +} + +// SetDhcpOptionsSetIds gets a reference to the given []string and assigns it to the DhcpOptionsSetIds field. +func (o *FiltersDhcpOptions) SetDhcpOptionsSetIds(v []string) { + o.DhcpOptionsSetIds = &v +} + +// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetDomainNameServers() []string { + if o == nil || o.DomainNameServers == nil { + var ret []string + return ret + } + return *o.DomainNameServers +} + +// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetDomainNameServersOk() (*[]string, bool) { + if o == nil || o.DomainNameServers == nil { + return nil, false + } + return o.DomainNameServers, true +} + +// HasDomainNameServers returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasDomainNameServers() bool { + if o != nil && o.DomainNameServers != nil { + return true + } + + return false +} + +// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. +func (o *FiltersDhcpOptions) SetDomainNameServers(v []string) { + o.DomainNameServers = &v +} + +// GetDomainNames returns the DomainNames field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetDomainNames() []string { + if o == nil || o.DomainNames == nil { + var ret []string + return ret + } + return *o.DomainNames +} + +// GetDomainNamesOk returns a tuple with the DomainNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetDomainNamesOk() (*[]string, bool) { + if o == nil || o.DomainNames == nil { + return nil, false + } + return o.DomainNames, true +} + +// HasDomainNames returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasDomainNames() bool { + if o != nil && o.DomainNames != nil { + return true + } + + return false +} + +// SetDomainNames gets a reference to the given []string and assigns it to the DomainNames field. +func (o *FiltersDhcpOptions) SetDomainNames(v []string) { + o.DomainNames = &v +} + +// GetNtpServers returns the NtpServers field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetNtpServers() []string { + if o == nil || o.NtpServers == nil { + var ret []string + return ret + } + return *o.NtpServers +} + +// GetNtpServersOk returns a tuple with the NtpServers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetNtpServersOk() (*[]string, bool) { + if o == nil || o.NtpServers == nil { + return nil, false + } + return o.NtpServers, true +} + +// HasNtpServers returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasNtpServers() bool { + if o != nil && o.NtpServers != nil { + return true + } + + return false +} + +// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. +func (o *FiltersDhcpOptions) SetNtpServers(v []string) { + o.NtpServers = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersDhcpOptions) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersDhcpOptions) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersDhcpOptions) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDhcpOptions) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersDhcpOptions) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersDhcpOptions) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersDhcpOptions) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Default != nil { + toSerialize["Default"] = o.Default + } + if o.DhcpOptionsSetIds != nil { + toSerialize["DhcpOptionsSetIds"] = o.DhcpOptionsSetIds + } + if o.DomainNameServers != nil { + toSerialize["DomainNameServers"] = o.DomainNameServers + } + if o.DomainNames != nil { + toSerialize["DomainNames"] = o.DomainNames + } + if o.NtpServers != nil { + toSerialize["NtpServers"] = o.NtpServers + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersDhcpOptions struct { + value *FiltersDhcpOptions + isSet bool +} + +func (v NullableFiltersDhcpOptions) Get() *FiltersDhcpOptions { + return v.value +} + +func (v *NullableFiltersDhcpOptions) Set(val *FiltersDhcpOptions) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersDhcpOptions) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersDhcpOptions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersDhcpOptions(val *FiltersDhcpOptions) *NullableFiltersDhcpOptions { + return &NullableFiltersDhcpOptions{value: val, isSet: true} +} + +func (v NullableFiltersDhcpOptions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersDhcpOptions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go new file mode 100644 index 000000000..7cec0b1b7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersDirectLink One or more filters. +type FiltersDirectLink struct { + // The IDs of the DirectLinks. + DirectLinkIds *[]string `json:"DirectLinkIds,omitempty"` +} + +// NewFiltersDirectLink instantiates a new FiltersDirectLink object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersDirectLink() *FiltersDirectLink { + this := FiltersDirectLink{} + return &this +} + +// NewFiltersDirectLinkWithDefaults instantiates a new FiltersDirectLink object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersDirectLinkWithDefaults() *FiltersDirectLink { + this := FiltersDirectLink{} + return &this +} + +// GetDirectLinkIds returns the DirectLinkIds field value if set, zero value otherwise. +func (o *FiltersDirectLink) GetDirectLinkIds() []string { + if o == nil || o.DirectLinkIds == nil { + var ret []string + return ret + } + return *o.DirectLinkIds +} + +// GetDirectLinkIdsOk returns a tuple with the DirectLinkIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDirectLink) GetDirectLinkIdsOk() (*[]string, bool) { + if o == nil || o.DirectLinkIds == nil { + return nil, false + } + return o.DirectLinkIds, true +} + +// HasDirectLinkIds returns a boolean if a field has been set. +func (o *FiltersDirectLink) HasDirectLinkIds() bool { + if o != nil && o.DirectLinkIds != nil { + return true + } + + return false +} + +// SetDirectLinkIds gets a reference to the given []string and assigns it to the DirectLinkIds field. +func (o *FiltersDirectLink) SetDirectLinkIds(v []string) { + o.DirectLinkIds = &v +} + +func (o FiltersDirectLink) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLinkIds != nil { + toSerialize["DirectLinkIds"] = o.DirectLinkIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersDirectLink struct { + value *FiltersDirectLink + isSet bool +} + +func (v NullableFiltersDirectLink) Get() *FiltersDirectLink { + return v.value +} + +func (v *NullableFiltersDirectLink) Set(val *FiltersDirectLink) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersDirectLink) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersDirectLink) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersDirectLink(val *FiltersDirectLink) *NullableFiltersDirectLink { + return &NullableFiltersDirectLink{value: val, isSet: true} +} + +func (v NullableFiltersDirectLink) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersDirectLink) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go new file mode 100644 index 000000000..b1dfe1bdd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersDirectLinkInterface One or more filters. +type FiltersDirectLinkInterface struct { + // The IDs of the DirectLinks. + DirectLinkIds *[]string `json:"DirectLinkIds,omitempty"` + // The IDs of the DirectLink interfaces. + DirectLinkInterfaceIds *[]string `json:"DirectLinkInterfaceIds,omitempty"` +} + +// NewFiltersDirectLinkInterface instantiates a new FiltersDirectLinkInterface object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersDirectLinkInterface() *FiltersDirectLinkInterface { + this := FiltersDirectLinkInterface{} + return &this +} + +// NewFiltersDirectLinkInterfaceWithDefaults instantiates a new FiltersDirectLinkInterface object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersDirectLinkInterfaceWithDefaults() *FiltersDirectLinkInterface { + this := FiltersDirectLinkInterface{} + return &this +} + +// GetDirectLinkIds returns the DirectLinkIds field value if set, zero value otherwise. +func (o *FiltersDirectLinkInterface) GetDirectLinkIds() []string { + if o == nil || o.DirectLinkIds == nil { + var ret []string + return ret + } + return *o.DirectLinkIds +} + +// GetDirectLinkIdsOk returns a tuple with the DirectLinkIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDirectLinkInterface) GetDirectLinkIdsOk() (*[]string, bool) { + if o == nil || o.DirectLinkIds == nil { + return nil, false + } + return o.DirectLinkIds, true +} + +// HasDirectLinkIds returns a boolean if a field has been set. +func (o *FiltersDirectLinkInterface) HasDirectLinkIds() bool { + if o != nil && o.DirectLinkIds != nil { + return true + } + + return false +} + +// SetDirectLinkIds gets a reference to the given []string and assigns it to the DirectLinkIds field. +func (o *FiltersDirectLinkInterface) SetDirectLinkIds(v []string) { + o.DirectLinkIds = &v +} + +// GetDirectLinkInterfaceIds returns the DirectLinkInterfaceIds field value if set, zero value otherwise. +func (o *FiltersDirectLinkInterface) GetDirectLinkInterfaceIds() []string { + if o == nil || o.DirectLinkInterfaceIds == nil { + var ret []string + return ret + } + return *o.DirectLinkInterfaceIds +} + +// GetDirectLinkInterfaceIdsOk returns a tuple with the DirectLinkInterfaceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersDirectLinkInterface) GetDirectLinkInterfaceIdsOk() (*[]string, bool) { + if o == nil || o.DirectLinkInterfaceIds == nil { + return nil, false + } + return o.DirectLinkInterfaceIds, true +} + +// HasDirectLinkInterfaceIds returns a boolean if a field has been set. +func (o *FiltersDirectLinkInterface) HasDirectLinkInterfaceIds() bool { + if o != nil && o.DirectLinkInterfaceIds != nil { + return true + } + + return false +} + +// SetDirectLinkInterfaceIds gets a reference to the given []string and assigns it to the DirectLinkInterfaceIds field. +func (o *FiltersDirectLinkInterface) SetDirectLinkInterfaceIds(v []string) { + o.DirectLinkInterfaceIds = &v +} + +func (o FiltersDirectLinkInterface) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLinkIds != nil { + toSerialize["DirectLinkIds"] = o.DirectLinkIds + } + if o.DirectLinkInterfaceIds != nil { + toSerialize["DirectLinkInterfaceIds"] = o.DirectLinkInterfaceIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersDirectLinkInterface struct { + value *FiltersDirectLinkInterface + isSet bool +} + +func (v NullableFiltersDirectLinkInterface) Get() *FiltersDirectLinkInterface { + return v.value +} + +func (v *NullableFiltersDirectLinkInterface) Set(val *FiltersDirectLinkInterface) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersDirectLinkInterface) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersDirectLinkInterface) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersDirectLinkInterface(val *FiltersDirectLinkInterface) *NullableFiltersDirectLinkInterface { + return &NullableFiltersDirectLinkInterface{value: val, isSet: true} +} + +func (v NullableFiltersDirectLinkInterface) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersDirectLinkInterface) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go new file mode 100644 index 000000000..41968323f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersExportTask One or more filters. +type FiltersExportTask struct { + // The IDs of the export tasks. + TaskIds *[]string `json:"TaskIds,omitempty"` +} + +// NewFiltersExportTask instantiates a new FiltersExportTask object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersExportTask() *FiltersExportTask { + this := FiltersExportTask{} + return &this +} + +// NewFiltersExportTaskWithDefaults instantiates a new FiltersExportTask object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersExportTaskWithDefaults() *FiltersExportTask { + this := FiltersExportTask{} + return &this +} + +// GetTaskIds returns the TaskIds field value if set, zero value otherwise. +func (o *FiltersExportTask) GetTaskIds() []string { + if o == nil || o.TaskIds == nil { + var ret []string + return ret + } + return *o.TaskIds +} + +// GetTaskIdsOk returns a tuple with the TaskIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersExportTask) GetTaskIdsOk() (*[]string, bool) { + if o == nil || o.TaskIds == nil { + return nil, false + } + return o.TaskIds, true +} + +// HasTaskIds returns a boolean if a field has been set. +func (o *FiltersExportTask) HasTaskIds() bool { + if o != nil && o.TaskIds != nil { + return true + } + + return false +} + +// SetTaskIds gets a reference to the given []string and assigns it to the TaskIds field. +func (o *FiltersExportTask) SetTaskIds(v []string) { + o.TaskIds = &v +} + +func (o FiltersExportTask) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.TaskIds != nil { + toSerialize["TaskIds"] = o.TaskIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersExportTask struct { + value *FiltersExportTask + isSet bool +} + +func (v NullableFiltersExportTask) Get() *FiltersExportTask { + return v.value +} + +func (v *NullableFiltersExportTask) Set(val *FiltersExportTask) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersExportTask) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersExportTask) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersExportTask(val *FiltersExportTask) *NullableFiltersExportTask { + return &NullableFiltersExportTask{value: val, isSet: true} +} + +func (v NullableFiltersExportTask) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersExportTask) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go new file mode 100644 index 000000000..a8789a0f1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersFlexibleGpu One or more filters. +type FiltersFlexibleGpu struct { + // Indicates whether the fGPU is deleted when terminating the VM. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // One or more IDs of fGPUs. + FlexibleGpuIds *[]string `json:"FlexibleGpuIds,omitempty"` + // The processor generations that the fGPUs are compatible with. + Generations *[]string `json:"Generations,omitempty"` + // One or more models of fGPUs. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). + ModelNames *[]string `json:"ModelNames,omitempty"` + // The states of the fGPUs (`allocated` \\| `attaching` \\| `attached` \\| `detaching`). + States *[]string `json:"States,omitempty"` + // The Subregions where the fGPUs are located. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // One or more IDs of VMs. + VmIds *[]string `json:"VmIds,omitempty"` +} + +// NewFiltersFlexibleGpu instantiates a new FiltersFlexibleGpu object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersFlexibleGpu() *FiltersFlexibleGpu { + this := FiltersFlexibleGpu{} + return &this +} + +// NewFiltersFlexibleGpuWithDefaults instantiates a new FiltersFlexibleGpu object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersFlexibleGpuWithDefaults() *FiltersFlexibleGpu { + this := FiltersFlexibleGpu{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *FiltersFlexibleGpu) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetFlexibleGpuIds returns the FlexibleGpuIds field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetFlexibleGpuIds() []string { + if o == nil || o.FlexibleGpuIds == nil { + var ret []string + return ret + } + return *o.FlexibleGpuIds +} + +// GetFlexibleGpuIdsOk returns a tuple with the FlexibleGpuIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetFlexibleGpuIdsOk() (*[]string, bool) { + if o == nil || o.FlexibleGpuIds == nil { + return nil, false + } + return o.FlexibleGpuIds, true +} + +// HasFlexibleGpuIds returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasFlexibleGpuIds() bool { + if o != nil && o.FlexibleGpuIds != nil { + return true + } + + return false +} + +// SetFlexibleGpuIds gets a reference to the given []string and assigns it to the FlexibleGpuIds field. +func (o *FiltersFlexibleGpu) SetFlexibleGpuIds(v []string) { + o.FlexibleGpuIds = &v +} + +// GetGenerations returns the Generations field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetGenerations() []string { + if o == nil || o.Generations == nil { + var ret []string + return ret + } + return *o.Generations +} + +// GetGenerationsOk returns a tuple with the Generations field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetGenerationsOk() (*[]string, bool) { + if o == nil || o.Generations == nil { + return nil, false + } + return o.Generations, true +} + +// HasGenerations returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasGenerations() bool { + if o != nil && o.Generations != nil { + return true + } + + return false +} + +// SetGenerations gets a reference to the given []string and assigns it to the Generations field. +func (o *FiltersFlexibleGpu) SetGenerations(v []string) { + o.Generations = &v +} + +// GetModelNames returns the ModelNames field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetModelNames() []string { + if o == nil || o.ModelNames == nil { + var ret []string + return ret + } + return *o.ModelNames +} + +// GetModelNamesOk returns a tuple with the ModelNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetModelNamesOk() (*[]string, bool) { + if o == nil || o.ModelNames == nil { + return nil, false + } + return o.ModelNames, true +} + +// HasModelNames returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasModelNames() bool { + if o != nil && o.ModelNames != nil { + return true + } + + return false +} + +// SetModelNames gets a reference to the given []string and assigns it to the ModelNames field. +func (o *FiltersFlexibleGpu) SetModelNames(v []string) { + o.ModelNames = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersFlexibleGpu) SetStates(v []string) { + o.States = &v +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *FiltersFlexibleGpu) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetVmIds returns the VmIds field value if set, zero value otherwise. +func (o *FiltersFlexibleGpu) GetVmIds() []string { + if o == nil || o.VmIds == nil { + var ret []string + return ret + } + return *o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersFlexibleGpu) GetVmIdsOk() (*[]string, bool) { + if o == nil || o.VmIds == nil { + return nil, false + } + return o.VmIds, true +} + +// HasVmIds returns a boolean if a field has been set. +func (o *FiltersFlexibleGpu) HasVmIds() bool { + if o != nil && o.VmIds != nil { + return true + } + + return false +} + +// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. +func (o *FiltersFlexibleGpu) SetVmIds(v []string) { + o.VmIds = &v +} + +func (o FiltersFlexibleGpu) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.FlexibleGpuIds != nil { + toSerialize["FlexibleGpuIds"] = o.FlexibleGpuIds + } + if o.Generations != nil { + toSerialize["Generations"] = o.Generations + } + if o.ModelNames != nil { + toSerialize["ModelNames"] = o.ModelNames + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.VmIds != nil { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersFlexibleGpu struct { + value *FiltersFlexibleGpu + isSet bool +} + +func (v NullableFiltersFlexibleGpu) Get() *FiltersFlexibleGpu { + return v.value +} + +func (v *NullableFiltersFlexibleGpu) Set(val *FiltersFlexibleGpu) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersFlexibleGpu) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersFlexibleGpu) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersFlexibleGpu(val *FiltersFlexibleGpu) *NullableFiltersFlexibleGpu { + return &NullableFiltersFlexibleGpu{value: val, isSet: true} +} + +func (v NullableFiltersFlexibleGpu) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersFlexibleGpu) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go new file mode 100644 index 000000000..220b83596 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go @@ -0,0 +1,857 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersImage One or more filters. +type FiltersImage struct { + // The account aliases of the owners of the OMIs. + AccountAliases *[]string `json:"AccountAliases,omitempty"` + // The account IDs of the owners of the OMIs. By default, all the OMIs for which you have launch permissions are described. + AccountIds *[]string `json:"AccountIds,omitempty"` + // The architectures of the OMIs (`i386` \\| `x86_64`). + Architectures *[]string `json:"Architectures,omitempty"` + // Indicates whether the block device mapping is deleted when terminating the VM. + BlockDeviceMappingDeleteOnVmDeletion *bool `json:"BlockDeviceMappingDeleteOnVmDeletion,omitempty"` + // The device names for the volumes. + BlockDeviceMappingDeviceNames *[]string `json:"BlockDeviceMappingDeviceNames,omitempty"` + // The IDs of the snapshots used to create the volumes. + BlockDeviceMappingSnapshotIds *[]string `json:"BlockDeviceMappingSnapshotIds,omitempty"` + // The sizes of the volumes, in gibibytes (GiB). + BlockDeviceMappingVolumeSizes *[]int32 `json:"BlockDeviceMappingVolumeSizes,omitempty"` + // The types of volumes (`standard` \\| `gp2` \\| `io1`). + BlockDeviceMappingVolumeTypes *[]string `json:"BlockDeviceMappingVolumeTypes,omitempty"` + // The descriptions of the OMIs, provided when they were created. + Descriptions *[]string `json:"Descriptions,omitempty"` + // The locations where the OMI files are stored on Object Storage Unit (OSU). + FileLocations *[]string `json:"FileLocations,omitempty"` + // The IDs of the OMIs. + ImageIds *[]string `json:"ImageIds,omitempty"` + // The names of the OMIs, provided when they were created. + ImageNames *[]string `json:"ImageNames,omitempty"` + // The account IDs of the users who have launch permissions for the OMIs. + PermissionsToLaunchAccountIds *[]string `json:"PermissionsToLaunchAccountIds,omitempty"` + // If `true`, lists all public OMIs. If `false`, lists all private OMIs. + PermissionsToLaunchGlobalPermission *bool `json:"PermissionsToLaunchGlobalPermission,omitempty"` + // The device names of the root devices (for example, `/dev/sda1`). + RootDeviceNames *[]string `json:"RootDeviceNames,omitempty"` + // The types of root device used by the OMIs (always `bsu`). + RootDeviceTypes *[]string `json:"RootDeviceTypes,omitempty"` + // The states of the OMIs (`pending` \\| `available` \\| `failed`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the OMIs. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the OMIs. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the OMIs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The virtualization types (always `hvm`). + VirtualizationTypes *[]string `json:"VirtualizationTypes,omitempty"` +} + +// NewFiltersImage instantiates a new FiltersImage object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersImage() *FiltersImage { + this := FiltersImage{} + return &this +} + +// NewFiltersImageWithDefaults instantiates a new FiltersImage object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersImageWithDefaults() *FiltersImage { + this := FiltersImage{} + return &this +} + +// GetAccountAliases returns the AccountAliases field value if set, zero value otherwise. +func (o *FiltersImage) GetAccountAliases() []string { + if o == nil || o.AccountAliases == nil { + var ret []string + return ret + } + return *o.AccountAliases +} + +// GetAccountAliasesOk returns a tuple with the AccountAliases field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetAccountAliasesOk() (*[]string, bool) { + if o == nil || o.AccountAliases == nil { + return nil, false + } + return o.AccountAliases, true +} + +// HasAccountAliases returns a boolean if a field has been set. +func (o *FiltersImage) HasAccountAliases() bool { + if o != nil && o.AccountAliases != nil { + return true + } + + return false +} + +// SetAccountAliases gets a reference to the given []string and assigns it to the AccountAliases field. +func (o *FiltersImage) SetAccountAliases(v []string) { + o.AccountAliases = &v +} + +// GetAccountIds returns the AccountIds field value if set, zero value otherwise. +func (o *FiltersImage) GetAccountIds() []string { + if o == nil || o.AccountIds == nil { + var ret []string + return ret + } + return *o.AccountIds +} + +// GetAccountIdsOk returns a tuple with the AccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetAccountIdsOk() (*[]string, bool) { + if o == nil || o.AccountIds == nil { + return nil, false + } + return o.AccountIds, true +} + +// HasAccountIds returns a boolean if a field has been set. +func (o *FiltersImage) HasAccountIds() bool { + if o != nil && o.AccountIds != nil { + return true + } + + return false +} + +// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. +func (o *FiltersImage) SetAccountIds(v []string) { + o.AccountIds = &v +} + +// GetArchitectures returns the Architectures field value if set, zero value otherwise. +func (o *FiltersImage) GetArchitectures() []string { + if o == nil || o.Architectures == nil { + var ret []string + return ret + } + return *o.Architectures +} + +// GetArchitecturesOk returns a tuple with the Architectures field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetArchitecturesOk() (*[]string, bool) { + if o == nil || o.Architectures == nil { + return nil, false + } + return o.Architectures, true +} + +// HasArchitectures returns a boolean if a field has been set. +func (o *FiltersImage) HasArchitectures() bool { + if o != nil && o.Architectures != nil { + return true + } + + return false +} + +// SetArchitectures gets a reference to the given []string and assigns it to the Architectures field. +func (o *FiltersImage) SetArchitectures(v []string) { + o.Architectures = &v +} + +// GetBlockDeviceMappingDeleteOnVmDeletion returns the BlockDeviceMappingDeleteOnVmDeletion field value if set, zero value otherwise. +func (o *FiltersImage) GetBlockDeviceMappingDeleteOnVmDeletion() bool { + if o == nil || o.BlockDeviceMappingDeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.BlockDeviceMappingDeleteOnVmDeletion +} + +// GetBlockDeviceMappingDeleteOnVmDeletionOk returns a tuple with the BlockDeviceMappingDeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetBlockDeviceMappingDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.BlockDeviceMappingDeleteOnVmDeletion == nil { + return nil, false + } + return o.BlockDeviceMappingDeleteOnVmDeletion, true +} + +// HasBlockDeviceMappingDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *FiltersImage) HasBlockDeviceMappingDeleteOnVmDeletion() bool { + if o != nil && o.BlockDeviceMappingDeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetBlockDeviceMappingDeleteOnVmDeletion gets a reference to the given bool and assigns it to the BlockDeviceMappingDeleteOnVmDeletion field. +func (o *FiltersImage) SetBlockDeviceMappingDeleteOnVmDeletion(v bool) { + o.BlockDeviceMappingDeleteOnVmDeletion = &v +} + +// GetBlockDeviceMappingDeviceNames returns the BlockDeviceMappingDeviceNames field value if set, zero value otherwise. +func (o *FiltersImage) GetBlockDeviceMappingDeviceNames() []string { + if o == nil || o.BlockDeviceMappingDeviceNames == nil { + var ret []string + return ret + } + return *o.BlockDeviceMappingDeviceNames +} + +// GetBlockDeviceMappingDeviceNamesOk returns a tuple with the BlockDeviceMappingDeviceNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetBlockDeviceMappingDeviceNamesOk() (*[]string, bool) { + if o == nil || o.BlockDeviceMappingDeviceNames == nil { + return nil, false + } + return o.BlockDeviceMappingDeviceNames, true +} + +// HasBlockDeviceMappingDeviceNames returns a boolean if a field has been set. +func (o *FiltersImage) HasBlockDeviceMappingDeviceNames() bool { + if o != nil && o.BlockDeviceMappingDeviceNames != nil { + return true + } + + return false +} + +// SetBlockDeviceMappingDeviceNames gets a reference to the given []string and assigns it to the BlockDeviceMappingDeviceNames field. +func (o *FiltersImage) SetBlockDeviceMappingDeviceNames(v []string) { + o.BlockDeviceMappingDeviceNames = &v +} + +// GetBlockDeviceMappingSnapshotIds returns the BlockDeviceMappingSnapshotIds field value if set, zero value otherwise. +func (o *FiltersImage) GetBlockDeviceMappingSnapshotIds() []string { + if o == nil || o.BlockDeviceMappingSnapshotIds == nil { + var ret []string + return ret + } + return *o.BlockDeviceMappingSnapshotIds +} + +// GetBlockDeviceMappingSnapshotIdsOk returns a tuple with the BlockDeviceMappingSnapshotIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetBlockDeviceMappingSnapshotIdsOk() (*[]string, bool) { + if o == nil || o.BlockDeviceMappingSnapshotIds == nil { + return nil, false + } + return o.BlockDeviceMappingSnapshotIds, true +} + +// HasBlockDeviceMappingSnapshotIds returns a boolean if a field has been set. +func (o *FiltersImage) HasBlockDeviceMappingSnapshotIds() bool { + if o != nil && o.BlockDeviceMappingSnapshotIds != nil { + return true + } + + return false +} + +// SetBlockDeviceMappingSnapshotIds gets a reference to the given []string and assigns it to the BlockDeviceMappingSnapshotIds field. +func (o *FiltersImage) SetBlockDeviceMappingSnapshotIds(v []string) { + o.BlockDeviceMappingSnapshotIds = &v +} + +// GetBlockDeviceMappingVolumeSizes returns the BlockDeviceMappingVolumeSizes field value if set, zero value otherwise. +func (o *FiltersImage) GetBlockDeviceMappingVolumeSizes() []int32 { + if o == nil || o.BlockDeviceMappingVolumeSizes == nil { + var ret []int32 + return ret + } + return *o.BlockDeviceMappingVolumeSizes +} + +// GetBlockDeviceMappingVolumeSizesOk returns a tuple with the BlockDeviceMappingVolumeSizes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetBlockDeviceMappingVolumeSizesOk() (*[]int32, bool) { + if o == nil || o.BlockDeviceMappingVolumeSizes == nil { + return nil, false + } + return o.BlockDeviceMappingVolumeSizes, true +} + +// HasBlockDeviceMappingVolumeSizes returns a boolean if a field has been set. +func (o *FiltersImage) HasBlockDeviceMappingVolumeSizes() bool { + if o != nil && o.BlockDeviceMappingVolumeSizes != nil { + return true + } + + return false +} + +// SetBlockDeviceMappingVolumeSizes gets a reference to the given []int32 and assigns it to the BlockDeviceMappingVolumeSizes field. +func (o *FiltersImage) SetBlockDeviceMappingVolumeSizes(v []int32) { + o.BlockDeviceMappingVolumeSizes = &v +} + +// GetBlockDeviceMappingVolumeTypes returns the BlockDeviceMappingVolumeTypes field value if set, zero value otherwise. +func (o *FiltersImage) GetBlockDeviceMappingVolumeTypes() []string { + if o == nil || o.BlockDeviceMappingVolumeTypes == nil { + var ret []string + return ret + } + return *o.BlockDeviceMappingVolumeTypes +} + +// GetBlockDeviceMappingVolumeTypesOk returns a tuple with the BlockDeviceMappingVolumeTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetBlockDeviceMappingVolumeTypesOk() (*[]string, bool) { + if o == nil || o.BlockDeviceMappingVolumeTypes == nil { + return nil, false + } + return o.BlockDeviceMappingVolumeTypes, true +} + +// HasBlockDeviceMappingVolumeTypes returns a boolean if a field has been set. +func (o *FiltersImage) HasBlockDeviceMappingVolumeTypes() bool { + if o != nil && o.BlockDeviceMappingVolumeTypes != nil { + return true + } + + return false +} + +// SetBlockDeviceMappingVolumeTypes gets a reference to the given []string and assigns it to the BlockDeviceMappingVolumeTypes field. +func (o *FiltersImage) SetBlockDeviceMappingVolumeTypes(v []string) { + o.BlockDeviceMappingVolumeTypes = &v +} + +// GetDescriptions returns the Descriptions field value if set, zero value otherwise. +func (o *FiltersImage) GetDescriptions() []string { + if o == nil || o.Descriptions == nil { + var ret []string + return ret + } + return *o.Descriptions +} + +// GetDescriptionsOk returns a tuple with the Descriptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetDescriptionsOk() (*[]string, bool) { + if o == nil || o.Descriptions == nil { + return nil, false + } + return o.Descriptions, true +} + +// HasDescriptions returns a boolean if a field has been set. +func (o *FiltersImage) HasDescriptions() bool { + if o != nil && o.Descriptions != nil { + return true + } + + return false +} + +// SetDescriptions gets a reference to the given []string and assigns it to the Descriptions field. +func (o *FiltersImage) SetDescriptions(v []string) { + o.Descriptions = &v +} + +// GetFileLocations returns the FileLocations field value if set, zero value otherwise. +func (o *FiltersImage) GetFileLocations() []string { + if o == nil || o.FileLocations == nil { + var ret []string + return ret + } + return *o.FileLocations +} + +// GetFileLocationsOk returns a tuple with the FileLocations field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetFileLocationsOk() (*[]string, bool) { + if o == nil || o.FileLocations == nil { + return nil, false + } + return o.FileLocations, true +} + +// HasFileLocations returns a boolean if a field has been set. +func (o *FiltersImage) HasFileLocations() bool { + if o != nil && o.FileLocations != nil { + return true + } + + return false +} + +// SetFileLocations gets a reference to the given []string and assigns it to the FileLocations field. +func (o *FiltersImage) SetFileLocations(v []string) { + o.FileLocations = &v +} + +// GetImageIds returns the ImageIds field value if set, zero value otherwise. +func (o *FiltersImage) GetImageIds() []string { + if o == nil || o.ImageIds == nil { + var ret []string + return ret + } + return *o.ImageIds +} + +// GetImageIdsOk returns a tuple with the ImageIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetImageIdsOk() (*[]string, bool) { + if o == nil || o.ImageIds == nil { + return nil, false + } + return o.ImageIds, true +} + +// HasImageIds returns a boolean if a field has been set. +func (o *FiltersImage) HasImageIds() bool { + if o != nil && o.ImageIds != nil { + return true + } + + return false +} + +// SetImageIds gets a reference to the given []string and assigns it to the ImageIds field. +func (o *FiltersImage) SetImageIds(v []string) { + o.ImageIds = &v +} + +// GetImageNames returns the ImageNames field value if set, zero value otherwise. +func (o *FiltersImage) GetImageNames() []string { + if o == nil || o.ImageNames == nil { + var ret []string + return ret + } + return *o.ImageNames +} + +// GetImageNamesOk returns a tuple with the ImageNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetImageNamesOk() (*[]string, bool) { + if o == nil || o.ImageNames == nil { + return nil, false + } + return o.ImageNames, true +} + +// HasImageNames returns a boolean if a field has been set. +func (o *FiltersImage) HasImageNames() bool { + if o != nil && o.ImageNames != nil { + return true + } + + return false +} + +// SetImageNames gets a reference to the given []string and assigns it to the ImageNames field. +func (o *FiltersImage) SetImageNames(v []string) { + o.ImageNames = &v +} + +// GetPermissionsToLaunchAccountIds returns the PermissionsToLaunchAccountIds field value if set, zero value otherwise. +func (o *FiltersImage) GetPermissionsToLaunchAccountIds() []string { + if o == nil || o.PermissionsToLaunchAccountIds == nil { + var ret []string + return ret + } + return *o.PermissionsToLaunchAccountIds +} + +// GetPermissionsToLaunchAccountIdsOk returns a tuple with the PermissionsToLaunchAccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetPermissionsToLaunchAccountIdsOk() (*[]string, bool) { + if o == nil || o.PermissionsToLaunchAccountIds == nil { + return nil, false + } + return o.PermissionsToLaunchAccountIds, true +} + +// HasPermissionsToLaunchAccountIds returns a boolean if a field has been set. +func (o *FiltersImage) HasPermissionsToLaunchAccountIds() bool { + if o != nil && o.PermissionsToLaunchAccountIds != nil { + return true + } + + return false +} + +// SetPermissionsToLaunchAccountIds gets a reference to the given []string and assigns it to the PermissionsToLaunchAccountIds field. +func (o *FiltersImage) SetPermissionsToLaunchAccountIds(v []string) { + o.PermissionsToLaunchAccountIds = &v +} + +// GetPermissionsToLaunchGlobalPermission returns the PermissionsToLaunchGlobalPermission field value if set, zero value otherwise. +func (o *FiltersImage) GetPermissionsToLaunchGlobalPermission() bool { + if o == nil || o.PermissionsToLaunchGlobalPermission == nil { + var ret bool + return ret + } + return *o.PermissionsToLaunchGlobalPermission +} + +// GetPermissionsToLaunchGlobalPermissionOk returns a tuple with the PermissionsToLaunchGlobalPermission field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetPermissionsToLaunchGlobalPermissionOk() (*bool, bool) { + if o == nil || o.PermissionsToLaunchGlobalPermission == nil { + return nil, false + } + return o.PermissionsToLaunchGlobalPermission, true +} + +// HasPermissionsToLaunchGlobalPermission returns a boolean if a field has been set. +func (o *FiltersImage) HasPermissionsToLaunchGlobalPermission() bool { + if o != nil && o.PermissionsToLaunchGlobalPermission != nil { + return true + } + + return false +} + +// SetPermissionsToLaunchGlobalPermission gets a reference to the given bool and assigns it to the PermissionsToLaunchGlobalPermission field. +func (o *FiltersImage) SetPermissionsToLaunchGlobalPermission(v bool) { + o.PermissionsToLaunchGlobalPermission = &v +} + +// GetRootDeviceNames returns the RootDeviceNames field value if set, zero value otherwise. +func (o *FiltersImage) GetRootDeviceNames() []string { + if o == nil || o.RootDeviceNames == nil { + var ret []string + return ret + } + return *o.RootDeviceNames +} + +// GetRootDeviceNamesOk returns a tuple with the RootDeviceNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetRootDeviceNamesOk() (*[]string, bool) { + if o == nil || o.RootDeviceNames == nil { + return nil, false + } + return o.RootDeviceNames, true +} + +// HasRootDeviceNames returns a boolean if a field has been set. +func (o *FiltersImage) HasRootDeviceNames() bool { + if o != nil && o.RootDeviceNames != nil { + return true + } + + return false +} + +// SetRootDeviceNames gets a reference to the given []string and assigns it to the RootDeviceNames field. +func (o *FiltersImage) SetRootDeviceNames(v []string) { + o.RootDeviceNames = &v +} + +// GetRootDeviceTypes returns the RootDeviceTypes field value if set, zero value otherwise. +func (o *FiltersImage) GetRootDeviceTypes() []string { + if o == nil || o.RootDeviceTypes == nil { + var ret []string + return ret + } + return *o.RootDeviceTypes +} + +// GetRootDeviceTypesOk returns a tuple with the RootDeviceTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetRootDeviceTypesOk() (*[]string, bool) { + if o == nil || o.RootDeviceTypes == nil { + return nil, false + } + return o.RootDeviceTypes, true +} + +// HasRootDeviceTypes returns a boolean if a field has been set. +func (o *FiltersImage) HasRootDeviceTypes() bool { + if o != nil && o.RootDeviceTypes != nil { + return true + } + + return false +} + +// SetRootDeviceTypes gets a reference to the given []string and assigns it to the RootDeviceTypes field. +func (o *FiltersImage) SetRootDeviceTypes(v []string) { + o.RootDeviceTypes = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersImage) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersImage) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersImage) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersImage) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersImage) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersImage) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersImage) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersImage) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersImage) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersImage) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersImage) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersImage) SetTags(v []string) { + o.Tags = &v +} + +// GetVirtualizationTypes returns the VirtualizationTypes field value if set, zero value otherwise. +func (o *FiltersImage) GetVirtualizationTypes() []string { + if o == nil || o.VirtualizationTypes == nil { + var ret []string + return ret + } + return *o.VirtualizationTypes +} + +// GetVirtualizationTypesOk returns a tuple with the VirtualizationTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersImage) GetVirtualizationTypesOk() (*[]string, bool) { + if o == nil || o.VirtualizationTypes == nil { + return nil, false + } + return o.VirtualizationTypes, true +} + +// HasVirtualizationTypes returns a boolean if a field has been set. +func (o *FiltersImage) HasVirtualizationTypes() bool { + if o != nil && o.VirtualizationTypes != nil { + return true + } + + return false +} + +// SetVirtualizationTypes gets a reference to the given []string and assigns it to the VirtualizationTypes field. +func (o *FiltersImage) SetVirtualizationTypes(v []string) { + o.VirtualizationTypes = &v +} + +func (o FiltersImage) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountAliases != nil { + toSerialize["AccountAliases"] = o.AccountAliases + } + if o.AccountIds != nil { + toSerialize["AccountIds"] = o.AccountIds + } + if o.Architectures != nil { + toSerialize["Architectures"] = o.Architectures + } + if o.BlockDeviceMappingDeleteOnVmDeletion != nil { + toSerialize["BlockDeviceMappingDeleteOnVmDeletion"] = o.BlockDeviceMappingDeleteOnVmDeletion + } + if o.BlockDeviceMappingDeviceNames != nil { + toSerialize["BlockDeviceMappingDeviceNames"] = o.BlockDeviceMappingDeviceNames + } + if o.BlockDeviceMappingSnapshotIds != nil { + toSerialize["BlockDeviceMappingSnapshotIds"] = o.BlockDeviceMappingSnapshotIds + } + if o.BlockDeviceMappingVolumeSizes != nil { + toSerialize["BlockDeviceMappingVolumeSizes"] = o.BlockDeviceMappingVolumeSizes + } + if o.BlockDeviceMappingVolumeTypes != nil { + toSerialize["BlockDeviceMappingVolumeTypes"] = o.BlockDeviceMappingVolumeTypes + } + if o.Descriptions != nil { + toSerialize["Descriptions"] = o.Descriptions + } + if o.FileLocations != nil { + toSerialize["FileLocations"] = o.FileLocations + } + if o.ImageIds != nil { + toSerialize["ImageIds"] = o.ImageIds + } + if o.ImageNames != nil { + toSerialize["ImageNames"] = o.ImageNames + } + if o.PermissionsToLaunchAccountIds != nil { + toSerialize["PermissionsToLaunchAccountIds"] = o.PermissionsToLaunchAccountIds + } + if o.PermissionsToLaunchGlobalPermission != nil { + toSerialize["PermissionsToLaunchGlobalPermission"] = o.PermissionsToLaunchGlobalPermission + } + if o.RootDeviceNames != nil { + toSerialize["RootDeviceNames"] = o.RootDeviceNames + } + if o.RootDeviceTypes != nil { + toSerialize["RootDeviceTypes"] = o.RootDeviceTypes + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VirtualizationTypes != nil { + toSerialize["VirtualizationTypes"] = o.VirtualizationTypes + } + return json.Marshal(toSerialize) +} + +type NullableFiltersImage struct { + value *FiltersImage + isSet bool +} + +func (v NullableFiltersImage) Get() *FiltersImage { + return v.value +} + +func (v *NullableFiltersImage) Set(val *FiltersImage) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersImage) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersImage) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersImage(val *FiltersImage) *NullableFiltersImage { + return &NullableFiltersImage{value: val, isSet: true} +} + +func (v NullableFiltersImage) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersImage) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go new file mode 100644 index 000000000..735b09344 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersInternetService One or more filters. +type FiltersInternetService struct { + // The IDs of the Internet services. + InternetServiceIds *[]string `json:"InternetServiceIds,omitempty"` + // The IDs of the Nets the Internet services are attached to. + LinkNetIds *[]string `json:"LinkNetIds,omitempty"` + // The current states of the attachments between the Internet services and the Nets (only `available`, if the Internet gateway is attached to a VPC). + LinkStates *[]string `json:"LinkStates,omitempty"` + // The keys of the tags associated with the Internet services. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the Internet services. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the Internet services, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersInternetService instantiates a new FiltersInternetService object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersInternetService() *FiltersInternetService { + this := FiltersInternetService{} + return &this +} + +// NewFiltersInternetServiceWithDefaults instantiates a new FiltersInternetService object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersInternetServiceWithDefaults() *FiltersInternetService { + this := FiltersInternetService{} + return &this +} + +// GetInternetServiceIds returns the InternetServiceIds field value if set, zero value otherwise. +func (o *FiltersInternetService) GetInternetServiceIds() []string { + if o == nil || o.InternetServiceIds == nil { + var ret []string + return ret + } + return *o.InternetServiceIds +} + +// GetInternetServiceIdsOk returns a tuple with the InternetServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetInternetServiceIdsOk() (*[]string, bool) { + if o == nil || o.InternetServiceIds == nil { + return nil, false + } + return o.InternetServiceIds, true +} + +// HasInternetServiceIds returns a boolean if a field has been set. +func (o *FiltersInternetService) HasInternetServiceIds() bool { + if o != nil && o.InternetServiceIds != nil { + return true + } + + return false +} + +// SetInternetServiceIds gets a reference to the given []string and assigns it to the InternetServiceIds field. +func (o *FiltersInternetService) SetInternetServiceIds(v []string) { + o.InternetServiceIds = &v +} + +// GetLinkNetIds returns the LinkNetIds field value if set, zero value otherwise. +func (o *FiltersInternetService) GetLinkNetIds() []string { + if o == nil || o.LinkNetIds == nil { + var ret []string + return ret + } + return *o.LinkNetIds +} + +// GetLinkNetIdsOk returns a tuple with the LinkNetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetLinkNetIdsOk() (*[]string, bool) { + if o == nil || o.LinkNetIds == nil { + return nil, false + } + return o.LinkNetIds, true +} + +// HasLinkNetIds returns a boolean if a field has been set. +func (o *FiltersInternetService) HasLinkNetIds() bool { + if o != nil && o.LinkNetIds != nil { + return true + } + + return false +} + +// SetLinkNetIds gets a reference to the given []string and assigns it to the LinkNetIds field. +func (o *FiltersInternetService) SetLinkNetIds(v []string) { + o.LinkNetIds = &v +} + +// GetLinkStates returns the LinkStates field value if set, zero value otherwise. +func (o *FiltersInternetService) GetLinkStates() []string { + if o == nil || o.LinkStates == nil { + var ret []string + return ret + } + return *o.LinkStates +} + +// GetLinkStatesOk returns a tuple with the LinkStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetLinkStatesOk() (*[]string, bool) { + if o == nil || o.LinkStates == nil { + return nil, false + } + return o.LinkStates, true +} + +// HasLinkStates returns a boolean if a field has been set. +func (o *FiltersInternetService) HasLinkStates() bool { + if o != nil && o.LinkStates != nil { + return true + } + + return false +} + +// SetLinkStates gets a reference to the given []string and assigns it to the LinkStates field. +func (o *FiltersInternetService) SetLinkStates(v []string) { + o.LinkStates = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersInternetService) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersInternetService) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersInternetService) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersInternetService) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersInternetService) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersInternetService) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersInternetService) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersInternetService) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersInternetService) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersInternetService) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersInternetService) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.InternetServiceIds != nil { + toSerialize["InternetServiceIds"] = o.InternetServiceIds + } + if o.LinkNetIds != nil { + toSerialize["LinkNetIds"] = o.LinkNetIds + } + if o.LinkStates != nil { + toSerialize["LinkStates"] = o.LinkStates + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersInternetService struct { + value *FiltersInternetService + isSet bool +} + +func (v NullableFiltersInternetService) Get() *FiltersInternetService { + return v.value +} + +func (v *NullableFiltersInternetService) Set(val *FiltersInternetService) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersInternetService) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersInternetService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersInternetService(val *FiltersInternetService) *NullableFiltersInternetService { + return &NullableFiltersInternetService{value: val, isSet: true} +} + +func (v NullableFiltersInternetService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersInternetService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go new file mode 100644 index 000000000..d4e2f0cc3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersKeypair One or more filters. +type FiltersKeypair struct { + // The fingerprints of the keypairs. + KeypairFingerprints *[]string `json:"KeypairFingerprints,omitempty"` + // The names of the keypairs. + KeypairNames *[]string `json:"KeypairNames,omitempty"` +} + +// NewFiltersKeypair instantiates a new FiltersKeypair object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersKeypair() *FiltersKeypair { + this := FiltersKeypair{} + return &this +} + +// NewFiltersKeypairWithDefaults instantiates a new FiltersKeypair object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersKeypairWithDefaults() *FiltersKeypair { + this := FiltersKeypair{} + return &this +} + +// GetKeypairFingerprints returns the KeypairFingerprints field value if set, zero value otherwise. +func (o *FiltersKeypair) GetKeypairFingerprints() []string { + if o == nil || o.KeypairFingerprints == nil { + var ret []string + return ret + } + return *o.KeypairFingerprints +} + +// GetKeypairFingerprintsOk returns a tuple with the KeypairFingerprints field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersKeypair) GetKeypairFingerprintsOk() (*[]string, bool) { + if o == nil || o.KeypairFingerprints == nil { + return nil, false + } + return o.KeypairFingerprints, true +} + +// HasKeypairFingerprints returns a boolean if a field has been set. +func (o *FiltersKeypair) HasKeypairFingerprints() bool { + if o != nil && o.KeypairFingerprints != nil { + return true + } + + return false +} + +// SetKeypairFingerprints gets a reference to the given []string and assigns it to the KeypairFingerprints field. +func (o *FiltersKeypair) SetKeypairFingerprints(v []string) { + o.KeypairFingerprints = &v +} + +// GetKeypairNames returns the KeypairNames field value if set, zero value otherwise. +func (o *FiltersKeypair) GetKeypairNames() []string { + if o == nil || o.KeypairNames == nil { + var ret []string + return ret + } + return *o.KeypairNames +} + +// GetKeypairNamesOk returns a tuple with the KeypairNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersKeypair) GetKeypairNamesOk() (*[]string, bool) { + if o == nil || o.KeypairNames == nil { + return nil, false + } + return o.KeypairNames, true +} + +// HasKeypairNames returns a boolean if a field has been set. +func (o *FiltersKeypair) HasKeypairNames() bool { + if o != nil && o.KeypairNames != nil { + return true + } + + return false +} + +// SetKeypairNames gets a reference to the given []string and assigns it to the KeypairNames field. +func (o *FiltersKeypair) SetKeypairNames(v []string) { + o.KeypairNames = &v +} + +func (o FiltersKeypair) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.KeypairFingerprints != nil { + toSerialize["KeypairFingerprints"] = o.KeypairFingerprints + } + if o.KeypairNames != nil { + toSerialize["KeypairNames"] = o.KeypairNames + } + return json.Marshal(toSerialize) +} + +type NullableFiltersKeypair struct { + value *FiltersKeypair + isSet bool +} + +func (v NullableFiltersKeypair) Get() *FiltersKeypair { + return v.value +} + +func (v *NullableFiltersKeypair) Set(val *FiltersKeypair) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersKeypair) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersKeypair) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersKeypair(val *FiltersKeypair) *NullableFiltersKeypair { + return &NullableFiltersKeypair{value: val, isSet: true} +} + +func (v NullableFiltersKeypair) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersKeypair) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go new file mode 100644 index 000000000..f5b00d814 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersListenerRule One or more filters. +type FiltersListenerRule struct { + // The names of the listener rules. + ListenerRuleNames *[]string `json:"ListenerRuleNames,omitempty"` +} + +// NewFiltersListenerRule instantiates a new FiltersListenerRule object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersListenerRule() *FiltersListenerRule { + this := FiltersListenerRule{} + return &this +} + +// NewFiltersListenerRuleWithDefaults instantiates a new FiltersListenerRule object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersListenerRuleWithDefaults() *FiltersListenerRule { + this := FiltersListenerRule{} + return &this +} + +// GetListenerRuleNames returns the ListenerRuleNames field value if set, zero value otherwise. +func (o *FiltersListenerRule) GetListenerRuleNames() []string { + if o == nil || o.ListenerRuleNames == nil { + var ret []string + return ret + } + return *o.ListenerRuleNames +} + +// GetListenerRuleNamesOk returns a tuple with the ListenerRuleNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersListenerRule) GetListenerRuleNamesOk() (*[]string, bool) { + if o == nil || o.ListenerRuleNames == nil { + return nil, false + } + return o.ListenerRuleNames, true +} + +// HasListenerRuleNames returns a boolean if a field has been set. +func (o *FiltersListenerRule) HasListenerRuleNames() bool { + if o != nil && o.ListenerRuleNames != nil { + return true + } + + return false +} + +// SetListenerRuleNames gets a reference to the given []string and assigns it to the ListenerRuleNames field. +func (o *FiltersListenerRule) SetListenerRuleNames(v []string) { + o.ListenerRuleNames = &v +} + +func (o FiltersListenerRule) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ListenerRuleNames != nil { + toSerialize["ListenerRuleNames"] = o.ListenerRuleNames + } + return json.Marshal(toSerialize) +} + +type NullableFiltersListenerRule struct { + value *FiltersListenerRule + isSet bool +} + +func (v NullableFiltersListenerRule) Get() *FiltersListenerRule { + return v.value +} + +func (v *NullableFiltersListenerRule) Set(val *FiltersListenerRule) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersListenerRule) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersListenerRule) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersListenerRule(val *FiltersListenerRule) *NullableFiltersListenerRule { + return &NullableFiltersListenerRule{value: val, isSet: true} +} + +func (v NullableFiltersListenerRule) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersListenerRule) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go new file mode 100644 index 000000000..d514924f6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersLoadBalancer One or more filters. +type FiltersLoadBalancer struct { + // The names of the load balancers. + LoadBalancerNames *[]string `json:"LoadBalancerNames,omitempty"` +} + +// NewFiltersLoadBalancer instantiates a new FiltersLoadBalancer object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersLoadBalancer() *FiltersLoadBalancer { + this := FiltersLoadBalancer{} + return &this +} + +// NewFiltersLoadBalancerWithDefaults instantiates a new FiltersLoadBalancer object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersLoadBalancerWithDefaults() *FiltersLoadBalancer { + this := FiltersLoadBalancer{} + return &this +} + +// GetLoadBalancerNames returns the LoadBalancerNames field value if set, zero value otherwise. +func (o *FiltersLoadBalancer) GetLoadBalancerNames() []string { + if o == nil || o.LoadBalancerNames == nil { + var ret []string + return ret + } + return *o.LoadBalancerNames +} + +// GetLoadBalancerNamesOk returns a tuple with the LoadBalancerNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersLoadBalancer) GetLoadBalancerNamesOk() (*[]string, bool) { + if o == nil || o.LoadBalancerNames == nil { + return nil, false + } + return o.LoadBalancerNames, true +} + +// HasLoadBalancerNames returns a boolean if a field has been set. +func (o *FiltersLoadBalancer) HasLoadBalancerNames() bool { + if o != nil && o.LoadBalancerNames != nil { + return true + } + + return false +} + +// SetLoadBalancerNames gets a reference to the given []string and assigns it to the LoadBalancerNames field. +func (o *FiltersLoadBalancer) SetLoadBalancerNames(v []string) { + o.LoadBalancerNames = &v +} + +func (o FiltersLoadBalancer) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancerNames != nil { + toSerialize["LoadBalancerNames"] = o.LoadBalancerNames + } + return json.Marshal(toSerialize) +} + +type NullableFiltersLoadBalancer struct { + value *FiltersLoadBalancer + isSet bool +} + +func (v NullableFiltersLoadBalancer) Get() *FiltersLoadBalancer { + return v.value +} + +func (v *NullableFiltersLoadBalancer) Set(val *FiltersLoadBalancer) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersLoadBalancer) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersLoadBalancer) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersLoadBalancer(val *FiltersLoadBalancer) *NullableFiltersLoadBalancer { + return &NullableFiltersLoadBalancer{value: val, isSet: true} +} + +func (v NullableFiltersLoadBalancer) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersLoadBalancer) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go new file mode 100644 index 000000000..5ba25b28b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersNatService One or more filters. +type FiltersNatService struct { + // The IDs of the NAT services. + NatServiceIds *[]string `json:"NatServiceIds,omitempty"` + // The IDs of the Nets in which the NAT services are. + NetIds *[]string `json:"NetIds,omitempty"` + // The states of the NAT services (`pending` \\| `available` \\| `deleting` \\| `deleted`). + States *[]string `json:"States,omitempty"` + // The IDs of the Subnets in which the NAT services are. + SubnetIds *[]string `json:"SubnetIds,omitempty"` + // The keys of the tags associated with the NAT services. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the NAT services. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the NAT services, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersNatService instantiates a new FiltersNatService object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersNatService() *FiltersNatService { + this := FiltersNatService{} + return &this +} + +// NewFiltersNatServiceWithDefaults instantiates a new FiltersNatService object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersNatServiceWithDefaults() *FiltersNatService { + this := FiltersNatService{} + return &this +} + +// GetNatServiceIds returns the NatServiceIds field value if set, zero value otherwise. +func (o *FiltersNatService) GetNatServiceIds() []string { + if o == nil || o.NatServiceIds == nil { + var ret []string + return ret + } + return *o.NatServiceIds +} + +// GetNatServiceIdsOk returns a tuple with the NatServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetNatServiceIdsOk() (*[]string, bool) { + if o == nil || o.NatServiceIds == nil { + return nil, false + } + return o.NatServiceIds, true +} + +// HasNatServiceIds returns a boolean if a field has been set. +func (o *FiltersNatService) HasNatServiceIds() bool { + if o != nil && o.NatServiceIds != nil { + return true + } + + return false +} + +// SetNatServiceIds gets a reference to the given []string and assigns it to the NatServiceIds field. +func (o *FiltersNatService) SetNatServiceIds(v []string) { + o.NatServiceIds = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersNatService) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersNatService) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersNatService) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersNatService) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersNatService) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersNatService) SetStates(v []string) { + o.States = &v +} + +// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. +func (o *FiltersNatService) GetSubnetIds() []string { + if o == nil || o.SubnetIds == nil { + var ret []string + return ret + } + return *o.SubnetIds +} + +// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetSubnetIdsOk() (*[]string, bool) { + if o == nil || o.SubnetIds == nil { + return nil, false + } + return o.SubnetIds, true +} + +// HasSubnetIds returns a boolean if a field has been set. +func (o *FiltersNatService) HasSubnetIds() bool { + if o != nil && o.SubnetIds != nil { + return true + } + + return false +} + +// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. +func (o *FiltersNatService) SetSubnetIds(v []string) { + o.SubnetIds = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersNatService) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersNatService) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersNatService) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersNatService) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersNatService) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersNatService) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersNatService) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNatService) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersNatService) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersNatService) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersNatService) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NatServiceIds != nil { + toSerialize["NatServiceIds"] = o.NatServiceIds + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.SubnetIds != nil { + toSerialize["SubnetIds"] = o.SubnetIds + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersNatService struct { + value *FiltersNatService + isSet bool +} + +func (v NullableFiltersNatService) Get() *FiltersNatService { + return v.value +} + +func (v *NullableFiltersNatService) Set(val *FiltersNatService) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersNatService) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersNatService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersNatService(val *FiltersNatService) *NullableFiltersNatService { + return &NullableFiltersNatService{value: val, isSet: true} +} + +func (v NullableFiltersNatService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersNatService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go new file mode 100644 index 000000000..6628710eb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersNet One or more filters. +type FiltersNet struct { + // The IDs of the DHCP options sets. + DhcpOptionsSetIds *[]string `json:"DhcpOptionsSetIds,omitempty"` + // The IP ranges for the Nets, in CIDR notation (for example, 10.0.0.0/16). + IpRanges *[]string `json:"IpRanges,omitempty"` + // If `true`, the Net used is the default one. + IsDefault *bool `json:"IsDefault,omitempty"` + // The IDs of the Nets. + NetIds *[]string `json:"NetIds,omitempty"` + // The states of the Nets (`pending` \\| `available`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the Nets. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the Nets. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the Nets, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersNet instantiates a new FiltersNet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersNet() *FiltersNet { + this := FiltersNet{} + return &this +} + +// NewFiltersNetWithDefaults instantiates a new FiltersNet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersNetWithDefaults() *FiltersNet { + this := FiltersNet{} + return &this +} + +// GetDhcpOptionsSetIds returns the DhcpOptionsSetIds field value if set, zero value otherwise. +func (o *FiltersNet) GetDhcpOptionsSetIds() []string { + if o == nil || o.DhcpOptionsSetIds == nil { + var ret []string + return ret + } + return *o.DhcpOptionsSetIds +} + +// GetDhcpOptionsSetIdsOk returns a tuple with the DhcpOptionsSetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetDhcpOptionsSetIdsOk() (*[]string, bool) { + if o == nil || o.DhcpOptionsSetIds == nil { + return nil, false + } + return o.DhcpOptionsSetIds, true +} + +// HasDhcpOptionsSetIds returns a boolean if a field has been set. +func (o *FiltersNet) HasDhcpOptionsSetIds() bool { + if o != nil && o.DhcpOptionsSetIds != nil { + return true + } + + return false +} + +// SetDhcpOptionsSetIds gets a reference to the given []string and assigns it to the DhcpOptionsSetIds field. +func (o *FiltersNet) SetDhcpOptionsSetIds(v []string) { + o.DhcpOptionsSetIds = &v +} + +// GetIpRanges returns the IpRanges field value if set, zero value otherwise. +func (o *FiltersNet) GetIpRanges() []string { + if o == nil || o.IpRanges == nil { + var ret []string + return ret + } + return *o.IpRanges +} + +// GetIpRangesOk returns a tuple with the IpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetIpRangesOk() (*[]string, bool) { + if o == nil || o.IpRanges == nil { + return nil, false + } + return o.IpRanges, true +} + +// HasIpRanges returns a boolean if a field has been set. +func (o *FiltersNet) HasIpRanges() bool { + if o != nil && o.IpRanges != nil { + return true + } + + return false +} + +// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. +func (o *FiltersNet) SetIpRanges(v []string) { + o.IpRanges = &v +} + +// GetIsDefault returns the IsDefault field value if set, zero value otherwise. +func (o *FiltersNet) GetIsDefault() bool { + if o == nil || o.IsDefault == nil { + var ret bool + return ret + } + return *o.IsDefault +} + +// GetIsDefaultOk returns a tuple with the IsDefault field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetIsDefaultOk() (*bool, bool) { + if o == nil || o.IsDefault == nil { + return nil, false + } + return o.IsDefault, true +} + +// HasIsDefault returns a boolean if a field has been set. +func (o *FiltersNet) HasIsDefault() bool { + if o != nil && o.IsDefault != nil { + return true + } + + return false +} + +// SetIsDefault gets a reference to the given bool and assigns it to the IsDefault field. +func (o *FiltersNet) SetIsDefault(v bool) { + o.IsDefault = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersNet) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersNet) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersNet) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersNet) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersNet) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersNet) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersNet) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersNet) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersNet) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersNet) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersNet) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersNet) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersNet) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNet) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersNet) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersNet) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersNet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DhcpOptionsSetIds != nil { + toSerialize["DhcpOptionsSetIds"] = o.DhcpOptionsSetIds + } + if o.IpRanges != nil { + toSerialize["IpRanges"] = o.IpRanges + } + if o.IsDefault != nil { + toSerialize["IsDefault"] = o.IsDefault + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersNet struct { + value *FiltersNet + isSet bool +} + +func (v NullableFiltersNet) Get() *FiltersNet { + return v.value +} + +func (v *NullableFiltersNet) Set(val *FiltersNet) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersNet) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersNet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersNet(val *FiltersNet) *NullableFiltersNet { + return &NullableFiltersNet{value: val, isSet: true} +} + +func (v NullableFiltersNet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersNet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go new file mode 100644 index 000000000..f29457af7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersNetAccessPoint One or more filters. +type FiltersNetAccessPoint struct { + // The IDs of the Net access points. + NetAccessPointIds *[]string `json:"NetAccessPointIds,omitempty"` + // The IDs of the Nets. + NetIds *[]string `json:"NetIds,omitempty"` + // The names of the prefix lists corresponding to the services. For more information, see [DescribePrefixLists](#describeprefixlists) + ServiceNames *[]string `json:"ServiceNames,omitempty"` + // The states of the Net access points (`pending` \\| `available` \\| `deleting` \\| `deleted`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the Net access points. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the Net access points. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the Net access points, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersNetAccessPoint instantiates a new FiltersNetAccessPoint object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersNetAccessPoint() *FiltersNetAccessPoint { + this := FiltersNetAccessPoint{} + return &this +} + +// NewFiltersNetAccessPointWithDefaults instantiates a new FiltersNetAccessPoint object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersNetAccessPointWithDefaults() *FiltersNetAccessPoint { + this := FiltersNetAccessPoint{} + return &this +} + +// GetNetAccessPointIds returns the NetAccessPointIds field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetNetAccessPointIds() []string { + if o == nil || o.NetAccessPointIds == nil { + var ret []string + return ret + } + return *o.NetAccessPointIds +} + +// GetNetAccessPointIdsOk returns a tuple with the NetAccessPointIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetNetAccessPointIdsOk() (*[]string, bool) { + if o == nil || o.NetAccessPointIds == nil { + return nil, false + } + return o.NetAccessPointIds, true +} + +// HasNetAccessPointIds returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasNetAccessPointIds() bool { + if o != nil && o.NetAccessPointIds != nil { + return true + } + + return false +} + +// SetNetAccessPointIds gets a reference to the given []string and assigns it to the NetAccessPointIds field. +func (o *FiltersNetAccessPoint) SetNetAccessPointIds(v []string) { + o.NetAccessPointIds = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersNetAccessPoint) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetServiceNames returns the ServiceNames field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetServiceNames() []string { + if o == nil || o.ServiceNames == nil { + var ret []string + return ret + } + return *o.ServiceNames +} + +// GetServiceNamesOk returns a tuple with the ServiceNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetServiceNamesOk() (*[]string, bool) { + if o == nil || o.ServiceNames == nil { + return nil, false + } + return o.ServiceNames, true +} + +// HasServiceNames returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasServiceNames() bool { + if o != nil && o.ServiceNames != nil { + return true + } + + return false +} + +// SetServiceNames gets a reference to the given []string and assigns it to the ServiceNames field. +func (o *FiltersNetAccessPoint) SetServiceNames(v []string) { + o.ServiceNames = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersNetAccessPoint) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersNetAccessPoint) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersNetAccessPoint) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersNetAccessPoint) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetAccessPoint) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersNetAccessPoint) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersNetAccessPoint) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersNetAccessPoint) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetAccessPointIds != nil { + toSerialize["NetAccessPointIds"] = o.NetAccessPointIds + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.ServiceNames != nil { + toSerialize["ServiceNames"] = o.ServiceNames + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersNetAccessPoint struct { + value *FiltersNetAccessPoint + isSet bool +} + +func (v NullableFiltersNetAccessPoint) Get() *FiltersNetAccessPoint { + return v.value +} + +func (v *NullableFiltersNetAccessPoint) Set(val *FiltersNetAccessPoint) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersNetAccessPoint) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersNetAccessPoint) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersNetAccessPoint(val *FiltersNetAccessPoint) *NullableFiltersNetAccessPoint { + return &NullableFiltersNetAccessPoint{value: val, isSet: true} +} + +func (v NullableFiltersNetAccessPoint) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersNetAccessPoint) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go new file mode 100644 index 000000000..8ec795dd1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go @@ -0,0 +1,524 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersNetPeering One or more filters. +type FiltersNetPeering struct { + // The account IDs of the owners of the peer Nets. + AccepterNetAccountIds *[]string `json:"AccepterNetAccountIds,omitempty"` + // The IP ranges of the peer Nets, in CIDR notation (for example, 10.0.0.0/24). + AccepterNetIpRanges *[]string `json:"AccepterNetIpRanges,omitempty"` + // The IDs of the peer Nets. + AccepterNetNetIds *[]string `json:"AccepterNetNetIds,omitempty"` + // The IDs of the Net peering connections. + NetPeeringIds *[]string `json:"NetPeeringIds,omitempty"` + // The account IDs of the owners of the peer Nets. + SourceNetAccountIds *[]string `json:"SourceNetAccountIds,omitempty"` + // The IP ranges of the peer Nets. + SourceNetIpRanges *[]string `json:"SourceNetIpRanges,omitempty"` + // The IDs of the peer Nets. + SourceNetNetIds *[]string `json:"SourceNetNetIds,omitempty"` + // Additional information about the states of the Net peering connections. + StateMessages *[]string `json:"StateMessages,omitempty"` + // The states of the Net peering connections (`pending-acceptance` \\| `active` \\| `rejected` \\| `failed` \\| `expired` \\| `deleted`). + StateNames *[]string `json:"StateNames,omitempty"` + // The keys of the tags associated with the Net peering connections. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the Net peering connections. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the Net peering connections, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersNetPeering instantiates a new FiltersNetPeering object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersNetPeering() *FiltersNetPeering { + this := FiltersNetPeering{} + return &this +} + +// NewFiltersNetPeeringWithDefaults instantiates a new FiltersNetPeering object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersNetPeeringWithDefaults() *FiltersNetPeering { + this := FiltersNetPeering{} + return &this +} + +// GetAccepterNetAccountIds returns the AccepterNetAccountIds field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetAccepterNetAccountIds() []string { + if o == nil || o.AccepterNetAccountIds == nil { + var ret []string + return ret + } + return *o.AccepterNetAccountIds +} + +// GetAccepterNetAccountIdsOk returns a tuple with the AccepterNetAccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetAccepterNetAccountIdsOk() (*[]string, bool) { + if o == nil || o.AccepterNetAccountIds == nil { + return nil, false + } + return o.AccepterNetAccountIds, true +} + +// HasAccepterNetAccountIds returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasAccepterNetAccountIds() bool { + if o != nil && o.AccepterNetAccountIds != nil { + return true + } + + return false +} + +// SetAccepterNetAccountIds gets a reference to the given []string and assigns it to the AccepterNetAccountIds field. +func (o *FiltersNetPeering) SetAccepterNetAccountIds(v []string) { + o.AccepterNetAccountIds = &v +} + +// GetAccepterNetIpRanges returns the AccepterNetIpRanges field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetAccepterNetIpRanges() []string { + if o == nil || o.AccepterNetIpRanges == nil { + var ret []string + return ret + } + return *o.AccepterNetIpRanges +} + +// GetAccepterNetIpRangesOk returns a tuple with the AccepterNetIpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetAccepterNetIpRangesOk() (*[]string, bool) { + if o == nil || o.AccepterNetIpRanges == nil { + return nil, false + } + return o.AccepterNetIpRanges, true +} + +// HasAccepterNetIpRanges returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasAccepterNetIpRanges() bool { + if o != nil && o.AccepterNetIpRanges != nil { + return true + } + + return false +} + +// SetAccepterNetIpRanges gets a reference to the given []string and assigns it to the AccepterNetIpRanges field. +func (o *FiltersNetPeering) SetAccepterNetIpRanges(v []string) { + o.AccepterNetIpRanges = &v +} + +// GetAccepterNetNetIds returns the AccepterNetNetIds field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetAccepterNetNetIds() []string { + if o == nil || o.AccepterNetNetIds == nil { + var ret []string + return ret + } + return *o.AccepterNetNetIds +} + +// GetAccepterNetNetIdsOk returns a tuple with the AccepterNetNetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetAccepterNetNetIdsOk() (*[]string, bool) { + if o == nil || o.AccepterNetNetIds == nil { + return nil, false + } + return o.AccepterNetNetIds, true +} + +// HasAccepterNetNetIds returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasAccepterNetNetIds() bool { + if o != nil && o.AccepterNetNetIds != nil { + return true + } + + return false +} + +// SetAccepterNetNetIds gets a reference to the given []string and assigns it to the AccepterNetNetIds field. +func (o *FiltersNetPeering) SetAccepterNetNetIds(v []string) { + o.AccepterNetNetIds = &v +} + +// GetNetPeeringIds returns the NetPeeringIds field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetNetPeeringIds() []string { + if o == nil || o.NetPeeringIds == nil { + var ret []string + return ret + } + return *o.NetPeeringIds +} + +// GetNetPeeringIdsOk returns a tuple with the NetPeeringIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetNetPeeringIdsOk() (*[]string, bool) { + if o == nil || o.NetPeeringIds == nil { + return nil, false + } + return o.NetPeeringIds, true +} + +// HasNetPeeringIds returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasNetPeeringIds() bool { + if o != nil && o.NetPeeringIds != nil { + return true + } + + return false +} + +// SetNetPeeringIds gets a reference to the given []string and assigns it to the NetPeeringIds field. +func (o *FiltersNetPeering) SetNetPeeringIds(v []string) { + o.NetPeeringIds = &v +} + +// GetSourceNetAccountIds returns the SourceNetAccountIds field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetSourceNetAccountIds() []string { + if o == nil || o.SourceNetAccountIds == nil { + var ret []string + return ret + } + return *o.SourceNetAccountIds +} + +// GetSourceNetAccountIdsOk returns a tuple with the SourceNetAccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetSourceNetAccountIdsOk() (*[]string, bool) { + if o == nil || o.SourceNetAccountIds == nil { + return nil, false + } + return o.SourceNetAccountIds, true +} + +// HasSourceNetAccountIds returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasSourceNetAccountIds() bool { + if o != nil && o.SourceNetAccountIds != nil { + return true + } + + return false +} + +// SetSourceNetAccountIds gets a reference to the given []string and assigns it to the SourceNetAccountIds field. +func (o *FiltersNetPeering) SetSourceNetAccountIds(v []string) { + o.SourceNetAccountIds = &v +} + +// GetSourceNetIpRanges returns the SourceNetIpRanges field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetSourceNetIpRanges() []string { + if o == nil || o.SourceNetIpRanges == nil { + var ret []string + return ret + } + return *o.SourceNetIpRanges +} + +// GetSourceNetIpRangesOk returns a tuple with the SourceNetIpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetSourceNetIpRangesOk() (*[]string, bool) { + if o == nil || o.SourceNetIpRanges == nil { + return nil, false + } + return o.SourceNetIpRanges, true +} + +// HasSourceNetIpRanges returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasSourceNetIpRanges() bool { + if o != nil && o.SourceNetIpRanges != nil { + return true + } + + return false +} + +// SetSourceNetIpRanges gets a reference to the given []string and assigns it to the SourceNetIpRanges field. +func (o *FiltersNetPeering) SetSourceNetIpRanges(v []string) { + o.SourceNetIpRanges = &v +} + +// GetSourceNetNetIds returns the SourceNetNetIds field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetSourceNetNetIds() []string { + if o == nil || o.SourceNetNetIds == nil { + var ret []string + return ret + } + return *o.SourceNetNetIds +} + +// GetSourceNetNetIdsOk returns a tuple with the SourceNetNetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetSourceNetNetIdsOk() (*[]string, bool) { + if o == nil || o.SourceNetNetIds == nil { + return nil, false + } + return o.SourceNetNetIds, true +} + +// HasSourceNetNetIds returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasSourceNetNetIds() bool { + if o != nil && o.SourceNetNetIds != nil { + return true + } + + return false +} + +// SetSourceNetNetIds gets a reference to the given []string and assigns it to the SourceNetNetIds field. +func (o *FiltersNetPeering) SetSourceNetNetIds(v []string) { + o.SourceNetNetIds = &v +} + +// GetStateMessages returns the StateMessages field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetStateMessages() []string { + if o == nil || o.StateMessages == nil { + var ret []string + return ret + } + return *o.StateMessages +} + +// GetStateMessagesOk returns a tuple with the StateMessages field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetStateMessagesOk() (*[]string, bool) { + if o == nil || o.StateMessages == nil { + return nil, false + } + return o.StateMessages, true +} + +// HasStateMessages returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasStateMessages() bool { + if o != nil && o.StateMessages != nil { + return true + } + + return false +} + +// SetStateMessages gets a reference to the given []string and assigns it to the StateMessages field. +func (o *FiltersNetPeering) SetStateMessages(v []string) { + o.StateMessages = &v +} + +// GetStateNames returns the StateNames field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetStateNames() []string { + if o == nil || o.StateNames == nil { + var ret []string + return ret + } + return *o.StateNames +} + +// GetStateNamesOk returns a tuple with the StateNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetStateNamesOk() (*[]string, bool) { + if o == nil || o.StateNames == nil { + return nil, false + } + return o.StateNames, true +} + +// HasStateNames returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasStateNames() bool { + if o != nil && o.StateNames != nil { + return true + } + + return false +} + +// SetStateNames gets a reference to the given []string and assigns it to the StateNames field. +func (o *FiltersNetPeering) SetStateNames(v []string) { + o.StateNames = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersNetPeering) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersNetPeering) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersNetPeering) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNetPeering) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersNetPeering) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersNetPeering) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersNetPeering) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccepterNetAccountIds != nil { + toSerialize["AccepterNetAccountIds"] = o.AccepterNetAccountIds + } + if o.AccepterNetIpRanges != nil { + toSerialize["AccepterNetIpRanges"] = o.AccepterNetIpRanges + } + if o.AccepterNetNetIds != nil { + toSerialize["AccepterNetNetIds"] = o.AccepterNetNetIds + } + if o.NetPeeringIds != nil { + toSerialize["NetPeeringIds"] = o.NetPeeringIds + } + if o.SourceNetAccountIds != nil { + toSerialize["SourceNetAccountIds"] = o.SourceNetAccountIds + } + if o.SourceNetIpRanges != nil { + toSerialize["SourceNetIpRanges"] = o.SourceNetIpRanges + } + if o.SourceNetNetIds != nil { + toSerialize["SourceNetNetIds"] = o.SourceNetNetIds + } + if o.StateMessages != nil { + toSerialize["StateMessages"] = o.StateMessages + } + if o.StateNames != nil { + toSerialize["StateNames"] = o.StateNames + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersNetPeering struct { + value *FiltersNetPeering + isSet bool +} + +func (v NullableFiltersNetPeering) Get() *FiltersNetPeering { + return v.value +} + +func (v *NullableFiltersNetPeering) Set(val *FiltersNetPeering) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersNetPeering) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersNetPeering) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersNetPeering(val *FiltersNetPeering) *NullableFiltersNetPeering { + return &NullableFiltersNetPeering{value: val, isSet: true} +} + +func (v NullableFiltersNetPeering) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersNetPeering) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go new file mode 100644 index 000000000..1a4e9966b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersNic One or more filters. +type FiltersNic struct { + // The device numbers the NICs are attached to. + LinkNicSortNumbers *[]int32 `json:"LinkNicSortNumbers,omitempty"` + // The IDs of the VMs the NICs are attached to. + LinkNicVmIds *[]string `json:"LinkNicVmIds,omitempty"` + // The IDs of the NICs. + NicIds *[]string `json:"NicIds,omitempty"` + // The private IP addresses of the NICs. + PrivateIpsPrivateIps *[]string `json:"PrivateIpsPrivateIps,omitempty"` + // The IDs of the Subnets for the NICs. + SubnetIds *[]string `json:"SubnetIds,omitempty"` +} + +// NewFiltersNic instantiates a new FiltersNic object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersNic() *FiltersNic { + this := FiltersNic{} + return &this +} + +// NewFiltersNicWithDefaults instantiates a new FiltersNic object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersNicWithDefaults() *FiltersNic { + this := FiltersNic{} + return &this +} + +// GetLinkNicSortNumbers returns the LinkNicSortNumbers field value if set, zero value otherwise. +func (o *FiltersNic) GetLinkNicSortNumbers() []int32 { + if o == nil || o.LinkNicSortNumbers == nil { + var ret []int32 + return ret + } + return *o.LinkNicSortNumbers +} + +// GetLinkNicSortNumbersOk returns a tuple with the LinkNicSortNumbers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNic) GetLinkNicSortNumbersOk() (*[]int32, bool) { + if o == nil || o.LinkNicSortNumbers == nil { + return nil, false + } + return o.LinkNicSortNumbers, true +} + +// HasLinkNicSortNumbers returns a boolean if a field has been set. +func (o *FiltersNic) HasLinkNicSortNumbers() bool { + if o != nil && o.LinkNicSortNumbers != nil { + return true + } + + return false +} + +// SetLinkNicSortNumbers gets a reference to the given []int32 and assigns it to the LinkNicSortNumbers field. +func (o *FiltersNic) SetLinkNicSortNumbers(v []int32) { + o.LinkNicSortNumbers = &v +} + +// GetLinkNicVmIds returns the LinkNicVmIds field value if set, zero value otherwise. +func (o *FiltersNic) GetLinkNicVmIds() []string { + if o == nil || o.LinkNicVmIds == nil { + var ret []string + return ret + } + return *o.LinkNicVmIds +} + +// GetLinkNicVmIdsOk returns a tuple with the LinkNicVmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNic) GetLinkNicVmIdsOk() (*[]string, bool) { + if o == nil || o.LinkNicVmIds == nil { + return nil, false + } + return o.LinkNicVmIds, true +} + +// HasLinkNicVmIds returns a boolean if a field has been set. +func (o *FiltersNic) HasLinkNicVmIds() bool { + if o != nil && o.LinkNicVmIds != nil { + return true + } + + return false +} + +// SetLinkNicVmIds gets a reference to the given []string and assigns it to the LinkNicVmIds field. +func (o *FiltersNic) SetLinkNicVmIds(v []string) { + o.LinkNicVmIds = &v +} + +// GetNicIds returns the NicIds field value if set, zero value otherwise. +func (o *FiltersNic) GetNicIds() []string { + if o == nil || o.NicIds == nil { + var ret []string + return ret + } + return *o.NicIds +} + +// GetNicIdsOk returns a tuple with the NicIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNic) GetNicIdsOk() (*[]string, bool) { + if o == nil || o.NicIds == nil { + return nil, false + } + return o.NicIds, true +} + +// HasNicIds returns a boolean if a field has been set. +func (o *FiltersNic) HasNicIds() bool { + if o != nil && o.NicIds != nil { + return true + } + + return false +} + +// SetNicIds gets a reference to the given []string and assigns it to the NicIds field. +func (o *FiltersNic) SetNicIds(v []string) { + o.NicIds = &v +} + +// GetPrivateIpsPrivateIps returns the PrivateIpsPrivateIps field value if set, zero value otherwise. +func (o *FiltersNic) GetPrivateIpsPrivateIps() []string { + if o == nil || o.PrivateIpsPrivateIps == nil { + var ret []string + return ret + } + return *o.PrivateIpsPrivateIps +} + +// GetPrivateIpsPrivateIpsOk returns a tuple with the PrivateIpsPrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNic) GetPrivateIpsPrivateIpsOk() (*[]string, bool) { + if o == nil || o.PrivateIpsPrivateIps == nil { + return nil, false + } + return o.PrivateIpsPrivateIps, true +} + +// HasPrivateIpsPrivateIps returns a boolean if a field has been set. +func (o *FiltersNic) HasPrivateIpsPrivateIps() bool { + if o != nil && o.PrivateIpsPrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIpsPrivateIps gets a reference to the given []string and assigns it to the PrivateIpsPrivateIps field. +func (o *FiltersNic) SetPrivateIpsPrivateIps(v []string) { + o.PrivateIpsPrivateIps = &v +} + +// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. +func (o *FiltersNic) GetSubnetIds() []string { + if o == nil || o.SubnetIds == nil { + var ret []string + return ret + } + return *o.SubnetIds +} + +// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersNic) GetSubnetIdsOk() (*[]string, bool) { + if o == nil || o.SubnetIds == nil { + return nil, false + } + return o.SubnetIds, true +} + +// HasSubnetIds returns a boolean if a field has been set. +func (o *FiltersNic) HasSubnetIds() bool { + if o != nil && o.SubnetIds != nil { + return true + } + + return false +} + +// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. +func (o *FiltersNic) SetSubnetIds(v []string) { + o.SubnetIds = &v +} + +func (o FiltersNic) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkNicSortNumbers != nil { + toSerialize["LinkNicSortNumbers"] = o.LinkNicSortNumbers + } + if o.LinkNicVmIds != nil { + toSerialize["LinkNicVmIds"] = o.LinkNicVmIds + } + if o.NicIds != nil { + toSerialize["NicIds"] = o.NicIds + } + if o.PrivateIpsPrivateIps != nil { + toSerialize["PrivateIpsPrivateIps"] = o.PrivateIpsPrivateIps + } + if o.SubnetIds != nil { + toSerialize["SubnetIds"] = o.SubnetIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersNic struct { + value *FiltersNic + isSet bool +} + +func (v NullableFiltersNic) Get() *FiltersNic { + return v.value +} + +func (v *NullableFiltersNic) Set(val *FiltersNic) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersNic) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersNic) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersNic(val *FiltersNic) *NullableFiltersNic { + return &NullableFiltersNic{value: val, isSet: true} +} + +func (v NullableFiltersNic) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersNic) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go new file mode 100644 index 000000000..7b864a317 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersProductType One or more filters. +type FiltersProductType struct { + // The IDs of the product types. + ProductTypeIds *[]string `json:"ProductTypeIds,omitempty"` +} + +// NewFiltersProductType instantiates a new FiltersProductType object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersProductType() *FiltersProductType { + this := FiltersProductType{} + return &this +} + +// NewFiltersProductTypeWithDefaults instantiates a new FiltersProductType object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersProductTypeWithDefaults() *FiltersProductType { + this := FiltersProductType{} + return &this +} + +// GetProductTypeIds returns the ProductTypeIds field value if set, zero value otherwise. +func (o *FiltersProductType) GetProductTypeIds() []string { + if o == nil || o.ProductTypeIds == nil { + var ret []string + return ret + } + return *o.ProductTypeIds +} + +// GetProductTypeIdsOk returns a tuple with the ProductTypeIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersProductType) GetProductTypeIdsOk() (*[]string, bool) { + if o == nil || o.ProductTypeIds == nil { + return nil, false + } + return o.ProductTypeIds, true +} + +// HasProductTypeIds returns a boolean if a field has been set. +func (o *FiltersProductType) HasProductTypeIds() bool { + if o != nil && o.ProductTypeIds != nil { + return true + } + + return false +} + +// SetProductTypeIds gets a reference to the given []string and assigns it to the ProductTypeIds field. +func (o *FiltersProductType) SetProductTypeIds(v []string) { + o.ProductTypeIds = &v +} + +func (o FiltersProductType) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ProductTypeIds != nil { + toSerialize["ProductTypeIds"] = o.ProductTypeIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersProductType struct { + value *FiltersProductType + isSet bool +} + +func (v NullableFiltersProductType) Get() *FiltersProductType { + return v.value +} + +func (v *NullableFiltersProductType) Set(val *FiltersProductType) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersProductType) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersProductType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersProductType(val *FiltersProductType) *NullableFiltersProductType { + return &NullableFiltersProductType{value: val, isSet: true} +} + +func (v NullableFiltersProductType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersProductType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go new file mode 100644 index 000000000..bf36a2b57 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go @@ -0,0 +1,487 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersPublicIp One or more filters. +type FiltersPublicIp struct { + // The IDs representing the associations of EIPs with VMs or NICs. + LinkPublicIpIds *[]string `json:"LinkPublicIpIds,omitempty"` + // The account IDs of the owners of the NICs. + NicAccountIds *[]string `json:"NicAccountIds,omitempty"` + // The IDs of the NICs. + NicIds *[]string `json:"NicIds,omitempty"` + // Whether the EIPs are for use in the public Cloud or in a Net. + Placements *[]string `json:"Placements,omitempty"` + // The private IP addresses associated with the EIPs. + PrivateIps *[]string `json:"PrivateIps,omitempty"` + // The IDs of the External IP addresses (EIPs). + PublicIpIds *[]string `json:"PublicIpIds,omitempty"` + // The External IP addresses (EIPs). + PublicIps *[]string `json:"PublicIps,omitempty"` + // The keys of the tags associated with the EIPs. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the EIPs. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the EIPs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The IDs of the VMs. + VmIds *[]string `json:"VmIds,omitempty"` +} + +// NewFiltersPublicIp instantiates a new FiltersPublicIp object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersPublicIp() *FiltersPublicIp { + this := FiltersPublicIp{} + return &this +} + +// NewFiltersPublicIpWithDefaults instantiates a new FiltersPublicIp object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersPublicIpWithDefaults() *FiltersPublicIp { + this := FiltersPublicIp{} + return &this +} + +// GetLinkPublicIpIds returns the LinkPublicIpIds field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetLinkPublicIpIds() []string { + if o == nil || o.LinkPublicIpIds == nil { + var ret []string + return ret + } + return *o.LinkPublicIpIds +} + +// GetLinkPublicIpIdsOk returns a tuple with the LinkPublicIpIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetLinkPublicIpIdsOk() (*[]string, bool) { + if o == nil || o.LinkPublicIpIds == nil { + return nil, false + } + return o.LinkPublicIpIds, true +} + +// HasLinkPublicIpIds returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasLinkPublicIpIds() bool { + if o != nil && o.LinkPublicIpIds != nil { + return true + } + + return false +} + +// SetLinkPublicIpIds gets a reference to the given []string and assigns it to the LinkPublicIpIds field. +func (o *FiltersPublicIp) SetLinkPublicIpIds(v []string) { + o.LinkPublicIpIds = &v +} + +// GetNicAccountIds returns the NicAccountIds field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetNicAccountIds() []string { + if o == nil || o.NicAccountIds == nil { + var ret []string + return ret + } + return *o.NicAccountIds +} + +// GetNicAccountIdsOk returns a tuple with the NicAccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetNicAccountIdsOk() (*[]string, bool) { + if o == nil || o.NicAccountIds == nil { + return nil, false + } + return o.NicAccountIds, true +} + +// HasNicAccountIds returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasNicAccountIds() bool { + if o != nil && o.NicAccountIds != nil { + return true + } + + return false +} + +// SetNicAccountIds gets a reference to the given []string and assigns it to the NicAccountIds field. +func (o *FiltersPublicIp) SetNicAccountIds(v []string) { + o.NicAccountIds = &v +} + +// GetNicIds returns the NicIds field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetNicIds() []string { + if o == nil || o.NicIds == nil { + var ret []string + return ret + } + return *o.NicIds +} + +// GetNicIdsOk returns a tuple with the NicIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetNicIdsOk() (*[]string, bool) { + if o == nil || o.NicIds == nil { + return nil, false + } + return o.NicIds, true +} + +// HasNicIds returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasNicIds() bool { + if o != nil && o.NicIds != nil { + return true + } + + return false +} + +// SetNicIds gets a reference to the given []string and assigns it to the NicIds field. +func (o *FiltersPublicIp) SetNicIds(v []string) { + o.NicIds = &v +} + +// GetPlacements returns the Placements field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetPlacements() []string { + if o == nil || o.Placements == nil { + var ret []string + return ret + } + return *o.Placements +} + +// GetPlacementsOk returns a tuple with the Placements field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetPlacementsOk() (*[]string, bool) { + if o == nil || o.Placements == nil { + return nil, false + } + return o.Placements, true +} + +// HasPlacements returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasPlacements() bool { + if o != nil && o.Placements != nil { + return true + } + + return false +} + +// SetPlacements gets a reference to the given []string and assigns it to the Placements field. +func (o *FiltersPublicIp) SetPlacements(v []string) { + o.Placements = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetPrivateIps() []string { + if o == nil || o.PrivateIps == nil { + var ret []string + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetPrivateIpsOk() (*[]string, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. +func (o *FiltersPublicIp) SetPrivateIps(v []string) { + o.PrivateIps = &v +} + +// GetPublicIpIds returns the PublicIpIds field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetPublicIpIds() []string { + if o == nil || o.PublicIpIds == nil { + var ret []string + return ret + } + return *o.PublicIpIds +} + +// GetPublicIpIdsOk returns a tuple with the PublicIpIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetPublicIpIdsOk() (*[]string, bool) { + if o == nil || o.PublicIpIds == nil { + return nil, false + } + return o.PublicIpIds, true +} + +// HasPublicIpIds returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasPublicIpIds() bool { + if o != nil && o.PublicIpIds != nil { + return true + } + + return false +} + +// SetPublicIpIds gets a reference to the given []string and assigns it to the PublicIpIds field. +func (o *FiltersPublicIp) SetPublicIpIds(v []string) { + o.PublicIpIds = &v +} + +// GetPublicIps returns the PublicIps field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetPublicIps() []string { + if o == nil || o.PublicIps == nil { + var ret []string + return ret + } + return *o.PublicIps +} + +// GetPublicIpsOk returns a tuple with the PublicIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetPublicIpsOk() (*[]string, bool) { + if o == nil || o.PublicIps == nil { + return nil, false + } + return o.PublicIps, true +} + +// HasPublicIps returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasPublicIps() bool { + if o != nil && o.PublicIps != nil { + return true + } + + return false +} + +// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. +func (o *FiltersPublicIp) SetPublicIps(v []string) { + o.PublicIps = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersPublicIp) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersPublicIp) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersPublicIp) SetTags(v []string) { + o.Tags = &v +} + +// GetVmIds returns the VmIds field value if set, zero value otherwise. +func (o *FiltersPublicIp) GetVmIds() []string { + if o == nil || o.VmIds == nil { + var ret []string + return ret + } + return *o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersPublicIp) GetVmIdsOk() (*[]string, bool) { + if o == nil || o.VmIds == nil { + return nil, false + } + return o.VmIds, true +} + +// HasVmIds returns a boolean if a field has been set. +func (o *FiltersPublicIp) HasVmIds() bool { + if o != nil && o.VmIds != nil { + return true + } + + return false +} + +// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. +func (o *FiltersPublicIp) SetVmIds(v []string) { + o.VmIds = &v +} + +func (o FiltersPublicIp) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkPublicIpIds != nil { + toSerialize["LinkPublicIpIds"] = o.LinkPublicIpIds + } + if o.NicAccountIds != nil { + toSerialize["NicAccountIds"] = o.NicAccountIds + } + if o.NicIds != nil { + toSerialize["NicIds"] = o.NicIds + } + if o.Placements != nil { + toSerialize["Placements"] = o.Placements + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.PublicIpIds != nil { + toSerialize["PublicIpIds"] = o.PublicIpIds + } + if o.PublicIps != nil { + toSerialize["PublicIps"] = o.PublicIps + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VmIds != nil { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersPublicIp struct { + value *FiltersPublicIp + isSet bool +} + +func (v NullableFiltersPublicIp) Get() *FiltersPublicIp { + return v.value +} + +func (v *NullableFiltersPublicIp) Set(val *FiltersPublicIp) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersPublicIp) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersPublicIp) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersPublicIp(val *FiltersPublicIp) *NullableFiltersPublicIp { + return &NullableFiltersPublicIp{value: val, isSet: true} +} + +func (v NullableFiltersPublicIp) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersPublicIp) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go new file mode 100644 index 000000000..bb8137206 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersQuota One or more filters. +type FiltersQuota struct { + // The group names of the quotas. + Collections *[]string `json:"Collections,omitempty"` + // The names of the quotas. + QuotaNames *[]string `json:"QuotaNames,omitempty"` + // The resource IDs if these are resource-specific quotas, `global` if they are not. + QuotaTypes *[]string `json:"QuotaTypes,omitempty"` + // The description of the quotas. + ShortDescriptions *[]string `json:"ShortDescriptions,omitempty"` +} + +// NewFiltersQuota instantiates a new FiltersQuota object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersQuota() *FiltersQuota { + this := FiltersQuota{} + return &this +} + +// NewFiltersQuotaWithDefaults instantiates a new FiltersQuota object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersQuotaWithDefaults() *FiltersQuota { + this := FiltersQuota{} + return &this +} + +// GetCollections returns the Collections field value if set, zero value otherwise. +func (o *FiltersQuota) GetCollections() []string { + if o == nil || o.Collections == nil { + var ret []string + return ret + } + return *o.Collections +} + +// GetCollectionsOk returns a tuple with the Collections field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersQuota) GetCollectionsOk() (*[]string, bool) { + if o == nil || o.Collections == nil { + return nil, false + } + return o.Collections, true +} + +// HasCollections returns a boolean if a field has been set. +func (o *FiltersQuota) HasCollections() bool { + if o != nil && o.Collections != nil { + return true + } + + return false +} + +// SetCollections gets a reference to the given []string and assigns it to the Collections field. +func (o *FiltersQuota) SetCollections(v []string) { + o.Collections = &v +} + +// GetQuotaNames returns the QuotaNames field value if set, zero value otherwise. +func (o *FiltersQuota) GetQuotaNames() []string { + if o == nil || o.QuotaNames == nil { + var ret []string + return ret + } + return *o.QuotaNames +} + +// GetQuotaNamesOk returns a tuple with the QuotaNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersQuota) GetQuotaNamesOk() (*[]string, bool) { + if o == nil || o.QuotaNames == nil { + return nil, false + } + return o.QuotaNames, true +} + +// HasQuotaNames returns a boolean if a field has been set. +func (o *FiltersQuota) HasQuotaNames() bool { + if o != nil && o.QuotaNames != nil { + return true + } + + return false +} + +// SetQuotaNames gets a reference to the given []string and assigns it to the QuotaNames field. +func (o *FiltersQuota) SetQuotaNames(v []string) { + o.QuotaNames = &v +} + +// GetQuotaTypes returns the QuotaTypes field value if set, zero value otherwise. +func (o *FiltersQuota) GetQuotaTypes() []string { + if o == nil || o.QuotaTypes == nil { + var ret []string + return ret + } + return *o.QuotaTypes +} + +// GetQuotaTypesOk returns a tuple with the QuotaTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersQuota) GetQuotaTypesOk() (*[]string, bool) { + if o == nil || o.QuotaTypes == nil { + return nil, false + } + return o.QuotaTypes, true +} + +// HasQuotaTypes returns a boolean if a field has been set. +func (o *FiltersQuota) HasQuotaTypes() bool { + if o != nil && o.QuotaTypes != nil { + return true + } + + return false +} + +// SetQuotaTypes gets a reference to the given []string and assigns it to the QuotaTypes field. +func (o *FiltersQuota) SetQuotaTypes(v []string) { + o.QuotaTypes = &v +} + +// GetShortDescriptions returns the ShortDescriptions field value if set, zero value otherwise. +func (o *FiltersQuota) GetShortDescriptions() []string { + if o == nil || o.ShortDescriptions == nil { + var ret []string + return ret + } + return *o.ShortDescriptions +} + +// GetShortDescriptionsOk returns a tuple with the ShortDescriptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersQuota) GetShortDescriptionsOk() (*[]string, bool) { + if o == nil || o.ShortDescriptions == nil { + return nil, false + } + return o.ShortDescriptions, true +} + +// HasShortDescriptions returns a boolean if a field has been set. +func (o *FiltersQuota) HasShortDescriptions() bool { + if o != nil && o.ShortDescriptions != nil { + return true + } + + return false +} + +// SetShortDescriptions gets a reference to the given []string and assigns it to the ShortDescriptions field. +func (o *FiltersQuota) SetShortDescriptions(v []string) { + o.ShortDescriptions = &v +} + +func (o FiltersQuota) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Collections != nil { + toSerialize["Collections"] = o.Collections + } + if o.QuotaNames != nil { + toSerialize["QuotaNames"] = o.QuotaNames + } + if o.QuotaTypes != nil { + toSerialize["QuotaTypes"] = o.QuotaTypes + } + if o.ShortDescriptions != nil { + toSerialize["ShortDescriptions"] = o.ShortDescriptions + } + return json.Marshal(toSerialize) +} + +type NullableFiltersQuota struct { + value *FiltersQuota + isSet bool +} + +func (v NullableFiltersQuota) Get() *FiltersQuota { + return v.value +} + +func (v *NullableFiltersQuota) Set(val *FiltersQuota) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersQuota) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersQuota) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersQuota(val *FiltersQuota) *NullableFiltersQuota { + return &NullableFiltersQuota{value: val, isSet: true} +} + +func (v NullableFiltersQuota) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersQuota) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go new file mode 100644 index 000000000..8bfebe042 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go @@ -0,0 +1,709 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersRouteTable One or more filters. +type FiltersRouteTable struct { + // The IDs of the route tables involved in the associations. + LinkRouteTableIds *[]string `json:"LinkRouteTableIds,omitempty"` + // The IDs of the associations between the route tables and the Subnets. + LinkRouteTableLinkRouteTableIds *[]string `json:"LinkRouteTableLinkRouteTableIds,omitempty"` + // If `true`, the route tables are the main ones for their Nets. + LinkRouteTableMain *bool `json:"LinkRouteTableMain,omitempty"` + // The IDs of the Subnets involved in the associations. + LinkSubnetIds *[]string `json:"LinkSubnetIds,omitempty"` + // The IDs of the Nets for the route tables. + NetIds *[]string `json:"NetIds,omitempty"` + // The methods used to create a route. + RouteCreationMethods *[]string `json:"RouteCreationMethods,omitempty"` + // The IP ranges specified in routes in the tables. + RouteDestinationIpRanges *[]string `json:"RouteDestinationIpRanges,omitempty"` + // The service IDs specified in routes in the tables. + RouteDestinationServiceIds *[]string `json:"RouteDestinationServiceIds,omitempty"` + // The IDs of the gateways specified in routes in the tables. + RouteGatewayIds *[]string `json:"RouteGatewayIds,omitempty"` + // The IDs of the NAT services specified in routes in the tables. + RouteNatServiceIds *[]string `json:"RouteNatServiceIds,omitempty"` + // The IDs of the Net peering connections specified in routes in the tables. + RouteNetPeeringIds *[]string `json:"RouteNetPeeringIds,omitempty"` + // The states of routes in the route tables (`active` \\| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + RouteStates *[]string `json:"RouteStates,omitempty"` + // The IDs of the route tables. + RouteTableIds *[]string `json:"RouteTableIds,omitempty"` + // The IDs of the VMs specified in routes in the tables. + RouteVmIds *[]string `json:"RouteVmIds,omitempty"` + // The keys of the tags associated with the route tables. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the route tables. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the route tables, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersRouteTable instantiates a new FiltersRouteTable object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersRouteTable() *FiltersRouteTable { + this := FiltersRouteTable{} + return &this +} + +// NewFiltersRouteTableWithDefaults instantiates a new FiltersRouteTable object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersRouteTableWithDefaults() *FiltersRouteTable { + this := FiltersRouteTable{} + return &this +} + +// GetLinkRouteTableIds returns the LinkRouteTableIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetLinkRouteTableIds() []string { + if o == nil || o.LinkRouteTableIds == nil { + var ret []string + return ret + } + return *o.LinkRouteTableIds +} + +// GetLinkRouteTableIdsOk returns a tuple with the LinkRouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetLinkRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.LinkRouteTableIds == nil { + return nil, false + } + return o.LinkRouteTableIds, true +} + +// HasLinkRouteTableIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasLinkRouteTableIds() bool { + if o != nil && o.LinkRouteTableIds != nil { + return true + } + + return false +} + +// SetLinkRouteTableIds gets a reference to the given []string and assigns it to the LinkRouteTableIds field. +func (o *FiltersRouteTable) SetLinkRouteTableIds(v []string) { + o.LinkRouteTableIds = &v +} + +// GetLinkRouteTableLinkRouteTableIds returns the LinkRouteTableLinkRouteTableIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetLinkRouteTableLinkRouteTableIds() []string { + if o == nil || o.LinkRouteTableLinkRouteTableIds == nil { + var ret []string + return ret + } + return *o.LinkRouteTableLinkRouteTableIds +} + +// GetLinkRouteTableLinkRouteTableIdsOk returns a tuple with the LinkRouteTableLinkRouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetLinkRouteTableLinkRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.LinkRouteTableLinkRouteTableIds == nil { + return nil, false + } + return o.LinkRouteTableLinkRouteTableIds, true +} + +// HasLinkRouteTableLinkRouteTableIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasLinkRouteTableLinkRouteTableIds() bool { + if o != nil && o.LinkRouteTableLinkRouteTableIds != nil { + return true + } + + return false +} + +// SetLinkRouteTableLinkRouteTableIds gets a reference to the given []string and assigns it to the LinkRouteTableLinkRouteTableIds field. +func (o *FiltersRouteTable) SetLinkRouteTableLinkRouteTableIds(v []string) { + o.LinkRouteTableLinkRouteTableIds = &v +} + +// GetLinkRouteTableMain returns the LinkRouteTableMain field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetLinkRouteTableMain() bool { + if o == nil || o.LinkRouteTableMain == nil { + var ret bool + return ret + } + return *o.LinkRouteTableMain +} + +// GetLinkRouteTableMainOk returns a tuple with the LinkRouteTableMain field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetLinkRouteTableMainOk() (*bool, bool) { + if o == nil || o.LinkRouteTableMain == nil { + return nil, false + } + return o.LinkRouteTableMain, true +} + +// HasLinkRouteTableMain returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasLinkRouteTableMain() bool { + if o != nil && o.LinkRouteTableMain != nil { + return true + } + + return false +} + +// SetLinkRouteTableMain gets a reference to the given bool and assigns it to the LinkRouteTableMain field. +func (o *FiltersRouteTable) SetLinkRouteTableMain(v bool) { + o.LinkRouteTableMain = &v +} + +// GetLinkSubnetIds returns the LinkSubnetIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetLinkSubnetIds() []string { + if o == nil || o.LinkSubnetIds == nil { + var ret []string + return ret + } + return *o.LinkSubnetIds +} + +// GetLinkSubnetIdsOk returns a tuple with the LinkSubnetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetLinkSubnetIdsOk() (*[]string, bool) { + if o == nil || o.LinkSubnetIds == nil { + return nil, false + } + return o.LinkSubnetIds, true +} + +// HasLinkSubnetIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasLinkSubnetIds() bool { + if o != nil && o.LinkSubnetIds != nil { + return true + } + + return false +} + +// SetLinkSubnetIds gets a reference to the given []string and assigns it to the LinkSubnetIds field. +func (o *FiltersRouteTable) SetLinkSubnetIds(v []string) { + o.LinkSubnetIds = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersRouteTable) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetRouteCreationMethods returns the RouteCreationMethods field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteCreationMethods() []string { + if o == nil || o.RouteCreationMethods == nil { + var ret []string + return ret + } + return *o.RouteCreationMethods +} + +// GetRouteCreationMethodsOk returns a tuple with the RouteCreationMethods field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteCreationMethodsOk() (*[]string, bool) { + if o == nil || o.RouteCreationMethods == nil { + return nil, false + } + return o.RouteCreationMethods, true +} + +// HasRouteCreationMethods returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteCreationMethods() bool { + if o != nil && o.RouteCreationMethods != nil { + return true + } + + return false +} + +// SetRouteCreationMethods gets a reference to the given []string and assigns it to the RouteCreationMethods field. +func (o *FiltersRouteTable) SetRouteCreationMethods(v []string) { + o.RouteCreationMethods = &v +} + +// GetRouteDestinationIpRanges returns the RouteDestinationIpRanges field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteDestinationIpRanges() []string { + if o == nil || o.RouteDestinationIpRanges == nil { + var ret []string + return ret + } + return *o.RouteDestinationIpRanges +} + +// GetRouteDestinationIpRangesOk returns a tuple with the RouteDestinationIpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteDestinationIpRangesOk() (*[]string, bool) { + if o == nil || o.RouteDestinationIpRanges == nil { + return nil, false + } + return o.RouteDestinationIpRanges, true +} + +// HasRouteDestinationIpRanges returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteDestinationIpRanges() bool { + if o != nil && o.RouteDestinationIpRanges != nil { + return true + } + + return false +} + +// SetRouteDestinationIpRanges gets a reference to the given []string and assigns it to the RouteDestinationIpRanges field. +func (o *FiltersRouteTable) SetRouteDestinationIpRanges(v []string) { + o.RouteDestinationIpRanges = &v +} + +// GetRouteDestinationServiceIds returns the RouteDestinationServiceIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteDestinationServiceIds() []string { + if o == nil || o.RouteDestinationServiceIds == nil { + var ret []string + return ret + } + return *o.RouteDestinationServiceIds +} + +// GetRouteDestinationServiceIdsOk returns a tuple with the RouteDestinationServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteDestinationServiceIdsOk() (*[]string, bool) { + if o == nil || o.RouteDestinationServiceIds == nil { + return nil, false + } + return o.RouteDestinationServiceIds, true +} + +// HasRouteDestinationServiceIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteDestinationServiceIds() bool { + if o != nil && o.RouteDestinationServiceIds != nil { + return true + } + + return false +} + +// SetRouteDestinationServiceIds gets a reference to the given []string and assigns it to the RouteDestinationServiceIds field. +func (o *FiltersRouteTable) SetRouteDestinationServiceIds(v []string) { + o.RouteDestinationServiceIds = &v +} + +// GetRouteGatewayIds returns the RouteGatewayIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteGatewayIds() []string { + if o == nil || o.RouteGatewayIds == nil { + var ret []string + return ret + } + return *o.RouteGatewayIds +} + +// GetRouteGatewayIdsOk returns a tuple with the RouteGatewayIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteGatewayIdsOk() (*[]string, bool) { + if o == nil || o.RouteGatewayIds == nil { + return nil, false + } + return o.RouteGatewayIds, true +} + +// HasRouteGatewayIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteGatewayIds() bool { + if o != nil && o.RouteGatewayIds != nil { + return true + } + + return false +} + +// SetRouteGatewayIds gets a reference to the given []string and assigns it to the RouteGatewayIds field. +func (o *FiltersRouteTable) SetRouteGatewayIds(v []string) { + o.RouteGatewayIds = &v +} + +// GetRouteNatServiceIds returns the RouteNatServiceIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteNatServiceIds() []string { + if o == nil || o.RouteNatServiceIds == nil { + var ret []string + return ret + } + return *o.RouteNatServiceIds +} + +// GetRouteNatServiceIdsOk returns a tuple with the RouteNatServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteNatServiceIdsOk() (*[]string, bool) { + if o == nil || o.RouteNatServiceIds == nil { + return nil, false + } + return o.RouteNatServiceIds, true +} + +// HasRouteNatServiceIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteNatServiceIds() bool { + if o != nil && o.RouteNatServiceIds != nil { + return true + } + + return false +} + +// SetRouteNatServiceIds gets a reference to the given []string and assigns it to the RouteNatServiceIds field. +func (o *FiltersRouteTable) SetRouteNatServiceIds(v []string) { + o.RouteNatServiceIds = &v +} + +// GetRouteNetPeeringIds returns the RouteNetPeeringIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteNetPeeringIds() []string { + if o == nil || o.RouteNetPeeringIds == nil { + var ret []string + return ret + } + return *o.RouteNetPeeringIds +} + +// GetRouteNetPeeringIdsOk returns a tuple with the RouteNetPeeringIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteNetPeeringIdsOk() (*[]string, bool) { + if o == nil || o.RouteNetPeeringIds == nil { + return nil, false + } + return o.RouteNetPeeringIds, true +} + +// HasRouteNetPeeringIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteNetPeeringIds() bool { + if o != nil && o.RouteNetPeeringIds != nil { + return true + } + + return false +} + +// SetRouteNetPeeringIds gets a reference to the given []string and assigns it to the RouteNetPeeringIds field. +func (o *FiltersRouteTable) SetRouteNetPeeringIds(v []string) { + o.RouteNetPeeringIds = &v +} + +// GetRouteStates returns the RouteStates field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteStates() []string { + if o == nil || o.RouteStates == nil { + var ret []string + return ret + } + return *o.RouteStates +} + +// GetRouteStatesOk returns a tuple with the RouteStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteStatesOk() (*[]string, bool) { + if o == nil || o.RouteStates == nil { + return nil, false + } + return o.RouteStates, true +} + +// HasRouteStates returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteStates() bool { + if o != nil && o.RouteStates != nil { + return true + } + + return false +} + +// SetRouteStates gets a reference to the given []string and assigns it to the RouteStates field. +func (o *FiltersRouteTable) SetRouteStates(v []string) { + o.RouteStates = &v +} + +// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteTableIds() []string { + if o == nil || o.RouteTableIds == nil { + var ret []string + return ret + } + return *o.RouteTableIds +} + +// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.RouteTableIds == nil { + return nil, false + } + return o.RouteTableIds, true +} + +// HasRouteTableIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteTableIds() bool { + if o != nil && o.RouteTableIds != nil { + return true + } + + return false +} + +// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. +func (o *FiltersRouteTable) SetRouteTableIds(v []string) { + o.RouteTableIds = &v +} + +// GetRouteVmIds returns the RouteVmIds field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetRouteVmIds() []string { + if o == nil || o.RouteVmIds == nil { + var ret []string + return ret + } + return *o.RouteVmIds +} + +// GetRouteVmIdsOk returns a tuple with the RouteVmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetRouteVmIdsOk() (*[]string, bool) { + if o == nil || o.RouteVmIds == nil { + return nil, false + } + return o.RouteVmIds, true +} + +// HasRouteVmIds returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasRouteVmIds() bool { + if o != nil && o.RouteVmIds != nil { + return true + } + + return false +} + +// SetRouteVmIds gets a reference to the given []string and assigns it to the RouteVmIds field. +func (o *FiltersRouteTable) SetRouteVmIds(v []string) { + o.RouteVmIds = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersRouteTable) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersRouteTable) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersRouteTable) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersRouteTable) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersRouteTable) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersRouteTable) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersRouteTable) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkRouteTableIds != nil { + toSerialize["LinkRouteTableIds"] = o.LinkRouteTableIds + } + if o.LinkRouteTableLinkRouteTableIds != nil { + toSerialize["LinkRouteTableLinkRouteTableIds"] = o.LinkRouteTableLinkRouteTableIds + } + if o.LinkRouteTableMain != nil { + toSerialize["LinkRouteTableMain"] = o.LinkRouteTableMain + } + if o.LinkSubnetIds != nil { + toSerialize["LinkSubnetIds"] = o.LinkSubnetIds + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.RouteCreationMethods != nil { + toSerialize["RouteCreationMethods"] = o.RouteCreationMethods + } + if o.RouteDestinationIpRanges != nil { + toSerialize["RouteDestinationIpRanges"] = o.RouteDestinationIpRanges + } + if o.RouteDestinationServiceIds != nil { + toSerialize["RouteDestinationServiceIds"] = o.RouteDestinationServiceIds + } + if o.RouteGatewayIds != nil { + toSerialize["RouteGatewayIds"] = o.RouteGatewayIds + } + if o.RouteNatServiceIds != nil { + toSerialize["RouteNatServiceIds"] = o.RouteNatServiceIds + } + if o.RouteNetPeeringIds != nil { + toSerialize["RouteNetPeeringIds"] = o.RouteNetPeeringIds + } + if o.RouteStates != nil { + toSerialize["RouteStates"] = o.RouteStates + } + if o.RouteTableIds != nil { + toSerialize["RouteTableIds"] = o.RouteTableIds + } + if o.RouteVmIds != nil { + toSerialize["RouteVmIds"] = o.RouteVmIds + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersRouteTable struct { + value *FiltersRouteTable + isSet bool +} + +func (v NullableFiltersRouteTable) Get() *FiltersRouteTable { + return v.value +} + +func (v *NullableFiltersRouteTable) Set(val *FiltersRouteTable) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersRouteTable) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersRouteTable) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersRouteTable(val *FiltersRouteTable) *NullableFiltersRouteTable { + return &NullableFiltersRouteTable{value: val, isSet: true} +} + +func (v NullableFiltersRouteTable) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersRouteTable) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go new file mode 100644 index 000000000..97bfffa7a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersSecurityGroup One or more filters. +type FiltersSecurityGroup struct { + // The account IDs of the owners of the security groups. + AccountIds *[]string `json:"AccountIds,omitempty"` + // The IDs of the Nets specified when the security groups were created. + NetIds *[]string `json:"NetIds,omitempty"` + // The IDs of the security groups. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` + // The names of the security groups. + SecurityGroupNames *[]string `json:"SecurityGroupNames,omitempty"` + // The keys of the tags associated with the security groups. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the security groups. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the security groups, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersSecurityGroup instantiates a new FiltersSecurityGroup object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersSecurityGroup() *FiltersSecurityGroup { + this := FiltersSecurityGroup{} + return &this +} + +// NewFiltersSecurityGroupWithDefaults instantiates a new FiltersSecurityGroup object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersSecurityGroupWithDefaults() *FiltersSecurityGroup { + this := FiltersSecurityGroup{} + return &this +} + +// GetAccountIds returns the AccountIds field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetAccountIds() []string { + if o == nil || o.AccountIds == nil { + var ret []string + return ret + } + return *o.AccountIds +} + +// GetAccountIdsOk returns a tuple with the AccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetAccountIdsOk() (*[]string, bool) { + if o == nil || o.AccountIds == nil { + return nil, false + } + return o.AccountIds, true +} + +// HasAccountIds returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasAccountIds() bool { + if o != nil && o.AccountIds != nil { + return true + } + + return false +} + +// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. +func (o *FiltersSecurityGroup) SetAccountIds(v []string) { + o.AccountIds = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersSecurityGroup) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *FiltersSecurityGroup) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +// GetSecurityGroupNames returns the SecurityGroupNames field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetSecurityGroupNames() []string { + if o == nil || o.SecurityGroupNames == nil { + var ret []string + return ret + } + return *o.SecurityGroupNames +} + +// GetSecurityGroupNamesOk returns a tuple with the SecurityGroupNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetSecurityGroupNamesOk() (*[]string, bool) { + if o == nil || o.SecurityGroupNames == nil { + return nil, false + } + return o.SecurityGroupNames, true +} + +// HasSecurityGroupNames returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasSecurityGroupNames() bool { + if o != nil && o.SecurityGroupNames != nil { + return true + } + + return false +} + +// SetSecurityGroupNames gets a reference to the given []string and assigns it to the SecurityGroupNames field. +func (o *FiltersSecurityGroup) SetSecurityGroupNames(v []string) { + o.SecurityGroupNames = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersSecurityGroup) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersSecurityGroup) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersSecurityGroup) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSecurityGroup) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersSecurityGroup) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersSecurityGroup) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersSecurityGroup) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountIds != nil { + toSerialize["AccountIds"] = o.AccountIds + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + if o.SecurityGroupNames != nil { + toSerialize["SecurityGroupNames"] = o.SecurityGroupNames + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersSecurityGroup struct { + value *FiltersSecurityGroup + isSet bool +} + +func (v NullableFiltersSecurityGroup) Get() *FiltersSecurityGroup { + return v.value +} + +func (v *NullableFiltersSecurityGroup) Set(val *FiltersSecurityGroup) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersSecurityGroup) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersSecurityGroup) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersSecurityGroup(val *FiltersSecurityGroup) *NullableFiltersSecurityGroup { + return &NullableFiltersSecurityGroup{value: val, isSet: true} +} + +func (v NullableFiltersSecurityGroup) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersSecurityGroup) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go new file mode 100644 index 000000000..761cd658e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersServerCertificate One or more filters. +type FiltersServerCertificate struct { + // The path to the server certificate. + Paths *string `json:"Paths,omitempty"` +} + +// NewFiltersServerCertificate instantiates a new FiltersServerCertificate object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersServerCertificate() *FiltersServerCertificate { + this := FiltersServerCertificate{} + return &this +} + +// NewFiltersServerCertificateWithDefaults instantiates a new FiltersServerCertificate object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersServerCertificateWithDefaults() *FiltersServerCertificate { + this := FiltersServerCertificate{} + return &this +} + +// GetPaths returns the Paths field value if set, zero value otherwise. +func (o *FiltersServerCertificate) GetPaths() string { + if o == nil || o.Paths == nil { + var ret string + return ret + } + return *o.Paths +} + +// GetPathsOk returns a tuple with the Paths field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersServerCertificate) GetPathsOk() (*string, bool) { + if o == nil || o.Paths == nil { + return nil, false + } + return o.Paths, true +} + +// HasPaths returns a boolean if a field has been set. +func (o *FiltersServerCertificate) HasPaths() bool { + if o != nil && o.Paths != nil { + return true + } + + return false +} + +// SetPaths gets a reference to the given string and assigns it to the Paths field. +func (o *FiltersServerCertificate) SetPaths(v string) { + o.Paths = &v +} + +func (o FiltersServerCertificate) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Paths != nil { + toSerialize["Paths"] = o.Paths + } + return json.Marshal(toSerialize) +} + +type NullableFiltersServerCertificate struct { + value *FiltersServerCertificate + isSet bool +} + +func (v NullableFiltersServerCertificate) Get() *FiltersServerCertificate { + return v.value +} + +func (v *NullableFiltersServerCertificate) Set(val *FiltersServerCertificate) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersServerCertificate) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersServerCertificate) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersServerCertificate(val *FiltersServerCertificate) *NullableFiltersServerCertificate { + return &NullableFiltersServerCertificate{value: val, isSet: true} +} + +func (v NullableFiltersServerCertificate) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersServerCertificate) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go new file mode 100644 index 000000000..addeb30cb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersService One or more filters. +type FiltersService struct { + // The IDs of the services. + ServiceIds *[]string `json:"ServiceIds,omitempty"` + // The names of the prefix lists, which identify the 3DS OUTSCALE services they are associated with. + ServiceNames *[]string `json:"ServiceNames,omitempty"` +} + +// NewFiltersService instantiates a new FiltersService object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersService() *FiltersService { + this := FiltersService{} + return &this +} + +// NewFiltersServiceWithDefaults instantiates a new FiltersService object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersServiceWithDefaults() *FiltersService { + this := FiltersService{} + return &this +} + +// GetServiceIds returns the ServiceIds field value if set, zero value otherwise. +func (o *FiltersService) GetServiceIds() []string { + if o == nil || o.ServiceIds == nil { + var ret []string + return ret + } + return *o.ServiceIds +} + +// GetServiceIdsOk returns a tuple with the ServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersService) GetServiceIdsOk() (*[]string, bool) { + if o == nil || o.ServiceIds == nil { + return nil, false + } + return o.ServiceIds, true +} + +// HasServiceIds returns a boolean if a field has been set. +func (o *FiltersService) HasServiceIds() bool { + if o != nil && o.ServiceIds != nil { + return true + } + + return false +} + +// SetServiceIds gets a reference to the given []string and assigns it to the ServiceIds field. +func (o *FiltersService) SetServiceIds(v []string) { + o.ServiceIds = &v +} + +// GetServiceNames returns the ServiceNames field value if set, zero value otherwise. +func (o *FiltersService) GetServiceNames() []string { + if o == nil || o.ServiceNames == nil { + var ret []string + return ret + } + return *o.ServiceNames +} + +// GetServiceNamesOk returns a tuple with the ServiceNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersService) GetServiceNamesOk() (*[]string, bool) { + if o == nil || o.ServiceNames == nil { + return nil, false + } + return o.ServiceNames, true +} + +// HasServiceNames returns a boolean if a field has been set. +func (o *FiltersService) HasServiceNames() bool { + if o != nil && o.ServiceNames != nil { + return true + } + + return false +} + +// SetServiceNames gets a reference to the given []string and assigns it to the ServiceNames field. +func (o *FiltersService) SetServiceNames(v []string) { + o.ServiceNames = &v +} + +func (o FiltersService) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ServiceIds != nil { + toSerialize["ServiceIds"] = o.ServiceIds + } + if o.ServiceNames != nil { + toSerialize["ServiceNames"] = o.ServiceNames + } + return json.Marshal(toSerialize) +} + +type NullableFiltersService struct { + value *FiltersService + isSet bool +} + +func (v NullableFiltersService) Get() *FiltersService { + return v.value +} + +func (v *NullableFiltersService) Set(val *FiltersService) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersService) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersService(val *FiltersService) *NullableFiltersService { + return &NullableFiltersService{value: val, isSet: true} +} + +func (v NullableFiltersService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go new file mode 100644 index 000000000..dce35987c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go @@ -0,0 +1,561 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersSnapshot One or more filters. +type FiltersSnapshot struct { + // The account aliases of the owners of the snapshots. + AccountAliases *[]string `json:"AccountAliases,omitempty"` + // The account IDs of the owners of the snapshots. + AccountIds *[]string `json:"AccountIds,omitempty"` + // The descriptions of the snapshots. + Descriptions *[]string `json:"Descriptions,omitempty"` + // The account IDs of one or more users who have permissions to create volumes. + PermissionsToCreateVolumeAccountIds *[]string `json:"PermissionsToCreateVolumeAccountIds,omitempty"` + // If `true`, lists all public volumes. If `false`, lists all private volumes. + PermissionsToCreateVolumeGlobalPermission *bool `json:"PermissionsToCreateVolumeGlobalPermission,omitempty"` + // The progresses of the snapshots, as a percentage. + Progresses *[]int32 `json:"Progresses,omitempty"` + // The IDs of the snapshots. + SnapshotIds *[]string `json:"SnapshotIds,omitempty"` + // The states of the snapshots (`in-queue` \\| `completed` \\| `error`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the snapshots. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the snapshots. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the snapshots, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The IDs of the volumes used to create the snapshots. + VolumeIds *[]string `json:"VolumeIds,omitempty"` + // The sizes of the volumes used to create the snapshots, in gibibytes (GiB). + VolumeSizes *[]int32 `json:"VolumeSizes,omitempty"` +} + +// NewFiltersSnapshot instantiates a new FiltersSnapshot object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersSnapshot() *FiltersSnapshot { + this := FiltersSnapshot{} + return &this +} + +// NewFiltersSnapshotWithDefaults instantiates a new FiltersSnapshot object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersSnapshotWithDefaults() *FiltersSnapshot { + this := FiltersSnapshot{} + return &this +} + +// GetAccountAliases returns the AccountAliases field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetAccountAliases() []string { + if o == nil || o.AccountAliases == nil { + var ret []string + return ret + } + return *o.AccountAliases +} + +// GetAccountAliasesOk returns a tuple with the AccountAliases field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetAccountAliasesOk() (*[]string, bool) { + if o == nil || o.AccountAliases == nil { + return nil, false + } + return o.AccountAliases, true +} + +// HasAccountAliases returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasAccountAliases() bool { + if o != nil && o.AccountAliases != nil { + return true + } + + return false +} + +// SetAccountAliases gets a reference to the given []string and assigns it to the AccountAliases field. +func (o *FiltersSnapshot) SetAccountAliases(v []string) { + o.AccountAliases = &v +} + +// GetAccountIds returns the AccountIds field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetAccountIds() []string { + if o == nil || o.AccountIds == nil { + var ret []string + return ret + } + return *o.AccountIds +} + +// GetAccountIdsOk returns a tuple with the AccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetAccountIdsOk() (*[]string, bool) { + if o == nil || o.AccountIds == nil { + return nil, false + } + return o.AccountIds, true +} + +// HasAccountIds returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasAccountIds() bool { + if o != nil && o.AccountIds != nil { + return true + } + + return false +} + +// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. +func (o *FiltersSnapshot) SetAccountIds(v []string) { + o.AccountIds = &v +} + +// GetDescriptions returns the Descriptions field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetDescriptions() []string { + if o == nil || o.Descriptions == nil { + var ret []string + return ret + } + return *o.Descriptions +} + +// GetDescriptionsOk returns a tuple with the Descriptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetDescriptionsOk() (*[]string, bool) { + if o == nil || o.Descriptions == nil { + return nil, false + } + return o.Descriptions, true +} + +// HasDescriptions returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasDescriptions() bool { + if o != nil && o.Descriptions != nil { + return true + } + + return false +} + +// SetDescriptions gets a reference to the given []string and assigns it to the Descriptions field. +func (o *FiltersSnapshot) SetDescriptions(v []string) { + o.Descriptions = &v +} + +// GetPermissionsToCreateVolumeAccountIds returns the PermissionsToCreateVolumeAccountIds field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetPermissionsToCreateVolumeAccountIds() []string { + if o == nil || o.PermissionsToCreateVolumeAccountIds == nil { + var ret []string + return ret + } + return *o.PermissionsToCreateVolumeAccountIds +} + +// GetPermissionsToCreateVolumeAccountIdsOk returns a tuple with the PermissionsToCreateVolumeAccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetPermissionsToCreateVolumeAccountIdsOk() (*[]string, bool) { + if o == nil || o.PermissionsToCreateVolumeAccountIds == nil { + return nil, false + } + return o.PermissionsToCreateVolumeAccountIds, true +} + +// HasPermissionsToCreateVolumeAccountIds returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasPermissionsToCreateVolumeAccountIds() bool { + if o != nil && o.PermissionsToCreateVolumeAccountIds != nil { + return true + } + + return false +} + +// SetPermissionsToCreateVolumeAccountIds gets a reference to the given []string and assigns it to the PermissionsToCreateVolumeAccountIds field. +func (o *FiltersSnapshot) SetPermissionsToCreateVolumeAccountIds(v []string) { + o.PermissionsToCreateVolumeAccountIds = &v +} + +// GetPermissionsToCreateVolumeGlobalPermission returns the PermissionsToCreateVolumeGlobalPermission field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetPermissionsToCreateVolumeGlobalPermission() bool { + if o == nil || o.PermissionsToCreateVolumeGlobalPermission == nil { + var ret bool + return ret + } + return *o.PermissionsToCreateVolumeGlobalPermission +} + +// GetPermissionsToCreateVolumeGlobalPermissionOk returns a tuple with the PermissionsToCreateVolumeGlobalPermission field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetPermissionsToCreateVolumeGlobalPermissionOk() (*bool, bool) { + if o == nil || o.PermissionsToCreateVolumeGlobalPermission == nil { + return nil, false + } + return o.PermissionsToCreateVolumeGlobalPermission, true +} + +// HasPermissionsToCreateVolumeGlobalPermission returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasPermissionsToCreateVolumeGlobalPermission() bool { + if o != nil && o.PermissionsToCreateVolumeGlobalPermission != nil { + return true + } + + return false +} + +// SetPermissionsToCreateVolumeGlobalPermission gets a reference to the given bool and assigns it to the PermissionsToCreateVolumeGlobalPermission field. +func (o *FiltersSnapshot) SetPermissionsToCreateVolumeGlobalPermission(v bool) { + o.PermissionsToCreateVolumeGlobalPermission = &v +} + +// GetProgresses returns the Progresses field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetProgresses() []int32 { + if o == nil || o.Progresses == nil { + var ret []int32 + return ret + } + return *o.Progresses +} + +// GetProgressesOk returns a tuple with the Progresses field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetProgressesOk() (*[]int32, bool) { + if o == nil || o.Progresses == nil { + return nil, false + } + return o.Progresses, true +} + +// HasProgresses returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasProgresses() bool { + if o != nil && o.Progresses != nil { + return true + } + + return false +} + +// SetProgresses gets a reference to the given []int32 and assigns it to the Progresses field. +func (o *FiltersSnapshot) SetProgresses(v []int32) { + o.Progresses = &v +} + +// GetSnapshotIds returns the SnapshotIds field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetSnapshotIds() []string { + if o == nil || o.SnapshotIds == nil { + var ret []string + return ret + } + return *o.SnapshotIds +} + +// GetSnapshotIdsOk returns a tuple with the SnapshotIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetSnapshotIdsOk() (*[]string, bool) { + if o == nil || o.SnapshotIds == nil { + return nil, false + } + return o.SnapshotIds, true +} + +// HasSnapshotIds returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasSnapshotIds() bool { + if o != nil && o.SnapshotIds != nil { + return true + } + + return false +} + +// SetSnapshotIds gets a reference to the given []string and assigns it to the SnapshotIds field. +func (o *FiltersSnapshot) SetSnapshotIds(v []string) { + o.SnapshotIds = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersSnapshot) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersSnapshot) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersSnapshot) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersSnapshot) SetTags(v []string) { + o.Tags = &v +} + +// GetVolumeIds returns the VolumeIds field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetVolumeIds() []string { + if o == nil || o.VolumeIds == nil { + var ret []string + return ret + } + return *o.VolumeIds +} + +// GetVolumeIdsOk returns a tuple with the VolumeIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetVolumeIdsOk() (*[]string, bool) { + if o == nil || o.VolumeIds == nil { + return nil, false + } + return o.VolumeIds, true +} + +// HasVolumeIds returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasVolumeIds() bool { + if o != nil && o.VolumeIds != nil { + return true + } + + return false +} + +// SetVolumeIds gets a reference to the given []string and assigns it to the VolumeIds field. +func (o *FiltersSnapshot) SetVolumeIds(v []string) { + o.VolumeIds = &v +} + +// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. +func (o *FiltersSnapshot) GetVolumeSizes() []int32 { + if o == nil || o.VolumeSizes == nil { + var ret []int32 + return ret + } + return *o.VolumeSizes +} + +// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSnapshot) GetVolumeSizesOk() (*[]int32, bool) { + if o == nil || o.VolumeSizes == nil { + return nil, false + } + return o.VolumeSizes, true +} + +// HasVolumeSizes returns a boolean if a field has been set. +func (o *FiltersSnapshot) HasVolumeSizes() bool { + if o != nil && o.VolumeSizes != nil { + return true + } + + return false +} + +// SetVolumeSizes gets a reference to the given []int32 and assigns it to the VolumeSizes field. +func (o *FiltersSnapshot) SetVolumeSizes(v []int32) { + o.VolumeSizes = &v +} + +func (o FiltersSnapshot) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountAliases != nil { + toSerialize["AccountAliases"] = o.AccountAliases + } + if o.AccountIds != nil { + toSerialize["AccountIds"] = o.AccountIds + } + if o.Descriptions != nil { + toSerialize["Descriptions"] = o.Descriptions + } + if o.PermissionsToCreateVolumeAccountIds != nil { + toSerialize["PermissionsToCreateVolumeAccountIds"] = o.PermissionsToCreateVolumeAccountIds + } + if o.PermissionsToCreateVolumeGlobalPermission != nil { + toSerialize["PermissionsToCreateVolumeGlobalPermission"] = o.PermissionsToCreateVolumeGlobalPermission + } + if o.Progresses != nil { + toSerialize["Progresses"] = o.Progresses + } + if o.SnapshotIds != nil { + toSerialize["SnapshotIds"] = o.SnapshotIds + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VolumeIds != nil { + toSerialize["VolumeIds"] = o.VolumeIds + } + if o.VolumeSizes != nil { + toSerialize["VolumeSizes"] = o.VolumeSizes + } + return json.Marshal(toSerialize) +} + +type NullableFiltersSnapshot struct { + value *FiltersSnapshot + isSet bool +} + +func (v NullableFiltersSnapshot) Get() *FiltersSnapshot { + return v.value +} + +func (v *NullableFiltersSnapshot) Set(val *FiltersSnapshot) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersSnapshot) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersSnapshot) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersSnapshot(val *FiltersSnapshot) *NullableFiltersSnapshot { + return &NullableFiltersSnapshot{value: val, isSet: true} +} + +func (v NullableFiltersSnapshot) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersSnapshot) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go new file mode 100644 index 000000000..145230b23 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go @@ -0,0 +1,413 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersSubnet One or more filters. +type FiltersSubnet struct { + // The number of available IPs. + AvailableIpsCounts *[]int32 `json:"AvailableIpsCounts,omitempty"` + // The IP ranges in the Subnets, in CIDR notation (for example, 10.0.0.0/16). + IpRanges *[]string `json:"IpRanges,omitempty"` + // The IDs of the Nets in which the Subnets are. + NetIds *[]string `json:"NetIds,omitempty"` + // The states of the Subnets (`pending` \\| `available`). + States *[]string `json:"States,omitempty"` + // The IDs of the Subnets. + SubnetIds *[]string `json:"SubnetIds,omitempty"` + // The names of the Subregions in which the Subnets are located. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // The keys of the tags associated with the Subnets. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the Subnets. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the Subnets, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` +} + +// NewFiltersSubnet instantiates a new FiltersSubnet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersSubnet() *FiltersSubnet { + this := FiltersSubnet{} + return &this +} + +// NewFiltersSubnetWithDefaults instantiates a new FiltersSubnet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersSubnetWithDefaults() *FiltersSubnet { + this := FiltersSubnet{} + return &this +} + +// GetAvailableIpsCounts returns the AvailableIpsCounts field value if set, zero value otherwise. +func (o *FiltersSubnet) GetAvailableIpsCounts() []int32 { + if o == nil || o.AvailableIpsCounts == nil { + var ret []int32 + return ret + } + return *o.AvailableIpsCounts +} + +// GetAvailableIpsCountsOk returns a tuple with the AvailableIpsCounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetAvailableIpsCountsOk() (*[]int32, bool) { + if o == nil || o.AvailableIpsCounts == nil { + return nil, false + } + return o.AvailableIpsCounts, true +} + +// HasAvailableIpsCounts returns a boolean if a field has been set. +func (o *FiltersSubnet) HasAvailableIpsCounts() bool { + if o != nil && o.AvailableIpsCounts != nil { + return true + } + + return false +} + +// SetAvailableIpsCounts gets a reference to the given []int32 and assigns it to the AvailableIpsCounts field. +func (o *FiltersSubnet) SetAvailableIpsCounts(v []int32) { + o.AvailableIpsCounts = &v +} + +// GetIpRanges returns the IpRanges field value if set, zero value otherwise. +func (o *FiltersSubnet) GetIpRanges() []string { + if o == nil || o.IpRanges == nil { + var ret []string + return ret + } + return *o.IpRanges +} + +// GetIpRangesOk returns a tuple with the IpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetIpRangesOk() (*[]string, bool) { + if o == nil || o.IpRanges == nil { + return nil, false + } + return o.IpRanges, true +} + +// HasIpRanges returns a boolean if a field has been set. +func (o *FiltersSubnet) HasIpRanges() bool { + if o != nil && o.IpRanges != nil { + return true + } + + return false +} + +// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. +func (o *FiltersSubnet) SetIpRanges(v []string) { + o.IpRanges = &v +} + +// GetNetIds returns the NetIds field value if set, zero value otherwise. +func (o *FiltersSubnet) GetNetIds() []string { + if o == nil || o.NetIds == nil { + var ret []string + return ret + } + return *o.NetIds +} + +// GetNetIdsOk returns a tuple with the NetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetNetIdsOk() (*[]string, bool) { + if o == nil || o.NetIds == nil { + return nil, false + } + return o.NetIds, true +} + +// HasNetIds returns a boolean if a field has been set. +func (o *FiltersSubnet) HasNetIds() bool { + if o != nil && o.NetIds != nil { + return true + } + + return false +} + +// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. +func (o *FiltersSubnet) SetNetIds(v []string) { + o.NetIds = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersSubnet) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersSubnet) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersSubnet) SetStates(v []string) { + o.States = &v +} + +// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. +func (o *FiltersSubnet) GetSubnetIds() []string { + if o == nil || o.SubnetIds == nil { + var ret []string + return ret + } + return *o.SubnetIds +} + +// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetSubnetIdsOk() (*[]string, bool) { + if o == nil || o.SubnetIds == nil { + return nil, false + } + return o.SubnetIds, true +} + +// HasSubnetIds returns a boolean if a field has been set. +func (o *FiltersSubnet) HasSubnetIds() bool { + if o != nil && o.SubnetIds != nil { + return true + } + + return false +} + +// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. +func (o *FiltersSubnet) SetSubnetIds(v []string) { + o.SubnetIds = &v +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *FiltersSubnet) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *FiltersSubnet) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *FiltersSubnet) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersSubnet) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersSubnet) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersSubnet) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersSubnet) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersSubnet) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersSubnet) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersSubnet) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubnet) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersSubnet) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersSubnet) SetTags(v []string) { + o.Tags = &v +} + +func (o FiltersSubnet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AvailableIpsCounts != nil { + toSerialize["AvailableIpsCounts"] = o.AvailableIpsCounts + } + if o.IpRanges != nil { + toSerialize["IpRanges"] = o.IpRanges + } + if o.NetIds != nil { + toSerialize["NetIds"] = o.NetIds + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.SubnetIds != nil { + toSerialize["SubnetIds"] = o.SubnetIds + } + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableFiltersSubnet struct { + value *FiltersSubnet + isSet bool +} + +func (v NullableFiltersSubnet) Get() *FiltersSubnet { + return v.value +} + +func (v *NullableFiltersSubnet) Set(val *FiltersSubnet) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersSubnet) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersSubnet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersSubnet(val *FiltersSubnet) *NullableFiltersSubnet { + return &NullableFiltersSubnet{value: val, isSet: true} +} + +func (v NullableFiltersSubnet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersSubnet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go new file mode 100644 index 000000000..193edf109 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersSubregion One or more filters. +type FiltersSubregion struct { + // The names of the Subregions. + SubregionNames *[]string `json:"SubregionNames,omitempty"` +} + +// NewFiltersSubregion instantiates a new FiltersSubregion object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersSubregion() *FiltersSubregion { + this := FiltersSubregion{} + return &this +} + +// NewFiltersSubregionWithDefaults instantiates a new FiltersSubregion object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersSubregionWithDefaults() *FiltersSubregion { + this := FiltersSubregion{} + return &this +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *FiltersSubregion) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersSubregion) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *FiltersSubregion) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *FiltersSubregion) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +func (o FiltersSubregion) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + return json.Marshal(toSerialize) +} + +type NullableFiltersSubregion struct { + value *FiltersSubregion + isSet bool +} + +func (v NullableFiltersSubregion) Get() *FiltersSubregion { + return v.value +} + +func (v *NullableFiltersSubregion) Set(val *FiltersSubregion) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersSubregion) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersSubregion) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersSubregion(val *FiltersSubregion) *NullableFiltersSubregion { + return &NullableFiltersSubregion{value: val, isSet: true} +} + +func (v NullableFiltersSubregion) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersSubregion) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go new file mode 100644 index 000000000..b37f890ff --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersTag One or more filters. +type FiltersTag struct { + // The keys of the tags that are assigned to the resources. You can use this filter alongside the `Values` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. + Keys *[]string `json:"Keys,omitempty"` + // The IDs of the resources with which the tags are associated. + ResourceIds *[]string `json:"ResourceIds,omitempty"` + // The resource type (`vm` \\| `image` \\| `volume` \\| `snapshot` \\| `public-ip` \\| `security-group` \\| `route-table` \\| `nic` \\| `net` \\| `subnet` \\| `net-peering` \\| `net-access-point` \\| `nat-service` \\| `internet-service` \\| `client-gateway` \\| `virtual-gateway` \\| `vpn-connection` \\| `dhcp-options` \\| `task`). + ResourceTypes *[]string `json:"ResourceTypes,omitempty"` + // The values of the tags that are assigned to the resources. You can use this filter alongside the `TagKeys` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. + Values *[]string `json:"Values,omitempty"` +} + +// NewFiltersTag instantiates a new FiltersTag object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersTag() *FiltersTag { + this := FiltersTag{} + return &this +} + +// NewFiltersTagWithDefaults instantiates a new FiltersTag object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersTagWithDefaults() *FiltersTag { + this := FiltersTag{} + return &this +} + +// GetKeys returns the Keys field value if set, zero value otherwise. +func (o *FiltersTag) GetKeys() []string { + if o == nil || o.Keys == nil { + var ret []string + return ret + } + return *o.Keys +} + +// GetKeysOk returns a tuple with the Keys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersTag) GetKeysOk() (*[]string, bool) { + if o == nil || o.Keys == nil { + return nil, false + } + return o.Keys, true +} + +// HasKeys returns a boolean if a field has been set. +func (o *FiltersTag) HasKeys() bool { + if o != nil && o.Keys != nil { + return true + } + + return false +} + +// SetKeys gets a reference to the given []string and assigns it to the Keys field. +func (o *FiltersTag) SetKeys(v []string) { + o.Keys = &v +} + +// GetResourceIds returns the ResourceIds field value if set, zero value otherwise. +func (o *FiltersTag) GetResourceIds() []string { + if o == nil || o.ResourceIds == nil { + var ret []string + return ret + } + return *o.ResourceIds +} + +// GetResourceIdsOk returns a tuple with the ResourceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersTag) GetResourceIdsOk() (*[]string, bool) { + if o == nil || o.ResourceIds == nil { + return nil, false + } + return o.ResourceIds, true +} + +// HasResourceIds returns a boolean if a field has been set. +func (o *FiltersTag) HasResourceIds() bool { + if o != nil && o.ResourceIds != nil { + return true + } + + return false +} + +// SetResourceIds gets a reference to the given []string and assigns it to the ResourceIds field. +func (o *FiltersTag) SetResourceIds(v []string) { + o.ResourceIds = &v +} + +// GetResourceTypes returns the ResourceTypes field value if set, zero value otherwise. +func (o *FiltersTag) GetResourceTypes() []string { + if o == nil || o.ResourceTypes == nil { + var ret []string + return ret + } + return *o.ResourceTypes +} + +// GetResourceTypesOk returns a tuple with the ResourceTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersTag) GetResourceTypesOk() (*[]string, bool) { + if o == nil || o.ResourceTypes == nil { + return nil, false + } + return o.ResourceTypes, true +} + +// HasResourceTypes returns a boolean if a field has been set. +func (o *FiltersTag) HasResourceTypes() bool { + if o != nil && o.ResourceTypes != nil { + return true + } + + return false +} + +// SetResourceTypes gets a reference to the given []string and assigns it to the ResourceTypes field. +func (o *FiltersTag) SetResourceTypes(v []string) { + o.ResourceTypes = &v +} + +// GetValues returns the Values field value if set, zero value otherwise. +func (o *FiltersTag) GetValues() []string { + if o == nil || o.Values == nil { + var ret []string + return ret + } + return *o.Values +} + +// GetValuesOk returns a tuple with the Values field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersTag) GetValuesOk() (*[]string, bool) { + if o == nil || o.Values == nil { + return nil, false + } + return o.Values, true +} + +// HasValues returns a boolean if a field has been set. +func (o *FiltersTag) HasValues() bool { + if o != nil && o.Values != nil { + return true + } + + return false +} + +// SetValues gets a reference to the given []string and assigns it to the Values field. +func (o *FiltersTag) SetValues(v []string) { + o.Values = &v +} + +func (o FiltersTag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Keys != nil { + toSerialize["Keys"] = o.Keys + } + if o.ResourceIds != nil { + toSerialize["ResourceIds"] = o.ResourceIds + } + if o.ResourceTypes != nil { + toSerialize["ResourceTypes"] = o.ResourceTypes + } + if o.Values != nil { + toSerialize["Values"] = o.Values + } + return json.Marshal(toSerialize) +} + +type NullableFiltersTag struct { + value *FiltersTag + isSet bool +} + +func (v NullableFiltersTag) Get() *FiltersTag { + return v.value +} + +func (v *NullableFiltersTag) Set(val *FiltersTag) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersTag) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersTag) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersTag(val *FiltersTag) *NullableFiltersTag { + return &NullableFiltersTag{value: val, isSet: true} +} + +func (v NullableFiltersTag) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersTag) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go new file mode 100644 index 000000000..ca917350e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVirtualGateway One or more filters. +type FiltersVirtualGateway struct { + // The types of the virtual gateways (only `ipsec.1` is supported). + ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` + // The IDs of the Nets the virtual gateways are attached to. + LinkNetIds *[]string `json:"LinkNetIds,omitempty"` + // The current states of the attachments between the virtual gateways and the Nets (`attaching` \\| `attached` \\| `detaching` \\| `detached`). + LinkStates *[]string `json:"LinkStates,omitempty"` + // The states of the virtual gateways (`pending` \\| `available` \\| `deleting` \\| `deleted`). + States *[]string `json:"States,omitempty"` + // The keys of the tags associated with the virtual gateways. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the virtual gateways. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the virtual gateways, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The IDs of the virtual gateways. + VirtualGatewayIds *[]string `json:"VirtualGatewayIds,omitempty"` +} + +// NewFiltersVirtualGateway instantiates a new FiltersVirtualGateway object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVirtualGateway() *FiltersVirtualGateway { + this := FiltersVirtualGateway{} + return &this +} + +// NewFiltersVirtualGatewayWithDefaults instantiates a new FiltersVirtualGateway object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVirtualGatewayWithDefaults() *FiltersVirtualGateway { + this := FiltersVirtualGateway{} + return &this +} + +// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetConnectionTypes() []string { + if o == nil || o.ConnectionTypes == nil { + var ret []string + return ret + } + return *o.ConnectionTypes +} + +// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetConnectionTypesOk() (*[]string, bool) { + if o == nil || o.ConnectionTypes == nil { + return nil, false + } + return o.ConnectionTypes, true +} + +// HasConnectionTypes returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasConnectionTypes() bool { + if o != nil && o.ConnectionTypes != nil { + return true + } + + return false +} + +// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. +func (o *FiltersVirtualGateway) SetConnectionTypes(v []string) { + o.ConnectionTypes = &v +} + +// GetLinkNetIds returns the LinkNetIds field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetLinkNetIds() []string { + if o == nil || o.LinkNetIds == nil { + var ret []string + return ret + } + return *o.LinkNetIds +} + +// GetLinkNetIdsOk returns a tuple with the LinkNetIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetLinkNetIdsOk() (*[]string, bool) { + if o == nil || o.LinkNetIds == nil { + return nil, false + } + return o.LinkNetIds, true +} + +// HasLinkNetIds returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasLinkNetIds() bool { + if o != nil && o.LinkNetIds != nil { + return true + } + + return false +} + +// SetLinkNetIds gets a reference to the given []string and assigns it to the LinkNetIds field. +func (o *FiltersVirtualGateway) SetLinkNetIds(v []string) { + o.LinkNetIds = &v +} + +// GetLinkStates returns the LinkStates field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetLinkStates() []string { + if o == nil || o.LinkStates == nil { + var ret []string + return ret + } + return *o.LinkStates +} + +// GetLinkStatesOk returns a tuple with the LinkStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetLinkStatesOk() (*[]string, bool) { + if o == nil || o.LinkStates == nil { + return nil, false + } + return o.LinkStates, true +} + +// HasLinkStates returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasLinkStates() bool { + if o != nil && o.LinkStates != nil { + return true + } + + return false +} + +// SetLinkStates gets a reference to the given []string and assigns it to the LinkStates field. +func (o *FiltersVirtualGateway) SetLinkStates(v []string) { + o.LinkStates = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersVirtualGateway) SetStates(v []string) { + o.States = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersVirtualGateway) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersVirtualGateway) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersVirtualGateway) SetTags(v []string) { + o.Tags = &v +} + +// GetVirtualGatewayIds returns the VirtualGatewayIds field value if set, zero value otherwise. +func (o *FiltersVirtualGateway) GetVirtualGatewayIds() []string { + if o == nil || o.VirtualGatewayIds == nil { + var ret []string + return ret + } + return *o.VirtualGatewayIds +} + +// GetVirtualGatewayIdsOk returns a tuple with the VirtualGatewayIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVirtualGateway) GetVirtualGatewayIdsOk() (*[]string, bool) { + if o == nil || o.VirtualGatewayIds == nil { + return nil, false + } + return o.VirtualGatewayIds, true +} + +// HasVirtualGatewayIds returns a boolean if a field has been set. +func (o *FiltersVirtualGateway) HasVirtualGatewayIds() bool { + if o != nil && o.VirtualGatewayIds != nil { + return true + } + + return false +} + +// SetVirtualGatewayIds gets a reference to the given []string and assigns it to the VirtualGatewayIds field. +func (o *FiltersVirtualGateway) SetVirtualGatewayIds(v []string) { + o.VirtualGatewayIds = &v +} + +func (o FiltersVirtualGateway) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ConnectionTypes != nil { + toSerialize["ConnectionTypes"] = o.ConnectionTypes + } + if o.LinkNetIds != nil { + toSerialize["LinkNetIds"] = o.LinkNetIds + } + if o.LinkStates != nil { + toSerialize["LinkStates"] = o.LinkStates + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VirtualGatewayIds != nil { + toSerialize["VirtualGatewayIds"] = o.VirtualGatewayIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVirtualGateway struct { + value *FiltersVirtualGateway + isSet bool +} + +func (v NullableFiltersVirtualGateway) Get() *FiltersVirtualGateway { + return v.value +} + +func (v *NullableFiltersVirtualGateway) Set(val *FiltersVirtualGateway) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVirtualGateway) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVirtualGateway) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVirtualGateway(val *FiltersVirtualGateway) *NullableFiltersVirtualGateway { + return &NullableFiltersVirtualGateway{value: val, isSet: true} +} + +func (v NullableFiltersVirtualGateway) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVirtualGateway) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go new file mode 100644 index 000000000..711f7644a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVm One or more filters. +type FiltersVm struct { + // The keys of the tags associated with the VMs. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the VMs. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the VMs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // One or more IDs of VMs. + VmIds *[]string `json:"VmIds,omitempty"` +} + +// NewFiltersVm instantiates a new FiltersVm object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVm() *FiltersVm { + this := FiltersVm{} + return &this +} + +// NewFiltersVmWithDefaults instantiates a new FiltersVm object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVmWithDefaults() *FiltersVm { + this := FiltersVm{} + return &this +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersVm) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVm) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersVm) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersVm) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersVm) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVm) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersVm) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersVm) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersVm) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVm) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersVm) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersVm) SetTags(v []string) { + o.Tags = &v +} + +// GetVmIds returns the VmIds field value if set, zero value otherwise. +func (o *FiltersVm) GetVmIds() []string { + if o == nil || o.VmIds == nil { + var ret []string + return ret + } + return *o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVm) GetVmIdsOk() (*[]string, bool) { + if o == nil || o.VmIds == nil { + return nil, false + } + return o.VmIds, true +} + +// HasVmIds returns a boolean if a field has been set. +func (o *FiltersVm) HasVmIds() bool { + if o != nil && o.VmIds != nil { + return true + } + + return false +} + +// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. +func (o *FiltersVm) SetVmIds(v []string) { + o.VmIds = &v +} + +func (o FiltersVm) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VmIds != nil { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVm struct { + value *FiltersVm + isSet bool +} + +func (v NullableFiltersVm) Get() *FiltersVm { + return v.value +} + +func (v *NullableFiltersVm) Set(val *FiltersVm) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVm) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVm) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVm(val *FiltersVm) *NullableFiltersVm { + return &NullableFiltersVm{value: val, isSet: true} +} + +func (v NullableFiltersVm) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVm) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go new file mode 100644 index 000000000..1a560a4b7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVmType One or more filters. +type FiltersVmType struct { + // Indicates whether the VM is optimized for BSU I/O. + BsuOptimized *bool `json:"BsuOptimized,omitempty"` + // The amounts of memory, in gibibytes (GiB). + MemorySizes *[]float32 `json:"MemorySizes,omitempty"` + // The numbers of vCores. + VcoreCounts *[]int32 `json:"VcoreCounts,omitempty"` + // The names of the VM types. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). + VmTypeNames *[]string `json:"VmTypeNames,omitempty"` + // The maximum number of ephemeral storage disks. + VolumeCounts *[]int32 `json:"VolumeCounts,omitempty"` + // The size of one ephemeral storage disk, in gibibytes (GiB). + VolumeSizes *[]int32 `json:"VolumeSizes,omitempty"` +} + +// NewFiltersVmType instantiates a new FiltersVmType object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVmType() *FiltersVmType { + this := FiltersVmType{} + return &this +} + +// NewFiltersVmTypeWithDefaults instantiates a new FiltersVmType object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVmTypeWithDefaults() *FiltersVmType { + this := FiltersVmType{} + return &this +} + +// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. +func (o *FiltersVmType) GetBsuOptimized() bool { + if o == nil || o.BsuOptimized == nil { + var ret bool + return ret + } + return *o.BsuOptimized +} + +// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetBsuOptimizedOk() (*bool, bool) { + if o == nil || o.BsuOptimized == nil { + return nil, false + } + return o.BsuOptimized, true +} + +// HasBsuOptimized returns a boolean if a field has been set. +func (o *FiltersVmType) HasBsuOptimized() bool { + if o != nil && o.BsuOptimized != nil { + return true + } + + return false +} + +// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. +func (o *FiltersVmType) SetBsuOptimized(v bool) { + o.BsuOptimized = &v +} + +// GetMemorySizes returns the MemorySizes field value if set, zero value otherwise. +func (o *FiltersVmType) GetMemorySizes() []float32 { + if o == nil || o.MemorySizes == nil { + var ret []float32 + return ret + } + return *o.MemorySizes +} + +// GetMemorySizesOk returns a tuple with the MemorySizes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetMemorySizesOk() (*[]float32, bool) { + if o == nil || o.MemorySizes == nil { + return nil, false + } + return o.MemorySizes, true +} + +// HasMemorySizes returns a boolean if a field has been set. +func (o *FiltersVmType) HasMemorySizes() bool { + if o != nil && o.MemorySizes != nil { + return true + } + + return false +} + +// SetMemorySizes gets a reference to the given []float32 and assigns it to the MemorySizes field. +func (o *FiltersVmType) SetMemorySizes(v []float32) { + o.MemorySizes = &v +} + +// GetVcoreCounts returns the VcoreCounts field value if set, zero value otherwise. +func (o *FiltersVmType) GetVcoreCounts() []int32 { + if o == nil || o.VcoreCounts == nil { + var ret []int32 + return ret + } + return *o.VcoreCounts +} + +// GetVcoreCountsOk returns a tuple with the VcoreCounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetVcoreCountsOk() (*[]int32, bool) { + if o == nil || o.VcoreCounts == nil { + return nil, false + } + return o.VcoreCounts, true +} + +// HasVcoreCounts returns a boolean if a field has been set. +func (o *FiltersVmType) HasVcoreCounts() bool { + if o != nil && o.VcoreCounts != nil { + return true + } + + return false +} + +// SetVcoreCounts gets a reference to the given []int32 and assigns it to the VcoreCounts field. +func (o *FiltersVmType) SetVcoreCounts(v []int32) { + o.VcoreCounts = &v +} + +// GetVmTypeNames returns the VmTypeNames field value if set, zero value otherwise. +func (o *FiltersVmType) GetVmTypeNames() []string { + if o == nil || o.VmTypeNames == nil { + var ret []string + return ret + } + return *o.VmTypeNames +} + +// GetVmTypeNamesOk returns a tuple with the VmTypeNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetVmTypeNamesOk() (*[]string, bool) { + if o == nil || o.VmTypeNames == nil { + return nil, false + } + return o.VmTypeNames, true +} + +// HasVmTypeNames returns a boolean if a field has been set. +func (o *FiltersVmType) HasVmTypeNames() bool { + if o != nil && o.VmTypeNames != nil { + return true + } + + return false +} + +// SetVmTypeNames gets a reference to the given []string and assigns it to the VmTypeNames field. +func (o *FiltersVmType) SetVmTypeNames(v []string) { + o.VmTypeNames = &v +} + +// GetVolumeCounts returns the VolumeCounts field value if set, zero value otherwise. +func (o *FiltersVmType) GetVolumeCounts() []int32 { + if o == nil || o.VolumeCounts == nil { + var ret []int32 + return ret + } + return *o.VolumeCounts +} + +// GetVolumeCountsOk returns a tuple with the VolumeCounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetVolumeCountsOk() (*[]int32, bool) { + if o == nil || o.VolumeCounts == nil { + return nil, false + } + return o.VolumeCounts, true +} + +// HasVolumeCounts returns a boolean if a field has been set. +func (o *FiltersVmType) HasVolumeCounts() bool { + if o != nil && o.VolumeCounts != nil { + return true + } + + return false +} + +// SetVolumeCounts gets a reference to the given []int32 and assigns it to the VolumeCounts field. +func (o *FiltersVmType) SetVolumeCounts(v []int32) { + o.VolumeCounts = &v +} + +// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. +func (o *FiltersVmType) GetVolumeSizes() []int32 { + if o == nil || o.VolumeSizes == nil { + var ret []int32 + return ret + } + return *o.VolumeSizes +} + +// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmType) GetVolumeSizesOk() (*[]int32, bool) { + if o == nil || o.VolumeSizes == nil { + return nil, false + } + return o.VolumeSizes, true +} + +// HasVolumeSizes returns a boolean if a field has been set. +func (o *FiltersVmType) HasVolumeSizes() bool { + if o != nil && o.VolumeSizes != nil { + return true + } + + return false +} + +// SetVolumeSizes gets a reference to the given []int32 and assigns it to the VolumeSizes field. +func (o *FiltersVmType) SetVolumeSizes(v []int32) { + o.VolumeSizes = &v +} + +func (o FiltersVmType) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BsuOptimized != nil { + toSerialize["BsuOptimized"] = o.BsuOptimized + } + if o.MemorySizes != nil { + toSerialize["MemorySizes"] = o.MemorySizes + } + if o.VcoreCounts != nil { + toSerialize["VcoreCounts"] = o.VcoreCounts + } + if o.VmTypeNames != nil { + toSerialize["VmTypeNames"] = o.VmTypeNames + } + if o.VolumeCounts != nil { + toSerialize["VolumeCounts"] = o.VolumeCounts + } + if o.VolumeSizes != nil { + toSerialize["VolumeSizes"] = o.VolumeSizes + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVmType struct { + value *FiltersVmType + isSet bool +} + +func (v NullableFiltersVmType) Get() *FiltersVmType { + return v.value +} + +func (v *NullableFiltersVmType) Set(val *FiltersVmType) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVmType) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVmType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVmType(val *FiltersVmType) *NullableFiltersVmType { + return &NullableFiltersVmType{value: val, isSet: true} +} + +func (v NullableFiltersVmType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVmType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go new file mode 100644 index 000000000..c045914cb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVmsState One or more filters. +type FiltersVmsState struct { + // The names of the Subregions of the VMs. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // One or more IDs of VMs. + VmIds *[]string `json:"VmIds,omitempty"` + // The states of the VMs (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). + VmStates *[]string `json:"VmStates,omitempty"` +} + +// NewFiltersVmsState instantiates a new FiltersVmsState object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVmsState() *FiltersVmsState { + this := FiltersVmsState{} + return &this +} + +// NewFiltersVmsStateWithDefaults instantiates a new FiltersVmsState object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVmsStateWithDefaults() *FiltersVmsState { + this := FiltersVmsState{} + return &this +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *FiltersVmsState) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmsState) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *FiltersVmsState) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *FiltersVmsState) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetVmIds returns the VmIds field value if set, zero value otherwise. +func (o *FiltersVmsState) GetVmIds() []string { + if o == nil || o.VmIds == nil { + var ret []string + return ret + } + return *o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmsState) GetVmIdsOk() (*[]string, bool) { + if o == nil || o.VmIds == nil { + return nil, false + } + return o.VmIds, true +} + +// HasVmIds returns a boolean if a field has been set. +func (o *FiltersVmsState) HasVmIds() bool { + if o != nil && o.VmIds != nil { + return true + } + + return false +} + +// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. +func (o *FiltersVmsState) SetVmIds(v []string) { + o.VmIds = &v +} + +// GetVmStates returns the VmStates field value if set, zero value otherwise. +func (o *FiltersVmsState) GetVmStates() []string { + if o == nil || o.VmStates == nil { + var ret []string + return ret + } + return *o.VmStates +} + +// GetVmStatesOk returns a tuple with the VmStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVmsState) GetVmStatesOk() (*[]string, bool) { + if o == nil || o.VmStates == nil { + return nil, false + } + return o.VmStates, true +} + +// HasVmStates returns a boolean if a field has been set. +func (o *FiltersVmsState) HasVmStates() bool { + if o != nil && o.VmStates != nil { + return true + } + + return false +} + +// SetVmStates gets a reference to the given []string and assigns it to the VmStates field. +func (o *FiltersVmsState) SetVmStates(v []string) { + o.VmStates = &v +} + +func (o FiltersVmsState) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.VmIds != nil { + toSerialize["VmIds"] = o.VmIds + } + if o.VmStates != nil { + toSerialize["VmStates"] = o.VmStates + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVmsState struct { + value *FiltersVmsState + isSet bool +} + +func (v NullableFiltersVmsState) Get() *FiltersVmsState { + return v.value +} + +func (v *NullableFiltersVmsState) Set(val *FiltersVmsState) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVmsState) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVmsState) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVmsState(val *FiltersVmsState) *NullableFiltersVmsState { + return &NullableFiltersVmsState{value: val, isSet: true} +} + +func (v NullableFiltersVmsState) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVmsState) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go new file mode 100644 index 000000000..3683b0df6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go @@ -0,0 +1,635 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVolume One or more filters. +type FiltersVolume struct { + // The dates and times at which the volumes were created. + CreationDates *[]string `json:"CreationDates,omitempty"` + // Indicates whether the volumes are deleted when terminating the VMs. + LinkVolumeDeleteOnVmDeletion *bool `json:"LinkVolumeDeleteOnVmDeletion,omitempty"` + // The VM device names. + LinkVolumeDeviceNames *[]string `json:"LinkVolumeDeviceNames,omitempty"` + // The dates and times at which the volumes were created. + LinkVolumeLinkDates *[]string `json:"LinkVolumeLinkDates,omitempty"` + // The attachment states of the volumes (`attaching` \\| `detaching` \\| `attached` \\| `detached`). + LinkVolumeLinkStates *[]string `json:"LinkVolumeLinkStates,omitempty"` + // One or more IDs of VMs. + LinkVolumeVmIds *[]string `json:"LinkVolumeVmIds,omitempty"` + // The snapshots from which the volumes were created. + SnapshotIds *[]string `json:"SnapshotIds,omitempty"` + // The names of the Subregions in which the volumes were created. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // The keys of the tags associated with the volumes. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the volumes. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the volumes, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The IDs of the volumes. + VolumeIds *[]string `json:"VolumeIds,omitempty"` + // The sizes of the volumes, in gibibytes (GiB). + VolumeSizes *[]int32 `json:"VolumeSizes,omitempty"` + // The states of the volumes (`creating` \\| `available` \\| `in-use` \\| `deleting` \\| `error`). + VolumeStates *[]string `json:"VolumeStates,omitempty"` + // The types of the volumes (`standard` \\| `gp2` \\| `io1`). + VolumeTypes *[]string `json:"VolumeTypes,omitempty"` +} + +// NewFiltersVolume instantiates a new FiltersVolume object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVolume() *FiltersVolume { + this := FiltersVolume{} + return &this +} + +// NewFiltersVolumeWithDefaults instantiates a new FiltersVolume object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVolumeWithDefaults() *FiltersVolume { + this := FiltersVolume{} + return &this +} + +// GetCreationDates returns the CreationDates field value if set, zero value otherwise. +func (o *FiltersVolume) GetCreationDates() []string { + if o == nil || o.CreationDates == nil { + var ret []string + return ret + } + return *o.CreationDates +} + +// GetCreationDatesOk returns a tuple with the CreationDates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetCreationDatesOk() (*[]string, bool) { + if o == nil || o.CreationDates == nil { + return nil, false + } + return o.CreationDates, true +} + +// HasCreationDates returns a boolean if a field has been set. +func (o *FiltersVolume) HasCreationDates() bool { + if o != nil && o.CreationDates != nil { + return true + } + + return false +} + +// SetCreationDates gets a reference to the given []string and assigns it to the CreationDates field. +func (o *FiltersVolume) SetCreationDates(v []string) { + o.CreationDates = &v +} + +// GetLinkVolumeDeleteOnVmDeletion returns the LinkVolumeDeleteOnVmDeletion field value if set, zero value otherwise. +func (o *FiltersVolume) GetLinkVolumeDeleteOnVmDeletion() bool { + if o == nil || o.LinkVolumeDeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.LinkVolumeDeleteOnVmDeletion +} + +// GetLinkVolumeDeleteOnVmDeletionOk returns a tuple with the LinkVolumeDeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetLinkVolumeDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.LinkVolumeDeleteOnVmDeletion == nil { + return nil, false + } + return o.LinkVolumeDeleteOnVmDeletion, true +} + +// HasLinkVolumeDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *FiltersVolume) HasLinkVolumeDeleteOnVmDeletion() bool { + if o != nil && o.LinkVolumeDeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetLinkVolumeDeleteOnVmDeletion gets a reference to the given bool and assigns it to the LinkVolumeDeleteOnVmDeletion field. +func (o *FiltersVolume) SetLinkVolumeDeleteOnVmDeletion(v bool) { + o.LinkVolumeDeleteOnVmDeletion = &v +} + +// GetLinkVolumeDeviceNames returns the LinkVolumeDeviceNames field value if set, zero value otherwise. +func (o *FiltersVolume) GetLinkVolumeDeviceNames() []string { + if o == nil || o.LinkVolumeDeviceNames == nil { + var ret []string + return ret + } + return *o.LinkVolumeDeviceNames +} + +// GetLinkVolumeDeviceNamesOk returns a tuple with the LinkVolumeDeviceNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetLinkVolumeDeviceNamesOk() (*[]string, bool) { + if o == nil || o.LinkVolumeDeviceNames == nil { + return nil, false + } + return o.LinkVolumeDeviceNames, true +} + +// HasLinkVolumeDeviceNames returns a boolean if a field has been set. +func (o *FiltersVolume) HasLinkVolumeDeviceNames() bool { + if o != nil && o.LinkVolumeDeviceNames != nil { + return true + } + + return false +} + +// SetLinkVolumeDeviceNames gets a reference to the given []string and assigns it to the LinkVolumeDeviceNames field. +func (o *FiltersVolume) SetLinkVolumeDeviceNames(v []string) { + o.LinkVolumeDeviceNames = &v +} + +// GetLinkVolumeLinkDates returns the LinkVolumeLinkDates field value if set, zero value otherwise. +func (o *FiltersVolume) GetLinkVolumeLinkDates() []string { + if o == nil || o.LinkVolumeLinkDates == nil { + var ret []string + return ret + } + return *o.LinkVolumeLinkDates +} + +// GetLinkVolumeLinkDatesOk returns a tuple with the LinkVolumeLinkDates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetLinkVolumeLinkDatesOk() (*[]string, bool) { + if o == nil || o.LinkVolumeLinkDates == nil { + return nil, false + } + return o.LinkVolumeLinkDates, true +} + +// HasLinkVolumeLinkDates returns a boolean if a field has been set. +func (o *FiltersVolume) HasLinkVolumeLinkDates() bool { + if o != nil && o.LinkVolumeLinkDates != nil { + return true + } + + return false +} + +// SetLinkVolumeLinkDates gets a reference to the given []string and assigns it to the LinkVolumeLinkDates field. +func (o *FiltersVolume) SetLinkVolumeLinkDates(v []string) { + o.LinkVolumeLinkDates = &v +} + +// GetLinkVolumeLinkStates returns the LinkVolumeLinkStates field value if set, zero value otherwise. +func (o *FiltersVolume) GetLinkVolumeLinkStates() []string { + if o == nil || o.LinkVolumeLinkStates == nil { + var ret []string + return ret + } + return *o.LinkVolumeLinkStates +} + +// GetLinkVolumeLinkStatesOk returns a tuple with the LinkVolumeLinkStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetLinkVolumeLinkStatesOk() (*[]string, bool) { + if o == nil || o.LinkVolumeLinkStates == nil { + return nil, false + } + return o.LinkVolumeLinkStates, true +} + +// HasLinkVolumeLinkStates returns a boolean if a field has been set. +func (o *FiltersVolume) HasLinkVolumeLinkStates() bool { + if o != nil && o.LinkVolumeLinkStates != nil { + return true + } + + return false +} + +// SetLinkVolumeLinkStates gets a reference to the given []string and assigns it to the LinkVolumeLinkStates field. +func (o *FiltersVolume) SetLinkVolumeLinkStates(v []string) { + o.LinkVolumeLinkStates = &v +} + +// GetLinkVolumeVmIds returns the LinkVolumeVmIds field value if set, zero value otherwise. +func (o *FiltersVolume) GetLinkVolumeVmIds() []string { + if o == nil || o.LinkVolumeVmIds == nil { + var ret []string + return ret + } + return *o.LinkVolumeVmIds +} + +// GetLinkVolumeVmIdsOk returns a tuple with the LinkVolumeVmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetLinkVolumeVmIdsOk() (*[]string, bool) { + if o == nil || o.LinkVolumeVmIds == nil { + return nil, false + } + return o.LinkVolumeVmIds, true +} + +// HasLinkVolumeVmIds returns a boolean if a field has been set. +func (o *FiltersVolume) HasLinkVolumeVmIds() bool { + if o != nil && o.LinkVolumeVmIds != nil { + return true + } + + return false +} + +// SetLinkVolumeVmIds gets a reference to the given []string and assigns it to the LinkVolumeVmIds field. +func (o *FiltersVolume) SetLinkVolumeVmIds(v []string) { + o.LinkVolumeVmIds = &v +} + +// GetSnapshotIds returns the SnapshotIds field value if set, zero value otherwise. +func (o *FiltersVolume) GetSnapshotIds() []string { + if o == nil || o.SnapshotIds == nil { + var ret []string + return ret + } + return *o.SnapshotIds +} + +// GetSnapshotIdsOk returns a tuple with the SnapshotIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetSnapshotIdsOk() (*[]string, bool) { + if o == nil || o.SnapshotIds == nil { + return nil, false + } + return o.SnapshotIds, true +} + +// HasSnapshotIds returns a boolean if a field has been set. +func (o *FiltersVolume) HasSnapshotIds() bool { + if o != nil && o.SnapshotIds != nil { + return true + } + + return false +} + +// SetSnapshotIds gets a reference to the given []string and assigns it to the SnapshotIds field. +func (o *FiltersVolume) SetSnapshotIds(v []string) { + o.SnapshotIds = &v +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *FiltersVolume) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *FiltersVolume) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *FiltersVolume) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersVolume) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersVolume) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersVolume) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersVolume) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersVolume) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersVolume) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersVolume) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersVolume) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersVolume) SetTags(v []string) { + o.Tags = &v +} + +// GetVolumeIds returns the VolumeIds field value if set, zero value otherwise. +func (o *FiltersVolume) GetVolumeIds() []string { + if o == nil || o.VolumeIds == nil { + var ret []string + return ret + } + return *o.VolumeIds +} + +// GetVolumeIdsOk returns a tuple with the VolumeIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetVolumeIdsOk() (*[]string, bool) { + if o == nil || o.VolumeIds == nil { + return nil, false + } + return o.VolumeIds, true +} + +// HasVolumeIds returns a boolean if a field has been set. +func (o *FiltersVolume) HasVolumeIds() bool { + if o != nil && o.VolumeIds != nil { + return true + } + + return false +} + +// SetVolumeIds gets a reference to the given []string and assigns it to the VolumeIds field. +func (o *FiltersVolume) SetVolumeIds(v []string) { + o.VolumeIds = &v +} + +// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. +func (o *FiltersVolume) GetVolumeSizes() []int32 { + if o == nil || o.VolumeSizes == nil { + var ret []int32 + return ret + } + return *o.VolumeSizes +} + +// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetVolumeSizesOk() (*[]int32, bool) { + if o == nil || o.VolumeSizes == nil { + return nil, false + } + return o.VolumeSizes, true +} + +// HasVolumeSizes returns a boolean if a field has been set. +func (o *FiltersVolume) HasVolumeSizes() bool { + if o != nil && o.VolumeSizes != nil { + return true + } + + return false +} + +// SetVolumeSizes gets a reference to the given []int32 and assigns it to the VolumeSizes field. +func (o *FiltersVolume) SetVolumeSizes(v []int32) { + o.VolumeSizes = &v +} + +// GetVolumeStates returns the VolumeStates field value if set, zero value otherwise. +func (o *FiltersVolume) GetVolumeStates() []string { + if o == nil || o.VolumeStates == nil { + var ret []string + return ret + } + return *o.VolumeStates +} + +// GetVolumeStatesOk returns a tuple with the VolumeStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetVolumeStatesOk() (*[]string, bool) { + if o == nil || o.VolumeStates == nil { + return nil, false + } + return o.VolumeStates, true +} + +// HasVolumeStates returns a boolean if a field has been set. +func (o *FiltersVolume) HasVolumeStates() bool { + if o != nil && o.VolumeStates != nil { + return true + } + + return false +} + +// SetVolumeStates gets a reference to the given []string and assigns it to the VolumeStates field. +func (o *FiltersVolume) SetVolumeStates(v []string) { + o.VolumeStates = &v +} + +// GetVolumeTypes returns the VolumeTypes field value if set, zero value otherwise. +func (o *FiltersVolume) GetVolumeTypes() []string { + if o == nil || o.VolumeTypes == nil { + var ret []string + return ret + } + return *o.VolumeTypes +} + +// GetVolumeTypesOk returns a tuple with the VolumeTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVolume) GetVolumeTypesOk() (*[]string, bool) { + if o == nil || o.VolumeTypes == nil { + return nil, false + } + return o.VolumeTypes, true +} + +// HasVolumeTypes returns a boolean if a field has been set. +func (o *FiltersVolume) HasVolumeTypes() bool { + if o != nil && o.VolumeTypes != nil { + return true + } + + return false +} + +// SetVolumeTypes gets a reference to the given []string and assigns it to the VolumeTypes field. +func (o *FiltersVolume) SetVolumeTypes(v []string) { + o.VolumeTypes = &v +} + +func (o FiltersVolume) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.CreationDates != nil { + toSerialize["CreationDates"] = o.CreationDates + } + if o.LinkVolumeDeleteOnVmDeletion != nil { + toSerialize["LinkVolumeDeleteOnVmDeletion"] = o.LinkVolumeDeleteOnVmDeletion + } + if o.LinkVolumeDeviceNames != nil { + toSerialize["LinkVolumeDeviceNames"] = o.LinkVolumeDeviceNames + } + if o.LinkVolumeLinkDates != nil { + toSerialize["LinkVolumeLinkDates"] = o.LinkVolumeLinkDates + } + if o.LinkVolumeLinkStates != nil { + toSerialize["LinkVolumeLinkStates"] = o.LinkVolumeLinkStates + } + if o.LinkVolumeVmIds != nil { + toSerialize["LinkVolumeVmIds"] = o.LinkVolumeVmIds + } + if o.SnapshotIds != nil { + toSerialize["SnapshotIds"] = o.SnapshotIds + } + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VolumeIds != nil { + toSerialize["VolumeIds"] = o.VolumeIds + } + if o.VolumeSizes != nil { + toSerialize["VolumeSizes"] = o.VolumeSizes + } + if o.VolumeStates != nil { + toSerialize["VolumeStates"] = o.VolumeStates + } + if o.VolumeTypes != nil { + toSerialize["VolumeTypes"] = o.VolumeTypes + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVolume struct { + value *FiltersVolume + isSet bool +} + +func (v NullableFiltersVolume) Get() *FiltersVolume { + return v.value +} + +func (v *NullableFiltersVolume) Set(val *FiltersVolume) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVolume) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVolume) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVolume(val *FiltersVolume) *NullableFiltersVolume { + return &NullableFiltersVolume{value: val, isSet: true} +} + +func (v NullableFiltersVolume) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVolume) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go new file mode 100644 index 000000000..e9077b29c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go @@ -0,0 +1,487 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FiltersVpnConnection One or more filters. +type FiltersVpnConnection struct { + // The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. + BgpAsns *[]int32 `json:"BgpAsns,omitempty"` + // The IDs of the client gateways. + ClientGatewayIds *[]string `json:"ClientGatewayIds,omitempty"` + // The types of the VPN connections (only `ipsec.1` is supported). + ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` + // The destination IP ranges. + RouteDestinationIpRanges *[]string `json:"RouteDestinationIpRanges,omitempty"` + // The states of the VPN connections (`pending` \\| `available` \\| `deleting` \\| `deleted`). + States *[]string `json:"States,omitempty"` + // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). + StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` + // The keys of the tags associated with the VPN connections. + TagKeys *[]string `json:"TagKeys,omitempty"` + // The values of the tags associated with the VPN connections. + TagValues *[]string `json:"TagValues,omitempty"` + // The key/value combination of the tags associated with the VPN connections, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. + Tags *[]string `json:"Tags,omitempty"` + // The IDs of the virtual gateways. + VirtualGatewayIds *[]string `json:"VirtualGatewayIds,omitempty"` + // The IDs of the VPN connections. + VpnConnectionIds *[]string `json:"VpnConnectionIds,omitempty"` +} + +// NewFiltersVpnConnection instantiates a new FiltersVpnConnection object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFiltersVpnConnection() *FiltersVpnConnection { + this := FiltersVpnConnection{} + return &this +} + +// NewFiltersVpnConnectionWithDefaults instantiates a new FiltersVpnConnection object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFiltersVpnConnectionWithDefaults() *FiltersVpnConnection { + this := FiltersVpnConnection{} + return &this +} + +// GetBgpAsns returns the BgpAsns field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetBgpAsns() []int32 { + if o == nil || o.BgpAsns == nil { + var ret []int32 + return ret + } + return *o.BgpAsns +} + +// GetBgpAsnsOk returns a tuple with the BgpAsns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetBgpAsnsOk() (*[]int32, bool) { + if o == nil || o.BgpAsns == nil { + return nil, false + } + return o.BgpAsns, true +} + +// HasBgpAsns returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasBgpAsns() bool { + if o != nil && o.BgpAsns != nil { + return true + } + + return false +} + +// SetBgpAsns gets a reference to the given []int32 and assigns it to the BgpAsns field. +func (o *FiltersVpnConnection) SetBgpAsns(v []int32) { + o.BgpAsns = &v +} + +// GetClientGatewayIds returns the ClientGatewayIds field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetClientGatewayIds() []string { + if o == nil || o.ClientGatewayIds == nil { + var ret []string + return ret + } + return *o.ClientGatewayIds +} + +// GetClientGatewayIdsOk returns a tuple with the ClientGatewayIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetClientGatewayIdsOk() (*[]string, bool) { + if o == nil || o.ClientGatewayIds == nil { + return nil, false + } + return o.ClientGatewayIds, true +} + +// HasClientGatewayIds returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasClientGatewayIds() bool { + if o != nil && o.ClientGatewayIds != nil { + return true + } + + return false +} + +// SetClientGatewayIds gets a reference to the given []string and assigns it to the ClientGatewayIds field. +func (o *FiltersVpnConnection) SetClientGatewayIds(v []string) { + o.ClientGatewayIds = &v +} + +// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetConnectionTypes() []string { + if o == nil || o.ConnectionTypes == nil { + var ret []string + return ret + } + return *o.ConnectionTypes +} + +// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetConnectionTypesOk() (*[]string, bool) { + if o == nil || o.ConnectionTypes == nil { + return nil, false + } + return o.ConnectionTypes, true +} + +// HasConnectionTypes returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasConnectionTypes() bool { + if o != nil && o.ConnectionTypes != nil { + return true + } + + return false +} + +// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. +func (o *FiltersVpnConnection) SetConnectionTypes(v []string) { + o.ConnectionTypes = &v +} + +// GetRouteDestinationIpRanges returns the RouteDestinationIpRanges field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetRouteDestinationIpRanges() []string { + if o == nil || o.RouteDestinationIpRanges == nil { + var ret []string + return ret + } + return *o.RouteDestinationIpRanges +} + +// GetRouteDestinationIpRangesOk returns a tuple with the RouteDestinationIpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetRouteDestinationIpRangesOk() (*[]string, bool) { + if o == nil || o.RouteDestinationIpRanges == nil { + return nil, false + } + return o.RouteDestinationIpRanges, true +} + +// HasRouteDestinationIpRanges returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasRouteDestinationIpRanges() bool { + if o != nil && o.RouteDestinationIpRanges != nil { + return true + } + + return false +} + +// SetRouteDestinationIpRanges gets a reference to the given []string and assigns it to the RouteDestinationIpRanges field. +func (o *FiltersVpnConnection) SetRouteDestinationIpRanges(v []string) { + o.RouteDestinationIpRanges = &v +} + +// GetStates returns the States field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetStates() []string { + if o == nil || o.States == nil { + var ret []string + return ret + } + return *o.States +} + +// GetStatesOk returns a tuple with the States field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetStatesOk() (*[]string, bool) { + if o == nil || o.States == nil { + return nil, false + } + return o.States, true +} + +// HasStates returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasStates() bool { + if o != nil && o.States != nil { + return true + } + + return false +} + +// SetStates gets a reference to the given []string and assigns it to the States field. +func (o *FiltersVpnConnection) SetStates(v []string) { + o.States = &v +} + +// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetStaticRoutesOnly() bool { + if o == nil || o.StaticRoutesOnly == nil { + var ret bool + return ret + } + return *o.StaticRoutesOnly +} + +// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetStaticRoutesOnlyOk() (*bool, bool) { + if o == nil || o.StaticRoutesOnly == nil { + return nil, false + } + return o.StaticRoutesOnly, true +} + +// HasStaticRoutesOnly returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasStaticRoutesOnly() bool { + if o != nil && o.StaticRoutesOnly != nil { + return true + } + + return false +} + +// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. +func (o *FiltersVpnConnection) SetStaticRoutesOnly(v bool) { + o.StaticRoutesOnly = &v +} + +// GetTagKeys returns the TagKeys field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetTagKeys() []string { + if o == nil || o.TagKeys == nil { + var ret []string + return ret + } + return *o.TagKeys +} + +// GetTagKeysOk returns a tuple with the TagKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetTagKeysOk() (*[]string, bool) { + if o == nil || o.TagKeys == nil { + return nil, false + } + return o.TagKeys, true +} + +// HasTagKeys returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasTagKeys() bool { + if o != nil && o.TagKeys != nil { + return true + } + + return false +} + +// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. +func (o *FiltersVpnConnection) SetTagKeys(v []string) { + o.TagKeys = &v +} + +// GetTagValues returns the TagValues field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetTagValues() []string { + if o == nil || o.TagValues == nil { + var ret []string + return ret + } + return *o.TagValues +} + +// GetTagValuesOk returns a tuple with the TagValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetTagValuesOk() (*[]string, bool) { + if o == nil || o.TagValues == nil { + return nil, false + } + return o.TagValues, true +} + +// HasTagValues returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasTagValues() bool { + if o != nil && o.TagValues != nil { + return true + } + + return false +} + +// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. +func (o *FiltersVpnConnection) SetTagValues(v []string) { + o.TagValues = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetTags() []string { + if o == nil || o.Tags == nil { + var ret []string + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetTagsOk() (*[]string, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *FiltersVpnConnection) SetTags(v []string) { + o.Tags = &v +} + +// GetVirtualGatewayIds returns the VirtualGatewayIds field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetVirtualGatewayIds() []string { + if o == nil || o.VirtualGatewayIds == nil { + var ret []string + return ret + } + return *o.VirtualGatewayIds +} + +// GetVirtualGatewayIdsOk returns a tuple with the VirtualGatewayIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetVirtualGatewayIdsOk() (*[]string, bool) { + if o == nil || o.VirtualGatewayIds == nil { + return nil, false + } + return o.VirtualGatewayIds, true +} + +// HasVirtualGatewayIds returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasVirtualGatewayIds() bool { + if o != nil && o.VirtualGatewayIds != nil { + return true + } + + return false +} + +// SetVirtualGatewayIds gets a reference to the given []string and assigns it to the VirtualGatewayIds field. +func (o *FiltersVpnConnection) SetVirtualGatewayIds(v []string) { + o.VirtualGatewayIds = &v +} + +// GetVpnConnectionIds returns the VpnConnectionIds field value if set, zero value otherwise. +func (o *FiltersVpnConnection) GetVpnConnectionIds() []string { + if o == nil || o.VpnConnectionIds == nil { + var ret []string + return ret + } + return *o.VpnConnectionIds +} + +// GetVpnConnectionIdsOk returns a tuple with the VpnConnectionIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FiltersVpnConnection) GetVpnConnectionIdsOk() (*[]string, bool) { + if o == nil || o.VpnConnectionIds == nil { + return nil, false + } + return o.VpnConnectionIds, true +} + +// HasVpnConnectionIds returns a boolean if a field has been set. +func (o *FiltersVpnConnection) HasVpnConnectionIds() bool { + if o != nil && o.VpnConnectionIds != nil { + return true + } + + return false +} + +// SetVpnConnectionIds gets a reference to the given []string and assigns it to the VpnConnectionIds field. +func (o *FiltersVpnConnection) SetVpnConnectionIds(v []string) { + o.VpnConnectionIds = &v +} + +func (o FiltersVpnConnection) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BgpAsns != nil { + toSerialize["BgpAsns"] = o.BgpAsns + } + if o.ClientGatewayIds != nil { + toSerialize["ClientGatewayIds"] = o.ClientGatewayIds + } + if o.ConnectionTypes != nil { + toSerialize["ConnectionTypes"] = o.ConnectionTypes + } + if o.RouteDestinationIpRanges != nil { + toSerialize["RouteDestinationIpRanges"] = o.RouteDestinationIpRanges + } + if o.States != nil { + toSerialize["States"] = o.States + } + if o.StaticRoutesOnly != nil { + toSerialize["StaticRoutesOnly"] = o.StaticRoutesOnly + } + if o.TagKeys != nil { + toSerialize["TagKeys"] = o.TagKeys + } + if o.TagValues != nil { + toSerialize["TagValues"] = o.TagValues + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VirtualGatewayIds != nil { + toSerialize["VirtualGatewayIds"] = o.VirtualGatewayIds + } + if o.VpnConnectionIds != nil { + toSerialize["VpnConnectionIds"] = o.VpnConnectionIds + } + return json.Marshal(toSerialize) +} + +type NullableFiltersVpnConnection struct { + value *FiltersVpnConnection + isSet bool +} + +func (v NullableFiltersVpnConnection) Get() *FiltersVpnConnection { + return v.value +} + +func (v *NullableFiltersVpnConnection) Set(val *FiltersVpnConnection) { + v.value = val + v.isSet = true +} + +func (v NullableFiltersVpnConnection) IsSet() bool { + return v.isSet +} + +func (v *NullableFiltersVpnConnection) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFiltersVpnConnection(val *FiltersVpnConnection) *NullableFiltersVpnConnection { + return &NullableFiltersVpnConnection{value: val, isSet: true} +} + +func (v NullableFiltersVpnConnection) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFiltersVpnConnection) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go new file mode 100644 index 000000000..9d9fd4c6e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FlexibleGpu Information about the flexible GPU (fGPU). +type FlexibleGpu struct { + // If `true`, the fGPU is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The ID of the fGPU. + FlexibleGpuId *string `json:"FlexibleGpuId,omitempty"` + // The compatible processor generation. + Generation *string `json:"Generation,omitempty"` + // The model of fGPU. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). + ModelName *string `json:"ModelName,omitempty"` + // The state of the fGPU (`allocated` \\| `attaching` \\| `attached` \\| `detaching`). + State *string `json:"State,omitempty"` + // The Subregion where the fGPU is located. + SubregionName *string `json:"SubregionName,omitempty"` + // The ID of the VM the fGPU is attached to, if any. + VmId *string `json:"VmId,omitempty"` +} + +// NewFlexibleGpu instantiates a new FlexibleGpu object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFlexibleGpu() *FlexibleGpu { + this := FlexibleGpu{} + return &this +} + +// NewFlexibleGpuWithDefaults instantiates a new FlexibleGpu object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFlexibleGpuWithDefaults() *FlexibleGpu { + this := FlexibleGpu{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *FlexibleGpu) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *FlexibleGpu) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *FlexibleGpu) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetFlexibleGpuId returns the FlexibleGpuId field value if set, zero value otherwise. +func (o *FlexibleGpu) GetFlexibleGpuId() string { + if o == nil || o.FlexibleGpuId == nil { + var ret string + return ret + } + return *o.FlexibleGpuId +} + +// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetFlexibleGpuIdOk() (*string, bool) { + if o == nil || o.FlexibleGpuId == nil { + return nil, false + } + return o.FlexibleGpuId, true +} + +// HasFlexibleGpuId returns a boolean if a field has been set. +func (o *FlexibleGpu) HasFlexibleGpuId() bool { + if o != nil && o.FlexibleGpuId != nil { + return true + } + + return false +} + +// SetFlexibleGpuId gets a reference to the given string and assigns it to the FlexibleGpuId field. +func (o *FlexibleGpu) SetFlexibleGpuId(v string) { + o.FlexibleGpuId = &v +} + +// GetGeneration returns the Generation field value if set, zero value otherwise. +func (o *FlexibleGpu) GetGeneration() string { + if o == nil || o.Generation == nil { + var ret string + return ret + } + return *o.Generation +} + +// GetGenerationOk returns a tuple with the Generation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetGenerationOk() (*string, bool) { + if o == nil || o.Generation == nil { + return nil, false + } + return o.Generation, true +} + +// HasGeneration returns a boolean if a field has been set. +func (o *FlexibleGpu) HasGeneration() bool { + if o != nil && o.Generation != nil { + return true + } + + return false +} + +// SetGeneration gets a reference to the given string and assigns it to the Generation field. +func (o *FlexibleGpu) SetGeneration(v string) { + o.Generation = &v +} + +// GetModelName returns the ModelName field value if set, zero value otherwise. +func (o *FlexibleGpu) GetModelName() string { + if o == nil || o.ModelName == nil { + var ret string + return ret + } + return *o.ModelName +} + +// GetModelNameOk returns a tuple with the ModelName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetModelNameOk() (*string, bool) { + if o == nil || o.ModelName == nil { + return nil, false + } + return o.ModelName, true +} + +// HasModelName returns a boolean if a field has been set. +func (o *FlexibleGpu) HasModelName() bool { + if o != nil && o.ModelName != nil { + return true + } + + return false +} + +// SetModelName gets a reference to the given string and assigns it to the ModelName field. +func (o *FlexibleGpu) SetModelName(v string) { + o.ModelName = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *FlexibleGpu) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *FlexibleGpu) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *FlexibleGpu) SetState(v string) { + o.State = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *FlexibleGpu) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *FlexibleGpu) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *FlexibleGpu) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *FlexibleGpu) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpu) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *FlexibleGpu) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *FlexibleGpu) SetVmId(v string) { + o.VmId = &v +} + +func (o FlexibleGpu) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.FlexibleGpuId != nil { + toSerialize["FlexibleGpuId"] = o.FlexibleGpuId + } + if o.Generation != nil { + toSerialize["Generation"] = o.Generation + } + if o.ModelName != nil { + toSerialize["ModelName"] = o.ModelName + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableFlexibleGpu struct { + value *FlexibleGpu + isSet bool +} + +func (v NullableFlexibleGpu) Get() *FlexibleGpu { + return v.value +} + +func (v *NullableFlexibleGpu) Set(val *FlexibleGpu) { + v.value = val + v.isSet = true +} + +func (v NullableFlexibleGpu) IsSet() bool { + return v.isSet +} + +func (v *NullableFlexibleGpu) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFlexibleGpu(val *FlexibleGpu) *NullableFlexibleGpu { + return &NullableFlexibleGpu{value: val, isSet: true} +} + +func (v NullableFlexibleGpu) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFlexibleGpu) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go new file mode 100644 index 000000000..ee183a911 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// FlexibleGpuCatalog Information about the flexible GPU (fGPU) that is available in the public catalog. +type FlexibleGpuCatalog struct { + // The generations of VMs that the fGPU is compatible with. + Generations *[]string `json:"Generations,omitempty"` + // The maximum number of VM vCores that the fGPU is compatible with. + MaxCpu *int32 `json:"MaxCpu,omitempty"` + // The maximum amount of VM memory that the fGPU is compatible with. + MaxRam *int32 `json:"MaxRam,omitempty"` + // The model of fGPU. + ModelName *string `json:"ModelName,omitempty"` + // The amount of video RAM (VRAM) of the fGPU. + VRam *int32 `json:"VRam,omitempty"` +} + +// NewFlexibleGpuCatalog instantiates a new FlexibleGpuCatalog object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFlexibleGpuCatalog() *FlexibleGpuCatalog { + this := FlexibleGpuCatalog{} + return &this +} + +// NewFlexibleGpuCatalogWithDefaults instantiates a new FlexibleGpuCatalog object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFlexibleGpuCatalogWithDefaults() *FlexibleGpuCatalog { + this := FlexibleGpuCatalog{} + return &this +} + +// GetGenerations returns the Generations field value if set, zero value otherwise. +func (o *FlexibleGpuCatalog) GetGenerations() []string { + if o == nil || o.Generations == nil { + var ret []string + return ret + } + return *o.Generations +} + +// GetGenerationsOk returns a tuple with the Generations field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpuCatalog) GetGenerationsOk() (*[]string, bool) { + if o == nil || o.Generations == nil { + return nil, false + } + return o.Generations, true +} + +// HasGenerations returns a boolean if a field has been set. +func (o *FlexibleGpuCatalog) HasGenerations() bool { + if o != nil && o.Generations != nil { + return true + } + + return false +} + +// SetGenerations gets a reference to the given []string and assigns it to the Generations field. +func (o *FlexibleGpuCatalog) SetGenerations(v []string) { + o.Generations = &v +} + +// GetMaxCpu returns the MaxCpu field value if set, zero value otherwise. +func (o *FlexibleGpuCatalog) GetMaxCpu() int32 { + if o == nil || o.MaxCpu == nil { + var ret int32 + return ret + } + return *o.MaxCpu +} + +// GetMaxCpuOk returns a tuple with the MaxCpu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpuCatalog) GetMaxCpuOk() (*int32, bool) { + if o == nil || o.MaxCpu == nil { + return nil, false + } + return o.MaxCpu, true +} + +// HasMaxCpu returns a boolean if a field has been set. +func (o *FlexibleGpuCatalog) HasMaxCpu() bool { + if o != nil && o.MaxCpu != nil { + return true + } + + return false +} + +// SetMaxCpu gets a reference to the given int32 and assigns it to the MaxCpu field. +func (o *FlexibleGpuCatalog) SetMaxCpu(v int32) { + o.MaxCpu = &v +} + +// GetMaxRam returns the MaxRam field value if set, zero value otherwise. +func (o *FlexibleGpuCatalog) GetMaxRam() int32 { + if o == nil || o.MaxRam == nil { + var ret int32 + return ret + } + return *o.MaxRam +} + +// GetMaxRamOk returns a tuple with the MaxRam field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpuCatalog) GetMaxRamOk() (*int32, bool) { + if o == nil || o.MaxRam == nil { + return nil, false + } + return o.MaxRam, true +} + +// HasMaxRam returns a boolean if a field has been set. +func (o *FlexibleGpuCatalog) HasMaxRam() bool { + if o != nil && o.MaxRam != nil { + return true + } + + return false +} + +// SetMaxRam gets a reference to the given int32 and assigns it to the MaxRam field. +func (o *FlexibleGpuCatalog) SetMaxRam(v int32) { + o.MaxRam = &v +} + +// GetModelName returns the ModelName field value if set, zero value otherwise. +func (o *FlexibleGpuCatalog) GetModelName() string { + if o == nil || o.ModelName == nil { + var ret string + return ret + } + return *o.ModelName +} + +// GetModelNameOk returns a tuple with the ModelName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpuCatalog) GetModelNameOk() (*string, bool) { + if o == nil || o.ModelName == nil { + return nil, false + } + return o.ModelName, true +} + +// HasModelName returns a boolean if a field has been set. +func (o *FlexibleGpuCatalog) HasModelName() bool { + if o != nil && o.ModelName != nil { + return true + } + + return false +} + +// SetModelName gets a reference to the given string and assigns it to the ModelName field. +func (o *FlexibleGpuCatalog) SetModelName(v string) { + o.ModelName = &v +} + +// GetVRam returns the VRam field value if set, zero value otherwise. +func (o *FlexibleGpuCatalog) GetVRam() int32 { + if o == nil || o.VRam == nil { + var ret int32 + return ret + } + return *o.VRam +} + +// GetVRamOk returns a tuple with the VRam field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FlexibleGpuCatalog) GetVRamOk() (*int32, bool) { + if o == nil || o.VRam == nil { + return nil, false + } + return o.VRam, true +} + +// HasVRam returns a boolean if a field has been set. +func (o *FlexibleGpuCatalog) HasVRam() bool { + if o != nil && o.VRam != nil { + return true + } + + return false +} + +// SetVRam gets a reference to the given int32 and assigns it to the VRam field. +func (o *FlexibleGpuCatalog) SetVRam(v int32) { + o.VRam = &v +} + +func (o FlexibleGpuCatalog) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Generations != nil { + toSerialize["Generations"] = o.Generations + } + if o.MaxCpu != nil { + toSerialize["MaxCpu"] = o.MaxCpu + } + if o.MaxRam != nil { + toSerialize["MaxRam"] = o.MaxRam + } + if o.ModelName != nil { + toSerialize["ModelName"] = o.ModelName + } + if o.VRam != nil { + toSerialize["VRam"] = o.VRam + } + return json.Marshal(toSerialize) +} + +type NullableFlexibleGpuCatalog struct { + value *FlexibleGpuCatalog + isSet bool +} + +func (v NullableFlexibleGpuCatalog) Get() *FlexibleGpuCatalog { + return v.value +} + +func (v *NullableFlexibleGpuCatalog) Set(val *FlexibleGpuCatalog) { + v.value = val + v.isSet = true +} + +func (v NullableFlexibleGpuCatalog) IsSet() bool { + return v.isSet +} + +func (v *NullableFlexibleGpuCatalog) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFlexibleGpuCatalog(val *FlexibleGpuCatalog) *NullableFlexibleGpuCatalog { + return &NullableFlexibleGpuCatalog{value: val, isSet: true} +} + +func (v NullableFlexibleGpuCatalog) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFlexibleGpuCatalog) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go new file mode 100644 index 000000000..f9191b083 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go @@ -0,0 +1,297 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// HealthCheck Information about the health check configuration. +type HealthCheck struct { + // The number of seconds between two pings (between `5` and `600` both included). + CheckInterval int32 `json:"CheckInterval"` + // The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + HealthyThreshold int32 `json:"HealthyThreshold"` + // The path for HTTP or HTTPS requests. + Path *string `json:"Path,omitempty"` + // The port number (between `1` and `65535`, both included). + Port int32 `json:"Port"` + // The protocol for the URL of the VM (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). + Protocol string `json:"Protocol"` + // The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + Timeout int32 `json:"Timeout"` + // The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + UnhealthyThreshold int32 `json:"UnhealthyThreshold"` +} + +// NewHealthCheck instantiates a new HealthCheck object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewHealthCheck(checkInterval int32, healthyThreshold int32, port int32, protocol string, timeout int32, unhealthyThreshold int32, ) *HealthCheck { + this := HealthCheck{} + this.CheckInterval = checkInterval + this.HealthyThreshold = healthyThreshold + this.Port = port + this.Protocol = protocol + this.Timeout = timeout + this.UnhealthyThreshold = unhealthyThreshold + return &this +} + +// NewHealthCheckWithDefaults instantiates a new HealthCheck object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewHealthCheckWithDefaults() *HealthCheck { + this := HealthCheck{} + return &this +} + +// GetCheckInterval returns the CheckInterval field value +func (o *HealthCheck) GetCheckInterval() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.CheckInterval +} + +// GetCheckIntervalOk returns a tuple with the CheckInterval field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetCheckIntervalOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.CheckInterval, true +} + +// SetCheckInterval sets field value +func (o *HealthCheck) SetCheckInterval(v int32) { + o.CheckInterval = v +} + +// GetHealthyThreshold returns the HealthyThreshold field value +func (o *HealthCheck) GetHealthyThreshold() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.HealthyThreshold +} + +// GetHealthyThresholdOk returns a tuple with the HealthyThreshold field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetHealthyThresholdOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.HealthyThreshold, true +} + +// SetHealthyThreshold sets field value +func (o *HealthCheck) SetHealthyThreshold(v int32) { + o.HealthyThreshold = v +} + +// GetPath returns the Path field value if set, zero value otherwise. +func (o *HealthCheck) GetPath() string { + if o == nil || o.Path == nil { + var ret string + return ret + } + return *o.Path +} + +// GetPathOk returns a tuple with the Path field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetPathOk() (*string, bool) { + if o == nil || o.Path == nil { + return nil, false + } + return o.Path, true +} + +// HasPath returns a boolean if a field has been set. +func (o *HealthCheck) HasPath() bool { + if o != nil && o.Path != nil { + return true + } + + return false +} + +// SetPath gets a reference to the given string and assigns it to the Path field. +func (o *HealthCheck) SetPath(v string) { + o.Path = &v +} + +// GetPort returns the Port field value +func (o *HealthCheck) GetPort() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Port +} + +// GetPortOk returns a tuple with the Port field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetPortOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Port, true +} + +// SetPort sets field value +func (o *HealthCheck) SetPort(v int32) { + o.Port = v +} + +// GetProtocol returns the Protocol field value +func (o *HealthCheck) GetProtocol() string { + if o == nil { + var ret string + return ret + } + + return o.Protocol +} + +// GetProtocolOk returns a tuple with the Protocol field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetProtocolOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Protocol, true +} + +// SetProtocol sets field value +func (o *HealthCheck) SetProtocol(v string) { + o.Protocol = v +} + +// GetTimeout returns the Timeout field value +func (o *HealthCheck) GetTimeout() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Timeout +} + +// GetTimeoutOk returns a tuple with the Timeout field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetTimeoutOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Timeout, true +} + +// SetTimeout sets field value +func (o *HealthCheck) SetTimeout(v int32) { + o.Timeout = v +} + +// GetUnhealthyThreshold returns the UnhealthyThreshold field value +func (o *HealthCheck) GetUnhealthyThreshold() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.UnhealthyThreshold +} + +// GetUnhealthyThresholdOk returns a tuple with the UnhealthyThreshold field value +// and a boolean to check if the value has been set. +func (o *HealthCheck) GetUnhealthyThresholdOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.UnhealthyThreshold, true +} + +// SetUnhealthyThreshold sets field value +func (o *HealthCheck) SetUnhealthyThreshold(v int32) { + o.UnhealthyThreshold = v +} + +func (o HealthCheck) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["CheckInterval"] = o.CheckInterval + } + if true { + toSerialize["HealthyThreshold"] = o.HealthyThreshold + } + if o.Path != nil { + toSerialize["Path"] = o.Path + } + if true { + toSerialize["Port"] = o.Port + } + if true { + toSerialize["Protocol"] = o.Protocol + } + if true { + toSerialize["Timeout"] = o.Timeout + } + if true { + toSerialize["UnhealthyThreshold"] = o.UnhealthyThreshold + } + return json.Marshal(toSerialize) +} + +type NullableHealthCheck struct { + value *HealthCheck + isSet bool +} + +func (v NullableHealthCheck) Get() *HealthCheck { + return v.value +} + +func (v *NullableHealthCheck) Set(val *HealthCheck) { + v.value = val + v.isSet = true +} + +func (v NullableHealthCheck) IsSet() bool { + return v.isSet +} + +func (v *NullableHealthCheck) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableHealthCheck(val *HealthCheck) *NullableHealthCheck { + return &NullableHealthCheck{value: val, isSet: true} +} + +func (v NullableHealthCheck) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableHealthCheck) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_image.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_image.go new file mode 100644 index 000000000..af8ab9ae4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_image.go @@ -0,0 +1,707 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Image Information about the OMI. +type Image struct { + // The account alias of the owner of the OMI. + AccountAlias *string `json:"AccountAlias,omitempty"` + // The account ID of the owner of the OMI. + AccountId *string `json:"AccountId,omitempty"` + // The architecture of the OMI (by default, `i386`). + Architecture *string `json:"Architecture,omitempty"` + // One or more block device mappings. + BlockDeviceMappings *[]BlockDeviceMappingImage `json:"BlockDeviceMappings,omitempty"` + // The date and time at which the OMI was created. + CreationDate *string `json:"CreationDate,omitempty"` + // The description of the OMI. + Description *string `json:"Description,omitempty"` + // The location where the OMI file is stored on Object Storage Unit (OSU). + FileLocation *string `json:"FileLocation,omitempty"` + // The ID of the OMI. + ImageId *string `json:"ImageId,omitempty"` + // The name of the OMI. + ImageName *string `json:"ImageName,omitempty"` + // The type of the OMI. + ImageType *string `json:"ImageType,omitempty"` + PermissionsToLaunch *PermissionsOnResource `json:"PermissionsToLaunch,omitempty"` + // The product code associated with the OMI (`0001` Linux/Unix \\| `0002` Windows \\| `0004` Linux/Oracle \\| `0005` Windows 10). + ProductCodes *[]string `json:"ProductCodes,omitempty"` + // The name of the root device. + RootDeviceName *string `json:"RootDeviceName,omitempty"` + // The type of root device used by the OMI (always `bsu`). + RootDeviceType *string `json:"RootDeviceType,omitempty"` + // The state of the OMI (`pending` \\| `available` \\| `failed`). + State *string `json:"State,omitempty"` + StateComment *StateComment `json:"StateComment,omitempty"` + // One or more tags associated with the OMI. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewImage instantiates a new Image object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewImage() *Image { + this := Image{} + return &this +} + +// NewImageWithDefaults instantiates a new Image object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewImageWithDefaults() *Image { + this := Image{} + return &this +} + +// GetAccountAlias returns the AccountAlias field value if set, zero value otherwise. +func (o *Image) GetAccountAlias() string { + if o == nil || o.AccountAlias == nil { + var ret string + return ret + } + return *o.AccountAlias +} + +// GetAccountAliasOk returns a tuple with the AccountAlias field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetAccountAliasOk() (*string, bool) { + if o == nil || o.AccountAlias == nil { + return nil, false + } + return o.AccountAlias, true +} + +// HasAccountAlias returns a boolean if a field has been set. +func (o *Image) HasAccountAlias() bool { + if o != nil && o.AccountAlias != nil { + return true + } + + return false +} + +// SetAccountAlias gets a reference to the given string and assigns it to the AccountAlias field. +func (o *Image) SetAccountAlias(v string) { + o.AccountAlias = &v +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Image) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Image) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Image) SetAccountId(v string) { + o.AccountId = &v +} + +// GetArchitecture returns the Architecture field value if set, zero value otherwise. +func (o *Image) GetArchitecture() string { + if o == nil || o.Architecture == nil { + var ret string + return ret + } + return *o.Architecture +} + +// GetArchitectureOk returns a tuple with the Architecture field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetArchitectureOk() (*string, bool) { + if o == nil || o.Architecture == nil { + return nil, false + } + return o.Architecture, true +} + +// HasArchitecture returns a boolean if a field has been set. +func (o *Image) HasArchitecture() bool { + if o != nil && o.Architecture != nil { + return true + } + + return false +} + +// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. +func (o *Image) SetArchitecture(v string) { + o.Architecture = &v +} + +// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. +func (o *Image) GetBlockDeviceMappings() []BlockDeviceMappingImage { + if o == nil || o.BlockDeviceMappings == nil { + var ret []BlockDeviceMappingImage + return ret + } + return *o.BlockDeviceMappings +} + +// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetBlockDeviceMappingsOk() (*[]BlockDeviceMappingImage, bool) { + if o == nil || o.BlockDeviceMappings == nil { + return nil, false + } + return o.BlockDeviceMappings, true +} + +// HasBlockDeviceMappings returns a boolean if a field has been set. +func (o *Image) HasBlockDeviceMappings() bool { + if o != nil && o.BlockDeviceMappings != nil { + return true + } + + return false +} + +// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingImage and assigns it to the BlockDeviceMappings field. +func (o *Image) SetBlockDeviceMappings(v []BlockDeviceMappingImage) { + o.BlockDeviceMappings = &v +} + +// GetCreationDate returns the CreationDate field value if set, zero value otherwise. +func (o *Image) GetCreationDate() string { + if o == nil || o.CreationDate == nil { + var ret string + return ret + } + return *o.CreationDate +} + +// GetCreationDateOk returns a tuple with the CreationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetCreationDateOk() (*string, bool) { + if o == nil || o.CreationDate == nil { + return nil, false + } + return o.CreationDate, true +} + +// HasCreationDate returns a boolean if a field has been set. +func (o *Image) HasCreationDate() bool { + if o != nil && o.CreationDate != nil { + return true + } + + return false +} + +// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. +func (o *Image) SetCreationDate(v string) { + o.CreationDate = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *Image) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *Image) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *Image) SetDescription(v string) { + o.Description = &v +} + +// GetFileLocation returns the FileLocation field value if set, zero value otherwise. +func (o *Image) GetFileLocation() string { + if o == nil || o.FileLocation == nil { + var ret string + return ret + } + return *o.FileLocation +} + +// GetFileLocationOk returns a tuple with the FileLocation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetFileLocationOk() (*string, bool) { + if o == nil || o.FileLocation == nil { + return nil, false + } + return o.FileLocation, true +} + +// HasFileLocation returns a boolean if a field has been set. +func (o *Image) HasFileLocation() bool { + if o != nil && o.FileLocation != nil { + return true + } + + return false +} + +// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. +func (o *Image) SetFileLocation(v string) { + o.FileLocation = &v +} + +// GetImageId returns the ImageId field value if set, zero value otherwise. +func (o *Image) GetImageId() string { + if o == nil || o.ImageId == nil { + var ret string + return ret + } + return *o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetImageIdOk() (*string, bool) { + if o == nil || o.ImageId == nil { + return nil, false + } + return o.ImageId, true +} + +// HasImageId returns a boolean if a field has been set. +func (o *Image) HasImageId() bool { + if o != nil && o.ImageId != nil { + return true + } + + return false +} + +// SetImageId gets a reference to the given string and assigns it to the ImageId field. +func (o *Image) SetImageId(v string) { + o.ImageId = &v +} + +// GetImageName returns the ImageName field value if set, zero value otherwise. +func (o *Image) GetImageName() string { + if o == nil || o.ImageName == nil { + var ret string + return ret + } + return *o.ImageName +} + +// GetImageNameOk returns a tuple with the ImageName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetImageNameOk() (*string, bool) { + if o == nil || o.ImageName == nil { + return nil, false + } + return o.ImageName, true +} + +// HasImageName returns a boolean if a field has been set. +func (o *Image) HasImageName() bool { + if o != nil && o.ImageName != nil { + return true + } + + return false +} + +// SetImageName gets a reference to the given string and assigns it to the ImageName field. +func (o *Image) SetImageName(v string) { + o.ImageName = &v +} + +// GetImageType returns the ImageType field value if set, zero value otherwise. +func (o *Image) GetImageType() string { + if o == nil || o.ImageType == nil { + var ret string + return ret + } + return *o.ImageType +} + +// GetImageTypeOk returns a tuple with the ImageType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetImageTypeOk() (*string, bool) { + if o == nil || o.ImageType == nil { + return nil, false + } + return o.ImageType, true +} + +// HasImageType returns a boolean if a field has been set. +func (o *Image) HasImageType() bool { + if o != nil && o.ImageType != nil { + return true + } + + return false +} + +// SetImageType gets a reference to the given string and assigns it to the ImageType field. +func (o *Image) SetImageType(v string) { + o.ImageType = &v +} + +// GetPermissionsToLaunch returns the PermissionsToLaunch field value if set, zero value otherwise. +func (o *Image) GetPermissionsToLaunch() PermissionsOnResource { + if o == nil || o.PermissionsToLaunch == nil { + var ret PermissionsOnResource + return ret + } + return *o.PermissionsToLaunch +} + +// GetPermissionsToLaunchOk returns a tuple with the PermissionsToLaunch field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetPermissionsToLaunchOk() (*PermissionsOnResource, bool) { + if o == nil || o.PermissionsToLaunch == nil { + return nil, false + } + return o.PermissionsToLaunch, true +} + +// HasPermissionsToLaunch returns a boolean if a field has been set. +func (o *Image) HasPermissionsToLaunch() bool { + if o != nil && o.PermissionsToLaunch != nil { + return true + } + + return false +} + +// SetPermissionsToLaunch gets a reference to the given PermissionsOnResource and assigns it to the PermissionsToLaunch field. +func (o *Image) SetPermissionsToLaunch(v PermissionsOnResource) { + o.PermissionsToLaunch = &v +} + +// GetProductCodes returns the ProductCodes field value if set, zero value otherwise. +func (o *Image) GetProductCodes() []string { + if o == nil || o.ProductCodes == nil { + var ret []string + return ret + } + return *o.ProductCodes +} + +// GetProductCodesOk returns a tuple with the ProductCodes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetProductCodesOk() (*[]string, bool) { + if o == nil || o.ProductCodes == nil { + return nil, false + } + return o.ProductCodes, true +} + +// HasProductCodes returns a boolean if a field has been set. +func (o *Image) HasProductCodes() bool { + if o != nil && o.ProductCodes != nil { + return true + } + + return false +} + +// SetProductCodes gets a reference to the given []string and assigns it to the ProductCodes field. +func (o *Image) SetProductCodes(v []string) { + o.ProductCodes = &v +} + +// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. +func (o *Image) GetRootDeviceName() string { + if o == nil || o.RootDeviceName == nil { + var ret string + return ret + } + return *o.RootDeviceName +} + +// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetRootDeviceNameOk() (*string, bool) { + if o == nil || o.RootDeviceName == nil { + return nil, false + } + return o.RootDeviceName, true +} + +// HasRootDeviceName returns a boolean if a field has been set. +func (o *Image) HasRootDeviceName() bool { + if o != nil && o.RootDeviceName != nil { + return true + } + + return false +} + +// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. +func (o *Image) SetRootDeviceName(v string) { + o.RootDeviceName = &v +} + +// GetRootDeviceType returns the RootDeviceType field value if set, zero value otherwise. +func (o *Image) GetRootDeviceType() string { + if o == nil || o.RootDeviceType == nil { + var ret string + return ret + } + return *o.RootDeviceType +} + +// GetRootDeviceTypeOk returns a tuple with the RootDeviceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetRootDeviceTypeOk() (*string, bool) { + if o == nil || o.RootDeviceType == nil { + return nil, false + } + return o.RootDeviceType, true +} + +// HasRootDeviceType returns a boolean if a field has been set. +func (o *Image) HasRootDeviceType() bool { + if o != nil && o.RootDeviceType != nil { + return true + } + + return false +} + +// SetRootDeviceType gets a reference to the given string and assigns it to the RootDeviceType field. +func (o *Image) SetRootDeviceType(v string) { + o.RootDeviceType = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Image) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Image) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Image) SetState(v string) { + o.State = &v +} + +// GetStateComment returns the StateComment field value if set, zero value otherwise. +func (o *Image) GetStateComment() StateComment { + if o == nil || o.StateComment == nil { + var ret StateComment + return ret + } + return *o.StateComment +} + +// GetStateCommentOk returns a tuple with the StateComment field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetStateCommentOk() (*StateComment, bool) { + if o == nil || o.StateComment == nil { + return nil, false + } + return o.StateComment, true +} + +// HasStateComment returns a boolean if a field has been set. +func (o *Image) HasStateComment() bool { + if o != nil && o.StateComment != nil { + return true + } + + return false +} + +// SetStateComment gets a reference to the given StateComment and assigns it to the StateComment field. +func (o *Image) SetStateComment(v StateComment) { + o.StateComment = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Image) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Image) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Image) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Image) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o Image) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountAlias != nil { + toSerialize["AccountAlias"] = o.AccountAlias + } + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Architecture != nil { + toSerialize["Architecture"] = o.Architecture + } + if o.BlockDeviceMappings != nil { + toSerialize["BlockDeviceMappings"] = o.BlockDeviceMappings + } + if o.CreationDate != nil { + toSerialize["CreationDate"] = o.CreationDate + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.FileLocation != nil { + toSerialize["FileLocation"] = o.FileLocation + } + if o.ImageId != nil { + toSerialize["ImageId"] = o.ImageId + } + if o.ImageName != nil { + toSerialize["ImageName"] = o.ImageName + } + if o.ImageType != nil { + toSerialize["ImageType"] = o.ImageType + } + if o.PermissionsToLaunch != nil { + toSerialize["PermissionsToLaunch"] = o.PermissionsToLaunch + } + if o.ProductCodes != nil { + toSerialize["ProductCodes"] = o.ProductCodes + } + if o.RootDeviceName != nil { + toSerialize["RootDeviceName"] = o.RootDeviceName + } + if o.RootDeviceType != nil { + toSerialize["RootDeviceType"] = o.RootDeviceType + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.StateComment != nil { + toSerialize["StateComment"] = o.StateComment + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableImage struct { + value *Image + isSet bool +} + +func (v NullableImage) Get() *Image { + return v.value +} + +func (v *NullableImage) Set(val *Image) { + v.value = val + v.isSet = true +} + +func (v NullableImage) IsSet() bool { + return v.isSet +} + +func (v *NullableImage) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableImage(val *Image) *NullableImage { + return &NullableImage{value: val, isSet: true} +} + +func (v NullableImage) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableImage) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go new file mode 100644 index 000000000..21166f830 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go @@ -0,0 +1,338 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ImageExportTask Information about the OMI export task. +type ImageExportTask struct { + // If the OMI export task fails, an error message appears. + Comment *string `json:"Comment,omitempty"` + // The ID of the OMI to be exported. + ImageId *string `json:"ImageId,omitempty"` + OsuExport *OsuExport `json:"OsuExport,omitempty"` + // The progress of the OMI export task, as a percentage. + Progress *int32 `json:"Progress,omitempty"` + // The state of the OMI export task (`pending/queued` \\| `pending` \\| `completed` \\| `failed` \\| `cancelled`). + State *string `json:"State,omitempty"` + // One or more tags associated with the image export task. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the OMI export task. + TaskId *string `json:"TaskId,omitempty"` +} + +// NewImageExportTask instantiates a new ImageExportTask object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewImageExportTask() *ImageExportTask { + this := ImageExportTask{} + return &this +} + +// NewImageExportTaskWithDefaults instantiates a new ImageExportTask object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewImageExportTaskWithDefaults() *ImageExportTask { + this := ImageExportTask{} + return &this +} + +// GetComment returns the Comment field value if set, zero value otherwise. +func (o *ImageExportTask) GetComment() string { + if o == nil || o.Comment == nil { + var ret string + return ret + } + return *o.Comment +} + +// GetCommentOk returns a tuple with the Comment field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetCommentOk() (*string, bool) { + if o == nil || o.Comment == nil { + return nil, false + } + return o.Comment, true +} + +// HasComment returns a boolean if a field has been set. +func (o *ImageExportTask) HasComment() bool { + if o != nil && o.Comment != nil { + return true + } + + return false +} + +// SetComment gets a reference to the given string and assigns it to the Comment field. +func (o *ImageExportTask) SetComment(v string) { + o.Comment = &v +} + +// GetImageId returns the ImageId field value if set, zero value otherwise. +func (o *ImageExportTask) GetImageId() string { + if o == nil || o.ImageId == nil { + var ret string + return ret + } + return *o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetImageIdOk() (*string, bool) { + if o == nil || o.ImageId == nil { + return nil, false + } + return o.ImageId, true +} + +// HasImageId returns a boolean if a field has been set. +func (o *ImageExportTask) HasImageId() bool { + if o != nil && o.ImageId != nil { + return true + } + + return false +} + +// SetImageId gets a reference to the given string and assigns it to the ImageId field. +func (o *ImageExportTask) SetImageId(v string) { + o.ImageId = &v +} + +// GetOsuExport returns the OsuExport field value if set, zero value otherwise. +func (o *ImageExportTask) GetOsuExport() OsuExport { + if o == nil || o.OsuExport == nil { + var ret OsuExport + return ret + } + return *o.OsuExport +} + +// GetOsuExportOk returns a tuple with the OsuExport field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetOsuExportOk() (*OsuExport, bool) { + if o == nil || o.OsuExport == nil { + return nil, false + } + return o.OsuExport, true +} + +// HasOsuExport returns a boolean if a field has been set. +func (o *ImageExportTask) HasOsuExport() bool { + if o != nil && o.OsuExport != nil { + return true + } + + return false +} + +// SetOsuExport gets a reference to the given OsuExport and assigns it to the OsuExport field. +func (o *ImageExportTask) SetOsuExport(v OsuExport) { + o.OsuExport = &v +} + +// GetProgress returns the Progress field value if set, zero value otherwise. +func (o *ImageExportTask) GetProgress() int32 { + if o == nil || o.Progress == nil { + var ret int32 + return ret + } + return *o.Progress +} + +// GetProgressOk returns a tuple with the Progress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetProgressOk() (*int32, bool) { + if o == nil || o.Progress == nil { + return nil, false + } + return o.Progress, true +} + +// HasProgress returns a boolean if a field has been set. +func (o *ImageExportTask) HasProgress() bool { + if o != nil && o.Progress != nil { + return true + } + + return false +} + +// SetProgress gets a reference to the given int32 and assigns it to the Progress field. +func (o *ImageExportTask) SetProgress(v int32) { + o.Progress = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *ImageExportTask) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *ImageExportTask) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *ImageExportTask) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *ImageExportTask) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *ImageExportTask) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *ImageExportTask) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetTaskId returns the TaskId field value if set, zero value otherwise. +func (o *ImageExportTask) GetTaskId() string { + if o == nil || o.TaskId == nil { + var ret string + return ret + } + return *o.TaskId +} + +// GetTaskIdOk returns a tuple with the TaskId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ImageExportTask) GetTaskIdOk() (*string, bool) { + if o == nil || o.TaskId == nil { + return nil, false + } + return o.TaskId, true +} + +// HasTaskId returns a boolean if a field has been set. +func (o *ImageExportTask) HasTaskId() bool { + if o != nil && o.TaskId != nil { + return true + } + + return false +} + +// SetTaskId gets a reference to the given string and assigns it to the TaskId field. +func (o *ImageExportTask) SetTaskId(v string) { + o.TaskId = &v +} + +func (o ImageExportTask) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Comment != nil { + toSerialize["Comment"] = o.Comment + } + if o.ImageId != nil { + toSerialize["ImageId"] = o.ImageId + } + if o.OsuExport != nil { + toSerialize["OsuExport"] = o.OsuExport + } + if o.Progress != nil { + toSerialize["Progress"] = o.Progress + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.TaskId != nil { + toSerialize["TaskId"] = o.TaskId + } + return json.Marshal(toSerialize) +} + +type NullableImageExportTask struct { + value *ImageExportTask + isSet bool +} + +func (v NullableImageExportTask) Get() *ImageExportTask { + return v.value +} + +func (v *NullableImageExportTask) Set(val *ImageExportTask) { + v.value = val + v.isSet = true +} + +func (v NullableImageExportTask) IsSet() bool { + return v.isSet +} + +func (v *NullableImageExportTask) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableImageExportTask(val *ImageExportTask) *NullableImageExportTask { + return &NullableImageExportTask{value: val, isSet: true} +} + +func (v NullableImageExportTask) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableImageExportTask) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go new file mode 100644 index 000000000..83f6e2671 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// InternetService Information about the Internet service. +type InternetService struct { + // The ID of the Internet service. + InternetServiceId *string `json:"InternetServiceId,omitempty"` + // The ID of the Net attached to the Internet service. + NetId *string `json:"NetId,omitempty"` + // The state of the attachment of the Net to the Internet service (always `available`). + State *string `json:"State,omitempty"` + // One or more tags associated with the Internet service. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewInternetService instantiates a new InternetService object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewInternetService() *InternetService { + this := InternetService{} + return &this +} + +// NewInternetServiceWithDefaults instantiates a new InternetService object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewInternetServiceWithDefaults() *InternetService { + this := InternetService{} + return &this +} + +// GetInternetServiceId returns the InternetServiceId field value if set, zero value otherwise. +func (o *InternetService) GetInternetServiceId() string { + if o == nil || o.InternetServiceId == nil { + var ret string + return ret + } + return *o.InternetServiceId +} + +// GetInternetServiceIdOk returns a tuple with the InternetServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *InternetService) GetInternetServiceIdOk() (*string, bool) { + if o == nil || o.InternetServiceId == nil { + return nil, false + } + return o.InternetServiceId, true +} + +// HasInternetServiceId returns a boolean if a field has been set. +func (o *InternetService) HasInternetServiceId() bool { + if o != nil && o.InternetServiceId != nil { + return true + } + + return false +} + +// SetInternetServiceId gets a reference to the given string and assigns it to the InternetServiceId field. +func (o *InternetService) SetInternetServiceId(v string) { + o.InternetServiceId = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *InternetService) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *InternetService) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *InternetService) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *InternetService) SetNetId(v string) { + o.NetId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *InternetService) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *InternetService) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *InternetService) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *InternetService) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *InternetService) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *InternetService) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *InternetService) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *InternetService) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o InternetService) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.InternetServiceId != nil { + toSerialize["InternetServiceId"] = o.InternetServiceId + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableInternetService struct { + value *InternetService + isSet bool +} + +func (v NullableInternetService) Get() *InternetService { + return v.value +} + +func (v *NullableInternetService) Set(val *InternetService) { + v.value = val + v.isSet = true +} + +func (v NullableInternetService) IsSet() bool { + return v.isSet +} + +func (v *NullableInternetService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInternetService(val *InternetService) *NullableInternetService { + return &NullableInternetService{value: val, isSet: true} +} + +func (v NullableInternetService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInternetService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go new file mode 100644 index 000000000..3612b3a54 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Keypair Information about the keypair. +type Keypair struct { + // If you create a keypair, the SHA-1 digest of the DER encoded private key.
If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716. + KeypairFingerprint *string `json:"KeypairFingerprint,omitempty"` + // The name of the keypair. + KeypairName *string `json:"KeypairName,omitempty"` +} + +// NewKeypair instantiates a new Keypair object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewKeypair() *Keypair { + this := Keypair{} + return &this +} + +// NewKeypairWithDefaults instantiates a new Keypair object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewKeypairWithDefaults() *Keypair { + this := Keypair{} + return &this +} + +// GetKeypairFingerprint returns the KeypairFingerprint field value if set, zero value otherwise. +func (o *Keypair) GetKeypairFingerprint() string { + if o == nil || o.KeypairFingerprint == nil { + var ret string + return ret + } + return *o.KeypairFingerprint +} + +// GetKeypairFingerprintOk returns a tuple with the KeypairFingerprint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Keypair) GetKeypairFingerprintOk() (*string, bool) { + if o == nil || o.KeypairFingerprint == nil { + return nil, false + } + return o.KeypairFingerprint, true +} + +// HasKeypairFingerprint returns a boolean if a field has been set. +func (o *Keypair) HasKeypairFingerprint() bool { + if o != nil && o.KeypairFingerprint != nil { + return true + } + + return false +} + +// SetKeypairFingerprint gets a reference to the given string and assigns it to the KeypairFingerprint field. +func (o *Keypair) SetKeypairFingerprint(v string) { + o.KeypairFingerprint = &v +} + +// GetKeypairName returns the KeypairName field value if set, zero value otherwise. +func (o *Keypair) GetKeypairName() string { + if o == nil || o.KeypairName == nil { + var ret string + return ret + } + return *o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Keypair) GetKeypairNameOk() (*string, bool) { + if o == nil || o.KeypairName == nil { + return nil, false + } + return o.KeypairName, true +} + +// HasKeypairName returns a boolean if a field has been set. +func (o *Keypair) HasKeypairName() bool { + if o != nil && o.KeypairName != nil { + return true + } + + return false +} + +// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. +func (o *Keypair) SetKeypairName(v string) { + o.KeypairName = &v +} + +func (o Keypair) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.KeypairFingerprint != nil { + toSerialize["KeypairFingerprint"] = o.KeypairFingerprint + } + if o.KeypairName != nil { + toSerialize["KeypairName"] = o.KeypairName + } + return json.Marshal(toSerialize) +} + +type NullableKeypair struct { + value *Keypair + isSet bool +} + +func (v NullableKeypair) Get() *Keypair { + return v.value +} + +func (v *NullableKeypair) Set(val *Keypair) { + v.value = val + v.isSet = true +} + +func (v NullableKeypair) IsSet() bool { + return v.isSet +} + +func (v *NullableKeypair) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableKeypair(val *Keypair) *NullableKeypair { + return &NullableKeypair{value: val, isSet: true} +} + +func (v NullableKeypair) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableKeypair) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go new file mode 100644 index 000000000..093a38201 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// KeypairCreated Information about the created keypair. +type KeypairCreated struct { + // If you create a keypair, the SHA-1 digest of the DER encoded private key.
If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716. + KeypairFingerprint *string `json:"KeypairFingerprint,omitempty"` + // The name of the keypair. + KeypairName *string `json:"KeypairName,omitempty"` + // The private key. + PrivateKey *string `json:"PrivateKey,omitempty"` +} + +// NewKeypairCreated instantiates a new KeypairCreated object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewKeypairCreated() *KeypairCreated { + this := KeypairCreated{} + return &this +} + +// NewKeypairCreatedWithDefaults instantiates a new KeypairCreated object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewKeypairCreatedWithDefaults() *KeypairCreated { + this := KeypairCreated{} + return &this +} + +// GetKeypairFingerprint returns the KeypairFingerprint field value if set, zero value otherwise. +func (o *KeypairCreated) GetKeypairFingerprint() string { + if o == nil || o.KeypairFingerprint == nil { + var ret string + return ret + } + return *o.KeypairFingerprint +} + +// GetKeypairFingerprintOk returns a tuple with the KeypairFingerprint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *KeypairCreated) GetKeypairFingerprintOk() (*string, bool) { + if o == nil || o.KeypairFingerprint == nil { + return nil, false + } + return o.KeypairFingerprint, true +} + +// HasKeypairFingerprint returns a boolean if a field has been set. +func (o *KeypairCreated) HasKeypairFingerprint() bool { + if o != nil && o.KeypairFingerprint != nil { + return true + } + + return false +} + +// SetKeypairFingerprint gets a reference to the given string and assigns it to the KeypairFingerprint field. +func (o *KeypairCreated) SetKeypairFingerprint(v string) { + o.KeypairFingerprint = &v +} + +// GetKeypairName returns the KeypairName field value if set, zero value otherwise. +func (o *KeypairCreated) GetKeypairName() string { + if o == nil || o.KeypairName == nil { + var ret string + return ret + } + return *o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *KeypairCreated) GetKeypairNameOk() (*string, bool) { + if o == nil || o.KeypairName == nil { + return nil, false + } + return o.KeypairName, true +} + +// HasKeypairName returns a boolean if a field has been set. +func (o *KeypairCreated) HasKeypairName() bool { + if o != nil && o.KeypairName != nil { + return true + } + + return false +} + +// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. +func (o *KeypairCreated) SetKeypairName(v string) { + o.KeypairName = &v +} + +// GetPrivateKey returns the PrivateKey field value if set, zero value otherwise. +func (o *KeypairCreated) GetPrivateKey() string { + if o == nil || o.PrivateKey == nil { + var ret string + return ret + } + return *o.PrivateKey +} + +// GetPrivateKeyOk returns a tuple with the PrivateKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *KeypairCreated) GetPrivateKeyOk() (*string, bool) { + if o == nil || o.PrivateKey == nil { + return nil, false + } + return o.PrivateKey, true +} + +// HasPrivateKey returns a boolean if a field has been set. +func (o *KeypairCreated) HasPrivateKey() bool { + if o != nil && o.PrivateKey != nil { + return true + } + + return false +} + +// SetPrivateKey gets a reference to the given string and assigns it to the PrivateKey field. +func (o *KeypairCreated) SetPrivateKey(v string) { + o.PrivateKey = &v +} + +func (o KeypairCreated) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.KeypairFingerprint != nil { + toSerialize["KeypairFingerprint"] = o.KeypairFingerprint + } + if o.KeypairName != nil { + toSerialize["KeypairName"] = o.KeypairName + } + if o.PrivateKey != nil { + toSerialize["PrivateKey"] = o.PrivateKey + } + return json.Marshal(toSerialize) +} + +type NullableKeypairCreated struct { + value *KeypairCreated + isSet bool +} + +func (v NullableKeypairCreated) Get() *KeypairCreated { + return v.value +} + +func (v *NullableKeypairCreated) Set(val *KeypairCreated) { + v.value = val + v.isSet = true +} + +func (v NullableKeypairCreated) IsSet() bool { + return v.isSet +} + +func (v *NullableKeypairCreated) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableKeypairCreated(val *KeypairCreated) *NullableKeypairCreated { + return &NullableKeypairCreated{value: val, isSet: true} +} + +func (v NullableKeypairCreated) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableKeypairCreated) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go new file mode 100644 index 000000000..305ec05fc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkFlexibleGpuRequest struct for LinkFlexibleGpuRequest +type LinkFlexibleGpuRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the fGPU you want to attach. + FlexibleGpuId string `json:"FlexibleGpuId"` + // The ID of the VM you want to attach the fGPU to. + VmId string `json:"VmId"` +} + +// NewLinkFlexibleGpuRequest instantiates a new LinkFlexibleGpuRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkFlexibleGpuRequest(flexibleGpuId string, vmId string, ) *LinkFlexibleGpuRequest { + this := LinkFlexibleGpuRequest{} + this.FlexibleGpuId = flexibleGpuId + this.VmId = vmId + return &this +} + +// NewLinkFlexibleGpuRequestWithDefaults instantiates a new LinkFlexibleGpuRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkFlexibleGpuRequestWithDefaults() *LinkFlexibleGpuRequest { + this := LinkFlexibleGpuRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkFlexibleGpuRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkFlexibleGpuRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkFlexibleGpuRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkFlexibleGpuRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlexibleGpuId returns the FlexibleGpuId field value +func (o *LinkFlexibleGpuRequest) GetFlexibleGpuId() string { + if o == nil { + var ret string + return ret + } + + return o.FlexibleGpuId +} + +// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value +// and a boolean to check if the value has been set. +func (o *LinkFlexibleGpuRequest) GetFlexibleGpuIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FlexibleGpuId, true +} + +// SetFlexibleGpuId sets field value +func (o *LinkFlexibleGpuRequest) SetFlexibleGpuId(v string) { + o.FlexibleGpuId = v +} + +// GetVmId returns the VmId field value +func (o *LinkFlexibleGpuRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *LinkFlexibleGpuRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *LinkFlexibleGpuRequest) SetVmId(v string) { + o.VmId = v +} + +func (o LinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["FlexibleGpuId"] = o.FlexibleGpuId + } + if true { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableLinkFlexibleGpuRequest struct { + value *LinkFlexibleGpuRequest + isSet bool +} + +func (v NullableLinkFlexibleGpuRequest) Get() *LinkFlexibleGpuRequest { + return v.value +} + +func (v *NullableLinkFlexibleGpuRequest) Set(val *LinkFlexibleGpuRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkFlexibleGpuRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkFlexibleGpuRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkFlexibleGpuRequest(val *LinkFlexibleGpuRequest) *NullableLinkFlexibleGpuRequest { + return &NullableLinkFlexibleGpuRequest{value: val, isSet: true} +} + +func (v NullableLinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkFlexibleGpuRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go new file mode 100644 index 000000000..65698f4fc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkFlexibleGpuResponse struct for LinkFlexibleGpuResponse +type LinkFlexibleGpuResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkFlexibleGpuResponse instantiates a new LinkFlexibleGpuResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkFlexibleGpuResponse() *LinkFlexibleGpuResponse { + this := LinkFlexibleGpuResponse{} + return &this +} + +// NewLinkFlexibleGpuResponseWithDefaults instantiates a new LinkFlexibleGpuResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkFlexibleGpuResponseWithDefaults() *LinkFlexibleGpuResponse { + this := LinkFlexibleGpuResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkFlexibleGpuResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkFlexibleGpuResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkFlexibleGpuResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkFlexibleGpuResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkFlexibleGpuResponse struct { + value *LinkFlexibleGpuResponse + isSet bool +} + +func (v NullableLinkFlexibleGpuResponse) Get() *LinkFlexibleGpuResponse { + return v.value +} + +func (v *NullableLinkFlexibleGpuResponse) Set(val *LinkFlexibleGpuResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkFlexibleGpuResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkFlexibleGpuResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkFlexibleGpuResponse(val *LinkFlexibleGpuResponse) *NullableLinkFlexibleGpuResponse { + return &NullableLinkFlexibleGpuResponse{value: val, isSet: true} +} + +func (v NullableLinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkFlexibleGpuResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go new file mode 100644 index 000000000..b5ab55547 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkInternetServiceRequest struct for LinkInternetServiceRequest +type LinkInternetServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Internet service you want to attach. + InternetServiceId string `json:"InternetServiceId"` + // The ID of the Net to which you want to attach the Internet service. + NetId string `json:"NetId"` +} + +// NewLinkInternetServiceRequest instantiates a new LinkInternetServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkInternetServiceRequest(internetServiceId string, netId string, ) *LinkInternetServiceRequest { + this := LinkInternetServiceRequest{} + this.InternetServiceId = internetServiceId + this.NetId = netId + return &this +} + +// NewLinkInternetServiceRequestWithDefaults instantiates a new LinkInternetServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkInternetServiceRequestWithDefaults() *LinkInternetServiceRequest { + this := LinkInternetServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkInternetServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkInternetServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkInternetServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkInternetServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetInternetServiceId returns the InternetServiceId field value +func (o *LinkInternetServiceRequest) GetInternetServiceId() string { + if o == nil { + var ret string + return ret + } + + return o.InternetServiceId +} + +// GetInternetServiceIdOk returns a tuple with the InternetServiceId field value +// and a boolean to check if the value has been set. +func (o *LinkInternetServiceRequest) GetInternetServiceIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.InternetServiceId, true +} + +// SetInternetServiceId sets field value +func (o *LinkInternetServiceRequest) SetInternetServiceId(v string) { + o.InternetServiceId = v +} + +// GetNetId returns the NetId field value +func (o *LinkInternetServiceRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *LinkInternetServiceRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *LinkInternetServiceRequest) SetNetId(v string) { + o.NetId = v +} + +func (o LinkInternetServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["InternetServiceId"] = o.InternetServiceId + } + if true { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableLinkInternetServiceRequest struct { + value *LinkInternetServiceRequest + isSet bool +} + +func (v NullableLinkInternetServiceRequest) Get() *LinkInternetServiceRequest { + return v.value +} + +func (v *NullableLinkInternetServiceRequest) Set(val *LinkInternetServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkInternetServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkInternetServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkInternetServiceRequest(val *LinkInternetServiceRequest) *NullableLinkInternetServiceRequest { + return &NullableLinkInternetServiceRequest{value: val, isSet: true} +} + +func (v NullableLinkInternetServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkInternetServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go new file mode 100644 index 000000000..55474405c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkInternetServiceResponse struct for LinkInternetServiceResponse +type LinkInternetServiceResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkInternetServiceResponse instantiates a new LinkInternetServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkInternetServiceResponse() *LinkInternetServiceResponse { + this := LinkInternetServiceResponse{} + return &this +} + +// NewLinkInternetServiceResponseWithDefaults instantiates a new LinkInternetServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkInternetServiceResponseWithDefaults() *LinkInternetServiceResponse { + this := LinkInternetServiceResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkInternetServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkInternetServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkInternetServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkInternetServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkInternetServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkInternetServiceResponse struct { + value *LinkInternetServiceResponse + isSet bool +} + +func (v NullableLinkInternetServiceResponse) Get() *LinkInternetServiceResponse { + return v.value +} + +func (v *NullableLinkInternetServiceResponse) Set(val *LinkInternetServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkInternetServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkInternetServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkInternetServiceResponse(val *LinkInternetServiceResponse) *NullableLinkInternetServiceResponse { + return &NullableLinkInternetServiceResponse{value: val, isSet: true} +} + +func (v NullableLinkInternetServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkInternetServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go new file mode 100644 index 000000000..cb483b1dd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkNic Information about the NIC attachment. +type LinkNic struct { + // If `true`, the volume is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The device index for the NIC attachment (between 1 and 7, both included). + DeviceNumber *int32 `json:"DeviceNumber,omitempty"` + // The ID of the NIC to attach. + LinkNicId *string `json:"LinkNicId,omitempty"` + // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). + State *string `json:"State,omitempty"` + // The account ID of the owner of the VM. + VmAccountId *string `json:"VmAccountId,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` +} + +// NewLinkNic instantiates a new LinkNic object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkNic() *LinkNic { + this := LinkNic{} + return &this +} + +// NewLinkNicWithDefaults instantiates a new LinkNic object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkNicWithDefaults() *LinkNic { + this := LinkNic{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *LinkNic) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *LinkNic) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *LinkNic) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. +func (o *LinkNic) GetDeviceNumber() int32 { + if o == nil || o.DeviceNumber == nil { + var ret int32 + return ret + } + return *o.DeviceNumber +} + +// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetDeviceNumberOk() (*int32, bool) { + if o == nil || o.DeviceNumber == nil { + return nil, false + } + return o.DeviceNumber, true +} + +// HasDeviceNumber returns a boolean if a field has been set. +func (o *LinkNic) HasDeviceNumber() bool { + if o != nil && o.DeviceNumber != nil { + return true + } + + return false +} + +// SetDeviceNumber gets a reference to the given int32 and assigns it to the DeviceNumber field. +func (o *LinkNic) SetDeviceNumber(v int32) { + o.DeviceNumber = &v +} + +// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. +func (o *LinkNic) GetLinkNicId() string { + if o == nil || o.LinkNicId == nil { + var ret string + return ret + } + return *o.LinkNicId +} + +// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetLinkNicIdOk() (*string, bool) { + if o == nil || o.LinkNicId == nil { + return nil, false + } + return o.LinkNicId, true +} + +// HasLinkNicId returns a boolean if a field has been set. +func (o *LinkNic) HasLinkNicId() bool { + if o != nil && o.LinkNicId != nil { + return true + } + + return false +} + +// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. +func (o *LinkNic) SetLinkNicId(v string) { + o.LinkNicId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *LinkNic) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *LinkNic) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *LinkNic) SetState(v string) { + o.State = &v +} + +// GetVmAccountId returns the VmAccountId field value if set, zero value otherwise. +func (o *LinkNic) GetVmAccountId() string { + if o == nil || o.VmAccountId == nil { + var ret string + return ret + } + return *o.VmAccountId +} + +// GetVmAccountIdOk returns a tuple with the VmAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetVmAccountIdOk() (*string, bool) { + if o == nil || o.VmAccountId == nil { + return nil, false + } + return o.VmAccountId, true +} + +// HasVmAccountId returns a boolean if a field has been set. +func (o *LinkNic) HasVmAccountId() bool { + if o != nil && o.VmAccountId != nil { + return true + } + + return false +} + +// SetVmAccountId gets a reference to the given string and assigns it to the VmAccountId field. +func (o *LinkNic) SetVmAccountId(v string) { + o.VmAccountId = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *LinkNic) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNic) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *LinkNic) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *LinkNic) SetVmId(v string) { + o.VmId = &v +} + +func (o LinkNic) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.DeviceNumber != nil { + toSerialize["DeviceNumber"] = o.DeviceNumber + } + if o.LinkNicId != nil { + toSerialize["LinkNicId"] = o.LinkNicId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.VmAccountId != nil { + toSerialize["VmAccountId"] = o.VmAccountId + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableLinkNic struct { + value *LinkNic + isSet bool +} + +func (v NullableLinkNic) Get() *LinkNic { + return v.value +} + +func (v *NullableLinkNic) Set(val *LinkNic) { + v.value = val + v.isSet = true +} + +func (v NullableLinkNic) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkNic) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkNic(val *LinkNic) *NullableLinkNic { + return &NullableLinkNic{value: val, isSet: true} +} + +func (v NullableLinkNic) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkNic) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go new file mode 100644 index 000000000..e92571f17 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkNicLight Information about the network interface card (NIC). +type LinkNicLight struct { + // If `true`, the volume is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The device index for the NIC attachment (between 1 and 7, both included). + DeviceNumber *int32 `json:"DeviceNumber,omitempty"` + // The ID of the NIC to attach. + LinkNicId *string `json:"LinkNicId,omitempty"` + // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). + State *string `json:"State,omitempty"` +} + +// NewLinkNicLight instantiates a new LinkNicLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkNicLight() *LinkNicLight { + this := LinkNicLight{} + return &this +} + +// NewLinkNicLightWithDefaults instantiates a new LinkNicLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkNicLightWithDefaults() *LinkNicLight { + this := LinkNicLight{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *LinkNicLight) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicLight) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *LinkNicLight) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *LinkNicLight) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. +func (o *LinkNicLight) GetDeviceNumber() int32 { + if o == nil || o.DeviceNumber == nil { + var ret int32 + return ret + } + return *o.DeviceNumber +} + +// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicLight) GetDeviceNumberOk() (*int32, bool) { + if o == nil || o.DeviceNumber == nil { + return nil, false + } + return o.DeviceNumber, true +} + +// HasDeviceNumber returns a boolean if a field has been set. +func (o *LinkNicLight) HasDeviceNumber() bool { + if o != nil && o.DeviceNumber != nil { + return true + } + + return false +} + +// SetDeviceNumber gets a reference to the given int32 and assigns it to the DeviceNumber field. +func (o *LinkNicLight) SetDeviceNumber(v int32) { + o.DeviceNumber = &v +} + +// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. +func (o *LinkNicLight) GetLinkNicId() string { + if o == nil || o.LinkNicId == nil { + var ret string + return ret + } + return *o.LinkNicId +} + +// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicLight) GetLinkNicIdOk() (*string, bool) { + if o == nil || o.LinkNicId == nil { + return nil, false + } + return o.LinkNicId, true +} + +// HasLinkNicId returns a boolean if a field has been set. +func (o *LinkNicLight) HasLinkNicId() bool { + if o != nil && o.LinkNicId != nil { + return true + } + + return false +} + +// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. +func (o *LinkNicLight) SetLinkNicId(v string) { + o.LinkNicId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *LinkNicLight) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicLight) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *LinkNicLight) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *LinkNicLight) SetState(v string) { + o.State = &v +} + +func (o LinkNicLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.DeviceNumber != nil { + toSerialize["DeviceNumber"] = o.DeviceNumber + } + if o.LinkNicId != nil { + toSerialize["LinkNicId"] = o.LinkNicId + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableLinkNicLight struct { + value *LinkNicLight + isSet bool +} + +func (v NullableLinkNicLight) Get() *LinkNicLight { + return v.value +} + +func (v *NullableLinkNicLight) Set(val *LinkNicLight) { + v.value = val + v.isSet = true +} + +func (v NullableLinkNicLight) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkNicLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkNicLight(val *LinkNicLight) *NullableLinkNicLight { + return &NullableLinkNicLight{value: val, isSet: true} +} + +func (v NullableLinkNicLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkNicLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go new file mode 100644 index 000000000..1b261c01b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go @@ -0,0 +1,207 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkNicRequest struct for LinkNicRequest +type LinkNicRequest struct { + // The index of the VM device for the NIC attachment (between 1 and 7, both included). + DeviceNumber int32 `json:"DeviceNumber"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the NIC you want to attach. + NicId string `json:"NicId"` + // The ID of the VM to which you want to attach the NIC. + VmId string `json:"VmId"` +} + +// NewLinkNicRequest instantiates a new LinkNicRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkNicRequest(deviceNumber int32, nicId string, vmId string, ) *LinkNicRequest { + this := LinkNicRequest{} + this.DeviceNumber = deviceNumber + this.NicId = nicId + this.VmId = vmId + return &this +} + +// NewLinkNicRequestWithDefaults instantiates a new LinkNicRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkNicRequestWithDefaults() *LinkNicRequest { + this := LinkNicRequest{} + return &this +} + +// GetDeviceNumber returns the DeviceNumber field value +func (o *LinkNicRequest) GetDeviceNumber() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.DeviceNumber +} + +// GetDeviceNumberOk returns a tuple with the DeviceNumber field value +// and a boolean to check if the value has been set. +func (o *LinkNicRequest) GetDeviceNumberOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.DeviceNumber, true +} + +// SetDeviceNumber sets field value +func (o *LinkNicRequest) SetDeviceNumber(v int32) { + o.DeviceNumber = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkNicRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkNicRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkNicRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNicId returns the NicId field value +func (o *LinkNicRequest) GetNicId() string { + if o == nil { + var ret string + return ret + } + + return o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value +// and a boolean to check if the value has been set. +func (o *LinkNicRequest) GetNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NicId, true +} + +// SetNicId sets field value +func (o *LinkNicRequest) SetNicId(v string) { + o.NicId = v +} + +// GetVmId returns the VmId field value +func (o *LinkNicRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *LinkNicRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *LinkNicRequest) SetVmId(v string) { + o.VmId = v +} + +func (o LinkNicRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DeviceNumber"] = o.DeviceNumber + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NicId"] = o.NicId + } + if true { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableLinkNicRequest struct { + value *LinkNicRequest + isSet bool +} + +func (v NullableLinkNicRequest) Get() *LinkNicRequest { + return v.value +} + +func (v *NullableLinkNicRequest) Set(val *LinkNicRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkNicRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkNicRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkNicRequest(val *LinkNicRequest) *NullableLinkNicRequest { + return &NullableLinkNicRequest{value: val, isSet: true} +} + +func (v NullableLinkNicRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkNicRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go new file mode 100644 index 000000000..22c3d4e66 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkNicResponse struct for LinkNicResponse +type LinkNicResponse struct { + // The ID of the NIC attachment. + LinkNicId *string `json:"LinkNicId,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkNicResponse instantiates a new LinkNicResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkNicResponse() *LinkNicResponse { + this := LinkNicResponse{} + return &this +} + +// NewLinkNicResponseWithDefaults instantiates a new LinkNicResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkNicResponseWithDefaults() *LinkNicResponse { + this := LinkNicResponse{} + return &this +} + +// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. +func (o *LinkNicResponse) GetLinkNicId() string { + if o == nil || o.LinkNicId == nil { + var ret string + return ret + } + return *o.LinkNicId +} + +// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicResponse) GetLinkNicIdOk() (*string, bool) { + if o == nil || o.LinkNicId == nil { + return nil, false + } + return o.LinkNicId, true +} + +// HasLinkNicId returns a boolean if a field has been set. +func (o *LinkNicResponse) HasLinkNicId() bool { + if o != nil && o.LinkNicId != nil { + return true + } + + return false +} + +// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. +func (o *LinkNicResponse) SetLinkNicId(v string) { + o.LinkNicId = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkNicResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkNicResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkNicResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkNicResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkNicId != nil { + toSerialize["LinkNicId"] = o.LinkNicId + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkNicResponse struct { + value *LinkNicResponse + isSet bool +} + +func (v NullableLinkNicResponse) Get() *LinkNicResponse { + return v.value +} + +func (v *NullableLinkNicResponse) Set(val *LinkNicResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkNicResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkNicResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkNicResponse(val *LinkNicResponse) *NullableLinkNicResponse { + return &NullableLinkNicResponse{value: val, isSet: true} +} + +func (v NullableLinkNicResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkNicResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go new file mode 100644 index 000000000..f013a45ed --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkNicToUpdate Information about the NIC attachment. If you are modifying the `DeleteOnVmDeletion` attribute, you must specify the ID of the NIC attachment. +type LinkNicToUpdate struct { + // If `true`, the NIC is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The ID of the NIC attachment. + LinkNicId *string `json:"LinkNicId,omitempty"` +} + +// NewLinkNicToUpdate instantiates a new LinkNicToUpdate object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkNicToUpdate() *LinkNicToUpdate { + this := LinkNicToUpdate{} + return &this +} + +// NewLinkNicToUpdateWithDefaults instantiates a new LinkNicToUpdate object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkNicToUpdateWithDefaults() *LinkNicToUpdate { + this := LinkNicToUpdate{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *LinkNicToUpdate) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicToUpdate) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *LinkNicToUpdate) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *LinkNicToUpdate) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. +func (o *LinkNicToUpdate) GetLinkNicId() string { + if o == nil || o.LinkNicId == nil { + var ret string + return ret + } + return *o.LinkNicId +} + +// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkNicToUpdate) GetLinkNicIdOk() (*string, bool) { + if o == nil || o.LinkNicId == nil { + return nil, false + } + return o.LinkNicId, true +} + +// HasLinkNicId returns a boolean if a field has been set. +func (o *LinkNicToUpdate) HasLinkNicId() bool { + if o != nil && o.LinkNicId != nil { + return true + } + + return false +} + +// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. +func (o *LinkNicToUpdate) SetLinkNicId(v string) { + o.LinkNicId = &v +} + +func (o LinkNicToUpdate) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.LinkNicId != nil { + toSerialize["LinkNicId"] = o.LinkNicId + } + return json.Marshal(toSerialize) +} + +type NullableLinkNicToUpdate struct { + value *LinkNicToUpdate + isSet bool +} + +func (v NullableLinkNicToUpdate) Get() *LinkNicToUpdate { + return v.value +} + +func (v *NullableLinkNicToUpdate) Set(val *LinkNicToUpdate) { + v.value = val + v.isSet = true +} + +func (v NullableLinkNicToUpdate) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkNicToUpdate) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkNicToUpdate(val *LinkNicToUpdate) *NullableLinkNicToUpdate { + return &NullableLinkNicToUpdate{value: val, isSet: true} +} + +func (v NullableLinkNicToUpdate) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkNicToUpdate) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go new file mode 100644 index 000000000..e80f933a7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go @@ -0,0 +1,258 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPrivateIpsRequest struct for LinkPrivateIpsRequest +type LinkPrivateIpsRequest struct { + // If `true`, allows an IP address that is already assigned to another NIC in the same Subnet to be assigned to the NIC you specified. + AllowRelink *bool `json:"AllowRelink,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the NIC. + NicId string `json:"NicId"` + // The secondary private IP address or addresses you want to assign to the NIC within the IP address range of the Subnet. + PrivateIps *[]string `json:"PrivateIps,omitempty"` + // The number of secondary private IP addresses to assign to the NIC. + SecondaryPrivateIpCount *int32 `json:"SecondaryPrivateIpCount,omitempty"` +} + +// NewLinkPrivateIpsRequest instantiates a new LinkPrivateIpsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPrivateIpsRequest(nicId string, ) *LinkPrivateIpsRequest { + this := LinkPrivateIpsRequest{} + this.NicId = nicId + return &this +} + +// NewLinkPrivateIpsRequestWithDefaults instantiates a new LinkPrivateIpsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPrivateIpsRequestWithDefaults() *LinkPrivateIpsRequest { + this := LinkPrivateIpsRequest{} + return &this +} + +// GetAllowRelink returns the AllowRelink field value if set, zero value otherwise. +func (o *LinkPrivateIpsRequest) GetAllowRelink() bool { + if o == nil || o.AllowRelink == nil { + var ret bool + return ret + } + return *o.AllowRelink +} + +// GetAllowRelinkOk returns a tuple with the AllowRelink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsRequest) GetAllowRelinkOk() (*bool, bool) { + if o == nil || o.AllowRelink == nil { + return nil, false + } + return o.AllowRelink, true +} + +// HasAllowRelink returns a boolean if a field has been set. +func (o *LinkPrivateIpsRequest) HasAllowRelink() bool { + if o != nil && o.AllowRelink != nil { + return true + } + + return false +} + +// SetAllowRelink gets a reference to the given bool and assigns it to the AllowRelink field. +func (o *LinkPrivateIpsRequest) SetAllowRelink(v bool) { + o.AllowRelink = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkPrivateIpsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkPrivateIpsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkPrivateIpsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNicId returns the NicId field value +func (o *LinkPrivateIpsRequest) GetNicId() string { + if o == nil { + var ret string + return ret + } + + return o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsRequest) GetNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NicId, true +} + +// SetNicId sets field value +func (o *LinkPrivateIpsRequest) SetNicId(v string) { + o.NicId = v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *LinkPrivateIpsRequest) GetPrivateIps() []string { + if o == nil || o.PrivateIps == nil { + var ret []string + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsRequest) GetPrivateIpsOk() (*[]string, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *LinkPrivateIpsRequest) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. +func (o *LinkPrivateIpsRequest) SetPrivateIps(v []string) { + o.PrivateIps = &v +} + +// GetSecondaryPrivateIpCount returns the SecondaryPrivateIpCount field value if set, zero value otherwise. +func (o *LinkPrivateIpsRequest) GetSecondaryPrivateIpCount() int32 { + if o == nil || o.SecondaryPrivateIpCount == nil { + var ret int32 + return ret + } + return *o.SecondaryPrivateIpCount +} + +// GetSecondaryPrivateIpCountOk returns a tuple with the SecondaryPrivateIpCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsRequest) GetSecondaryPrivateIpCountOk() (*int32, bool) { + if o == nil || o.SecondaryPrivateIpCount == nil { + return nil, false + } + return o.SecondaryPrivateIpCount, true +} + +// HasSecondaryPrivateIpCount returns a boolean if a field has been set. +func (o *LinkPrivateIpsRequest) HasSecondaryPrivateIpCount() bool { + if o != nil && o.SecondaryPrivateIpCount != nil { + return true + } + + return false +} + +// SetSecondaryPrivateIpCount gets a reference to the given int32 and assigns it to the SecondaryPrivateIpCount field. +func (o *LinkPrivateIpsRequest) SetSecondaryPrivateIpCount(v int32) { + o.SecondaryPrivateIpCount = &v +} + +func (o LinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AllowRelink != nil { + toSerialize["AllowRelink"] = o.AllowRelink + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NicId"] = o.NicId + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecondaryPrivateIpCount != nil { + toSerialize["SecondaryPrivateIpCount"] = o.SecondaryPrivateIpCount + } + return json.Marshal(toSerialize) +} + +type NullableLinkPrivateIpsRequest struct { + value *LinkPrivateIpsRequest + isSet bool +} + +func (v NullableLinkPrivateIpsRequest) Get() *LinkPrivateIpsRequest { + return v.value +} + +func (v *NullableLinkPrivateIpsRequest) Set(val *LinkPrivateIpsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPrivateIpsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPrivateIpsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPrivateIpsRequest(val *LinkPrivateIpsRequest) *NullableLinkPrivateIpsRequest { + return &NullableLinkPrivateIpsRequest{value: val, isSet: true} +} + +func (v NullableLinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPrivateIpsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go new file mode 100644 index 000000000..5277585de --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPrivateIpsResponse struct for LinkPrivateIpsResponse +type LinkPrivateIpsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkPrivateIpsResponse instantiates a new LinkPrivateIpsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPrivateIpsResponse() *LinkPrivateIpsResponse { + this := LinkPrivateIpsResponse{} + return &this +} + +// NewLinkPrivateIpsResponseWithDefaults instantiates a new LinkPrivateIpsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPrivateIpsResponseWithDefaults() *LinkPrivateIpsResponse { + this := LinkPrivateIpsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkPrivateIpsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPrivateIpsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkPrivateIpsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkPrivateIpsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkPrivateIpsResponse struct { + value *LinkPrivateIpsResponse + isSet bool +} + +func (v NullableLinkPrivateIpsResponse) Get() *LinkPrivateIpsResponse { + return v.value +} + +func (v *NullableLinkPrivateIpsResponse) Set(val *LinkPrivateIpsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPrivateIpsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPrivateIpsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPrivateIpsResponse(val *LinkPrivateIpsResponse) *NullableLinkPrivateIpsResponse { + return &NullableLinkPrivateIpsResponse{value: val, isSet: true} +} + +func (v NullableLinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPrivateIpsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go new file mode 100644 index 000000000..30b31e1b8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPublicIp Information about the EIP association. +type LinkPublicIp struct { + // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` + // The name of the public DNS. + PublicDnsName *string `json:"PublicDnsName,omitempty"` + // The External IP address (EIP) associated with the NIC. + PublicIp *string `json:"PublicIp,omitempty"` + // The account ID of the owner of the EIP. + PublicIpAccountId *string `json:"PublicIpAccountId,omitempty"` + // The allocation ID of the EIP. + PublicIpId *string `json:"PublicIpId,omitempty"` +} + +// NewLinkPublicIp instantiates a new LinkPublicIp object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPublicIp() *LinkPublicIp { + this := LinkPublicIp{} + return &this +} + +// NewLinkPublicIpWithDefaults instantiates a new LinkPublicIp object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPublicIpWithDefaults() *LinkPublicIp { + this := LinkPublicIp{} + return &this +} + +// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. +func (o *LinkPublicIp) GetLinkPublicIpId() string { + if o == nil || o.LinkPublicIpId == nil { + var ret string + return ret + } + return *o.LinkPublicIpId +} + +// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIp) GetLinkPublicIpIdOk() (*string, bool) { + if o == nil || o.LinkPublicIpId == nil { + return nil, false + } + return o.LinkPublicIpId, true +} + +// HasLinkPublicIpId returns a boolean if a field has been set. +func (o *LinkPublicIp) HasLinkPublicIpId() bool { + if o != nil && o.LinkPublicIpId != nil { + return true + } + + return false +} + +// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. +func (o *LinkPublicIp) SetLinkPublicIpId(v string) { + o.LinkPublicIpId = &v +} + +// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. +func (o *LinkPublicIp) GetPublicDnsName() string { + if o == nil || o.PublicDnsName == nil { + var ret string + return ret + } + return *o.PublicDnsName +} + +// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIp) GetPublicDnsNameOk() (*string, bool) { + if o == nil || o.PublicDnsName == nil { + return nil, false + } + return o.PublicDnsName, true +} + +// HasPublicDnsName returns a boolean if a field has been set. +func (o *LinkPublicIp) HasPublicDnsName() bool { + if o != nil && o.PublicDnsName != nil { + return true + } + + return false +} + +// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. +func (o *LinkPublicIp) SetPublicDnsName(v string) { + o.PublicDnsName = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *LinkPublicIp) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIp) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *LinkPublicIp) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *LinkPublicIp) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpAccountId returns the PublicIpAccountId field value if set, zero value otherwise. +func (o *LinkPublicIp) GetPublicIpAccountId() string { + if o == nil || o.PublicIpAccountId == nil { + var ret string + return ret + } + return *o.PublicIpAccountId +} + +// GetPublicIpAccountIdOk returns a tuple with the PublicIpAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIp) GetPublicIpAccountIdOk() (*string, bool) { + if o == nil || o.PublicIpAccountId == nil { + return nil, false + } + return o.PublicIpAccountId, true +} + +// HasPublicIpAccountId returns a boolean if a field has been set. +func (o *LinkPublicIp) HasPublicIpAccountId() bool { + if o != nil && o.PublicIpAccountId != nil { + return true + } + + return false +} + +// SetPublicIpAccountId gets a reference to the given string and assigns it to the PublicIpAccountId field. +func (o *LinkPublicIp) SetPublicIpAccountId(v string) { + o.PublicIpAccountId = &v +} + +// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. +func (o *LinkPublicIp) GetPublicIpId() string { + if o == nil || o.PublicIpId == nil { + var ret string + return ret + } + return *o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIp) GetPublicIpIdOk() (*string, bool) { + if o == nil || o.PublicIpId == nil { + return nil, false + } + return o.PublicIpId, true +} + +// HasPublicIpId returns a boolean if a field has been set. +func (o *LinkPublicIp) HasPublicIpId() bool { + if o != nil && o.PublicIpId != nil { + return true + } + + return false +} + +// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. +func (o *LinkPublicIp) SetPublicIpId(v string) { + o.PublicIpId = &v +} + +func (o LinkPublicIp) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkPublicIpId != nil { + toSerialize["LinkPublicIpId"] = o.LinkPublicIpId + } + if o.PublicDnsName != nil { + toSerialize["PublicDnsName"] = o.PublicDnsName + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpAccountId != nil { + toSerialize["PublicIpAccountId"] = o.PublicIpAccountId + } + if o.PublicIpId != nil { + toSerialize["PublicIpId"] = o.PublicIpId + } + return json.Marshal(toSerialize) +} + +type NullableLinkPublicIp struct { + value *LinkPublicIp + isSet bool +} + +func (v NullableLinkPublicIp) Get() *LinkPublicIp { + return v.value +} + +func (v *NullableLinkPublicIp) Set(val *LinkPublicIp) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPublicIp) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPublicIp) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPublicIp(val *LinkPublicIp) *NullableLinkPublicIp { + return &NullableLinkPublicIp{value: val, isSet: true} +} + +func (v NullableLinkPublicIp) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPublicIp) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go new file mode 100644 index 000000000..858c6cd97 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPublicIpLightForVm Information about the EIP associated with the NIC. +type LinkPublicIpLightForVm struct { + // The name of the public DNS. + PublicDnsName *string `json:"PublicDnsName,omitempty"` + // The External IP address (EIP) associated with the NIC. + PublicIp *string `json:"PublicIp,omitempty"` + // The account ID of the owner of the EIP. + PublicIpAccountId *string `json:"PublicIpAccountId,omitempty"` +} + +// NewLinkPublicIpLightForVm instantiates a new LinkPublicIpLightForVm object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPublicIpLightForVm() *LinkPublicIpLightForVm { + this := LinkPublicIpLightForVm{} + return &this +} + +// NewLinkPublicIpLightForVmWithDefaults instantiates a new LinkPublicIpLightForVm object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPublicIpLightForVmWithDefaults() *LinkPublicIpLightForVm { + this := LinkPublicIpLightForVm{} + return &this +} + +// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. +func (o *LinkPublicIpLightForVm) GetPublicDnsName() string { + if o == nil || o.PublicDnsName == nil { + var ret string + return ret + } + return *o.PublicDnsName +} + +// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpLightForVm) GetPublicDnsNameOk() (*string, bool) { + if o == nil || o.PublicDnsName == nil { + return nil, false + } + return o.PublicDnsName, true +} + +// HasPublicDnsName returns a boolean if a field has been set. +func (o *LinkPublicIpLightForVm) HasPublicDnsName() bool { + if o != nil && o.PublicDnsName != nil { + return true + } + + return false +} + +// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. +func (o *LinkPublicIpLightForVm) SetPublicDnsName(v string) { + o.PublicDnsName = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *LinkPublicIpLightForVm) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpLightForVm) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *LinkPublicIpLightForVm) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *LinkPublicIpLightForVm) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpAccountId returns the PublicIpAccountId field value if set, zero value otherwise. +func (o *LinkPublicIpLightForVm) GetPublicIpAccountId() string { + if o == nil || o.PublicIpAccountId == nil { + var ret string + return ret + } + return *o.PublicIpAccountId +} + +// GetPublicIpAccountIdOk returns a tuple with the PublicIpAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpLightForVm) GetPublicIpAccountIdOk() (*string, bool) { + if o == nil || o.PublicIpAccountId == nil { + return nil, false + } + return o.PublicIpAccountId, true +} + +// HasPublicIpAccountId returns a boolean if a field has been set. +func (o *LinkPublicIpLightForVm) HasPublicIpAccountId() bool { + if o != nil && o.PublicIpAccountId != nil { + return true + } + + return false +} + +// SetPublicIpAccountId gets a reference to the given string and assigns it to the PublicIpAccountId field. +func (o *LinkPublicIpLightForVm) SetPublicIpAccountId(v string) { + o.PublicIpAccountId = &v +} + +func (o LinkPublicIpLightForVm) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PublicDnsName != nil { + toSerialize["PublicDnsName"] = o.PublicDnsName + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpAccountId != nil { + toSerialize["PublicIpAccountId"] = o.PublicIpAccountId + } + return json.Marshal(toSerialize) +} + +type NullableLinkPublicIpLightForVm struct { + value *LinkPublicIpLightForVm + isSet bool +} + +func (v NullableLinkPublicIpLightForVm) Get() *LinkPublicIpLightForVm { + return v.value +} + +func (v *NullableLinkPublicIpLightForVm) Set(val *LinkPublicIpLightForVm) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPublicIpLightForVm) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPublicIpLightForVm) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPublicIpLightForVm(val *LinkPublicIpLightForVm) *NullableLinkPublicIpLightForVm { + return &NullableLinkPublicIpLightForVm{value: val, isSet: true} +} + +func (v NullableLinkPublicIpLightForVm) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPublicIpLightForVm) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go new file mode 100644 index 000000000..e2fc86d3e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPublicIpRequest struct for LinkPublicIpRequest +type LinkPublicIpRequest struct { + // - If `true`, allows the EIP to be associated with the VM or NIC that you specify even if it is already associated with another VM or NIC.
- If `false`, prevents the EIP from being associated with the VM or NIC that you specify if it is already associated with another VM or NIC.

(By default, `true` in the public Cloud, `false` in a Net.) + AllowRelink *bool `json:"AllowRelink,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // (Net only) The ID of the NIC. This parameter is required if the VM has more than one NIC attached. Otherwise, you need to specify the `VmId` parameter instead. You cannot specify both parameters at the same time. + NicId *string `json:"NicId,omitempty"` + // (Net only) The primary or secondary private IP address of the specified NIC. By default, the primary private IP address. + PrivateIp *string `json:"PrivateIp,omitempty"` + // The EIP. In the public Cloud, this parameter is required. + PublicIp *string `json:"PublicIp,omitempty"` + // The allocation ID of the EIP. In a Net, this parameter is required. + PublicIpId *string `json:"PublicIpId,omitempty"` + // The ID of the VM.
- In the public Cloud, this parameter is required.
- In a Net, this parameter is required if the VM has only one NIC. Otherwise, you need to specify the `NicId` parameter instead. You cannot specify both parameters at the same time. + VmId *string `json:"VmId,omitempty"` +} + +// NewLinkPublicIpRequest instantiates a new LinkPublicIpRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPublicIpRequest() *LinkPublicIpRequest { + this := LinkPublicIpRequest{} + return &this +} + +// NewLinkPublicIpRequestWithDefaults instantiates a new LinkPublicIpRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPublicIpRequestWithDefaults() *LinkPublicIpRequest { + this := LinkPublicIpRequest{} + return &this +} + +// GetAllowRelink returns the AllowRelink field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetAllowRelink() bool { + if o == nil || o.AllowRelink == nil { + var ret bool + return ret + } + return *o.AllowRelink +} + +// GetAllowRelinkOk returns a tuple with the AllowRelink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetAllowRelinkOk() (*bool, bool) { + if o == nil || o.AllowRelink == nil { + return nil, false + } + return o.AllowRelink, true +} + +// HasAllowRelink returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasAllowRelink() bool { + if o != nil && o.AllowRelink != nil { + return true + } + + return false +} + +// SetAllowRelink gets a reference to the given bool and assigns it to the AllowRelink field. +func (o *LinkPublicIpRequest) SetAllowRelink(v bool) { + o.AllowRelink = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkPublicIpRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *LinkPublicIpRequest) SetNicId(v string) { + o.NicId = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *LinkPublicIpRequest) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *LinkPublicIpRequest) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetPublicIpId() string { + if o == nil || o.PublicIpId == nil { + var ret string + return ret + } + return *o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetPublicIpIdOk() (*string, bool) { + if o == nil || o.PublicIpId == nil { + return nil, false + } + return o.PublicIpId, true +} + +// HasPublicIpId returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasPublicIpId() bool { + if o != nil && o.PublicIpId != nil { + return true + } + + return false +} + +// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. +func (o *LinkPublicIpRequest) SetPublicIpId(v string) { + o.PublicIpId = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *LinkPublicIpRequest) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpRequest) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *LinkPublicIpRequest) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *LinkPublicIpRequest) SetVmId(v string) { + o.VmId = &v +} + +func (o LinkPublicIpRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AllowRelink != nil { + toSerialize["AllowRelink"] = o.AllowRelink + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpId != nil { + toSerialize["PublicIpId"] = o.PublicIpId + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableLinkPublicIpRequest struct { + value *LinkPublicIpRequest + isSet bool +} + +func (v NullableLinkPublicIpRequest) Get() *LinkPublicIpRequest { + return v.value +} + +func (v *NullableLinkPublicIpRequest) Set(val *LinkPublicIpRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPublicIpRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPublicIpRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPublicIpRequest(val *LinkPublicIpRequest) *NullableLinkPublicIpRequest { + return &NullableLinkPublicIpRequest{value: val, isSet: true} +} + +func (v NullableLinkPublicIpRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPublicIpRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go new file mode 100644 index 000000000..46cefe06c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkPublicIpResponse struct for LinkPublicIpResponse +type LinkPublicIpResponse struct { + // (Net only) The ID representing the association of the EIP with the VM or the NIC. + LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkPublicIpResponse instantiates a new LinkPublicIpResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkPublicIpResponse() *LinkPublicIpResponse { + this := LinkPublicIpResponse{} + return &this +} + +// NewLinkPublicIpResponseWithDefaults instantiates a new LinkPublicIpResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkPublicIpResponseWithDefaults() *LinkPublicIpResponse { + this := LinkPublicIpResponse{} + return &this +} + +// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. +func (o *LinkPublicIpResponse) GetLinkPublicIpId() string { + if o == nil || o.LinkPublicIpId == nil { + var ret string + return ret + } + return *o.LinkPublicIpId +} + +// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpResponse) GetLinkPublicIpIdOk() (*string, bool) { + if o == nil || o.LinkPublicIpId == nil { + return nil, false + } + return o.LinkPublicIpId, true +} + +// HasLinkPublicIpId returns a boolean if a field has been set. +func (o *LinkPublicIpResponse) HasLinkPublicIpId() bool { + if o != nil && o.LinkPublicIpId != nil { + return true + } + + return false +} + +// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. +func (o *LinkPublicIpResponse) SetLinkPublicIpId(v string) { + o.LinkPublicIpId = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkPublicIpResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkPublicIpResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkPublicIpResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkPublicIpResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkPublicIpResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkPublicIpId != nil { + toSerialize["LinkPublicIpId"] = o.LinkPublicIpId + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkPublicIpResponse struct { + value *LinkPublicIpResponse + isSet bool +} + +func (v NullableLinkPublicIpResponse) Get() *LinkPublicIpResponse { + return v.value +} + +func (v *NullableLinkPublicIpResponse) Set(val *LinkPublicIpResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkPublicIpResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkPublicIpResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkPublicIpResponse(val *LinkPublicIpResponse) *NullableLinkPublicIpResponse { + return &NullableLinkPublicIpResponse{value: val, isSet: true} +} + +func (v NullableLinkPublicIpResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkPublicIpResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go new file mode 100644 index 000000000..fc60fbebb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkRouteTable One or more associations between the route table and the Subnets. +type LinkRouteTable struct { + // The ID of the association between the route table and the Subnet. + LinkRouteTableId *string `json:"LinkRouteTableId,omitempty"` + // If `true`, the route table is the main one. + Main *bool `json:"Main,omitempty"` + // The ID of the route table. + RouteTableId *string `json:"RouteTableId,omitempty"` + // The ID of the Subnet. + SubnetId *string `json:"SubnetId,omitempty"` +} + +// NewLinkRouteTable instantiates a new LinkRouteTable object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkRouteTable() *LinkRouteTable { + this := LinkRouteTable{} + return &this +} + +// NewLinkRouteTableWithDefaults instantiates a new LinkRouteTable object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkRouteTableWithDefaults() *LinkRouteTable { + this := LinkRouteTable{} + return &this +} + +// GetLinkRouteTableId returns the LinkRouteTableId field value if set, zero value otherwise. +func (o *LinkRouteTable) GetLinkRouteTableId() string { + if o == nil || o.LinkRouteTableId == nil { + var ret string + return ret + } + return *o.LinkRouteTableId +} + +// GetLinkRouteTableIdOk returns a tuple with the LinkRouteTableId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTable) GetLinkRouteTableIdOk() (*string, bool) { + if o == nil || o.LinkRouteTableId == nil { + return nil, false + } + return o.LinkRouteTableId, true +} + +// HasLinkRouteTableId returns a boolean if a field has been set. +func (o *LinkRouteTable) HasLinkRouteTableId() bool { + if o != nil && o.LinkRouteTableId != nil { + return true + } + + return false +} + +// SetLinkRouteTableId gets a reference to the given string and assigns it to the LinkRouteTableId field. +func (o *LinkRouteTable) SetLinkRouteTableId(v string) { + o.LinkRouteTableId = &v +} + +// GetMain returns the Main field value if set, zero value otherwise. +func (o *LinkRouteTable) GetMain() bool { + if o == nil || o.Main == nil { + var ret bool + return ret + } + return *o.Main +} + +// GetMainOk returns a tuple with the Main field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTable) GetMainOk() (*bool, bool) { + if o == nil || o.Main == nil { + return nil, false + } + return o.Main, true +} + +// HasMain returns a boolean if a field has been set. +func (o *LinkRouteTable) HasMain() bool { + if o != nil && o.Main != nil { + return true + } + + return false +} + +// SetMain gets a reference to the given bool and assigns it to the Main field. +func (o *LinkRouteTable) SetMain(v bool) { + o.Main = &v +} + +// GetRouteTableId returns the RouteTableId field value if set, zero value otherwise. +func (o *LinkRouteTable) GetRouteTableId() string { + if o == nil || o.RouteTableId == nil { + var ret string + return ret + } + return *o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTable) GetRouteTableIdOk() (*string, bool) { + if o == nil || o.RouteTableId == nil { + return nil, false + } + return o.RouteTableId, true +} + +// HasRouteTableId returns a boolean if a field has been set. +func (o *LinkRouteTable) HasRouteTableId() bool { + if o != nil && o.RouteTableId != nil { + return true + } + + return false +} + +// SetRouteTableId gets a reference to the given string and assigns it to the RouteTableId field. +func (o *LinkRouteTable) SetRouteTableId(v string) { + o.RouteTableId = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *LinkRouteTable) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTable) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *LinkRouteTable) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *LinkRouteTable) SetSubnetId(v string) { + o.SubnetId = &v +} + +func (o LinkRouteTable) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkRouteTableId != nil { + toSerialize["LinkRouteTableId"] = o.LinkRouteTableId + } + if o.Main != nil { + toSerialize["Main"] = o.Main + } + if o.RouteTableId != nil { + toSerialize["RouteTableId"] = o.RouteTableId + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableLinkRouteTable struct { + value *LinkRouteTable + isSet bool +} + +func (v NullableLinkRouteTable) Get() *LinkRouteTable { + return v.value +} + +func (v *NullableLinkRouteTable) Set(val *LinkRouteTable) { + v.value = val + v.isSet = true +} + +func (v NullableLinkRouteTable) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkRouteTable) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkRouteTable(val *LinkRouteTable) *NullableLinkRouteTable { + return &NullableLinkRouteTable{value: val, isSet: true} +} + +func (v NullableLinkRouteTable) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkRouteTable) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go new file mode 100644 index 000000000..edd19ecf8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkRouteTableRequest struct for LinkRouteTableRequest +type LinkRouteTableRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the route table. + RouteTableId string `json:"RouteTableId"` + // The ID of the Subnet. + SubnetId string `json:"SubnetId"` +} + +// NewLinkRouteTableRequest instantiates a new LinkRouteTableRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkRouteTableRequest(routeTableId string, subnetId string, ) *LinkRouteTableRequest { + this := LinkRouteTableRequest{} + this.RouteTableId = routeTableId + this.SubnetId = subnetId + return &this +} + +// NewLinkRouteTableRequestWithDefaults instantiates a new LinkRouteTableRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkRouteTableRequestWithDefaults() *LinkRouteTableRequest { + this := LinkRouteTableRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkRouteTableRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTableRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkRouteTableRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkRouteTableRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *LinkRouteTableRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *LinkRouteTableRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *LinkRouteTableRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +// GetSubnetId returns the SubnetId field value +func (o *LinkRouteTableRequest) GetSubnetId() string { + if o == nil { + var ret string + return ret + } + + return o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value +// and a boolean to check if the value has been set. +func (o *LinkRouteTableRequest) GetSubnetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubnetId, true +} + +// SetSubnetId sets field value +func (o *LinkRouteTableRequest) SetSubnetId(v string) { + o.SubnetId = v +} + +func (o LinkRouteTableRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + if true { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableLinkRouteTableRequest struct { + value *LinkRouteTableRequest + isSet bool +} + +func (v NullableLinkRouteTableRequest) Get() *LinkRouteTableRequest { + return v.value +} + +func (v *NullableLinkRouteTableRequest) Set(val *LinkRouteTableRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkRouteTableRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkRouteTableRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkRouteTableRequest(val *LinkRouteTableRequest) *NullableLinkRouteTableRequest { + return &NullableLinkRouteTableRequest{value: val, isSet: true} +} + +func (v NullableLinkRouteTableRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkRouteTableRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go new file mode 100644 index 000000000..14c0dbc31 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkRouteTableResponse struct for LinkRouteTableResponse +type LinkRouteTableResponse struct { + // The ID of the association between the route table and the Subnet. + LinkRouteTableId *string `json:"LinkRouteTableId,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkRouteTableResponse instantiates a new LinkRouteTableResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkRouteTableResponse() *LinkRouteTableResponse { + this := LinkRouteTableResponse{} + return &this +} + +// NewLinkRouteTableResponseWithDefaults instantiates a new LinkRouteTableResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkRouteTableResponseWithDefaults() *LinkRouteTableResponse { + this := LinkRouteTableResponse{} + return &this +} + +// GetLinkRouteTableId returns the LinkRouteTableId field value if set, zero value otherwise. +func (o *LinkRouteTableResponse) GetLinkRouteTableId() string { + if o == nil || o.LinkRouteTableId == nil { + var ret string + return ret + } + return *o.LinkRouteTableId +} + +// GetLinkRouteTableIdOk returns a tuple with the LinkRouteTableId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTableResponse) GetLinkRouteTableIdOk() (*string, bool) { + if o == nil || o.LinkRouteTableId == nil { + return nil, false + } + return o.LinkRouteTableId, true +} + +// HasLinkRouteTableId returns a boolean if a field has been set. +func (o *LinkRouteTableResponse) HasLinkRouteTableId() bool { + if o != nil && o.LinkRouteTableId != nil { + return true + } + + return false +} + +// SetLinkRouteTableId gets a reference to the given string and assigns it to the LinkRouteTableId field. +func (o *LinkRouteTableResponse) SetLinkRouteTableId(v string) { + o.LinkRouteTableId = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkRouteTableResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkRouteTableResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkRouteTableResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkRouteTableResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkRouteTableResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkRouteTableId != nil { + toSerialize["LinkRouteTableId"] = o.LinkRouteTableId + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkRouteTableResponse struct { + value *LinkRouteTableResponse + isSet bool +} + +func (v NullableLinkRouteTableResponse) Get() *LinkRouteTableResponse { + return v.value +} + +func (v *NullableLinkRouteTableResponse) Set(val *LinkRouteTableResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkRouteTableResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkRouteTableResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkRouteTableResponse(val *LinkRouteTableResponse) *NullableLinkRouteTableResponse { + return &NullableLinkRouteTableResponse{value: val, isSet: true} +} + +func (v NullableLinkRouteTableResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkRouteTableResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go new file mode 100644 index 000000000..c345e9bc7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkVirtualGatewayRequest struct for LinkVirtualGatewayRequest +type LinkVirtualGatewayRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net to which you want to attach the virtual gateway. + NetId string `json:"NetId"` + // The ID of the virtual gateway. + VirtualGatewayId string `json:"VirtualGatewayId"` +} + +// NewLinkVirtualGatewayRequest instantiates a new LinkVirtualGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkVirtualGatewayRequest(netId string, virtualGatewayId string, ) *LinkVirtualGatewayRequest { + this := LinkVirtualGatewayRequest{} + this.NetId = netId + this.VirtualGatewayId = virtualGatewayId + return &this +} + +// NewLinkVirtualGatewayRequestWithDefaults instantiates a new LinkVirtualGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkVirtualGatewayRequestWithDefaults() *LinkVirtualGatewayRequest { + this := LinkVirtualGatewayRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkVirtualGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkVirtualGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkVirtualGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkVirtualGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *LinkVirtualGatewayRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *LinkVirtualGatewayRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *LinkVirtualGatewayRequest) SetNetId(v string) { + o.NetId = v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *LinkVirtualGatewayRequest) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *LinkVirtualGatewayRequest) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *LinkVirtualGatewayRequest) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +func (o LinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableLinkVirtualGatewayRequest struct { + value *LinkVirtualGatewayRequest + isSet bool +} + +func (v NullableLinkVirtualGatewayRequest) Get() *LinkVirtualGatewayRequest { + return v.value +} + +func (v *NullableLinkVirtualGatewayRequest) Set(val *LinkVirtualGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkVirtualGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkVirtualGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkVirtualGatewayRequest(val *LinkVirtualGatewayRequest) *NullableLinkVirtualGatewayRequest { + return &NullableLinkVirtualGatewayRequest{value: val, isSet: true} +} + +func (v NullableLinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkVirtualGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go new file mode 100644 index 000000000..029cd0534 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkVirtualGatewayResponse struct for LinkVirtualGatewayResponse +type LinkVirtualGatewayResponse struct { + NetToVirtualGatewayLink *NetToVirtualGatewayLink `json:"NetToVirtualGatewayLink,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkVirtualGatewayResponse instantiates a new LinkVirtualGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkVirtualGatewayResponse() *LinkVirtualGatewayResponse { + this := LinkVirtualGatewayResponse{} + return &this +} + +// NewLinkVirtualGatewayResponseWithDefaults instantiates a new LinkVirtualGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkVirtualGatewayResponseWithDefaults() *LinkVirtualGatewayResponse { + this := LinkVirtualGatewayResponse{} + return &this +} + +// GetNetToVirtualGatewayLink returns the NetToVirtualGatewayLink field value if set, zero value otherwise. +func (o *LinkVirtualGatewayResponse) GetNetToVirtualGatewayLink() NetToVirtualGatewayLink { + if o == nil || o.NetToVirtualGatewayLink == nil { + var ret NetToVirtualGatewayLink + return ret + } + return *o.NetToVirtualGatewayLink +} + +// GetNetToVirtualGatewayLinkOk returns a tuple with the NetToVirtualGatewayLink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkVirtualGatewayResponse) GetNetToVirtualGatewayLinkOk() (*NetToVirtualGatewayLink, bool) { + if o == nil || o.NetToVirtualGatewayLink == nil { + return nil, false + } + return o.NetToVirtualGatewayLink, true +} + +// HasNetToVirtualGatewayLink returns a boolean if a field has been set. +func (o *LinkVirtualGatewayResponse) HasNetToVirtualGatewayLink() bool { + if o != nil && o.NetToVirtualGatewayLink != nil { + return true + } + + return false +} + +// SetNetToVirtualGatewayLink gets a reference to the given NetToVirtualGatewayLink and assigns it to the NetToVirtualGatewayLink field. +func (o *LinkVirtualGatewayResponse) SetNetToVirtualGatewayLink(v NetToVirtualGatewayLink) { + o.NetToVirtualGatewayLink = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkVirtualGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkVirtualGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkVirtualGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkVirtualGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetToVirtualGatewayLink != nil { + toSerialize["NetToVirtualGatewayLink"] = o.NetToVirtualGatewayLink + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkVirtualGatewayResponse struct { + value *LinkVirtualGatewayResponse + isSet bool +} + +func (v NullableLinkVirtualGatewayResponse) Get() *LinkVirtualGatewayResponse { + return v.value +} + +func (v *NullableLinkVirtualGatewayResponse) Set(val *LinkVirtualGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkVirtualGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkVirtualGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkVirtualGatewayResponse(val *LinkVirtualGatewayResponse) *NullableLinkVirtualGatewayResponse { + return &NullableLinkVirtualGatewayResponse{value: val, isSet: true} +} + +func (v NullableLinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkVirtualGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go new file mode 100644 index 000000000..3073f479a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go @@ -0,0 +1,207 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkVolumeRequest struct for LinkVolumeRequest +type LinkVolumeRequest struct { + // The name of the device. + DeviceName string `json:"DeviceName"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the VM you want to attach the volume to. + VmId string `json:"VmId"` + // The ID of the volume you want to attach. + VolumeId string `json:"VolumeId"` +} + +// NewLinkVolumeRequest instantiates a new LinkVolumeRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkVolumeRequest(deviceName string, vmId string, volumeId string, ) *LinkVolumeRequest { + this := LinkVolumeRequest{} + this.DeviceName = deviceName + this.VmId = vmId + this.VolumeId = volumeId + return &this +} + +// NewLinkVolumeRequestWithDefaults instantiates a new LinkVolumeRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkVolumeRequestWithDefaults() *LinkVolumeRequest { + this := LinkVolumeRequest{} + return &this +} + +// GetDeviceName returns the DeviceName field value +func (o *LinkVolumeRequest) GetDeviceName() string { + if o == nil { + var ret string + return ret + } + + return o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value +// and a boolean to check if the value has been set. +func (o *LinkVolumeRequest) GetDeviceNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DeviceName, true +} + +// SetDeviceName sets field value +func (o *LinkVolumeRequest) SetDeviceName(v string) { + o.DeviceName = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *LinkVolumeRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkVolumeRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *LinkVolumeRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *LinkVolumeRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmId returns the VmId field value +func (o *LinkVolumeRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *LinkVolumeRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *LinkVolumeRequest) SetVmId(v string) { + o.VmId = v +} + +// GetVolumeId returns the VolumeId field value +func (o *LinkVolumeRequest) GetVolumeId() string { + if o == nil { + var ret string + return ret + } + + return o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value +// and a boolean to check if the value has been set. +func (o *LinkVolumeRequest) GetVolumeIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VolumeId, true +} + +// SetVolumeId sets field value +func (o *LinkVolumeRequest) SetVolumeId(v string) { + o.VolumeId = v +} + +func (o LinkVolumeRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DeviceName"] = o.DeviceName + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmId"] = o.VmId + } + if true { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableLinkVolumeRequest struct { + value *LinkVolumeRequest + isSet bool +} + +func (v NullableLinkVolumeRequest) Get() *LinkVolumeRequest { + return v.value +} + +func (v *NullableLinkVolumeRequest) Set(val *LinkVolumeRequest) { + v.value = val + v.isSet = true +} + +func (v NullableLinkVolumeRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkVolumeRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkVolumeRequest(val *LinkVolumeRequest) *NullableLinkVolumeRequest { + return &NullableLinkVolumeRequest{value: val, isSet: true} +} + +func (v NullableLinkVolumeRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkVolumeRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go new file mode 100644 index 000000000..0b2bfc2b0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkVolumeResponse struct for LinkVolumeResponse +type LinkVolumeResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewLinkVolumeResponse instantiates a new LinkVolumeResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkVolumeResponse() *LinkVolumeResponse { + this := LinkVolumeResponse{} + return &this +} + +// NewLinkVolumeResponseWithDefaults instantiates a new LinkVolumeResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkVolumeResponseWithDefaults() *LinkVolumeResponse { + this := LinkVolumeResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *LinkVolumeResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkVolumeResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *LinkVolumeResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *LinkVolumeResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o LinkVolumeResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableLinkVolumeResponse struct { + value *LinkVolumeResponse + isSet bool +} + +func (v NullableLinkVolumeResponse) Get() *LinkVolumeResponse { + return v.value +} + +func (v *NullableLinkVolumeResponse) Set(val *LinkVolumeResponse) { + v.value = val + v.isSet = true +} + +func (v NullableLinkVolumeResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkVolumeResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkVolumeResponse(val *LinkVolumeResponse) *NullableLinkVolumeResponse { + return &NullableLinkVolumeResponse{value: val, isSet: true} +} + +func (v NullableLinkVolumeResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkVolumeResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go new file mode 100644 index 000000000..40b03507e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LinkedVolume Information about volume attachment. +type LinkedVolume struct { + // If `true`, the volume is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The name of the device. + DeviceName *string `json:"DeviceName,omitempty"` + // The state of the attachment of the volume (`attaching` \\| `detaching` \\| `attached` \\| `detached`). + State *string `json:"State,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` + // The ID of the volume. + VolumeId *string `json:"VolumeId,omitempty"` +} + +// NewLinkedVolume instantiates a new LinkedVolume object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLinkedVolume() *LinkedVolume { + this := LinkedVolume{} + return &this +} + +// NewLinkedVolumeWithDefaults instantiates a new LinkedVolume object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLinkedVolumeWithDefaults() *LinkedVolume { + this := LinkedVolume{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *LinkedVolume) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkedVolume) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *LinkedVolume) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *LinkedVolume) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDeviceName returns the DeviceName field value if set, zero value otherwise. +func (o *LinkedVolume) GetDeviceName() string { + if o == nil || o.DeviceName == nil { + var ret string + return ret + } + return *o.DeviceName +} + +// GetDeviceNameOk returns a tuple with the DeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkedVolume) GetDeviceNameOk() (*string, bool) { + if o == nil || o.DeviceName == nil { + return nil, false + } + return o.DeviceName, true +} + +// HasDeviceName returns a boolean if a field has been set. +func (o *LinkedVolume) HasDeviceName() bool { + if o != nil && o.DeviceName != nil { + return true + } + + return false +} + +// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. +func (o *LinkedVolume) SetDeviceName(v string) { + o.DeviceName = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *LinkedVolume) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkedVolume) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *LinkedVolume) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *LinkedVolume) SetState(v string) { + o.State = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *LinkedVolume) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkedVolume) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *LinkedVolume) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *LinkedVolume) SetVmId(v string) { + o.VmId = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *LinkedVolume) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LinkedVolume) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *LinkedVolume) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *LinkedVolume) SetVolumeId(v string) { + o.VolumeId = &v +} + +func (o LinkedVolume) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.DeviceName != nil { + toSerialize["DeviceName"] = o.DeviceName + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableLinkedVolume struct { + value *LinkedVolume + isSet bool +} + +func (v NullableLinkedVolume) Get() *LinkedVolume { + return v.value +} + +func (v *NullableLinkedVolume) Set(val *LinkedVolume) { + v.value = val + v.isSet = true +} + +func (v NullableLinkedVolume) IsSet() bool { + return v.isSet +} + +func (v *NullableLinkedVolume) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLinkedVolume(val *LinkedVolume) *NullableLinkedVolume { + return &NullableLinkedVolume{value: val, isSet: true} +} + +func (v NullableLinkedVolume) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLinkedVolume) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go new file mode 100644 index 000000000..0bfc4733e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Listener Information about the listener. +type Listener struct { + // The port on which the back-end VM is listening (between `1` and `65535`, both included). + BackendPort *int32 `json:"BackendPort,omitempty"` + // The protocol for routing traffic to back-end VMs (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). + BackendProtocol *string `json:"BackendProtocol,omitempty"` + // The port on which the load balancer is listening (between 1 and `65535`, both included). + LoadBalancerPort *int32 `json:"LoadBalancerPort,omitempty"` + // The routing protocol (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). + LoadBalancerProtocol *string `json:"LoadBalancerProtocol,omitempty"` + // The names of the policies. If there are no policies enabled, the list is empty. + PolicyNames *[]string `json:"PolicyNames,omitempty"` + // The ID of the server certificate. + ServerCertificateId *string `json:"ServerCertificateId,omitempty"` +} + +// NewListener instantiates a new Listener object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListener() *Listener { + this := Listener{} + return &this +} + +// NewListenerWithDefaults instantiates a new Listener object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListenerWithDefaults() *Listener { + this := Listener{} + return &this +} + +// GetBackendPort returns the BackendPort field value if set, zero value otherwise. +func (o *Listener) GetBackendPort() int32 { + if o == nil || o.BackendPort == nil { + var ret int32 + return ret + } + return *o.BackendPort +} + +// GetBackendPortOk returns a tuple with the BackendPort field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetBackendPortOk() (*int32, bool) { + if o == nil || o.BackendPort == nil { + return nil, false + } + return o.BackendPort, true +} + +// HasBackendPort returns a boolean if a field has been set. +func (o *Listener) HasBackendPort() bool { + if o != nil && o.BackendPort != nil { + return true + } + + return false +} + +// SetBackendPort gets a reference to the given int32 and assigns it to the BackendPort field. +func (o *Listener) SetBackendPort(v int32) { + o.BackendPort = &v +} + +// GetBackendProtocol returns the BackendProtocol field value if set, zero value otherwise. +func (o *Listener) GetBackendProtocol() string { + if o == nil || o.BackendProtocol == nil { + var ret string + return ret + } + return *o.BackendProtocol +} + +// GetBackendProtocolOk returns a tuple with the BackendProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetBackendProtocolOk() (*string, bool) { + if o == nil || o.BackendProtocol == nil { + return nil, false + } + return o.BackendProtocol, true +} + +// HasBackendProtocol returns a boolean if a field has been set. +func (o *Listener) HasBackendProtocol() bool { + if o != nil && o.BackendProtocol != nil { + return true + } + + return false +} + +// SetBackendProtocol gets a reference to the given string and assigns it to the BackendProtocol field. +func (o *Listener) SetBackendProtocol(v string) { + o.BackendProtocol = &v +} + +// GetLoadBalancerPort returns the LoadBalancerPort field value if set, zero value otherwise. +func (o *Listener) GetLoadBalancerPort() int32 { + if o == nil || o.LoadBalancerPort == nil { + var ret int32 + return ret + } + return *o.LoadBalancerPort +} + +// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetLoadBalancerPortOk() (*int32, bool) { + if o == nil || o.LoadBalancerPort == nil { + return nil, false + } + return o.LoadBalancerPort, true +} + +// HasLoadBalancerPort returns a boolean if a field has been set. +func (o *Listener) HasLoadBalancerPort() bool { + if o != nil && o.LoadBalancerPort != nil { + return true + } + + return false +} + +// SetLoadBalancerPort gets a reference to the given int32 and assigns it to the LoadBalancerPort field. +func (o *Listener) SetLoadBalancerPort(v int32) { + o.LoadBalancerPort = &v +} + +// GetLoadBalancerProtocol returns the LoadBalancerProtocol field value if set, zero value otherwise. +func (o *Listener) GetLoadBalancerProtocol() string { + if o == nil || o.LoadBalancerProtocol == nil { + var ret string + return ret + } + return *o.LoadBalancerProtocol +} + +// GetLoadBalancerProtocolOk returns a tuple with the LoadBalancerProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetLoadBalancerProtocolOk() (*string, bool) { + if o == nil || o.LoadBalancerProtocol == nil { + return nil, false + } + return o.LoadBalancerProtocol, true +} + +// HasLoadBalancerProtocol returns a boolean if a field has been set. +func (o *Listener) HasLoadBalancerProtocol() bool { + if o != nil && o.LoadBalancerProtocol != nil { + return true + } + + return false +} + +// SetLoadBalancerProtocol gets a reference to the given string and assigns it to the LoadBalancerProtocol field. +func (o *Listener) SetLoadBalancerProtocol(v string) { + o.LoadBalancerProtocol = &v +} + +// GetPolicyNames returns the PolicyNames field value if set, zero value otherwise. +func (o *Listener) GetPolicyNames() []string { + if o == nil || o.PolicyNames == nil { + var ret []string + return ret + } + return *o.PolicyNames +} + +// GetPolicyNamesOk returns a tuple with the PolicyNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetPolicyNamesOk() (*[]string, bool) { + if o == nil || o.PolicyNames == nil { + return nil, false + } + return o.PolicyNames, true +} + +// HasPolicyNames returns a boolean if a field has been set. +func (o *Listener) HasPolicyNames() bool { + if o != nil && o.PolicyNames != nil { + return true + } + + return false +} + +// SetPolicyNames gets a reference to the given []string and assigns it to the PolicyNames field. +func (o *Listener) SetPolicyNames(v []string) { + o.PolicyNames = &v +} + +// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. +func (o *Listener) GetServerCertificateId() string { + if o == nil || o.ServerCertificateId == nil { + var ret string + return ret + } + return *o.ServerCertificateId +} + +// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Listener) GetServerCertificateIdOk() (*string, bool) { + if o == nil || o.ServerCertificateId == nil { + return nil, false + } + return o.ServerCertificateId, true +} + +// HasServerCertificateId returns a boolean if a field has been set. +func (o *Listener) HasServerCertificateId() bool { + if o != nil && o.ServerCertificateId != nil { + return true + } + + return false +} + +// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. +func (o *Listener) SetServerCertificateId(v string) { + o.ServerCertificateId = &v +} + +func (o Listener) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BackendPort != nil { + toSerialize["BackendPort"] = o.BackendPort + } + if o.BackendProtocol != nil { + toSerialize["BackendProtocol"] = o.BackendProtocol + } + if o.LoadBalancerPort != nil { + toSerialize["LoadBalancerPort"] = o.LoadBalancerPort + } + if o.LoadBalancerProtocol != nil { + toSerialize["LoadBalancerProtocol"] = o.LoadBalancerProtocol + } + if o.PolicyNames != nil { + toSerialize["PolicyNames"] = o.PolicyNames + } + if o.ServerCertificateId != nil { + toSerialize["ServerCertificateId"] = o.ServerCertificateId + } + return json.Marshal(toSerialize) +} + +type NullableListener struct { + value *Listener + isSet bool +} + +func (v NullableListener) Get() *Listener { + return v.value +} + +func (v *NullableListener) Set(val *Listener) { + v.value = val + v.isSet = true +} + +func (v NullableListener) IsSet() bool { + return v.isSet +} + +func (v *NullableListener) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListener(val *Listener) *NullableListener { + return &NullableListener{value: val, isSet: true} +} + +func (v NullableListener) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListener) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go new file mode 100644 index 000000000..6d463290f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go @@ -0,0 +1,244 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ListenerForCreation Information about the listener to create. +type ListenerForCreation struct { + // The port on which the back-end VM is listening (between `1` and `65535`, both included). + BackendPort int32 `json:"BackendPort"` + // The protocol for routing traffic to back-end VMs (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). + BackendProtocol *string `json:"BackendProtocol,omitempty"` + // The port on which the load balancer is listening (between `1` and `65535`, both included). + LoadBalancerPort int32 `json:"LoadBalancerPort"` + // The routing protocol (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). + LoadBalancerProtocol string `json:"LoadBalancerProtocol"` + // The ID of the server certificate. + ServerCertificateId *string `json:"ServerCertificateId,omitempty"` +} + +// NewListenerForCreation instantiates a new ListenerForCreation object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListenerForCreation(backendPort int32, loadBalancerPort int32, loadBalancerProtocol string, ) *ListenerForCreation { + this := ListenerForCreation{} + this.BackendPort = backendPort + this.LoadBalancerPort = loadBalancerPort + this.LoadBalancerProtocol = loadBalancerProtocol + return &this +} + +// NewListenerForCreationWithDefaults instantiates a new ListenerForCreation object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListenerForCreationWithDefaults() *ListenerForCreation { + this := ListenerForCreation{} + return &this +} + +// GetBackendPort returns the BackendPort field value +func (o *ListenerForCreation) GetBackendPort() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.BackendPort +} + +// GetBackendPortOk returns a tuple with the BackendPort field value +// and a boolean to check if the value has been set. +func (o *ListenerForCreation) GetBackendPortOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.BackendPort, true +} + +// SetBackendPort sets field value +func (o *ListenerForCreation) SetBackendPort(v int32) { + o.BackendPort = v +} + +// GetBackendProtocol returns the BackendProtocol field value if set, zero value otherwise. +func (o *ListenerForCreation) GetBackendProtocol() string { + if o == nil || o.BackendProtocol == nil { + var ret string + return ret + } + return *o.BackendProtocol +} + +// GetBackendProtocolOk returns a tuple with the BackendProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerForCreation) GetBackendProtocolOk() (*string, bool) { + if o == nil || o.BackendProtocol == nil { + return nil, false + } + return o.BackendProtocol, true +} + +// HasBackendProtocol returns a boolean if a field has been set. +func (o *ListenerForCreation) HasBackendProtocol() bool { + if o != nil && o.BackendProtocol != nil { + return true + } + + return false +} + +// SetBackendProtocol gets a reference to the given string and assigns it to the BackendProtocol field. +func (o *ListenerForCreation) SetBackendProtocol(v string) { + o.BackendProtocol = &v +} + +// GetLoadBalancerPort returns the LoadBalancerPort field value +func (o *ListenerForCreation) GetLoadBalancerPort() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.LoadBalancerPort +} + +// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value +// and a boolean to check if the value has been set. +func (o *ListenerForCreation) GetLoadBalancerPortOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerPort, true +} + +// SetLoadBalancerPort sets field value +func (o *ListenerForCreation) SetLoadBalancerPort(v int32) { + o.LoadBalancerPort = v +} + +// GetLoadBalancerProtocol returns the LoadBalancerProtocol field value +func (o *ListenerForCreation) GetLoadBalancerProtocol() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerProtocol +} + +// GetLoadBalancerProtocolOk returns a tuple with the LoadBalancerProtocol field value +// and a boolean to check if the value has been set. +func (o *ListenerForCreation) GetLoadBalancerProtocolOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerProtocol, true +} + +// SetLoadBalancerProtocol sets field value +func (o *ListenerForCreation) SetLoadBalancerProtocol(v string) { + o.LoadBalancerProtocol = v +} + +// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. +func (o *ListenerForCreation) GetServerCertificateId() string { + if o == nil || o.ServerCertificateId == nil { + var ret string + return ret + } + return *o.ServerCertificateId +} + +// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerForCreation) GetServerCertificateIdOk() (*string, bool) { + if o == nil || o.ServerCertificateId == nil { + return nil, false + } + return o.ServerCertificateId, true +} + +// HasServerCertificateId returns a boolean if a field has been set. +func (o *ListenerForCreation) HasServerCertificateId() bool { + if o != nil && o.ServerCertificateId != nil { + return true + } + + return false +} + +// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. +func (o *ListenerForCreation) SetServerCertificateId(v string) { + o.ServerCertificateId = &v +} + +func (o ListenerForCreation) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["BackendPort"] = o.BackendPort + } + if o.BackendProtocol != nil { + toSerialize["BackendProtocol"] = o.BackendProtocol + } + if true { + toSerialize["LoadBalancerPort"] = o.LoadBalancerPort + } + if true { + toSerialize["LoadBalancerProtocol"] = o.LoadBalancerProtocol + } + if o.ServerCertificateId != nil { + toSerialize["ServerCertificateId"] = o.ServerCertificateId + } + return json.Marshal(toSerialize) +} + +type NullableListenerForCreation struct { + value *ListenerForCreation + isSet bool +} + +func (v NullableListenerForCreation) Get() *ListenerForCreation { + return v.value +} + +func (v *NullableListenerForCreation) Set(val *ListenerForCreation) { + v.value = val + v.isSet = true +} + +func (v NullableListenerForCreation) IsSet() bool { + return v.isSet +} + +func (v *NullableListenerForCreation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListenerForCreation(val *ListenerForCreation) *NullableListenerForCreation { + return &NullableListenerForCreation{value: val, isSet: true} +} + +func (v NullableListenerForCreation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListenerForCreation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go new file mode 100644 index 000000000..fb4f42245 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ListenerRule Information about the listener rule. +type ListenerRule struct { + // The type of action for the rule (always `forward`). + Action *string `json:"Action,omitempty"` + // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + HostNamePattern *string `json:"HostNamePattern,omitempty"` + // The ID of the listener. + ListenerId *int32 `json:"ListenerId,omitempty"` + // The ID of the listener rule. + ListenerRuleId *int32 `json:"ListenerRuleId,omitempty"` + // A human-readable name for the listener rule. + ListenerRuleName *string `json:"ListenerRuleName,omitempty"` + // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. + PathPattern *string `json:"PathPattern,omitempty"` + // The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. + Priority *int32 `json:"Priority,omitempty"` + // The IDs of the backend VMs. + VmIds *[]string `json:"VmIds,omitempty"` +} + +// NewListenerRule instantiates a new ListenerRule object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListenerRule() *ListenerRule { + this := ListenerRule{} + return &this +} + +// NewListenerRuleWithDefaults instantiates a new ListenerRule object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListenerRuleWithDefaults() *ListenerRule { + this := ListenerRule{} + return &this +} + +// GetAction returns the Action field value if set, zero value otherwise. +func (o *ListenerRule) GetAction() string { + if o == nil || o.Action == nil { + var ret string + return ret + } + return *o.Action +} + +// GetActionOk returns a tuple with the Action field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetActionOk() (*string, bool) { + if o == nil || o.Action == nil { + return nil, false + } + return o.Action, true +} + +// HasAction returns a boolean if a field has been set. +func (o *ListenerRule) HasAction() bool { + if o != nil && o.Action != nil { + return true + } + + return false +} + +// SetAction gets a reference to the given string and assigns it to the Action field. +func (o *ListenerRule) SetAction(v string) { + o.Action = &v +} + +// GetHostNamePattern returns the HostNamePattern field value if set, zero value otherwise. +func (o *ListenerRule) GetHostNamePattern() string { + if o == nil || o.HostNamePattern == nil { + var ret string + return ret + } + return *o.HostNamePattern +} + +// GetHostNamePatternOk returns a tuple with the HostNamePattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetHostNamePatternOk() (*string, bool) { + if o == nil || o.HostNamePattern == nil { + return nil, false + } + return o.HostNamePattern, true +} + +// HasHostNamePattern returns a boolean if a field has been set. +func (o *ListenerRule) HasHostNamePattern() bool { + if o != nil && o.HostNamePattern != nil { + return true + } + + return false +} + +// SetHostNamePattern gets a reference to the given string and assigns it to the HostNamePattern field. +func (o *ListenerRule) SetHostNamePattern(v string) { + o.HostNamePattern = &v +} + +// GetListenerId returns the ListenerId field value if set, zero value otherwise. +func (o *ListenerRule) GetListenerId() int32 { + if o == nil || o.ListenerId == nil { + var ret int32 + return ret + } + return *o.ListenerId +} + +// GetListenerIdOk returns a tuple with the ListenerId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetListenerIdOk() (*int32, bool) { + if o == nil || o.ListenerId == nil { + return nil, false + } + return o.ListenerId, true +} + +// HasListenerId returns a boolean if a field has been set. +func (o *ListenerRule) HasListenerId() bool { + if o != nil && o.ListenerId != nil { + return true + } + + return false +} + +// SetListenerId gets a reference to the given int32 and assigns it to the ListenerId field. +func (o *ListenerRule) SetListenerId(v int32) { + o.ListenerId = &v +} + +// GetListenerRuleId returns the ListenerRuleId field value if set, zero value otherwise. +func (o *ListenerRule) GetListenerRuleId() int32 { + if o == nil || o.ListenerRuleId == nil { + var ret int32 + return ret + } + return *o.ListenerRuleId +} + +// GetListenerRuleIdOk returns a tuple with the ListenerRuleId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetListenerRuleIdOk() (*int32, bool) { + if o == nil || o.ListenerRuleId == nil { + return nil, false + } + return o.ListenerRuleId, true +} + +// HasListenerRuleId returns a boolean if a field has been set. +func (o *ListenerRule) HasListenerRuleId() bool { + if o != nil && o.ListenerRuleId != nil { + return true + } + + return false +} + +// SetListenerRuleId gets a reference to the given int32 and assigns it to the ListenerRuleId field. +func (o *ListenerRule) SetListenerRuleId(v int32) { + o.ListenerRuleId = &v +} + +// GetListenerRuleName returns the ListenerRuleName field value if set, zero value otherwise. +func (o *ListenerRule) GetListenerRuleName() string { + if o == nil || o.ListenerRuleName == nil { + var ret string + return ret + } + return *o.ListenerRuleName +} + +// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetListenerRuleNameOk() (*string, bool) { + if o == nil || o.ListenerRuleName == nil { + return nil, false + } + return o.ListenerRuleName, true +} + +// HasListenerRuleName returns a boolean if a field has been set. +func (o *ListenerRule) HasListenerRuleName() bool { + if o != nil && o.ListenerRuleName != nil { + return true + } + + return false +} + +// SetListenerRuleName gets a reference to the given string and assigns it to the ListenerRuleName field. +func (o *ListenerRule) SetListenerRuleName(v string) { + o.ListenerRuleName = &v +} + +// GetPathPattern returns the PathPattern field value if set, zero value otherwise. +func (o *ListenerRule) GetPathPattern() string { + if o == nil || o.PathPattern == nil { + var ret string + return ret + } + return *o.PathPattern +} + +// GetPathPatternOk returns a tuple with the PathPattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetPathPatternOk() (*string, bool) { + if o == nil || o.PathPattern == nil { + return nil, false + } + return o.PathPattern, true +} + +// HasPathPattern returns a boolean if a field has been set. +func (o *ListenerRule) HasPathPattern() bool { + if o != nil && o.PathPattern != nil { + return true + } + + return false +} + +// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. +func (o *ListenerRule) SetPathPattern(v string) { + o.PathPattern = &v +} + +// GetPriority returns the Priority field value if set, zero value otherwise. +func (o *ListenerRule) GetPriority() int32 { + if o == nil || o.Priority == nil { + var ret int32 + return ret + } + return *o.Priority +} + +// GetPriorityOk returns a tuple with the Priority field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetPriorityOk() (*int32, bool) { + if o == nil || o.Priority == nil { + return nil, false + } + return o.Priority, true +} + +// HasPriority returns a boolean if a field has been set. +func (o *ListenerRule) HasPriority() bool { + if o != nil && o.Priority != nil { + return true + } + + return false +} + +// SetPriority gets a reference to the given int32 and assigns it to the Priority field. +func (o *ListenerRule) SetPriority(v int32) { + o.Priority = &v +} + +// GetVmIds returns the VmIds field value if set, zero value otherwise. +func (o *ListenerRule) GetVmIds() []string { + if o == nil || o.VmIds == nil { + var ret []string + return ret + } + return *o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRule) GetVmIdsOk() (*[]string, bool) { + if o == nil || o.VmIds == nil { + return nil, false + } + return o.VmIds, true +} + +// HasVmIds returns a boolean if a field has been set. +func (o *ListenerRule) HasVmIds() bool { + if o != nil && o.VmIds != nil { + return true + } + + return false +} + +// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. +func (o *ListenerRule) SetVmIds(v []string) { + o.VmIds = &v +} + +func (o ListenerRule) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Action != nil { + toSerialize["Action"] = o.Action + } + if o.HostNamePattern != nil { + toSerialize["HostNamePattern"] = o.HostNamePattern + } + if o.ListenerId != nil { + toSerialize["ListenerId"] = o.ListenerId + } + if o.ListenerRuleId != nil { + toSerialize["ListenerRuleId"] = o.ListenerRuleId + } + if o.ListenerRuleName != nil { + toSerialize["ListenerRuleName"] = o.ListenerRuleName + } + if o.PathPattern != nil { + toSerialize["PathPattern"] = o.PathPattern + } + if o.Priority != nil { + toSerialize["Priority"] = o.Priority + } + if o.VmIds != nil { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableListenerRule struct { + value *ListenerRule + isSet bool +} + +func (v NullableListenerRule) Get() *ListenerRule { + return v.value +} + +func (v *NullableListenerRule) Set(val *ListenerRule) { + v.value = val + v.isSet = true +} + +func (v NullableListenerRule) IsSet() bool { + return v.isSet +} + +func (v *NullableListenerRule) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListenerRule(val *ListenerRule) *NullableListenerRule { + return &NullableListenerRule{value: val, isSet: true} +} + +func (v NullableListenerRule) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListenerRule) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go new file mode 100644 index 000000000..b688826e0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go @@ -0,0 +1,295 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ListenerRuleForCreation Information about the listener rule. +type ListenerRuleForCreation struct { + // The type of action for the rule (always `forward`). + Action *string `json:"Action,omitempty"` + // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + HostNamePattern *string `json:"HostNamePattern,omitempty"` + // The ID of the listener. + ListenerRuleId *string `json:"ListenerRuleId,omitempty"` + // A human-readable name for the listener rule. + ListenerRuleName *string `json:"ListenerRuleName,omitempty"` + // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. + PathPattern *string `json:"PathPattern,omitempty"` + // The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. + Priority int32 `json:"Priority"` +} + +// NewListenerRuleForCreation instantiates a new ListenerRuleForCreation object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListenerRuleForCreation(priority int32, ) *ListenerRuleForCreation { + this := ListenerRuleForCreation{} + this.Priority = priority + return &this +} + +// NewListenerRuleForCreationWithDefaults instantiates a new ListenerRuleForCreation object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListenerRuleForCreationWithDefaults() *ListenerRuleForCreation { + this := ListenerRuleForCreation{} + return &this +} + +// GetAction returns the Action field value if set, zero value otherwise. +func (o *ListenerRuleForCreation) GetAction() string { + if o == nil || o.Action == nil { + var ret string + return ret + } + return *o.Action +} + +// GetActionOk returns a tuple with the Action field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetActionOk() (*string, bool) { + if o == nil || o.Action == nil { + return nil, false + } + return o.Action, true +} + +// HasAction returns a boolean if a field has been set. +func (o *ListenerRuleForCreation) HasAction() bool { + if o != nil && o.Action != nil { + return true + } + + return false +} + +// SetAction gets a reference to the given string and assigns it to the Action field. +func (o *ListenerRuleForCreation) SetAction(v string) { + o.Action = &v +} + +// GetHostNamePattern returns the HostNamePattern field value if set, zero value otherwise. +func (o *ListenerRuleForCreation) GetHostNamePattern() string { + if o == nil || o.HostNamePattern == nil { + var ret string + return ret + } + return *o.HostNamePattern +} + +// GetHostNamePatternOk returns a tuple with the HostNamePattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetHostNamePatternOk() (*string, bool) { + if o == nil || o.HostNamePattern == nil { + return nil, false + } + return o.HostNamePattern, true +} + +// HasHostNamePattern returns a boolean if a field has been set. +func (o *ListenerRuleForCreation) HasHostNamePattern() bool { + if o != nil && o.HostNamePattern != nil { + return true + } + + return false +} + +// SetHostNamePattern gets a reference to the given string and assigns it to the HostNamePattern field. +func (o *ListenerRuleForCreation) SetHostNamePattern(v string) { + o.HostNamePattern = &v +} + +// GetListenerRuleId returns the ListenerRuleId field value if set, zero value otherwise. +func (o *ListenerRuleForCreation) GetListenerRuleId() string { + if o == nil || o.ListenerRuleId == nil { + var ret string + return ret + } + return *o.ListenerRuleId +} + +// GetListenerRuleIdOk returns a tuple with the ListenerRuleId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetListenerRuleIdOk() (*string, bool) { + if o == nil || o.ListenerRuleId == nil { + return nil, false + } + return o.ListenerRuleId, true +} + +// HasListenerRuleId returns a boolean if a field has been set. +func (o *ListenerRuleForCreation) HasListenerRuleId() bool { + if o != nil && o.ListenerRuleId != nil { + return true + } + + return false +} + +// SetListenerRuleId gets a reference to the given string and assigns it to the ListenerRuleId field. +func (o *ListenerRuleForCreation) SetListenerRuleId(v string) { + o.ListenerRuleId = &v +} + +// GetListenerRuleName returns the ListenerRuleName field value if set, zero value otherwise. +func (o *ListenerRuleForCreation) GetListenerRuleName() string { + if o == nil || o.ListenerRuleName == nil { + var ret string + return ret + } + return *o.ListenerRuleName +} + +// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetListenerRuleNameOk() (*string, bool) { + if o == nil || o.ListenerRuleName == nil { + return nil, false + } + return o.ListenerRuleName, true +} + +// HasListenerRuleName returns a boolean if a field has been set. +func (o *ListenerRuleForCreation) HasListenerRuleName() bool { + if o != nil && o.ListenerRuleName != nil { + return true + } + + return false +} + +// SetListenerRuleName gets a reference to the given string and assigns it to the ListenerRuleName field. +func (o *ListenerRuleForCreation) SetListenerRuleName(v string) { + o.ListenerRuleName = &v +} + +// GetPathPattern returns the PathPattern field value if set, zero value otherwise. +func (o *ListenerRuleForCreation) GetPathPattern() string { + if o == nil || o.PathPattern == nil { + var ret string + return ret + } + return *o.PathPattern +} + +// GetPathPatternOk returns a tuple with the PathPattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetPathPatternOk() (*string, bool) { + if o == nil || o.PathPattern == nil { + return nil, false + } + return o.PathPattern, true +} + +// HasPathPattern returns a boolean if a field has been set. +func (o *ListenerRuleForCreation) HasPathPattern() bool { + if o != nil && o.PathPattern != nil { + return true + } + + return false +} + +// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. +func (o *ListenerRuleForCreation) SetPathPattern(v string) { + o.PathPattern = &v +} + +// GetPriority returns the Priority field value +func (o *ListenerRuleForCreation) GetPriority() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Priority +} + +// GetPriorityOk returns a tuple with the Priority field value +// and a boolean to check if the value has been set. +func (o *ListenerRuleForCreation) GetPriorityOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Priority, true +} + +// SetPriority sets field value +func (o *ListenerRuleForCreation) SetPriority(v int32) { + o.Priority = v +} + +func (o ListenerRuleForCreation) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Action != nil { + toSerialize["Action"] = o.Action + } + if o.HostNamePattern != nil { + toSerialize["HostNamePattern"] = o.HostNamePattern + } + if o.ListenerRuleId != nil { + toSerialize["ListenerRuleId"] = o.ListenerRuleId + } + if o.ListenerRuleName != nil { + toSerialize["ListenerRuleName"] = o.ListenerRuleName + } + if o.PathPattern != nil { + toSerialize["PathPattern"] = o.PathPattern + } + if true { + toSerialize["Priority"] = o.Priority + } + return json.Marshal(toSerialize) +} + +type NullableListenerRuleForCreation struct { + value *ListenerRuleForCreation + isSet bool +} + +func (v NullableListenerRuleForCreation) Get() *ListenerRuleForCreation { + return v.value +} + +func (v *NullableListenerRuleForCreation) Set(val *ListenerRuleForCreation) { + v.value = val + v.isSet = true +} + +func (v NullableListenerRuleForCreation) IsSet() bool { + return v.isSet +} + +func (v *NullableListenerRuleForCreation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListenerRuleForCreation(val *ListenerRuleForCreation) *NullableListenerRuleForCreation { + return &NullableListenerRuleForCreation{value: val, isSet: true} +} + +func (v NullableListenerRuleForCreation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListenerRuleForCreation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go new file mode 100644 index 000000000..269bd2d43 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go @@ -0,0 +1,632 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LoadBalancer Information about the load balancer. +type LoadBalancer struct { + AccessLog *AccessLog `json:"AccessLog,omitempty"` + // The stickiness policies defined for the load balancer. + ApplicationStickyCookiePolicies *[]ApplicationStickyCookiePolicy `json:"ApplicationStickyCookiePolicies,omitempty"` + // One or more IDs of back-end VMs for the load balancer. + BackendVmIds *[]string `json:"BackendVmIds,omitempty"` + // The DNS name of the load balancer. + DnsName *string `json:"DnsName,omitempty"` + HealthCheck *HealthCheck `json:"HealthCheck,omitempty"` + // The listeners for the load balancer. + Listeners *[]Listener `json:"Listeners,omitempty"` + // The name of the load balancer. + LoadBalancerName *string `json:"LoadBalancerName,omitempty"` + // The policies defined for the load balancer. + LoadBalancerStickyCookiePolicies *[]LoadBalancerStickyCookiePolicy `json:"LoadBalancerStickyCookiePolicies,omitempty"` + // The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + LoadBalancerType *string `json:"LoadBalancerType,omitempty"` + // The ID of the Net for the load balancer. + NetId *string `json:"NetId,omitempty"` + // One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + SecurityGroups *[]string `json:"SecurityGroups,omitempty"` + SourceSecurityGroup *SourceSecurityGroup `json:"SourceSecurityGroup,omitempty"` + // The IDs of the Subnets for the load balancer. + Subnets *[]string `json:"Subnets,omitempty"` + // One or more names of Subregions for the load balancer. + SubregionNames *[]string `json:"SubregionNames,omitempty"` + // One or more tags associated with the load balancer. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewLoadBalancer instantiates a new LoadBalancer object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLoadBalancer() *LoadBalancer { + this := LoadBalancer{} + return &this +} + +// NewLoadBalancerWithDefaults instantiates a new LoadBalancer object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLoadBalancerWithDefaults() *LoadBalancer { + this := LoadBalancer{} + return &this +} + +// GetAccessLog returns the AccessLog field value if set, zero value otherwise. +func (o *LoadBalancer) GetAccessLog() AccessLog { + if o == nil || o.AccessLog == nil { + var ret AccessLog + return ret + } + return *o.AccessLog +} + +// GetAccessLogOk returns a tuple with the AccessLog field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetAccessLogOk() (*AccessLog, bool) { + if o == nil || o.AccessLog == nil { + return nil, false + } + return o.AccessLog, true +} + +// HasAccessLog returns a boolean if a field has been set. +func (o *LoadBalancer) HasAccessLog() bool { + if o != nil && o.AccessLog != nil { + return true + } + + return false +} + +// SetAccessLog gets a reference to the given AccessLog and assigns it to the AccessLog field. +func (o *LoadBalancer) SetAccessLog(v AccessLog) { + o.AccessLog = &v +} + +// GetApplicationStickyCookiePolicies returns the ApplicationStickyCookiePolicies field value if set, zero value otherwise. +func (o *LoadBalancer) GetApplicationStickyCookiePolicies() []ApplicationStickyCookiePolicy { + if o == nil || o.ApplicationStickyCookiePolicies == nil { + var ret []ApplicationStickyCookiePolicy + return ret + } + return *o.ApplicationStickyCookiePolicies +} + +// GetApplicationStickyCookiePoliciesOk returns a tuple with the ApplicationStickyCookiePolicies field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetApplicationStickyCookiePoliciesOk() (*[]ApplicationStickyCookiePolicy, bool) { + if o == nil || o.ApplicationStickyCookiePolicies == nil { + return nil, false + } + return o.ApplicationStickyCookiePolicies, true +} + +// HasApplicationStickyCookiePolicies returns a boolean if a field has been set. +func (o *LoadBalancer) HasApplicationStickyCookiePolicies() bool { + if o != nil && o.ApplicationStickyCookiePolicies != nil { + return true + } + + return false +} + +// SetApplicationStickyCookiePolicies gets a reference to the given []ApplicationStickyCookiePolicy and assigns it to the ApplicationStickyCookiePolicies field. +func (o *LoadBalancer) SetApplicationStickyCookiePolicies(v []ApplicationStickyCookiePolicy) { + o.ApplicationStickyCookiePolicies = &v +} + +// GetBackendVmIds returns the BackendVmIds field value if set, zero value otherwise. +func (o *LoadBalancer) GetBackendVmIds() []string { + if o == nil || o.BackendVmIds == nil { + var ret []string + return ret + } + return *o.BackendVmIds +} + +// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetBackendVmIdsOk() (*[]string, bool) { + if o == nil || o.BackendVmIds == nil { + return nil, false + } + return o.BackendVmIds, true +} + +// HasBackendVmIds returns a boolean if a field has been set. +func (o *LoadBalancer) HasBackendVmIds() bool { + if o != nil && o.BackendVmIds != nil { + return true + } + + return false +} + +// SetBackendVmIds gets a reference to the given []string and assigns it to the BackendVmIds field. +func (o *LoadBalancer) SetBackendVmIds(v []string) { + o.BackendVmIds = &v +} + +// GetDnsName returns the DnsName field value if set, zero value otherwise. +func (o *LoadBalancer) GetDnsName() string { + if o == nil || o.DnsName == nil { + var ret string + return ret + } + return *o.DnsName +} + +// GetDnsNameOk returns a tuple with the DnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetDnsNameOk() (*string, bool) { + if o == nil || o.DnsName == nil { + return nil, false + } + return o.DnsName, true +} + +// HasDnsName returns a boolean if a field has been set. +func (o *LoadBalancer) HasDnsName() bool { + if o != nil && o.DnsName != nil { + return true + } + + return false +} + +// SetDnsName gets a reference to the given string and assigns it to the DnsName field. +func (o *LoadBalancer) SetDnsName(v string) { + o.DnsName = &v +} + +// GetHealthCheck returns the HealthCheck field value if set, zero value otherwise. +func (o *LoadBalancer) GetHealthCheck() HealthCheck { + if o == nil || o.HealthCheck == nil { + var ret HealthCheck + return ret + } + return *o.HealthCheck +} + +// GetHealthCheckOk returns a tuple with the HealthCheck field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetHealthCheckOk() (*HealthCheck, bool) { + if o == nil || o.HealthCheck == nil { + return nil, false + } + return o.HealthCheck, true +} + +// HasHealthCheck returns a boolean if a field has been set. +func (o *LoadBalancer) HasHealthCheck() bool { + if o != nil && o.HealthCheck != nil { + return true + } + + return false +} + +// SetHealthCheck gets a reference to the given HealthCheck and assigns it to the HealthCheck field. +func (o *LoadBalancer) SetHealthCheck(v HealthCheck) { + o.HealthCheck = &v +} + +// GetListeners returns the Listeners field value if set, zero value otherwise. +func (o *LoadBalancer) GetListeners() []Listener { + if o == nil || o.Listeners == nil { + var ret []Listener + return ret + } + return *o.Listeners +} + +// GetListenersOk returns a tuple with the Listeners field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetListenersOk() (*[]Listener, bool) { + if o == nil || o.Listeners == nil { + return nil, false + } + return o.Listeners, true +} + +// HasListeners returns a boolean if a field has been set. +func (o *LoadBalancer) HasListeners() bool { + if o != nil && o.Listeners != nil { + return true + } + + return false +} + +// SetListeners gets a reference to the given []Listener and assigns it to the Listeners field. +func (o *LoadBalancer) SetListeners(v []Listener) { + o.Listeners = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value if set, zero value otherwise. +func (o *LoadBalancer) GetLoadBalancerName() string { + if o == nil || o.LoadBalancerName == nil { + var ret string + return ret + } + return *o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetLoadBalancerNameOk() (*string, bool) { + if o == nil || o.LoadBalancerName == nil { + return nil, false + } + return o.LoadBalancerName, true +} + +// HasLoadBalancerName returns a boolean if a field has been set. +func (o *LoadBalancer) HasLoadBalancerName() bool { + if o != nil && o.LoadBalancerName != nil { + return true + } + + return false +} + +// SetLoadBalancerName gets a reference to the given string and assigns it to the LoadBalancerName field. +func (o *LoadBalancer) SetLoadBalancerName(v string) { + o.LoadBalancerName = &v +} + +// GetLoadBalancerStickyCookiePolicies returns the LoadBalancerStickyCookiePolicies field value if set, zero value otherwise. +func (o *LoadBalancer) GetLoadBalancerStickyCookiePolicies() []LoadBalancerStickyCookiePolicy { + if o == nil || o.LoadBalancerStickyCookiePolicies == nil { + var ret []LoadBalancerStickyCookiePolicy + return ret + } + return *o.LoadBalancerStickyCookiePolicies +} + +// GetLoadBalancerStickyCookiePoliciesOk returns a tuple with the LoadBalancerStickyCookiePolicies field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetLoadBalancerStickyCookiePoliciesOk() (*[]LoadBalancerStickyCookiePolicy, bool) { + if o == nil || o.LoadBalancerStickyCookiePolicies == nil { + return nil, false + } + return o.LoadBalancerStickyCookiePolicies, true +} + +// HasLoadBalancerStickyCookiePolicies returns a boolean if a field has been set. +func (o *LoadBalancer) HasLoadBalancerStickyCookiePolicies() bool { + if o != nil && o.LoadBalancerStickyCookiePolicies != nil { + return true + } + + return false +} + +// SetLoadBalancerStickyCookiePolicies gets a reference to the given []LoadBalancerStickyCookiePolicy and assigns it to the LoadBalancerStickyCookiePolicies field. +func (o *LoadBalancer) SetLoadBalancerStickyCookiePolicies(v []LoadBalancerStickyCookiePolicy) { + o.LoadBalancerStickyCookiePolicies = &v +} + +// GetLoadBalancerType returns the LoadBalancerType field value if set, zero value otherwise. +func (o *LoadBalancer) GetLoadBalancerType() string { + if o == nil || o.LoadBalancerType == nil { + var ret string + return ret + } + return *o.LoadBalancerType +} + +// GetLoadBalancerTypeOk returns a tuple with the LoadBalancerType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetLoadBalancerTypeOk() (*string, bool) { + if o == nil || o.LoadBalancerType == nil { + return nil, false + } + return o.LoadBalancerType, true +} + +// HasLoadBalancerType returns a boolean if a field has been set. +func (o *LoadBalancer) HasLoadBalancerType() bool { + if o != nil && o.LoadBalancerType != nil { + return true + } + + return false +} + +// SetLoadBalancerType gets a reference to the given string and assigns it to the LoadBalancerType field. +func (o *LoadBalancer) SetLoadBalancerType(v string) { + o.LoadBalancerType = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *LoadBalancer) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *LoadBalancer) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *LoadBalancer) SetNetId(v string) { + o.NetId = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *LoadBalancer) GetSecurityGroups() []string { + if o == nil || o.SecurityGroups == nil { + var ret []string + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetSecurityGroupsOk() (*[]string, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *LoadBalancer) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. +func (o *LoadBalancer) SetSecurityGroups(v []string) { + o.SecurityGroups = &v +} + +// GetSourceSecurityGroup returns the SourceSecurityGroup field value if set, zero value otherwise. +func (o *LoadBalancer) GetSourceSecurityGroup() SourceSecurityGroup { + if o == nil || o.SourceSecurityGroup == nil { + var ret SourceSecurityGroup + return ret + } + return *o.SourceSecurityGroup +} + +// GetSourceSecurityGroupOk returns a tuple with the SourceSecurityGroup field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetSourceSecurityGroupOk() (*SourceSecurityGroup, bool) { + if o == nil || o.SourceSecurityGroup == nil { + return nil, false + } + return o.SourceSecurityGroup, true +} + +// HasSourceSecurityGroup returns a boolean if a field has been set. +func (o *LoadBalancer) HasSourceSecurityGroup() bool { + if o != nil && o.SourceSecurityGroup != nil { + return true + } + + return false +} + +// SetSourceSecurityGroup gets a reference to the given SourceSecurityGroup and assigns it to the SourceSecurityGroup field. +func (o *LoadBalancer) SetSourceSecurityGroup(v SourceSecurityGroup) { + o.SourceSecurityGroup = &v +} + +// GetSubnets returns the Subnets field value if set, zero value otherwise. +func (o *LoadBalancer) GetSubnets() []string { + if o == nil || o.Subnets == nil { + var ret []string + return ret + } + return *o.Subnets +} + +// GetSubnetsOk returns a tuple with the Subnets field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetSubnetsOk() (*[]string, bool) { + if o == nil || o.Subnets == nil { + return nil, false + } + return o.Subnets, true +} + +// HasSubnets returns a boolean if a field has been set. +func (o *LoadBalancer) HasSubnets() bool { + if o != nil && o.Subnets != nil { + return true + } + + return false +} + +// SetSubnets gets a reference to the given []string and assigns it to the Subnets field. +func (o *LoadBalancer) SetSubnets(v []string) { + o.Subnets = &v +} + +// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. +func (o *LoadBalancer) GetSubregionNames() []string { + if o == nil || o.SubregionNames == nil { + var ret []string + return ret + } + return *o.SubregionNames +} + +// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetSubregionNamesOk() (*[]string, bool) { + if o == nil || o.SubregionNames == nil { + return nil, false + } + return o.SubregionNames, true +} + +// HasSubregionNames returns a boolean if a field has been set. +func (o *LoadBalancer) HasSubregionNames() bool { + if o != nil && o.SubregionNames != nil { + return true + } + + return false +} + +// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. +func (o *LoadBalancer) SetSubregionNames(v []string) { + o.SubregionNames = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *LoadBalancer) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancer) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *LoadBalancer) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *LoadBalancer) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o LoadBalancer) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessLog != nil { + toSerialize["AccessLog"] = o.AccessLog + } + if o.ApplicationStickyCookiePolicies != nil { + toSerialize["ApplicationStickyCookiePolicies"] = o.ApplicationStickyCookiePolicies + } + if o.BackendVmIds != nil { + toSerialize["BackendVmIds"] = o.BackendVmIds + } + if o.DnsName != nil { + toSerialize["DnsName"] = o.DnsName + } + if o.HealthCheck != nil { + toSerialize["HealthCheck"] = o.HealthCheck + } + if o.Listeners != nil { + toSerialize["Listeners"] = o.Listeners + } + if o.LoadBalancerName != nil { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if o.LoadBalancerStickyCookiePolicies != nil { + toSerialize["LoadBalancerStickyCookiePolicies"] = o.LoadBalancerStickyCookiePolicies + } + if o.LoadBalancerType != nil { + toSerialize["LoadBalancerType"] = o.LoadBalancerType + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.SourceSecurityGroup != nil { + toSerialize["SourceSecurityGroup"] = o.SourceSecurityGroup + } + if o.Subnets != nil { + toSerialize["Subnets"] = o.Subnets + } + if o.SubregionNames != nil { + toSerialize["SubregionNames"] = o.SubregionNames + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableLoadBalancer struct { + value *LoadBalancer + isSet bool +} + +func (v NullableLoadBalancer) Get() *LoadBalancer { + return v.value +} + +func (v *NullableLoadBalancer) Set(val *LoadBalancer) { + v.value = val + v.isSet = true +} + +func (v NullableLoadBalancer) IsSet() bool { + return v.isSet +} + +func (v *NullableLoadBalancer) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLoadBalancer(val *LoadBalancer) *NullableLoadBalancer { + return &NullableLoadBalancer{value: val, isSet: true} +} + +func (v NullableLoadBalancer) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLoadBalancer) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go new file mode 100644 index 000000000..2a809b33d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go @@ -0,0 +1,140 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LoadBalancerLight Information about the load balancer. +type LoadBalancerLight struct { + // The name of the load balancer to which the listener is attached. + LoadBalancerName string `json:"LoadBalancerName"` + // The port of load balancer on which the load balancer is listening (between `1` and `65535` both included). + LoadBalancerPort int32 `json:"LoadBalancerPort"` +} + +// NewLoadBalancerLight instantiates a new LoadBalancerLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLoadBalancerLight(loadBalancerName string, loadBalancerPort int32, ) *LoadBalancerLight { + this := LoadBalancerLight{} + this.LoadBalancerName = loadBalancerName + this.LoadBalancerPort = loadBalancerPort + return &this +} + +// NewLoadBalancerLightWithDefaults instantiates a new LoadBalancerLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLoadBalancerLightWithDefaults() *LoadBalancerLight { + this := LoadBalancerLight{} + return &this +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *LoadBalancerLight) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *LoadBalancerLight) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *LoadBalancerLight) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetLoadBalancerPort returns the LoadBalancerPort field value +func (o *LoadBalancerLight) GetLoadBalancerPort() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.LoadBalancerPort +} + +// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value +// and a boolean to check if the value has been set. +func (o *LoadBalancerLight) GetLoadBalancerPortOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerPort, true +} + +// SetLoadBalancerPort sets field value +func (o *LoadBalancerLight) SetLoadBalancerPort(v int32) { + o.LoadBalancerPort = v +} + +func (o LoadBalancerLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if true { + toSerialize["LoadBalancerPort"] = o.LoadBalancerPort + } + return json.Marshal(toSerialize) +} + +type NullableLoadBalancerLight struct { + value *LoadBalancerLight + isSet bool +} + +func (v NullableLoadBalancerLight) Get() *LoadBalancerLight { + return v.value +} + +func (v *NullableLoadBalancerLight) Set(val *LoadBalancerLight) { + v.value = val + v.isSet = true +} + +func (v NullableLoadBalancerLight) IsSet() bool { + return v.isSet +} + +func (v *NullableLoadBalancerLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLoadBalancerLight(val *LoadBalancerLight) *NullableLoadBalancerLight { + return &NullableLoadBalancerLight{value: val, isSet: true} +} + +func (v NullableLoadBalancerLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLoadBalancerLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go new file mode 100644 index 000000000..7462a6488 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LoadBalancerStickyCookiePolicy Information about the stickiness policy. +type LoadBalancerStickyCookiePolicy struct { + // The name of the stickiness policy. + PolicyName *string `json:"PolicyName,omitempty"` +} + +// NewLoadBalancerStickyCookiePolicy instantiates a new LoadBalancerStickyCookiePolicy object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLoadBalancerStickyCookiePolicy() *LoadBalancerStickyCookiePolicy { + this := LoadBalancerStickyCookiePolicy{} + return &this +} + +// NewLoadBalancerStickyCookiePolicyWithDefaults instantiates a new LoadBalancerStickyCookiePolicy object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLoadBalancerStickyCookiePolicyWithDefaults() *LoadBalancerStickyCookiePolicy { + this := LoadBalancerStickyCookiePolicy{} + return &this +} + +// GetPolicyName returns the PolicyName field value if set, zero value otherwise. +func (o *LoadBalancerStickyCookiePolicy) GetPolicyName() string { + if o == nil || o.PolicyName == nil { + var ret string + return ret + } + return *o.PolicyName +} + +// GetPolicyNameOk returns a tuple with the PolicyName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancerStickyCookiePolicy) GetPolicyNameOk() (*string, bool) { + if o == nil || o.PolicyName == nil { + return nil, false + } + return o.PolicyName, true +} + +// HasPolicyName returns a boolean if a field has been set. +func (o *LoadBalancerStickyCookiePolicy) HasPolicyName() bool { + if o != nil && o.PolicyName != nil { + return true + } + + return false +} + +// SetPolicyName gets a reference to the given string and assigns it to the PolicyName field. +func (o *LoadBalancerStickyCookiePolicy) SetPolicyName(v string) { + o.PolicyName = &v +} + +func (o LoadBalancerStickyCookiePolicy) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PolicyName != nil { + toSerialize["PolicyName"] = o.PolicyName + } + return json.Marshal(toSerialize) +} + +type NullableLoadBalancerStickyCookiePolicy struct { + value *LoadBalancerStickyCookiePolicy + isSet bool +} + +func (v NullableLoadBalancerStickyCookiePolicy) Get() *LoadBalancerStickyCookiePolicy { + return v.value +} + +func (v *NullableLoadBalancerStickyCookiePolicy) Set(val *LoadBalancerStickyCookiePolicy) { + v.value = val + v.isSet = true +} + +func (v NullableLoadBalancerStickyCookiePolicy) IsSet() bool { + return v.isSet +} + +func (v *NullableLoadBalancerStickyCookiePolicy) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLoadBalancerStickyCookiePolicy(val *LoadBalancerStickyCookiePolicy) *NullableLoadBalancerStickyCookiePolicy { + return &NullableLoadBalancerStickyCookiePolicy{value: val, isSet: true} +} + +func (v NullableLoadBalancerStickyCookiePolicy) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLoadBalancerStickyCookiePolicy) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go new file mode 100644 index 000000000..6ccdbc547 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// LoadBalancerTag Information about the load balancer tag. +type LoadBalancerTag struct { + // The key of the tag. + Key *string `json:"Key,omitempty"` + // The name of the load balancer. + LoadBalancerName *string `json:"LoadBalancerName,omitempty"` + // The value of the tag. + Value *string `json:"Value,omitempty"` +} + +// NewLoadBalancerTag instantiates a new LoadBalancerTag object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLoadBalancerTag() *LoadBalancerTag { + this := LoadBalancerTag{} + return &this +} + +// NewLoadBalancerTagWithDefaults instantiates a new LoadBalancerTag object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLoadBalancerTagWithDefaults() *LoadBalancerTag { + this := LoadBalancerTag{} + return &this +} + +// GetKey returns the Key field value if set, zero value otherwise. +func (o *LoadBalancerTag) GetKey() string { + if o == nil || o.Key == nil { + var ret string + return ret + } + return *o.Key +} + +// GetKeyOk returns a tuple with the Key field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancerTag) GetKeyOk() (*string, bool) { + if o == nil || o.Key == nil { + return nil, false + } + return o.Key, true +} + +// HasKey returns a boolean if a field has been set. +func (o *LoadBalancerTag) HasKey() bool { + if o != nil && o.Key != nil { + return true + } + + return false +} + +// SetKey gets a reference to the given string and assigns it to the Key field. +func (o *LoadBalancerTag) SetKey(v string) { + o.Key = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value if set, zero value otherwise. +func (o *LoadBalancerTag) GetLoadBalancerName() string { + if o == nil || o.LoadBalancerName == nil { + var ret string + return ret + } + return *o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancerTag) GetLoadBalancerNameOk() (*string, bool) { + if o == nil || o.LoadBalancerName == nil { + return nil, false + } + return o.LoadBalancerName, true +} + +// HasLoadBalancerName returns a boolean if a field has been set. +func (o *LoadBalancerTag) HasLoadBalancerName() bool { + if o != nil && o.LoadBalancerName != nil { + return true + } + + return false +} + +// SetLoadBalancerName gets a reference to the given string and assigns it to the LoadBalancerName field. +func (o *LoadBalancerTag) SetLoadBalancerName(v string) { + o.LoadBalancerName = &v +} + +// GetValue returns the Value field value if set, zero value otherwise. +func (o *LoadBalancerTag) GetValue() string { + if o == nil || o.Value == nil { + var ret string + return ret + } + return *o.Value +} + +// GetValueOk returns a tuple with the Value field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *LoadBalancerTag) GetValueOk() (*string, bool) { + if o == nil || o.Value == nil { + return nil, false + } + return o.Value, true +} + +// HasValue returns a boolean if a field has been set. +func (o *LoadBalancerTag) HasValue() bool { + if o != nil && o.Value != nil { + return true + } + + return false +} + +// SetValue gets a reference to the given string and assigns it to the Value field. +func (o *LoadBalancerTag) SetValue(v string) { + o.Value = &v +} + +func (o LoadBalancerTag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Key != nil { + toSerialize["Key"] = o.Key + } + if o.LoadBalancerName != nil { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if o.Value != nil { + toSerialize["Value"] = o.Value + } + return json.Marshal(toSerialize) +} + +type NullableLoadBalancerTag struct { + value *LoadBalancerTag + isSet bool +} + +func (v NullableLoadBalancerTag) Get() *LoadBalancerTag { + return v.value +} + +func (v *NullableLoadBalancerTag) Set(val *LoadBalancerTag) { + v.value = val + v.isSet = true +} + +func (v NullableLoadBalancerTag) IsSet() bool { + return v.isSet +} + +func (v *NullableLoadBalancerTag) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLoadBalancerTag(val *LoadBalancerTag) *NullableLoadBalancerTag { + return &NullableLoadBalancerTag{value: val, isSet: true} +} + +func (v NullableLoadBalancerTag) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLoadBalancerTag) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_location.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_location.go new file mode 100644 index 000000000..e84377fd2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_location.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Location Information about the DirectLink location. +type Location struct { + // The location code, to be set as the `Location` parameter of the *CreateDirectLink* method when creating a DirectLink. + Code *string `json:"Code,omitempty"` + // The name and description of the location, corresponding to a datacenter. + Name *string `json:"Name,omitempty"` +} + +// NewLocation instantiates a new Location object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLocation() *Location { + this := Location{} + return &this +} + +// NewLocationWithDefaults instantiates a new Location object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLocationWithDefaults() *Location { + this := Location{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *Location) GetCode() string { + if o == nil || o.Code == nil { + var ret string + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Location) GetCodeOk() (*string, bool) { + if o == nil || o.Code == nil { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *Location) HasCode() bool { + if o != nil && o.Code != nil { + return true + } + + return false +} + +// SetCode gets a reference to the given string and assigns it to the Code field. +func (o *Location) SetCode(v string) { + o.Code = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *Location) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Location) GetNameOk() (*string, bool) { + if o == nil || o.Name == nil { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Location) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *Location) SetName(v string) { + o.Name = &v +} + +func (o Location) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Code != nil { + toSerialize["Code"] = o.Code + } + if o.Name != nil { + toSerialize["Name"] = o.Name + } + return json.Marshal(toSerialize) +} + +type NullableLocation struct { + value *Location + isSet bool +} + +func (v NullableLocation) Get() *Location { + return v.value +} + +func (v *NullableLocation) Set(val *Location) { + v.value = val + v.isSet = true +} + +func (v NullableLocation) IsSet() bool { + return v.isSet +} + +func (v *NullableLocation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLocation(val *Location) *NullableLocation { + return &NullableLocation{value: val, isSet: true} +} + +func (v NullableLocation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLocation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_log.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_log.go new file mode 100644 index 000000000..67085789e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_log.go @@ -0,0 +1,672 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Log Information about the log. +type Log struct { + // The account ID. + AccountId *string `json:"AccountId,omitempty"` + // The duration of the call (in milliseconds). + CallDuration *int32 `json:"CallDuration,omitempty"` + // The API key used for the query. + QueryAccessKey *string `json:"QueryAccessKey,omitempty"` + // The name of the API service used by the call. + QueryApiName *string `json:"QueryApiName,omitempty"` + // The version of the API service used by the call. + QueryApiVersion *string `json:"QueryApiVersion,omitempty"` + // The name of the call. + QueryCallName *string `json:"QueryCallName,omitempty"` + // The date of the query, in ISO 8601 format. + QueryDate *string `json:"QueryDate,omitempty"` + // The query header raw. + QueryHeaderRaw *string `json:"QueryHeaderRaw,omitempty"` + // The query header size. + QueryHeaderSize *int32 `json:"QueryHeaderSize,omitempty"` + // The IP address used for the query. + QueryIpAddress *string `json:"QueryIpAddress,omitempty"` + // The query payload raw. + QueryPayloadRaw *string `json:"QueryPayloadRaw,omitempty"` + // The query payload size. + QueryPayloadSize *int32 `json:"QueryPayloadSize,omitempty"` + // The user agent used for the HTTP request. + QueryUserAgent *string `json:"QueryUserAgent,omitempty"` + // The ID provided in the response. + RequestId *string `json:"RequestId,omitempty"` + // The size of the response (in bytes). + ResponseSize *int32 `json:"ResponseSize,omitempty"` + // The HTTP code provided in the response. + ResponseStatusCode *int32 `json:"ResponseStatusCode,omitempty"` +} + +// NewLog instantiates a new Log object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewLog() *Log { + this := Log{} + return &this +} + +// NewLogWithDefaults instantiates a new Log object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewLogWithDefaults() *Log { + this := Log{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Log) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Log) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Log) SetAccountId(v string) { + o.AccountId = &v +} + +// GetCallDuration returns the CallDuration field value if set, zero value otherwise. +func (o *Log) GetCallDuration() int32 { + if o == nil || o.CallDuration == nil { + var ret int32 + return ret + } + return *o.CallDuration +} + +// GetCallDurationOk returns a tuple with the CallDuration field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetCallDurationOk() (*int32, bool) { + if o == nil || o.CallDuration == nil { + return nil, false + } + return o.CallDuration, true +} + +// HasCallDuration returns a boolean if a field has been set. +func (o *Log) HasCallDuration() bool { + if o != nil && o.CallDuration != nil { + return true + } + + return false +} + +// SetCallDuration gets a reference to the given int32 and assigns it to the CallDuration field. +func (o *Log) SetCallDuration(v int32) { + o.CallDuration = &v +} + +// GetQueryAccessKey returns the QueryAccessKey field value if set, zero value otherwise. +func (o *Log) GetQueryAccessKey() string { + if o == nil || o.QueryAccessKey == nil { + var ret string + return ret + } + return *o.QueryAccessKey +} + +// GetQueryAccessKeyOk returns a tuple with the QueryAccessKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryAccessKeyOk() (*string, bool) { + if o == nil || o.QueryAccessKey == nil { + return nil, false + } + return o.QueryAccessKey, true +} + +// HasQueryAccessKey returns a boolean if a field has been set. +func (o *Log) HasQueryAccessKey() bool { + if o != nil && o.QueryAccessKey != nil { + return true + } + + return false +} + +// SetQueryAccessKey gets a reference to the given string and assigns it to the QueryAccessKey field. +func (o *Log) SetQueryAccessKey(v string) { + o.QueryAccessKey = &v +} + +// GetQueryApiName returns the QueryApiName field value if set, zero value otherwise. +func (o *Log) GetQueryApiName() string { + if o == nil || o.QueryApiName == nil { + var ret string + return ret + } + return *o.QueryApiName +} + +// GetQueryApiNameOk returns a tuple with the QueryApiName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryApiNameOk() (*string, bool) { + if o == nil || o.QueryApiName == nil { + return nil, false + } + return o.QueryApiName, true +} + +// HasQueryApiName returns a boolean if a field has been set. +func (o *Log) HasQueryApiName() bool { + if o != nil && o.QueryApiName != nil { + return true + } + + return false +} + +// SetQueryApiName gets a reference to the given string and assigns it to the QueryApiName field. +func (o *Log) SetQueryApiName(v string) { + o.QueryApiName = &v +} + +// GetQueryApiVersion returns the QueryApiVersion field value if set, zero value otherwise. +func (o *Log) GetQueryApiVersion() string { + if o == nil || o.QueryApiVersion == nil { + var ret string + return ret + } + return *o.QueryApiVersion +} + +// GetQueryApiVersionOk returns a tuple with the QueryApiVersion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryApiVersionOk() (*string, bool) { + if o == nil || o.QueryApiVersion == nil { + return nil, false + } + return o.QueryApiVersion, true +} + +// HasQueryApiVersion returns a boolean if a field has been set. +func (o *Log) HasQueryApiVersion() bool { + if o != nil && o.QueryApiVersion != nil { + return true + } + + return false +} + +// SetQueryApiVersion gets a reference to the given string and assigns it to the QueryApiVersion field. +func (o *Log) SetQueryApiVersion(v string) { + o.QueryApiVersion = &v +} + +// GetQueryCallName returns the QueryCallName field value if set, zero value otherwise. +func (o *Log) GetQueryCallName() string { + if o == nil || o.QueryCallName == nil { + var ret string + return ret + } + return *o.QueryCallName +} + +// GetQueryCallNameOk returns a tuple with the QueryCallName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryCallNameOk() (*string, bool) { + if o == nil || o.QueryCallName == nil { + return nil, false + } + return o.QueryCallName, true +} + +// HasQueryCallName returns a boolean if a field has been set. +func (o *Log) HasQueryCallName() bool { + if o != nil && o.QueryCallName != nil { + return true + } + + return false +} + +// SetQueryCallName gets a reference to the given string and assigns it to the QueryCallName field. +func (o *Log) SetQueryCallName(v string) { + o.QueryCallName = &v +} + +// GetQueryDate returns the QueryDate field value if set, zero value otherwise. +func (o *Log) GetQueryDate() string { + if o == nil || o.QueryDate == nil { + var ret string + return ret + } + return *o.QueryDate +} + +// GetQueryDateOk returns a tuple with the QueryDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryDateOk() (*string, bool) { + if o == nil || o.QueryDate == nil { + return nil, false + } + return o.QueryDate, true +} + +// HasQueryDate returns a boolean if a field has been set. +func (o *Log) HasQueryDate() bool { + if o != nil && o.QueryDate != nil { + return true + } + + return false +} + +// SetQueryDate gets a reference to the given string and assigns it to the QueryDate field. +func (o *Log) SetQueryDate(v string) { + o.QueryDate = &v +} + +// GetQueryHeaderRaw returns the QueryHeaderRaw field value if set, zero value otherwise. +func (o *Log) GetQueryHeaderRaw() string { + if o == nil || o.QueryHeaderRaw == nil { + var ret string + return ret + } + return *o.QueryHeaderRaw +} + +// GetQueryHeaderRawOk returns a tuple with the QueryHeaderRaw field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryHeaderRawOk() (*string, bool) { + if o == nil || o.QueryHeaderRaw == nil { + return nil, false + } + return o.QueryHeaderRaw, true +} + +// HasQueryHeaderRaw returns a boolean if a field has been set. +func (o *Log) HasQueryHeaderRaw() bool { + if o != nil && o.QueryHeaderRaw != nil { + return true + } + + return false +} + +// SetQueryHeaderRaw gets a reference to the given string and assigns it to the QueryHeaderRaw field. +func (o *Log) SetQueryHeaderRaw(v string) { + o.QueryHeaderRaw = &v +} + +// GetQueryHeaderSize returns the QueryHeaderSize field value if set, zero value otherwise. +func (o *Log) GetQueryHeaderSize() int32 { + if o == nil || o.QueryHeaderSize == nil { + var ret int32 + return ret + } + return *o.QueryHeaderSize +} + +// GetQueryHeaderSizeOk returns a tuple with the QueryHeaderSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryHeaderSizeOk() (*int32, bool) { + if o == nil || o.QueryHeaderSize == nil { + return nil, false + } + return o.QueryHeaderSize, true +} + +// HasQueryHeaderSize returns a boolean if a field has been set. +func (o *Log) HasQueryHeaderSize() bool { + if o != nil && o.QueryHeaderSize != nil { + return true + } + + return false +} + +// SetQueryHeaderSize gets a reference to the given int32 and assigns it to the QueryHeaderSize field. +func (o *Log) SetQueryHeaderSize(v int32) { + o.QueryHeaderSize = &v +} + +// GetQueryIpAddress returns the QueryIpAddress field value if set, zero value otherwise. +func (o *Log) GetQueryIpAddress() string { + if o == nil || o.QueryIpAddress == nil { + var ret string + return ret + } + return *o.QueryIpAddress +} + +// GetQueryIpAddressOk returns a tuple with the QueryIpAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryIpAddressOk() (*string, bool) { + if o == nil || o.QueryIpAddress == nil { + return nil, false + } + return o.QueryIpAddress, true +} + +// HasQueryIpAddress returns a boolean if a field has been set. +func (o *Log) HasQueryIpAddress() bool { + if o != nil && o.QueryIpAddress != nil { + return true + } + + return false +} + +// SetQueryIpAddress gets a reference to the given string and assigns it to the QueryIpAddress field. +func (o *Log) SetQueryIpAddress(v string) { + o.QueryIpAddress = &v +} + +// GetQueryPayloadRaw returns the QueryPayloadRaw field value if set, zero value otherwise. +func (o *Log) GetQueryPayloadRaw() string { + if o == nil || o.QueryPayloadRaw == nil { + var ret string + return ret + } + return *o.QueryPayloadRaw +} + +// GetQueryPayloadRawOk returns a tuple with the QueryPayloadRaw field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryPayloadRawOk() (*string, bool) { + if o == nil || o.QueryPayloadRaw == nil { + return nil, false + } + return o.QueryPayloadRaw, true +} + +// HasQueryPayloadRaw returns a boolean if a field has been set. +func (o *Log) HasQueryPayloadRaw() bool { + if o != nil && o.QueryPayloadRaw != nil { + return true + } + + return false +} + +// SetQueryPayloadRaw gets a reference to the given string and assigns it to the QueryPayloadRaw field. +func (o *Log) SetQueryPayloadRaw(v string) { + o.QueryPayloadRaw = &v +} + +// GetQueryPayloadSize returns the QueryPayloadSize field value if set, zero value otherwise. +func (o *Log) GetQueryPayloadSize() int32 { + if o == nil || o.QueryPayloadSize == nil { + var ret int32 + return ret + } + return *o.QueryPayloadSize +} + +// GetQueryPayloadSizeOk returns a tuple with the QueryPayloadSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryPayloadSizeOk() (*int32, bool) { + if o == nil || o.QueryPayloadSize == nil { + return nil, false + } + return o.QueryPayloadSize, true +} + +// HasQueryPayloadSize returns a boolean if a field has been set. +func (o *Log) HasQueryPayloadSize() bool { + if o != nil && o.QueryPayloadSize != nil { + return true + } + + return false +} + +// SetQueryPayloadSize gets a reference to the given int32 and assigns it to the QueryPayloadSize field. +func (o *Log) SetQueryPayloadSize(v int32) { + o.QueryPayloadSize = &v +} + +// GetQueryUserAgent returns the QueryUserAgent field value if set, zero value otherwise. +func (o *Log) GetQueryUserAgent() string { + if o == nil || o.QueryUserAgent == nil { + var ret string + return ret + } + return *o.QueryUserAgent +} + +// GetQueryUserAgentOk returns a tuple with the QueryUserAgent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetQueryUserAgentOk() (*string, bool) { + if o == nil || o.QueryUserAgent == nil { + return nil, false + } + return o.QueryUserAgent, true +} + +// HasQueryUserAgent returns a boolean if a field has been set. +func (o *Log) HasQueryUserAgent() bool { + if o != nil && o.QueryUserAgent != nil { + return true + } + + return false +} + +// SetQueryUserAgent gets a reference to the given string and assigns it to the QueryUserAgent field. +func (o *Log) SetQueryUserAgent(v string) { + o.QueryUserAgent = &v +} + +// GetRequestId returns the RequestId field value if set, zero value otherwise. +func (o *Log) GetRequestId() string { + if o == nil || o.RequestId == nil { + var ret string + return ret + } + return *o.RequestId +} + +// GetRequestIdOk returns a tuple with the RequestId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetRequestIdOk() (*string, bool) { + if o == nil || o.RequestId == nil { + return nil, false + } + return o.RequestId, true +} + +// HasRequestId returns a boolean if a field has been set. +func (o *Log) HasRequestId() bool { + if o != nil && o.RequestId != nil { + return true + } + + return false +} + +// SetRequestId gets a reference to the given string and assigns it to the RequestId field. +func (o *Log) SetRequestId(v string) { + o.RequestId = &v +} + +// GetResponseSize returns the ResponseSize field value if set, zero value otherwise. +func (o *Log) GetResponseSize() int32 { + if o == nil || o.ResponseSize == nil { + var ret int32 + return ret + } + return *o.ResponseSize +} + +// GetResponseSizeOk returns a tuple with the ResponseSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetResponseSizeOk() (*int32, bool) { + if o == nil || o.ResponseSize == nil { + return nil, false + } + return o.ResponseSize, true +} + +// HasResponseSize returns a boolean if a field has been set. +func (o *Log) HasResponseSize() bool { + if o != nil && o.ResponseSize != nil { + return true + } + + return false +} + +// SetResponseSize gets a reference to the given int32 and assigns it to the ResponseSize field. +func (o *Log) SetResponseSize(v int32) { + o.ResponseSize = &v +} + +// GetResponseStatusCode returns the ResponseStatusCode field value if set, zero value otherwise. +func (o *Log) GetResponseStatusCode() int32 { + if o == nil || o.ResponseStatusCode == nil { + var ret int32 + return ret + } + return *o.ResponseStatusCode +} + +// GetResponseStatusCodeOk returns a tuple with the ResponseStatusCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Log) GetResponseStatusCodeOk() (*int32, bool) { + if o == nil || o.ResponseStatusCode == nil { + return nil, false + } + return o.ResponseStatusCode, true +} + +// HasResponseStatusCode returns a boolean if a field has been set. +func (o *Log) HasResponseStatusCode() bool { + if o != nil && o.ResponseStatusCode != nil { + return true + } + + return false +} + +// SetResponseStatusCode gets a reference to the given int32 and assigns it to the ResponseStatusCode field. +func (o *Log) SetResponseStatusCode(v int32) { + o.ResponseStatusCode = &v +} + +func (o Log) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.CallDuration != nil { + toSerialize["CallDuration"] = o.CallDuration + } + if o.QueryAccessKey != nil { + toSerialize["QueryAccessKey"] = o.QueryAccessKey + } + if o.QueryApiName != nil { + toSerialize["QueryApiName"] = o.QueryApiName + } + if o.QueryApiVersion != nil { + toSerialize["QueryApiVersion"] = o.QueryApiVersion + } + if o.QueryCallName != nil { + toSerialize["QueryCallName"] = o.QueryCallName + } + if o.QueryDate != nil { + toSerialize["QueryDate"] = o.QueryDate + } + if o.QueryHeaderRaw != nil { + toSerialize["QueryHeaderRaw"] = o.QueryHeaderRaw + } + if o.QueryHeaderSize != nil { + toSerialize["QueryHeaderSize"] = o.QueryHeaderSize + } + if o.QueryIpAddress != nil { + toSerialize["QueryIpAddress"] = o.QueryIpAddress + } + if o.QueryPayloadRaw != nil { + toSerialize["QueryPayloadRaw"] = o.QueryPayloadRaw + } + if o.QueryPayloadSize != nil { + toSerialize["QueryPayloadSize"] = o.QueryPayloadSize + } + if o.QueryUserAgent != nil { + toSerialize["QueryUserAgent"] = o.QueryUserAgent + } + if o.RequestId != nil { + toSerialize["RequestId"] = o.RequestId + } + if o.ResponseSize != nil { + toSerialize["ResponseSize"] = o.ResponseSize + } + if o.ResponseStatusCode != nil { + toSerialize["ResponseStatusCode"] = o.ResponseStatusCode + } + return json.Marshal(toSerialize) +} + +type NullableLog struct { + value *Log + isSet bool +} + +func (v NullableLog) Get() *Log { + return v.value +} + +func (v *NullableLog) Set(val *Log) { + v.value = val + v.isSet = true +} + +func (v NullableLog) IsSet() bool { + return v.isSet +} + +func (v *NullableLog) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableLog(val *Log) *NullableLog { + return &NullableLog{value: val, isSet: true} +} + +func (v NullableLog) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableLog) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go new file mode 100644 index 000000000..3ff8dab3d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// MaintenanceEvent Information about the maintenance event. +type MaintenanceEvent struct { + // The code of the event (`system-reboot` \\| `system-maintenance`). + Code *string `json:"Code,omitempty"` + // The description of the event. + Description *string `json:"Description,omitempty"` + // The latest scheduled end time for the event. + NotAfter *string `json:"NotAfter,omitempty"` + // The earliest scheduled start time for the event. + NotBefore *string `json:"NotBefore,omitempty"` +} + +// NewMaintenanceEvent instantiates a new MaintenanceEvent object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewMaintenanceEvent() *MaintenanceEvent { + this := MaintenanceEvent{} + return &this +} + +// NewMaintenanceEventWithDefaults instantiates a new MaintenanceEvent object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewMaintenanceEventWithDefaults() *MaintenanceEvent { + this := MaintenanceEvent{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *MaintenanceEvent) GetCode() string { + if o == nil || o.Code == nil { + var ret string + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *MaintenanceEvent) GetCodeOk() (*string, bool) { + if o == nil || o.Code == nil { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *MaintenanceEvent) HasCode() bool { + if o != nil && o.Code != nil { + return true + } + + return false +} + +// SetCode gets a reference to the given string and assigns it to the Code field. +func (o *MaintenanceEvent) SetCode(v string) { + o.Code = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *MaintenanceEvent) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *MaintenanceEvent) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *MaintenanceEvent) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *MaintenanceEvent) SetDescription(v string) { + o.Description = &v +} + +// GetNotAfter returns the NotAfter field value if set, zero value otherwise. +func (o *MaintenanceEvent) GetNotAfter() string { + if o == nil || o.NotAfter == nil { + var ret string + return ret + } + return *o.NotAfter +} + +// GetNotAfterOk returns a tuple with the NotAfter field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *MaintenanceEvent) GetNotAfterOk() (*string, bool) { + if o == nil || o.NotAfter == nil { + return nil, false + } + return o.NotAfter, true +} + +// HasNotAfter returns a boolean if a field has been set. +func (o *MaintenanceEvent) HasNotAfter() bool { + if o != nil && o.NotAfter != nil { + return true + } + + return false +} + +// SetNotAfter gets a reference to the given string and assigns it to the NotAfter field. +func (o *MaintenanceEvent) SetNotAfter(v string) { + o.NotAfter = &v +} + +// GetNotBefore returns the NotBefore field value if set, zero value otherwise. +func (o *MaintenanceEvent) GetNotBefore() string { + if o == nil || o.NotBefore == nil { + var ret string + return ret + } + return *o.NotBefore +} + +// GetNotBeforeOk returns a tuple with the NotBefore field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *MaintenanceEvent) GetNotBeforeOk() (*string, bool) { + if o == nil || o.NotBefore == nil { + return nil, false + } + return o.NotBefore, true +} + +// HasNotBefore returns a boolean if a field has been set. +func (o *MaintenanceEvent) HasNotBefore() bool { + if o != nil && o.NotBefore != nil { + return true + } + + return false +} + +// SetNotBefore gets a reference to the given string and assigns it to the NotBefore field. +func (o *MaintenanceEvent) SetNotBefore(v string) { + o.NotBefore = &v +} + +func (o MaintenanceEvent) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Code != nil { + toSerialize["Code"] = o.Code + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.NotAfter != nil { + toSerialize["NotAfter"] = o.NotAfter + } + if o.NotBefore != nil { + toSerialize["NotBefore"] = o.NotBefore + } + return json.Marshal(toSerialize) +} + +type NullableMaintenanceEvent struct { + value *MaintenanceEvent + isSet bool +} + +func (v NullableMaintenanceEvent) Get() *MaintenanceEvent { + return v.value +} + +func (v *NullableMaintenanceEvent) Set(val *MaintenanceEvent) { + v.value = val + v.isSet = true +} + +func (v NullableMaintenanceEvent) IsSet() bool { + return v.isSet +} + +func (v *NullableMaintenanceEvent) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableMaintenanceEvent(val *MaintenanceEvent) *NullableMaintenanceEvent { + return &NullableMaintenanceEvent{value: val, isSet: true} +} + +func (v NullableMaintenanceEvent) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableMaintenanceEvent) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go new file mode 100644 index 000000000..dc6801447 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NatService Information about the NAT service. +type NatService struct { + // The ID of the NAT service. + NatServiceId *string `json:"NatServiceId,omitempty"` + // The ID of the Net in which the NAT service is. + NetId *string `json:"NetId,omitempty"` + // Information about the External IP address or addresses (EIPs) associated with the NAT service. + PublicIps *[]PublicIpLight `json:"PublicIps,omitempty"` + // The state of the NAT service (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` + // The ID of the Subnet in which the NAT service is. + SubnetId *string `json:"SubnetId,omitempty"` + // One or more tags associated with the NAT service. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewNatService instantiates a new NatService object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNatService() *NatService { + this := NatService{} + return &this +} + +// NewNatServiceWithDefaults instantiates a new NatService object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNatServiceWithDefaults() *NatService { + this := NatService{} + return &this +} + +// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. +func (o *NatService) GetNatServiceId() string { + if o == nil || o.NatServiceId == nil { + var ret string + return ret + } + return *o.NatServiceId +} + +// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetNatServiceIdOk() (*string, bool) { + if o == nil || o.NatServiceId == nil { + return nil, false + } + return o.NatServiceId, true +} + +// HasNatServiceId returns a boolean if a field has been set. +func (o *NatService) HasNatServiceId() bool { + if o != nil && o.NatServiceId != nil { + return true + } + + return false +} + +// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. +func (o *NatService) SetNatServiceId(v string) { + o.NatServiceId = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *NatService) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *NatService) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *NatService) SetNetId(v string) { + o.NetId = &v +} + +// GetPublicIps returns the PublicIps field value if set, zero value otherwise. +func (o *NatService) GetPublicIps() []PublicIpLight { + if o == nil || o.PublicIps == nil { + var ret []PublicIpLight + return ret + } + return *o.PublicIps +} + +// GetPublicIpsOk returns a tuple with the PublicIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetPublicIpsOk() (*[]PublicIpLight, bool) { + if o == nil || o.PublicIps == nil { + return nil, false + } + return o.PublicIps, true +} + +// HasPublicIps returns a boolean if a field has been set. +func (o *NatService) HasPublicIps() bool { + if o != nil && o.PublicIps != nil { + return true + } + + return false +} + +// SetPublicIps gets a reference to the given []PublicIpLight and assigns it to the PublicIps field. +func (o *NatService) SetPublicIps(v []PublicIpLight) { + o.PublicIps = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *NatService) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *NatService) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *NatService) SetState(v string) { + o.State = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *NatService) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *NatService) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *NatService) SetSubnetId(v string) { + o.SubnetId = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *NatService) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NatService) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *NatService) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *NatService) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o NatService) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NatServiceId != nil { + toSerialize["NatServiceId"] = o.NatServiceId + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.PublicIps != nil { + toSerialize["PublicIps"] = o.PublicIps + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableNatService struct { + value *NatService + isSet bool +} + +func (v NullableNatService) Get() *NatService { + return v.value +} + +func (v *NullableNatService) Set(val *NatService) { + v.value = val + v.isSet = true +} + +func (v NullableNatService) IsSet() bool { + return v.isSet +} + +func (v *NullableNatService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNatService(val *NatService) *NullableNatService { + return &NullableNatService{value: val, isSet: true} +} + +func (v NullableNatService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNatService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_net.go new file mode 100644 index 000000000..05c14e33a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_net.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Net Information about the Net. +type Net struct { + // The ID of the DHCP options set (or `default` if you want to associate the default one). + DhcpOptionsSetId *string `json:"DhcpOptionsSetId,omitempty"` + // The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // The ID of the Net. + NetId *string `json:"NetId,omitempty"` + // The state of the Net (`pending` \\| `available`). + State *string `json:"State,omitempty"` + // One or more tags associated with the Net. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The VM tenancy in a Net. + Tenancy *string `json:"Tenancy,omitempty"` +} + +// NewNet instantiates a new Net object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNet() *Net { + this := Net{} + return &this +} + +// NewNetWithDefaults instantiates a new Net object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNetWithDefaults() *Net { + this := Net{} + return &this +} + +// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value if set, zero value otherwise. +func (o *Net) GetDhcpOptionsSetId() string { + if o == nil || o.DhcpOptionsSetId == nil { + var ret string + return ret + } + return *o.DhcpOptionsSetId +} + +// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetDhcpOptionsSetIdOk() (*string, bool) { + if o == nil || o.DhcpOptionsSetId == nil { + return nil, false + } + return o.DhcpOptionsSetId, true +} + +// HasDhcpOptionsSetId returns a boolean if a field has been set. +func (o *Net) HasDhcpOptionsSetId() bool { + if o != nil && o.DhcpOptionsSetId != nil { + return true + } + + return false +} + +// SetDhcpOptionsSetId gets a reference to the given string and assigns it to the DhcpOptionsSetId field. +func (o *Net) SetDhcpOptionsSetId(v string) { + o.DhcpOptionsSetId = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *Net) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *Net) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *Net) SetIpRange(v string) { + o.IpRange = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *Net) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *Net) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *Net) SetNetId(v string) { + o.NetId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Net) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Net) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Net) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Net) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Net) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Net) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetTenancy returns the Tenancy field value if set, zero value otherwise. +func (o *Net) GetTenancy() string { + if o == nil || o.Tenancy == nil { + var ret string + return ret + } + return *o.Tenancy +} + +// GetTenancyOk returns a tuple with the Tenancy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Net) GetTenancyOk() (*string, bool) { + if o == nil || o.Tenancy == nil { + return nil, false + } + return o.Tenancy, true +} + +// HasTenancy returns a boolean if a field has been set. +func (o *Net) HasTenancy() bool { + if o != nil && o.Tenancy != nil { + return true + } + + return false +} + +// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. +func (o *Net) SetTenancy(v string) { + o.Tenancy = &v +} + +func (o Net) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DhcpOptionsSetId != nil { + toSerialize["DhcpOptionsSetId"] = o.DhcpOptionsSetId + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.Tenancy != nil { + toSerialize["Tenancy"] = o.Tenancy + } + return json.Marshal(toSerialize) +} + +type NullableNet struct { + value *Net + isSet bool +} + +func (v NullableNet) Get() *Net { + return v.value +} + +func (v *NullableNet) Set(val *Net) { + v.value = val + v.isSet = true +} + +func (v NullableNet) IsSet() bool { + return v.isSet +} + +func (v *NullableNet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNet(val *Net) *NullableNet { + return &NullableNet{value: val, isSet: true} +} + +func (v NullableNet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go new file mode 100644 index 000000000..317cf3a9a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NetAccessPoint Information about the Net access point. +type NetAccessPoint struct { + // The ID of the Net access point. + NetAccessPointId *string `json:"NetAccessPointId,omitempty"` + // The ID of the Net with which the Net access point is associated. + NetId *string `json:"NetId,omitempty"` + // The ID of the route tables associated with the Net access point. + RouteTableIds *[]string `json:"RouteTableIds,omitempty"` + // The name of the prefix list corresponding to the service with which the Net access point is associated. + ServiceName *string `json:"ServiceName,omitempty"` + // The state of the Net access point (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` + // One or more tags associated with the Net access point. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewNetAccessPoint instantiates a new NetAccessPoint object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNetAccessPoint() *NetAccessPoint { + this := NetAccessPoint{} + return &this +} + +// NewNetAccessPointWithDefaults instantiates a new NetAccessPoint object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNetAccessPointWithDefaults() *NetAccessPoint { + this := NetAccessPoint{} + return &this +} + +// GetNetAccessPointId returns the NetAccessPointId field value if set, zero value otherwise. +func (o *NetAccessPoint) GetNetAccessPointId() string { + if o == nil || o.NetAccessPointId == nil { + var ret string + return ret + } + return *o.NetAccessPointId +} + +// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetNetAccessPointIdOk() (*string, bool) { + if o == nil || o.NetAccessPointId == nil { + return nil, false + } + return o.NetAccessPointId, true +} + +// HasNetAccessPointId returns a boolean if a field has been set. +func (o *NetAccessPoint) HasNetAccessPointId() bool { + if o != nil && o.NetAccessPointId != nil { + return true + } + + return false +} + +// SetNetAccessPointId gets a reference to the given string and assigns it to the NetAccessPointId field. +func (o *NetAccessPoint) SetNetAccessPointId(v string) { + o.NetAccessPointId = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *NetAccessPoint) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *NetAccessPoint) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *NetAccessPoint) SetNetId(v string) { + o.NetId = &v +} + +// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. +func (o *NetAccessPoint) GetRouteTableIds() []string { + if o == nil || o.RouteTableIds == nil { + var ret []string + return ret + } + return *o.RouteTableIds +} + +// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.RouteTableIds == nil { + return nil, false + } + return o.RouteTableIds, true +} + +// HasRouteTableIds returns a boolean if a field has been set. +func (o *NetAccessPoint) HasRouteTableIds() bool { + if o != nil && o.RouteTableIds != nil { + return true + } + + return false +} + +// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. +func (o *NetAccessPoint) SetRouteTableIds(v []string) { + o.RouteTableIds = &v +} + +// GetServiceName returns the ServiceName field value if set, zero value otherwise. +func (o *NetAccessPoint) GetServiceName() string { + if o == nil || o.ServiceName == nil { + var ret string + return ret + } + return *o.ServiceName +} + +// GetServiceNameOk returns a tuple with the ServiceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetServiceNameOk() (*string, bool) { + if o == nil || o.ServiceName == nil { + return nil, false + } + return o.ServiceName, true +} + +// HasServiceName returns a boolean if a field has been set. +func (o *NetAccessPoint) HasServiceName() bool { + if o != nil && o.ServiceName != nil { + return true + } + + return false +} + +// SetServiceName gets a reference to the given string and assigns it to the ServiceName field. +func (o *NetAccessPoint) SetServiceName(v string) { + o.ServiceName = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *NetAccessPoint) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *NetAccessPoint) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *NetAccessPoint) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *NetAccessPoint) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetAccessPoint) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *NetAccessPoint) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *NetAccessPoint) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o NetAccessPoint) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetAccessPointId != nil { + toSerialize["NetAccessPointId"] = o.NetAccessPointId + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.RouteTableIds != nil { + toSerialize["RouteTableIds"] = o.RouteTableIds + } + if o.ServiceName != nil { + toSerialize["ServiceName"] = o.ServiceName + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableNetAccessPoint struct { + value *NetAccessPoint + isSet bool +} + +func (v NullableNetAccessPoint) Get() *NetAccessPoint { + return v.value +} + +func (v *NullableNetAccessPoint) Set(val *NetAccessPoint) { + v.value = val + v.isSet = true +} + +func (v NullableNetAccessPoint) IsSet() bool { + return v.isSet +} + +func (v *NullableNetAccessPoint) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNetAccessPoint(val *NetAccessPoint) *NullableNetAccessPoint { + return &NullableNetAccessPoint{value: val, isSet: true} +} + +func (v NullableNetAccessPoint) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNetAccessPoint) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go new file mode 100644 index 000000000..934e0c7f5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go @@ -0,0 +1,262 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NetPeering Information about the Net peering connection. +type NetPeering struct { + AccepterNet *AccepterNet `json:"AccepterNet,omitempty"` + // The ID of the Net peering connection. + NetPeeringId *string `json:"NetPeeringId,omitempty"` + SourceNet *SourceNet `json:"SourceNet,omitempty"` + State *NetPeeringState `json:"State,omitempty"` + // One or more tags associated with the Net peering connection. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewNetPeering instantiates a new NetPeering object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNetPeering() *NetPeering { + this := NetPeering{} + return &this +} + +// NewNetPeeringWithDefaults instantiates a new NetPeering object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNetPeeringWithDefaults() *NetPeering { + this := NetPeering{} + return &this +} + +// GetAccepterNet returns the AccepterNet field value if set, zero value otherwise. +func (o *NetPeering) GetAccepterNet() AccepterNet { + if o == nil || o.AccepterNet == nil { + var ret AccepterNet + return ret + } + return *o.AccepterNet +} + +// GetAccepterNetOk returns a tuple with the AccepterNet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeering) GetAccepterNetOk() (*AccepterNet, bool) { + if o == nil || o.AccepterNet == nil { + return nil, false + } + return o.AccepterNet, true +} + +// HasAccepterNet returns a boolean if a field has been set. +func (o *NetPeering) HasAccepterNet() bool { + if o != nil && o.AccepterNet != nil { + return true + } + + return false +} + +// SetAccepterNet gets a reference to the given AccepterNet and assigns it to the AccepterNet field. +func (o *NetPeering) SetAccepterNet(v AccepterNet) { + o.AccepterNet = &v +} + +// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. +func (o *NetPeering) GetNetPeeringId() string { + if o == nil || o.NetPeeringId == nil { + var ret string + return ret + } + return *o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeering) GetNetPeeringIdOk() (*string, bool) { + if o == nil || o.NetPeeringId == nil { + return nil, false + } + return o.NetPeeringId, true +} + +// HasNetPeeringId returns a boolean if a field has been set. +func (o *NetPeering) HasNetPeeringId() bool { + if o != nil && o.NetPeeringId != nil { + return true + } + + return false +} + +// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. +func (o *NetPeering) SetNetPeeringId(v string) { + o.NetPeeringId = &v +} + +// GetSourceNet returns the SourceNet field value if set, zero value otherwise. +func (o *NetPeering) GetSourceNet() SourceNet { + if o == nil || o.SourceNet == nil { + var ret SourceNet + return ret + } + return *o.SourceNet +} + +// GetSourceNetOk returns a tuple with the SourceNet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeering) GetSourceNetOk() (*SourceNet, bool) { + if o == nil || o.SourceNet == nil { + return nil, false + } + return o.SourceNet, true +} + +// HasSourceNet returns a boolean if a field has been set. +func (o *NetPeering) HasSourceNet() bool { + if o != nil && o.SourceNet != nil { + return true + } + + return false +} + +// SetSourceNet gets a reference to the given SourceNet and assigns it to the SourceNet field. +func (o *NetPeering) SetSourceNet(v SourceNet) { + o.SourceNet = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *NetPeering) GetState() NetPeeringState { + if o == nil || o.State == nil { + var ret NetPeeringState + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeering) GetStateOk() (*NetPeeringState, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *NetPeering) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given NetPeeringState and assigns it to the State field. +func (o *NetPeering) SetState(v NetPeeringState) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *NetPeering) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeering) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *NetPeering) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *NetPeering) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o NetPeering) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccepterNet != nil { + toSerialize["AccepterNet"] = o.AccepterNet + } + if o.NetPeeringId != nil { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + if o.SourceNet != nil { + toSerialize["SourceNet"] = o.SourceNet + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableNetPeering struct { + value *NetPeering + isSet bool +} + +func (v NullableNetPeering) Get() *NetPeering { + return v.value +} + +func (v *NullableNetPeering) Set(val *NetPeering) { + v.value = val + v.isSet = true +} + +func (v NullableNetPeering) IsSet() bool { + return v.isSet +} + +func (v *NullableNetPeering) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNetPeering(val *NetPeering) *NullableNetPeering { + return &NullableNetPeering{value: val, isSet: true} +} + +func (v NullableNetPeering) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNetPeering) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go new file mode 100644 index 000000000..aa1e41ab6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NetPeeringState Information about the state of the Net peering connection. +type NetPeeringState struct { + // Additional information about the state of the Net peering connection. + Message *string `json:"Message,omitempty"` + // The state of the Net peering connection (`pending-acceptance` \\| `active` \\| `rejected` \\| `failed` \\| `expired` \\| `deleted`). + Name *string `json:"Name,omitempty"` +} + +// NewNetPeeringState instantiates a new NetPeeringState object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNetPeeringState() *NetPeeringState { + this := NetPeeringState{} + return &this +} + +// NewNetPeeringStateWithDefaults instantiates a new NetPeeringState object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNetPeeringStateWithDefaults() *NetPeeringState { + this := NetPeeringState{} + return &this +} + +// GetMessage returns the Message field value if set, zero value otherwise. +func (o *NetPeeringState) GetMessage() string { + if o == nil || o.Message == nil { + var ret string + return ret + } + return *o.Message +} + +// GetMessageOk returns a tuple with the Message field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeeringState) GetMessageOk() (*string, bool) { + if o == nil || o.Message == nil { + return nil, false + } + return o.Message, true +} + +// HasMessage returns a boolean if a field has been set. +func (o *NetPeeringState) HasMessage() bool { + if o != nil && o.Message != nil { + return true + } + + return false +} + +// SetMessage gets a reference to the given string and assigns it to the Message field. +func (o *NetPeeringState) SetMessage(v string) { + o.Message = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *NetPeeringState) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetPeeringState) GetNameOk() (*string, bool) { + if o == nil || o.Name == nil { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *NetPeeringState) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *NetPeeringState) SetName(v string) { + o.Name = &v +} + +func (o NetPeeringState) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Message != nil { + toSerialize["Message"] = o.Message + } + if o.Name != nil { + toSerialize["Name"] = o.Name + } + return json.Marshal(toSerialize) +} + +type NullableNetPeeringState struct { + value *NetPeeringState + isSet bool +} + +func (v NullableNetPeeringState) Get() *NetPeeringState { + return v.value +} + +func (v *NullableNetPeeringState) Set(val *NetPeeringState) { + v.value = val + v.isSet = true +} + +func (v NullableNetPeeringState) IsSet() bool { + return v.isSet +} + +func (v *NullableNetPeeringState) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNetPeeringState(val *NetPeeringState) *NullableNetPeeringState { + return &NullableNetPeeringState{value: val, isSet: true} +} + +func (v NullableNetPeeringState) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNetPeeringState) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go new file mode 100644 index 000000000..451b93851 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NetToVirtualGatewayLink Information about the attachment. +type NetToVirtualGatewayLink struct { + // The ID of the Net to which the virtual gateway is attached. + NetId *string `json:"NetId,omitempty"` + // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). + State *string `json:"State,omitempty"` +} + +// NewNetToVirtualGatewayLink instantiates a new NetToVirtualGatewayLink object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNetToVirtualGatewayLink() *NetToVirtualGatewayLink { + this := NetToVirtualGatewayLink{} + return &this +} + +// NewNetToVirtualGatewayLinkWithDefaults instantiates a new NetToVirtualGatewayLink object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNetToVirtualGatewayLinkWithDefaults() *NetToVirtualGatewayLink { + this := NetToVirtualGatewayLink{} + return &this +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *NetToVirtualGatewayLink) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetToVirtualGatewayLink) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *NetToVirtualGatewayLink) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *NetToVirtualGatewayLink) SetNetId(v string) { + o.NetId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *NetToVirtualGatewayLink) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NetToVirtualGatewayLink) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *NetToVirtualGatewayLink) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *NetToVirtualGatewayLink) SetState(v string) { + o.State = &v +} + +func (o NetToVirtualGatewayLink) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableNetToVirtualGatewayLink struct { + value *NetToVirtualGatewayLink + isSet bool +} + +func (v NullableNetToVirtualGatewayLink) Get() *NetToVirtualGatewayLink { + return v.value +} + +func (v *NullableNetToVirtualGatewayLink) Set(val *NetToVirtualGatewayLink) { + v.value = val + v.isSet = true +} + +func (v NullableNetToVirtualGatewayLink) IsSet() bool { + return v.isSet +} + +func (v *NullableNetToVirtualGatewayLink) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNetToVirtualGatewayLink(val *NetToVirtualGatewayLink) *NullableNetToVirtualGatewayLink { + return &NullableNetToVirtualGatewayLink{value: val, isSet: true} +} + +func (v NullableNetToVirtualGatewayLink) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNetToVirtualGatewayLink) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go new file mode 100644 index 000000000..84ecb354f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go @@ -0,0 +1,633 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Nic Information about the NIC. +type Nic struct { + // The account ID of the owner of the NIC. + AccountId *string `json:"AccountId,omitempty"` + // The description of the NIC. + Description *string `json:"Description,omitempty"` + // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` + LinkNic *LinkNic `json:"LinkNic,omitempty"` + LinkPublicIp *LinkPublicIp `json:"LinkPublicIp,omitempty"` + // The Media Access Control (MAC) address of the NIC. + MacAddress *string `json:"MacAddress,omitempty"` + // The ID of the Net for the NIC. + NetId *string `json:"NetId,omitempty"` + // The ID of the NIC. + NicId *string `json:"NicId,omitempty"` + // The name of the private DNS. + PrivateDnsName *string `json:"PrivateDnsName,omitempty"` + // The private IP addresses of the NIC. + PrivateIps *[]PrivateIp `json:"PrivateIps,omitempty"` + // One or more IDs of security groups for the NIC. + SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` + // The state of the NIC (`available` \\| `attaching` \\| `in-use` \\| `detaching`). + State *string `json:"State,omitempty"` + // The ID of the Subnet. + SubnetId *string `json:"SubnetId,omitempty"` + // The Subregion in which the NIC is located. + SubregionName *string `json:"SubregionName,omitempty"` + // One or more tags associated with the NIC. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewNic instantiates a new Nic object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNic() *Nic { + this := Nic{} + return &this +} + +// NewNicWithDefaults instantiates a new Nic object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNicWithDefaults() *Nic { + this := Nic{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Nic) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Nic) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Nic) SetAccountId(v string) { + o.AccountId = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *Nic) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *Nic) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *Nic) SetDescription(v string) { + o.Description = &v +} + +// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. +func (o *Nic) GetIsSourceDestChecked() bool { + if o == nil || o.IsSourceDestChecked == nil { + var ret bool + return ret + } + return *o.IsSourceDestChecked +} + +// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetIsSourceDestCheckedOk() (*bool, bool) { + if o == nil || o.IsSourceDestChecked == nil { + return nil, false + } + return o.IsSourceDestChecked, true +} + +// HasIsSourceDestChecked returns a boolean if a field has been set. +func (o *Nic) HasIsSourceDestChecked() bool { + if o != nil && o.IsSourceDestChecked != nil { + return true + } + + return false +} + +// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. +func (o *Nic) SetIsSourceDestChecked(v bool) { + o.IsSourceDestChecked = &v +} + +// GetLinkNic returns the LinkNic field value if set, zero value otherwise. +func (o *Nic) GetLinkNic() LinkNic { + if o == nil || o.LinkNic == nil { + var ret LinkNic + return ret + } + return *o.LinkNic +} + +// GetLinkNicOk returns a tuple with the LinkNic field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetLinkNicOk() (*LinkNic, bool) { + if o == nil || o.LinkNic == nil { + return nil, false + } + return o.LinkNic, true +} + +// HasLinkNic returns a boolean if a field has been set. +func (o *Nic) HasLinkNic() bool { + if o != nil && o.LinkNic != nil { + return true + } + + return false +} + +// SetLinkNic gets a reference to the given LinkNic and assigns it to the LinkNic field. +func (o *Nic) SetLinkNic(v LinkNic) { + o.LinkNic = &v +} + +// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. +func (o *Nic) GetLinkPublicIp() LinkPublicIp { + if o == nil || o.LinkPublicIp == nil { + var ret LinkPublicIp + return ret + } + return *o.LinkPublicIp +} + +// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetLinkPublicIpOk() (*LinkPublicIp, bool) { + if o == nil || o.LinkPublicIp == nil { + return nil, false + } + return o.LinkPublicIp, true +} + +// HasLinkPublicIp returns a boolean if a field has been set. +func (o *Nic) HasLinkPublicIp() bool { + if o != nil && o.LinkPublicIp != nil { + return true + } + + return false +} + +// SetLinkPublicIp gets a reference to the given LinkPublicIp and assigns it to the LinkPublicIp field. +func (o *Nic) SetLinkPublicIp(v LinkPublicIp) { + o.LinkPublicIp = &v +} + +// GetMacAddress returns the MacAddress field value if set, zero value otherwise. +func (o *Nic) GetMacAddress() string { + if o == nil || o.MacAddress == nil { + var ret string + return ret + } + return *o.MacAddress +} + +// GetMacAddressOk returns a tuple with the MacAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetMacAddressOk() (*string, bool) { + if o == nil || o.MacAddress == nil { + return nil, false + } + return o.MacAddress, true +} + +// HasMacAddress returns a boolean if a field has been set. +func (o *Nic) HasMacAddress() bool { + if o != nil && o.MacAddress != nil { + return true + } + + return false +} + +// SetMacAddress gets a reference to the given string and assigns it to the MacAddress field. +func (o *Nic) SetMacAddress(v string) { + o.MacAddress = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *Nic) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *Nic) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *Nic) SetNetId(v string) { + o.NetId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *Nic) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *Nic) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *Nic) SetNicId(v string) { + o.NicId = &v +} + +// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. +func (o *Nic) GetPrivateDnsName() string { + if o == nil || o.PrivateDnsName == nil { + var ret string + return ret + } + return *o.PrivateDnsName +} + +// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetPrivateDnsNameOk() (*string, bool) { + if o == nil || o.PrivateDnsName == nil { + return nil, false + } + return o.PrivateDnsName, true +} + +// HasPrivateDnsName returns a boolean if a field has been set. +func (o *Nic) HasPrivateDnsName() bool { + if o != nil && o.PrivateDnsName != nil { + return true + } + + return false +} + +// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. +func (o *Nic) SetPrivateDnsName(v string) { + o.PrivateDnsName = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *Nic) GetPrivateIps() []PrivateIp { + if o == nil || o.PrivateIps == nil { + var ret []PrivateIp + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetPrivateIpsOk() (*[]PrivateIp, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *Nic) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []PrivateIp and assigns it to the PrivateIps field. +func (o *Nic) SetPrivateIps(v []PrivateIp) { + o.PrivateIps = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *Nic) GetSecurityGroups() []SecurityGroupLight { + if o == nil || o.SecurityGroups == nil { + var ret []SecurityGroupLight + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetSecurityGroupsOk() (*[]SecurityGroupLight, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *Nic) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. +func (o *Nic) SetSecurityGroups(v []SecurityGroupLight) { + o.SecurityGroups = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Nic) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Nic) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Nic) SetState(v string) { + o.State = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *Nic) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *Nic) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *Nic) SetSubnetId(v string) { + o.SubnetId = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *Nic) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *Nic) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *Nic) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Nic) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Nic) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Nic) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Nic) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o Nic) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.IsSourceDestChecked != nil { + toSerialize["IsSourceDestChecked"] = o.IsSourceDestChecked + } + if o.LinkNic != nil { + toSerialize["LinkNic"] = o.LinkNic + } + if o.LinkPublicIp != nil { + toSerialize["LinkPublicIp"] = o.LinkPublicIp + } + if o.MacAddress != nil { + toSerialize["MacAddress"] = o.MacAddress + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.PrivateDnsName != nil { + toSerialize["PrivateDnsName"] = o.PrivateDnsName + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableNic struct { + value *Nic + isSet bool +} + +func (v NullableNic) Get() *Nic { + return v.value +} + +func (v *NullableNic) Set(val *Nic) { + v.value = val + v.isSet = true +} + +func (v NullableNic) IsSet() bool { + return v.isSet +} + +func (v *NullableNic) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNic(val *Nic) *NullableNic { + return &NullableNic{value: val, isSet: true} +} + +func (v NullableNic) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNic) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go new file mode 100644 index 000000000..acca3878c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NicForVmCreation Information about the network interface card (NIC) when creating a virtual machine (VM). +type NicForVmCreation struct { + // If `true`, the NIC is deleted when the VM is terminated. You can specify `true` only if you create a NIC when creating a VM. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // The description of the NIC, if you are creating a NIC when creating the VM. + Description *string `json:"Description,omitempty"` + // The index of the VM device for the NIC attachment (between 0 and 7, both included). This parameter is required if you create a NIC when creating the VM. + DeviceNumber *int32 `json:"DeviceNumber,omitempty"` + // The ID of the NIC, if you are attaching an existing NIC when creating a VM. + NicId *string `json:"NicId,omitempty"` + // One or more private IP addresses to assign to the NIC, if you create a NIC when creating a VM. Only one private IP address can be the primary private IP address. + PrivateIps *[]PrivateIpLight `json:"PrivateIps,omitempty"` + // The number of secondary private IP addresses, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP address in the `PrivateIps` parameter. + SecondaryPrivateIpCount *int32 `json:"SecondaryPrivateIpCount,omitempty"` + // One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` + // The ID of the Subnet for the NIC, if you create a NIC when creating a VM. + SubnetId *string `json:"SubnetId,omitempty"` +} + +// NewNicForVmCreation instantiates a new NicForVmCreation object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNicForVmCreation() *NicForVmCreation { + this := NicForVmCreation{} + return &this +} + +// NewNicForVmCreationWithDefaults instantiates a new NicForVmCreation object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNicForVmCreationWithDefaults() *NicForVmCreation { + this := NicForVmCreation{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *NicForVmCreation) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *NicForVmCreation) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *NicForVmCreation) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *NicForVmCreation) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *NicForVmCreation) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *NicForVmCreation) SetDescription(v string) { + o.Description = &v +} + +// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. +func (o *NicForVmCreation) GetDeviceNumber() int32 { + if o == nil || o.DeviceNumber == nil { + var ret int32 + return ret + } + return *o.DeviceNumber +} + +// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetDeviceNumberOk() (*int32, bool) { + if o == nil || o.DeviceNumber == nil { + return nil, false + } + return o.DeviceNumber, true +} + +// HasDeviceNumber returns a boolean if a field has been set. +func (o *NicForVmCreation) HasDeviceNumber() bool { + if o != nil && o.DeviceNumber != nil { + return true + } + + return false +} + +// SetDeviceNumber gets a reference to the given int32 and assigns it to the DeviceNumber field. +func (o *NicForVmCreation) SetDeviceNumber(v int32) { + o.DeviceNumber = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *NicForVmCreation) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *NicForVmCreation) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *NicForVmCreation) SetNicId(v string) { + o.NicId = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *NicForVmCreation) GetPrivateIps() []PrivateIpLight { + if o == nil || o.PrivateIps == nil { + var ret []PrivateIpLight + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetPrivateIpsOk() (*[]PrivateIpLight, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *NicForVmCreation) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []PrivateIpLight and assigns it to the PrivateIps field. +func (o *NicForVmCreation) SetPrivateIps(v []PrivateIpLight) { + o.PrivateIps = &v +} + +// GetSecondaryPrivateIpCount returns the SecondaryPrivateIpCount field value if set, zero value otherwise. +func (o *NicForVmCreation) GetSecondaryPrivateIpCount() int32 { + if o == nil || o.SecondaryPrivateIpCount == nil { + var ret int32 + return ret + } + return *o.SecondaryPrivateIpCount +} + +// GetSecondaryPrivateIpCountOk returns a tuple with the SecondaryPrivateIpCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetSecondaryPrivateIpCountOk() (*int32, bool) { + if o == nil || o.SecondaryPrivateIpCount == nil { + return nil, false + } + return o.SecondaryPrivateIpCount, true +} + +// HasSecondaryPrivateIpCount returns a boolean if a field has been set. +func (o *NicForVmCreation) HasSecondaryPrivateIpCount() bool { + if o != nil && o.SecondaryPrivateIpCount != nil { + return true + } + + return false +} + +// SetSecondaryPrivateIpCount gets a reference to the given int32 and assigns it to the SecondaryPrivateIpCount field. +func (o *NicForVmCreation) SetSecondaryPrivateIpCount(v int32) { + o.SecondaryPrivateIpCount = &v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *NicForVmCreation) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *NicForVmCreation) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *NicForVmCreation) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *NicForVmCreation) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicForVmCreation) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *NicForVmCreation) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *NicForVmCreation) SetSubnetId(v string) { + o.SubnetId = &v +} + +func (o NicForVmCreation) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.DeviceNumber != nil { + toSerialize["DeviceNumber"] = o.DeviceNumber + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecondaryPrivateIpCount != nil { + toSerialize["SecondaryPrivateIpCount"] = o.SecondaryPrivateIpCount + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableNicForVmCreation struct { + value *NicForVmCreation + isSet bool +} + +func (v NullableNicForVmCreation) Get() *NicForVmCreation { + return v.value +} + +func (v *NullableNicForVmCreation) Set(val *NicForVmCreation) { + v.value = val + v.isSet = true +} + +func (v NullableNicForVmCreation) IsSet() bool { + return v.isSet +} + +func (v *NullableNicForVmCreation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNicForVmCreation(val *NicForVmCreation) *NullableNicForVmCreation { + return &NullableNicForVmCreation{value: val, isSet: true} +} + +func (v NullableNicForVmCreation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNicForVmCreation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go new file mode 100644 index 000000000..bc8dd8362 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go @@ -0,0 +1,559 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// NicLight Information about the network interface card (NIC). +type NicLight struct { + // The account ID of the owner of the NIC. + AccountId *string `json:"AccountId,omitempty"` + // The description of the NIC. + Description *string `json:"Description,omitempty"` + // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` + LinkNic *LinkNicLight `json:"LinkNic,omitempty"` + LinkPublicIp *LinkPublicIpLightForVm `json:"LinkPublicIp,omitempty"` + // The Media Access Control (MAC) address of the NIC. + MacAddress *string `json:"MacAddress,omitempty"` + // The ID of the Net for the NIC. + NetId *string `json:"NetId,omitempty"` + // The ID of the NIC. + NicId *string `json:"NicId,omitempty"` + // The name of the private DNS. + PrivateDnsName *string `json:"PrivateDnsName,omitempty"` + // The private IP address or addresses of the NIC. + PrivateIps *[]PrivateIpLightForVm `json:"PrivateIps,omitempty"` + // One or more IDs of security groups for the NIC. + SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` + // The state of the NIC (`available` \\| `attaching` \\| `in-use` \\| `detaching`). + State *string `json:"State,omitempty"` + // The ID of the Subnet for the NIC. + SubnetId *string `json:"SubnetId,omitempty"` +} + +// NewNicLight instantiates a new NicLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNicLight() *NicLight { + this := NicLight{} + return &this +} + +// NewNicLightWithDefaults instantiates a new NicLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNicLightWithDefaults() *NicLight { + this := NicLight{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *NicLight) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *NicLight) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *NicLight) SetAccountId(v string) { + o.AccountId = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *NicLight) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *NicLight) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *NicLight) SetDescription(v string) { + o.Description = &v +} + +// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. +func (o *NicLight) GetIsSourceDestChecked() bool { + if o == nil || o.IsSourceDestChecked == nil { + var ret bool + return ret + } + return *o.IsSourceDestChecked +} + +// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetIsSourceDestCheckedOk() (*bool, bool) { + if o == nil || o.IsSourceDestChecked == nil { + return nil, false + } + return o.IsSourceDestChecked, true +} + +// HasIsSourceDestChecked returns a boolean if a field has been set. +func (o *NicLight) HasIsSourceDestChecked() bool { + if o != nil && o.IsSourceDestChecked != nil { + return true + } + + return false +} + +// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. +func (o *NicLight) SetIsSourceDestChecked(v bool) { + o.IsSourceDestChecked = &v +} + +// GetLinkNic returns the LinkNic field value if set, zero value otherwise. +func (o *NicLight) GetLinkNic() LinkNicLight { + if o == nil || o.LinkNic == nil { + var ret LinkNicLight + return ret + } + return *o.LinkNic +} + +// GetLinkNicOk returns a tuple with the LinkNic field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetLinkNicOk() (*LinkNicLight, bool) { + if o == nil || o.LinkNic == nil { + return nil, false + } + return o.LinkNic, true +} + +// HasLinkNic returns a boolean if a field has been set. +func (o *NicLight) HasLinkNic() bool { + if o != nil && o.LinkNic != nil { + return true + } + + return false +} + +// SetLinkNic gets a reference to the given LinkNicLight and assigns it to the LinkNic field. +func (o *NicLight) SetLinkNic(v LinkNicLight) { + o.LinkNic = &v +} + +// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. +func (o *NicLight) GetLinkPublicIp() LinkPublicIpLightForVm { + if o == nil || o.LinkPublicIp == nil { + var ret LinkPublicIpLightForVm + return ret + } + return *o.LinkPublicIp +} + +// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetLinkPublicIpOk() (*LinkPublicIpLightForVm, bool) { + if o == nil || o.LinkPublicIp == nil { + return nil, false + } + return o.LinkPublicIp, true +} + +// HasLinkPublicIp returns a boolean if a field has been set. +func (o *NicLight) HasLinkPublicIp() bool { + if o != nil && o.LinkPublicIp != nil { + return true + } + + return false +} + +// SetLinkPublicIp gets a reference to the given LinkPublicIpLightForVm and assigns it to the LinkPublicIp field. +func (o *NicLight) SetLinkPublicIp(v LinkPublicIpLightForVm) { + o.LinkPublicIp = &v +} + +// GetMacAddress returns the MacAddress field value if set, zero value otherwise. +func (o *NicLight) GetMacAddress() string { + if o == nil || o.MacAddress == nil { + var ret string + return ret + } + return *o.MacAddress +} + +// GetMacAddressOk returns a tuple with the MacAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetMacAddressOk() (*string, bool) { + if o == nil || o.MacAddress == nil { + return nil, false + } + return o.MacAddress, true +} + +// HasMacAddress returns a boolean if a field has been set. +func (o *NicLight) HasMacAddress() bool { + if o != nil && o.MacAddress != nil { + return true + } + + return false +} + +// SetMacAddress gets a reference to the given string and assigns it to the MacAddress field. +func (o *NicLight) SetMacAddress(v string) { + o.MacAddress = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *NicLight) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *NicLight) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *NicLight) SetNetId(v string) { + o.NetId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *NicLight) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *NicLight) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *NicLight) SetNicId(v string) { + o.NicId = &v +} + +// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. +func (o *NicLight) GetPrivateDnsName() string { + if o == nil || o.PrivateDnsName == nil { + var ret string + return ret + } + return *o.PrivateDnsName +} + +// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetPrivateDnsNameOk() (*string, bool) { + if o == nil || o.PrivateDnsName == nil { + return nil, false + } + return o.PrivateDnsName, true +} + +// HasPrivateDnsName returns a boolean if a field has been set. +func (o *NicLight) HasPrivateDnsName() bool { + if o != nil && o.PrivateDnsName != nil { + return true + } + + return false +} + +// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. +func (o *NicLight) SetPrivateDnsName(v string) { + o.PrivateDnsName = &v +} + +// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. +func (o *NicLight) GetPrivateIps() []PrivateIpLightForVm { + if o == nil || o.PrivateIps == nil { + var ret []PrivateIpLightForVm + return ret + } + return *o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetPrivateIpsOk() (*[]PrivateIpLightForVm, bool) { + if o == nil || o.PrivateIps == nil { + return nil, false + } + return o.PrivateIps, true +} + +// HasPrivateIps returns a boolean if a field has been set. +func (o *NicLight) HasPrivateIps() bool { + if o != nil && o.PrivateIps != nil { + return true + } + + return false +} + +// SetPrivateIps gets a reference to the given []PrivateIpLightForVm and assigns it to the PrivateIps field. +func (o *NicLight) SetPrivateIps(v []PrivateIpLightForVm) { + o.PrivateIps = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *NicLight) GetSecurityGroups() []SecurityGroupLight { + if o == nil || o.SecurityGroups == nil { + var ret []SecurityGroupLight + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetSecurityGroupsOk() (*[]SecurityGroupLight, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *NicLight) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. +func (o *NicLight) SetSecurityGroups(v []SecurityGroupLight) { + o.SecurityGroups = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *NicLight) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *NicLight) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *NicLight) SetState(v string) { + o.State = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *NicLight) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *NicLight) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *NicLight) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *NicLight) SetSubnetId(v string) { + o.SubnetId = &v +} + +func (o NicLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.IsSourceDestChecked != nil { + toSerialize["IsSourceDestChecked"] = o.IsSourceDestChecked + } + if o.LinkNic != nil { + toSerialize["LinkNic"] = o.LinkNic + } + if o.LinkPublicIp != nil { + toSerialize["LinkPublicIp"] = o.LinkPublicIp + } + if o.MacAddress != nil { + toSerialize["MacAddress"] = o.MacAddress + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.PrivateDnsName != nil { + toSerialize["PrivateDnsName"] = o.PrivateDnsName + } + if o.PrivateIps != nil { + toSerialize["PrivateIps"] = o.PrivateIps + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableNicLight struct { + value *NicLight + isSet bool +} + +func (v NullableNicLight) Get() *NicLight { + return v.value +} + +func (v *NullableNicLight) Set(val *NicLight) { + v.value = val + v.isSet = true +} + +func (v NullableNicLight) IsSet() bool { + return v.isSet +} + +func (v *NullableNicLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNicLight(val *NicLight) *NullableNicLight { + return &NullableNicLight{value: val, isSet: true} +} + +func (v NullableNicLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNicLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go new file mode 100644 index 000000000..aad11fec3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// OsuApiKey Information about the OSU API key. +type OsuApiKey struct { + // The API key of the OSU account that enables you to access the bucket. + ApiKeyId *string `json:"ApiKeyId,omitempty"` + // The secret key of the OSU account that enables you to access the bucket. + SecretKey *string `json:"SecretKey,omitempty"` +} + +// NewOsuApiKey instantiates a new OsuApiKey object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewOsuApiKey() *OsuApiKey { + this := OsuApiKey{} + return &this +} + +// NewOsuApiKeyWithDefaults instantiates a new OsuApiKey object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewOsuApiKeyWithDefaults() *OsuApiKey { + this := OsuApiKey{} + return &this +} + +// GetApiKeyId returns the ApiKeyId field value if set, zero value otherwise. +func (o *OsuApiKey) GetApiKeyId() string { + if o == nil || o.ApiKeyId == nil { + var ret string + return ret + } + return *o.ApiKeyId +} + +// GetApiKeyIdOk returns a tuple with the ApiKeyId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OsuApiKey) GetApiKeyIdOk() (*string, bool) { + if o == nil || o.ApiKeyId == nil { + return nil, false + } + return o.ApiKeyId, true +} + +// HasApiKeyId returns a boolean if a field has been set. +func (o *OsuApiKey) HasApiKeyId() bool { + if o != nil && o.ApiKeyId != nil { + return true + } + + return false +} + +// SetApiKeyId gets a reference to the given string and assigns it to the ApiKeyId field. +func (o *OsuApiKey) SetApiKeyId(v string) { + o.ApiKeyId = &v +} + +// GetSecretKey returns the SecretKey field value if set, zero value otherwise. +func (o *OsuApiKey) GetSecretKey() string { + if o == nil || o.SecretKey == nil { + var ret string + return ret + } + return *o.SecretKey +} + +// GetSecretKeyOk returns a tuple with the SecretKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OsuApiKey) GetSecretKeyOk() (*string, bool) { + if o == nil || o.SecretKey == nil { + return nil, false + } + return o.SecretKey, true +} + +// HasSecretKey returns a boolean if a field has been set. +func (o *OsuApiKey) HasSecretKey() bool { + if o != nil && o.SecretKey != nil { + return true + } + + return false +} + +// SetSecretKey gets a reference to the given string and assigns it to the SecretKey field. +func (o *OsuApiKey) SetSecretKey(v string) { + o.SecretKey = &v +} + +func (o OsuApiKey) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ApiKeyId != nil { + toSerialize["ApiKeyId"] = o.ApiKeyId + } + if o.SecretKey != nil { + toSerialize["SecretKey"] = o.SecretKey + } + return json.Marshal(toSerialize) +} + +type NullableOsuApiKey struct { + value *OsuApiKey + isSet bool +} + +func (v NullableOsuApiKey) Get() *OsuApiKey { + return v.value +} + +func (v *NullableOsuApiKey) Set(val *OsuApiKey) { + v.value = val + v.isSet = true +} + +func (v NullableOsuApiKey) IsSet() bool { + return v.isSet +} + +func (v *NullableOsuApiKey) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableOsuApiKey(val *OsuApiKey) *NullableOsuApiKey { + return &NullableOsuApiKey{value: val, isSet: true} +} + +func (v NullableOsuApiKey) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableOsuApiKey) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go new file mode 100644 index 000000000..b200eeffb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go @@ -0,0 +1,250 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// OsuExport Information about the OSU export. +type OsuExport struct { + // The format of the export disk (`qcow2` \\| `raw`). + DiskImageFormat string `json:"DiskImageFormat"` + OsuApiKey *OsuApiKey `json:"OsuApiKey,omitempty"` + // The name of the OSU bucket where you want to export the object. + OsuBucket string `json:"OsuBucket"` + // The URL of the manifest file. + OsuManifestUrl *string `json:"OsuManifestUrl,omitempty"` + // The prefix for the key of the OSU object. + OsuPrefix *string `json:"OsuPrefix,omitempty"` +} + +// NewOsuExport instantiates a new OsuExport object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewOsuExport(diskImageFormat string, osuBucket string, ) *OsuExport { + this := OsuExport{} + this.DiskImageFormat = diskImageFormat + this.OsuBucket = osuBucket + return &this +} + +// NewOsuExportWithDefaults instantiates a new OsuExport object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewOsuExportWithDefaults() *OsuExport { + this := OsuExport{} + return &this +} + +// GetDiskImageFormat returns the DiskImageFormat field value +func (o *OsuExport) GetDiskImageFormat() string { + if o == nil { + var ret string + return ret + } + + return o.DiskImageFormat +} + +// GetDiskImageFormatOk returns a tuple with the DiskImageFormat field value +// and a boolean to check if the value has been set. +func (o *OsuExport) GetDiskImageFormatOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DiskImageFormat, true +} + +// SetDiskImageFormat sets field value +func (o *OsuExport) SetDiskImageFormat(v string) { + o.DiskImageFormat = v +} + +// GetOsuApiKey returns the OsuApiKey field value if set, zero value otherwise. +func (o *OsuExport) GetOsuApiKey() OsuApiKey { + if o == nil || o.OsuApiKey == nil { + var ret OsuApiKey + return ret + } + return *o.OsuApiKey +} + +// GetOsuApiKeyOk returns a tuple with the OsuApiKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OsuExport) GetOsuApiKeyOk() (*OsuApiKey, bool) { + if o == nil || o.OsuApiKey == nil { + return nil, false + } + return o.OsuApiKey, true +} + +// HasOsuApiKey returns a boolean if a field has been set. +func (o *OsuExport) HasOsuApiKey() bool { + if o != nil && o.OsuApiKey != nil { + return true + } + + return false +} + +// SetOsuApiKey gets a reference to the given OsuApiKey and assigns it to the OsuApiKey field. +func (o *OsuExport) SetOsuApiKey(v OsuApiKey) { + o.OsuApiKey = &v +} + +// GetOsuBucket returns the OsuBucket field value +func (o *OsuExport) GetOsuBucket() string { + if o == nil { + var ret string + return ret + } + + return o.OsuBucket +} + +// GetOsuBucketOk returns a tuple with the OsuBucket field value +// and a boolean to check if the value has been set. +func (o *OsuExport) GetOsuBucketOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.OsuBucket, true +} + +// SetOsuBucket sets field value +func (o *OsuExport) SetOsuBucket(v string) { + o.OsuBucket = v +} + +// GetOsuManifestUrl returns the OsuManifestUrl field value if set, zero value otherwise. +func (o *OsuExport) GetOsuManifestUrl() string { + if o == nil || o.OsuManifestUrl == nil { + var ret string + return ret + } + return *o.OsuManifestUrl +} + +// GetOsuManifestUrlOk returns a tuple with the OsuManifestUrl field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OsuExport) GetOsuManifestUrlOk() (*string, bool) { + if o == nil || o.OsuManifestUrl == nil { + return nil, false + } + return o.OsuManifestUrl, true +} + +// HasOsuManifestUrl returns a boolean if a field has been set. +func (o *OsuExport) HasOsuManifestUrl() bool { + if o != nil && o.OsuManifestUrl != nil { + return true + } + + return false +} + +// SetOsuManifestUrl gets a reference to the given string and assigns it to the OsuManifestUrl field. +func (o *OsuExport) SetOsuManifestUrl(v string) { + o.OsuManifestUrl = &v +} + +// GetOsuPrefix returns the OsuPrefix field value if set, zero value otherwise. +func (o *OsuExport) GetOsuPrefix() string { + if o == nil || o.OsuPrefix == nil { + var ret string + return ret + } + return *o.OsuPrefix +} + +// GetOsuPrefixOk returns a tuple with the OsuPrefix field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OsuExport) GetOsuPrefixOk() (*string, bool) { + if o == nil || o.OsuPrefix == nil { + return nil, false + } + return o.OsuPrefix, true +} + +// HasOsuPrefix returns a boolean if a field has been set. +func (o *OsuExport) HasOsuPrefix() bool { + if o != nil && o.OsuPrefix != nil { + return true + } + + return false +} + +// SetOsuPrefix gets a reference to the given string and assigns it to the OsuPrefix field. +func (o *OsuExport) SetOsuPrefix(v string) { + o.OsuPrefix = &v +} + +func (o OsuExport) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DiskImageFormat"] = o.DiskImageFormat + } + if o.OsuApiKey != nil { + toSerialize["OsuApiKey"] = o.OsuApiKey + } + if true { + toSerialize["OsuBucket"] = o.OsuBucket + } + if o.OsuManifestUrl != nil { + toSerialize["OsuManifestUrl"] = o.OsuManifestUrl + } + if o.OsuPrefix != nil { + toSerialize["OsuPrefix"] = o.OsuPrefix + } + return json.Marshal(toSerialize) +} + +type NullableOsuExport struct { + value *OsuExport + isSet bool +} + +func (v NullableOsuExport) Get() *OsuExport { + return v.value +} + +func (v *NullableOsuExport) Set(val *OsuExport) { + v.value = val + v.isSet = true +} + +func (v NullableOsuExport) IsSet() bool { + return v.isSet +} + +func (v *NullableOsuExport) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableOsuExport(val *OsuExport) *NullableOsuExport { + return &NullableOsuExport{value: val, isSet: true} +} + +func (v NullableOsuExport) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableOsuExport) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go new file mode 100644 index 000000000..ded1383f8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PermissionsOnResource Information about the users who have permissions for the resource. +type PermissionsOnResource struct { + // The account ID of one or more users who have permissions for the resource. + AccountIds *[]string `json:"AccountIds,omitempty"` + // If `true`, the resource is public. If `false`, the resource is private. + GlobalPermission *bool `json:"GlobalPermission,omitempty"` +} + +// NewPermissionsOnResource instantiates a new PermissionsOnResource object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPermissionsOnResource() *PermissionsOnResource { + this := PermissionsOnResource{} + return &this +} + +// NewPermissionsOnResourceWithDefaults instantiates a new PermissionsOnResource object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPermissionsOnResourceWithDefaults() *PermissionsOnResource { + this := PermissionsOnResource{} + return &this +} + +// GetAccountIds returns the AccountIds field value if set, zero value otherwise. +func (o *PermissionsOnResource) GetAccountIds() []string { + if o == nil || o.AccountIds == nil { + var ret []string + return ret + } + return *o.AccountIds +} + +// GetAccountIdsOk returns a tuple with the AccountIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PermissionsOnResource) GetAccountIdsOk() (*[]string, bool) { + if o == nil || o.AccountIds == nil { + return nil, false + } + return o.AccountIds, true +} + +// HasAccountIds returns a boolean if a field has been set. +func (o *PermissionsOnResource) HasAccountIds() bool { + if o != nil && o.AccountIds != nil { + return true + } + + return false +} + +// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. +func (o *PermissionsOnResource) SetAccountIds(v []string) { + o.AccountIds = &v +} + +// GetGlobalPermission returns the GlobalPermission field value if set, zero value otherwise. +func (o *PermissionsOnResource) GetGlobalPermission() bool { + if o == nil || o.GlobalPermission == nil { + var ret bool + return ret + } + return *o.GlobalPermission +} + +// GetGlobalPermissionOk returns a tuple with the GlobalPermission field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PermissionsOnResource) GetGlobalPermissionOk() (*bool, bool) { + if o == nil || o.GlobalPermission == nil { + return nil, false + } + return o.GlobalPermission, true +} + +// HasGlobalPermission returns a boolean if a field has been set. +func (o *PermissionsOnResource) HasGlobalPermission() bool { + if o != nil && o.GlobalPermission != nil { + return true + } + + return false +} + +// SetGlobalPermission gets a reference to the given bool and assigns it to the GlobalPermission field. +func (o *PermissionsOnResource) SetGlobalPermission(v bool) { + o.GlobalPermission = &v +} + +func (o PermissionsOnResource) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountIds != nil { + toSerialize["AccountIds"] = o.AccountIds + } + if o.GlobalPermission != nil { + toSerialize["GlobalPermission"] = o.GlobalPermission + } + return json.Marshal(toSerialize) +} + +type NullablePermissionsOnResource struct { + value *PermissionsOnResource + isSet bool +} + +func (v NullablePermissionsOnResource) Get() *PermissionsOnResource { + return v.value +} + +func (v *NullablePermissionsOnResource) Set(val *PermissionsOnResource) { + v.value = val + v.isSet = true +} + +func (v NullablePermissionsOnResource) IsSet() bool { + return v.isSet +} + +func (v *NullablePermissionsOnResource) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePermissionsOnResource(val *PermissionsOnResource) *NullablePermissionsOnResource { + return &NullablePermissionsOnResource{value: val, isSet: true} +} + +func (v NullablePermissionsOnResource) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePermissionsOnResource) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go new file mode 100644 index 000000000..2d62148f6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PermissionsOnResourceCreation Information about the permissions for the resource. +type PermissionsOnResourceCreation struct { + Additions *PermissionsOnResource `json:"Additions,omitempty"` + Removals *PermissionsOnResource `json:"Removals,omitempty"` +} + +// NewPermissionsOnResourceCreation instantiates a new PermissionsOnResourceCreation object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPermissionsOnResourceCreation() *PermissionsOnResourceCreation { + this := PermissionsOnResourceCreation{} + return &this +} + +// NewPermissionsOnResourceCreationWithDefaults instantiates a new PermissionsOnResourceCreation object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPermissionsOnResourceCreationWithDefaults() *PermissionsOnResourceCreation { + this := PermissionsOnResourceCreation{} + return &this +} + +// GetAdditions returns the Additions field value if set, zero value otherwise. +func (o *PermissionsOnResourceCreation) GetAdditions() PermissionsOnResource { + if o == nil || o.Additions == nil { + var ret PermissionsOnResource + return ret + } + return *o.Additions +} + +// GetAdditionsOk returns a tuple with the Additions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PermissionsOnResourceCreation) GetAdditionsOk() (*PermissionsOnResource, bool) { + if o == nil || o.Additions == nil { + return nil, false + } + return o.Additions, true +} + +// HasAdditions returns a boolean if a field has been set. +func (o *PermissionsOnResourceCreation) HasAdditions() bool { + if o != nil && o.Additions != nil { + return true + } + + return false +} + +// SetAdditions gets a reference to the given PermissionsOnResource and assigns it to the Additions field. +func (o *PermissionsOnResourceCreation) SetAdditions(v PermissionsOnResource) { + o.Additions = &v +} + +// GetRemovals returns the Removals field value if set, zero value otherwise. +func (o *PermissionsOnResourceCreation) GetRemovals() PermissionsOnResource { + if o == nil || o.Removals == nil { + var ret PermissionsOnResource + return ret + } + return *o.Removals +} + +// GetRemovalsOk returns a tuple with the Removals field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PermissionsOnResourceCreation) GetRemovalsOk() (*PermissionsOnResource, bool) { + if o == nil || o.Removals == nil { + return nil, false + } + return o.Removals, true +} + +// HasRemovals returns a boolean if a field has been set. +func (o *PermissionsOnResourceCreation) HasRemovals() bool { + if o != nil && o.Removals != nil { + return true + } + + return false +} + +// SetRemovals gets a reference to the given PermissionsOnResource and assigns it to the Removals field. +func (o *PermissionsOnResourceCreation) SetRemovals(v PermissionsOnResource) { + o.Removals = &v +} + +func (o PermissionsOnResourceCreation) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Additions != nil { + toSerialize["Additions"] = o.Additions + } + if o.Removals != nil { + toSerialize["Removals"] = o.Removals + } + return json.Marshal(toSerialize) +} + +type NullablePermissionsOnResourceCreation struct { + value *PermissionsOnResourceCreation + isSet bool +} + +func (v NullablePermissionsOnResourceCreation) Get() *PermissionsOnResourceCreation { + return v.value +} + +func (v *NullablePermissionsOnResourceCreation) Set(val *PermissionsOnResourceCreation) { + v.value = val + v.isSet = true +} + +func (v NullablePermissionsOnResourceCreation) IsSet() bool { + return v.isSet +} + +func (v *NullablePermissionsOnResourceCreation) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePermissionsOnResourceCreation(val *PermissionsOnResourceCreation) *NullablePermissionsOnResourceCreation { + return &NullablePermissionsOnResourceCreation{value: val, isSet: true} +} + +func (v NullablePermissionsOnResourceCreation) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePermissionsOnResourceCreation) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go new file mode 100644 index 000000000..d6862e04f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Placement Information about the placement of the VM. +type Placement struct { + // The name of the Subregion. + SubregionName *string `json:"SubregionName,omitempty"` + // The tenancy of the VM (`default` \\| `dedicated`). + Tenancy *string `json:"Tenancy,omitempty"` +} + +// NewPlacement instantiates a new Placement object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPlacement() *Placement { + this := Placement{} + return &this +} + +// NewPlacementWithDefaults instantiates a new Placement object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPlacementWithDefaults() *Placement { + this := Placement{} + return &this +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *Placement) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Placement) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *Placement) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *Placement) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetTenancy returns the Tenancy field value if set, zero value otherwise. +func (o *Placement) GetTenancy() string { + if o == nil || o.Tenancy == nil { + var ret string + return ret + } + return *o.Tenancy +} + +// GetTenancyOk returns a tuple with the Tenancy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Placement) GetTenancyOk() (*string, bool) { + if o == nil || o.Tenancy == nil { + return nil, false + } + return o.Tenancy, true +} + +// HasTenancy returns a boolean if a field has been set. +func (o *Placement) HasTenancy() bool { + if o != nil && o.Tenancy != nil { + return true + } + + return false +} + +// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. +func (o *Placement) SetTenancy(v string) { + o.Tenancy = &v +} + +func (o Placement) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.Tenancy != nil { + toSerialize["Tenancy"] = o.Tenancy + } + return json.Marshal(toSerialize) +} + +type NullablePlacement struct { + value *Placement + isSet bool +} + +func (v NullablePlacement) Get() *Placement { + return v.value +} + +func (v *NullablePlacement) Set(val *Placement) { + v.value = val + v.isSet = true +} + +func (v NullablePlacement) IsSet() bool { + return v.isSet +} + +func (v *NullablePlacement) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePlacement(val *Placement) *NullablePlacement { + return &NullablePlacement{value: val, isSet: true} +} + +func (v NullablePlacement) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePlacement) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go new file mode 100644 index 000000000..00ad32a21 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go @@ -0,0 +1,227 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PrivateIp Information about the private IP. +type PrivateIp struct { + // If `true`, the IP address is the primary private IP address of the NIC. + IsPrimary *bool `json:"IsPrimary,omitempty"` + LinkPublicIp *LinkPublicIp `json:"LinkPublicIp,omitempty"` + // The name of the private DNS. + PrivateDnsName *string `json:"PrivateDnsName,omitempty"` + // The private IP address of the NIC. + PrivateIp *string `json:"PrivateIp,omitempty"` +} + +// NewPrivateIp instantiates a new PrivateIp object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPrivateIp() *PrivateIp { + this := PrivateIp{} + return &this +} + +// NewPrivateIpWithDefaults instantiates a new PrivateIp object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPrivateIpWithDefaults() *PrivateIp { + this := PrivateIp{} + return &this +} + +// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. +func (o *PrivateIp) GetIsPrimary() bool { + if o == nil || o.IsPrimary == nil { + var ret bool + return ret + } + return *o.IsPrimary +} + +// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIp) GetIsPrimaryOk() (*bool, bool) { + if o == nil || o.IsPrimary == nil { + return nil, false + } + return o.IsPrimary, true +} + +// HasIsPrimary returns a boolean if a field has been set. +func (o *PrivateIp) HasIsPrimary() bool { + if o != nil && o.IsPrimary != nil { + return true + } + + return false +} + +// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. +func (o *PrivateIp) SetIsPrimary(v bool) { + o.IsPrimary = &v +} + +// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. +func (o *PrivateIp) GetLinkPublicIp() LinkPublicIp { + if o == nil || o.LinkPublicIp == nil { + var ret LinkPublicIp + return ret + } + return *o.LinkPublicIp +} + +// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIp) GetLinkPublicIpOk() (*LinkPublicIp, bool) { + if o == nil || o.LinkPublicIp == nil { + return nil, false + } + return o.LinkPublicIp, true +} + +// HasLinkPublicIp returns a boolean if a field has been set. +func (o *PrivateIp) HasLinkPublicIp() bool { + if o != nil && o.LinkPublicIp != nil { + return true + } + + return false +} + +// SetLinkPublicIp gets a reference to the given LinkPublicIp and assigns it to the LinkPublicIp field. +func (o *PrivateIp) SetLinkPublicIp(v LinkPublicIp) { + o.LinkPublicIp = &v +} + +// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. +func (o *PrivateIp) GetPrivateDnsName() string { + if o == nil || o.PrivateDnsName == nil { + var ret string + return ret + } + return *o.PrivateDnsName +} + +// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIp) GetPrivateDnsNameOk() (*string, bool) { + if o == nil || o.PrivateDnsName == nil { + return nil, false + } + return o.PrivateDnsName, true +} + +// HasPrivateDnsName returns a boolean if a field has been set. +func (o *PrivateIp) HasPrivateDnsName() bool { + if o != nil && o.PrivateDnsName != nil { + return true + } + + return false +} + +// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. +func (o *PrivateIp) SetPrivateDnsName(v string) { + o.PrivateDnsName = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *PrivateIp) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIp) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *PrivateIp) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *PrivateIp) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +func (o PrivateIp) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.IsPrimary != nil { + toSerialize["IsPrimary"] = o.IsPrimary + } + if o.LinkPublicIp != nil { + toSerialize["LinkPublicIp"] = o.LinkPublicIp + } + if o.PrivateDnsName != nil { + toSerialize["PrivateDnsName"] = o.PrivateDnsName + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + return json.Marshal(toSerialize) +} + +type NullablePrivateIp struct { + value *PrivateIp + isSet bool +} + +func (v NullablePrivateIp) Get() *PrivateIp { + return v.value +} + +func (v *NullablePrivateIp) Set(val *PrivateIp) { + v.value = val + v.isSet = true +} + +func (v NullablePrivateIp) IsSet() bool { + return v.isSet +} + +func (v *NullablePrivateIp) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePrivateIp(val *PrivateIp) *NullablePrivateIp { + return &NullablePrivateIp{value: val, isSet: true} +} + +func (v NullablePrivateIp) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePrivateIp) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go new file mode 100644 index 000000000..4937ac730 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PrivateIpLight Information about the private IP. +type PrivateIpLight struct { + // If `true`, the IP address is the primary private IP address of the NIC. + IsPrimary *bool `json:"IsPrimary,omitempty"` + // The private IP address of the NIC. + PrivateIp *string `json:"PrivateIp,omitempty"` +} + +// NewPrivateIpLight instantiates a new PrivateIpLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPrivateIpLight() *PrivateIpLight { + this := PrivateIpLight{} + return &this +} + +// NewPrivateIpLightWithDefaults instantiates a new PrivateIpLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPrivateIpLightWithDefaults() *PrivateIpLight { + this := PrivateIpLight{} + return &this +} + +// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. +func (o *PrivateIpLight) GetIsPrimary() bool { + if o == nil || o.IsPrimary == nil { + var ret bool + return ret + } + return *o.IsPrimary +} + +// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLight) GetIsPrimaryOk() (*bool, bool) { + if o == nil || o.IsPrimary == nil { + return nil, false + } + return o.IsPrimary, true +} + +// HasIsPrimary returns a boolean if a field has been set. +func (o *PrivateIpLight) HasIsPrimary() bool { + if o != nil && o.IsPrimary != nil { + return true + } + + return false +} + +// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. +func (o *PrivateIpLight) SetIsPrimary(v bool) { + o.IsPrimary = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *PrivateIpLight) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLight) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *PrivateIpLight) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *PrivateIpLight) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +func (o PrivateIpLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.IsPrimary != nil { + toSerialize["IsPrimary"] = o.IsPrimary + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + return json.Marshal(toSerialize) +} + +type NullablePrivateIpLight struct { + value *PrivateIpLight + isSet bool +} + +func (v NullablePrivateIpLight) Get() *PrivateIpLight { + return v.value +} + +func (v *NullablePrivateIpLight) Set(val *PrivateIpLight) { + v.value = val + v.isSet = true +} + +func (v NullablePrivateIpLight) IsSet() bool { + return v.isSet +} + +func (v *NullablePrivateIpLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePrivateIpLight(val *PrivateIpLight) *NullablePrivateIpLight { + return &NullablePrivateIpLight{value: val, isSet: true} +} + +func (v NullablePrivateIpLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePrivateIpLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go new file mode 100644 index 000000000..74b9ef788 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go @@ -0,0 +1,227 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PrivateIpLightForVm Information about the private IP of the NIC. +type PrivateIpLightForVm struct { + // If `true`, the IP address is the primary private IP address of the NIC. + IsPrimary *bool `json:"IsPrimary,omitempty"` + LinkPublicIp *LinkPublicIpLightForVm `json:"LinkPublicIp,omitempty"` + // The name of the private DNS. + PrivateDnsName *string `json:"PrivateDnsName,omitempty"` + // The private IP address. + PrivateIp *string `json:"PrivateIp,omitempty"` +} + +// NewPrivateIpLightForVm instantiates a new PrivateIpLightForVm object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPrivateIpLightForVm() *PrivateIpLightForVm { + this := PrivateIpLightForVm{} + return &this +} + +// NewPrivateIpLightForVmWithDefaults instantiates a new PrivateIpLightForVm object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPrivateIpLightForVmWithDefaults() *PrivateIpLightForVm { + this := PrivateIpLightForVm{} + return &this +} + +// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. +func (o *PrivateIpLightForVm) GetIsPrimary() bool { + if o == nil || o.IsPrimary == nil { + var ret bool + return ret + } + return *o.IsPrimary +} + +// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLightForVm) GetIsPrimaryOk() (*bool, bool) { + if o == nil || o.IsPrimary == nil { + return nil, false + } + return o.IsPrimary, true +} + +// HasIsPrimary returns a boolean if a field has been set. +func (o *PrivateIpLightForVm) HasIsPrimary() bool { + if o != nil && o.IsPrimary != nil { + return true + } + + return false +} + +// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. +func (o *PrivateIpLightForVm) SetIsPrimary(v bool) { + o.IsPrimary = &v +} + +// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. +func (o *PrivateIpLightForVm) GetLinkPublicIp() LinkPublicIpLightForVm { + if o == nil || o.LinkPublicIp == nil { + var ret LinkPublicIpLightForVm + return ret + } + return *o.LinkPublicIp +} + +// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLightForVm) GetLinkPublicIpOk() (*LinkPublicIpLightForVm, bool) { + if o == nil || o.LinkPublicIp == nil { + return nil, false + } + return o.LinkPublicIp, true +} + +// HasLinkPublicIp returns a boolean if a field has been set. +func (o *PrivateIpLightForVm) HasLinkPublicIp() bool { + if o != nil && o.LinkPublicIp != nil { + return true + } + + return false +} + +// SetLinkPublicIp gets a reference to the given LinkPublicIpLightForVm and assigns it to the LinkPublicIp field. +func (o *PrivateIpLightForVm) SetLinkPublicIp(v LinkPublicIpLightForVm) { + o.LinkPublicIp = &v +} + +// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. +func (o *PrivateIpLightForVm) GetPrivateDnsName() string { + if o == nil || o.PrivateDnsName == nil { + var ret string + return ret + } + return *o.PrivateDnsName +} + +// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLightForVm) GetPrivateDnsNameOk() (*string, bool) { + if o == nil || o.PrivateDnsName == nil { + return nil, false + } + return o.PrivateDnsName, true +} + +// HasPrivateDnsName returns a boolean if a field has been set. +func (o *PrivateIpLightForVm) HasPrivateDnsName() bool { + if o != nil && o.PrivateDnsName != nil { + return true + } + + return false +} + +// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. +func (o *PrivateIpLightForVm) SetPrivateDnsName(v string) { + o.PrivateDnsName = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *PrivateIpLightForVm) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PrivateIpLightForVm) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *PrivateIpLightForVm) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *PrivateIpLightForVm) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +func (o PrivateIpLightForVm) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.IsPrimary != nil { + toSerialize["IsPrimary"] = o.IsPrimary + } + if o.LinkPublicIp != nil { + toSerialize["LinkPublicIp"] = o.LinkPublicIp + } + if o.PrivateDnsName != nil { + toSerialize["PrivateDnsName"] = o.PrivateDnsName + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + return json.Marshal(toSerialize) +} + +type NullablePrivateIpLightForVm struct { + value *PrivateIpLightForVm + isSet bool +} + +func (v NullablePrivateIpLightForVm) Get() *PrivateIpLightForVm { + return v.value +} + +func (v *NullablePrivateIpLightForVm) Set(val *PrivateIpLightForVm) { + v.value = val + v.isSet = true +} + +func (v NullablePrivateIpLightForVm) IsSet() bool { + return v.isSet +} + +func (v *NullablePrivateIpLightForVm) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePrivateIpLightForVm(val *PrivateIpLightForVm) *NullablePrivateIpLightForVm { + return &NullablePrivateIpLightForVm{value: val, isSet: true} +} + +func (v NullablePrivateIpLightForVm) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePrivateIpLightForVm) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go new file mode 100644 index 000000000..257385f84 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ProductType Information about the product type. +type ProductType struct { + // The description of the product type. + Description *string `json:"Description,omitempty"` + // The ID of the product type. + ProductTypeId *string `json:"ProductTypeId,omitempty"` + // The vendor of the product type. + Vendor *string `json:"Vendor,omitempty"` +} + +// NewProductType instantiates a new ProductType object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewProductType() *ProductType { + this := ProductType{} + return &this +} + +// NewProductTypeWithDefaults instantiates a new ProductType object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewProductTypeWithDefaults() *ProductType { + this := ProductType{} + return &this +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *ProductType) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProductType) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *ProductType) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *ProductType) SetDescription(v string) { + o.Description = &v +} + +// GetProductTypeId returns the ProductTypeId field value if set, zero value otherwise. +func (o *ProductType) GetProductTypeId() string { + if o == nil || o.ProductTypeId == nil { + var ret string + return ret + } + return *o.ProductTypeId +} + +// GetProductTypeIdOk returns a tuple with the ProductTypeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProductType) GetProductTypeIdOk() (*string, bool) { + if o == nil || o.ProductTypeId == nil { + return nil, false + } + return o.ProductTypeId, true +} + +// HasProductTypeId returns a boolean if a field has been set. +func (o *ProductType) HasProductTypeId() bool { + if o != nil && o.ProductTypeId != nil { + return true + } + + return false +} + +// SetProductTypeId gets a reference to the given string and assigns it to the ProductTypeId field. +func (o *ProductType) SetProductTypeId(v string) { + o.ProductTypeId = &v +} + +// GetVendor returns the Vendor field value if set, zero value otherwise. +func (o *ProductType) GetVendor() string { + if o == nil || o.Vendor == nil { + var ret string + return ret + } + return *o.Vendor +} + +// GetVendorOk returns a tuple with the Vendor field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ProductType) GetVendorOk() (*string, bool) { + if o == nil || o.Vendor == nil { + return nil, false + } + return o.Vendor, true +} + +// HasVendor returns a boolean if a field has been set. +func (o *ProductType) HasVendor() bool { + if o != nil && o.Vendor != nil { + return true + } + + return false +} + +// SetVendor gets a reference to the given string and assigns it to the Vendor field. +func (o *ProductType) SetVendor(v string) { + o.Vendor = &v +} + +func (o ProductType) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.ProductTypeId != nil { + toSerialize["ProductTypeId"] = o.ProductTypeId + } + if o.Vendor != nil { + toSerialize["Vendor"] = o.Vendor + } + return json.Marshal(toSerialize) +} + +type NullableProductType struct { + value *ProductType + isSet bool +} + +func (v NullableProductType) Get() *ProductType { + return v.value +} + +func (v *NullableProductType) Set(val *ProductType) { + v.value = val + v.isSet = true +} + +func (v NullableProductType) IsSet() bool { + return v.isSet +} + +func (v *NullableProductType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProductType(val *ProductType) *NullableProductType { + return &NullableProductType{value: val, isSet: true} +} + +func (v NullableProductType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProductType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go new file mode 100644 index 000000000..f812e563e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PublicIp Information about the public IP. +type PublicIp struct { + // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` + // The account ID of the owner of the NIC. + NicAccountId *string `json:"NicAccountId,omitempty"` + // The ID of the NIC the EIP is associated with (if any). + NicId *string `json:"NicId,omitempty"` + // The private IP address associated with the EIP. + PrivateIp *string `json:"PrivateIp,omitempty"` + // The External IP address (EIP) associated with the NAT service. + PublicIp *string `json:"PublicIp,omitempty"` + // The allocation ID of the EIP associated with the NAT service. + PublicIpId *string `json:"PublicIpId,omitempty"` + // One or more tags associated with the EIP. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the VM the External IP (EIP) is associated with (if any). + VmId *string `json:"VmId,omitempty"` +} + +// NewPublicIp instantiates a new PublicIp object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPublicIp() *PublicIp { + this := PublicIp{} + return &this +} + +// NewPublicIpWithDefaults instantiates a new PublicIp object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPublicIpWithDefaults() *PublicIp { + this := PublicIp{} + return &this +} + +// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. +func (o *PublicIp) GetLinkPublicIpId() string { + if o == nil || o.LinkPublicIpId == nil { + var ret string + return ret + } + return *o.LinkPublicIpId +} + +// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetLinkPublicIpIdOk() (*string, bool) { + if o == nil || o.LinkPublicIpId == nil { + return nil, false + } + return o.LinkPublicIpId, true +} + +// HasLinkPublicIpId returns a boolean if a field has been set. +func (o *PublicIp) HasLinkPublicIpId() bool { + if o != nil && o.LinkPublicIpId != nil { + return true + } + + return false +} + +// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. +func (o *PublicIp) SetLinkPublicIpId(v string) { + o.LinkPublicIpId = &v +} + +// GetNicAccountId returns the NicAccountId field value if set, zero value otherwise. +func (o *PublicIp) GetNicAccountId() string { + if o == nil || o.NicAccountId == nil { + var ret string + return ret + } + return *o.NicAccountId +} + +// GetNicAccountIdOk returns a tuple with the NicAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetNicAccountIdOk() (*string, bool) { + if o == nil || o.NicAccountId == nil { + return nil, false + } + return o.NicAccountId, true +} + +// HasNicAccountId returns a boolean if a field has been set. +func (o *PublicIp) HasNicAccountId() bool { + if o != nil && o.NicAccountId != nil { + return true + } + + return false +} + +// SetNicAccountId gets a reference to the given string and assigns it to the NicAccountId field. +func (o *PublicIp) SetNicAccountId(v string) { + o.NicAccountId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *PublicIp) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *PublicIp) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *PublicIp) SetNicId(v string) { + o.NicId = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *PublicIp) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *PublicIp) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *PublicIp) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *PublicIp) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *PublicIp) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *PublicIp) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. +func (o *PublicIp) GetPublicIpId() string { + if o == nil || o.PublicIpId == nil { + var ret string + return ret + } + return *o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetPublicIpIdOk() (*string, bool) { + if o == nil || o.PublicIpId == nil { + return nil, false + } + return o.PublicIpId, true +} + +// HasPublicIpId returns a boolean if a field has been set. +func (o *PublicIp) HasPublicIpId() bool { + if o != nil && o.PublicIpId != nil { + return true + } + + return false +} + +// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. +func (o *PublicIp) SetPublicIpId(v string) { + o.PublicIpId = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *PublicIp) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *PublicIp) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *PublicIp) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *PublicIp) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIp) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *PublicIp) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *PublicIp) SetVmId(v string) { + o.VmId = &v +} + +func (o PublicIp) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkPublicIpId != nil { + toSerialize["LinkPublicIpId"] = o.LinkPublicIpId + } + if o.NicAccountId != nil { + toSerialize["NicAccountId"] = o.NicAccountId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpId != nil { + toSerialize["PublicIpId"] = o.PublicIpId + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullablePublicIp struct { + value *PublicIp + isSet bool +} + +func (v NullablePublicIp) Get() *PublicIp { + return v.value +} + +func (v *NullablePublicIp) Set(val *PublicIp) { + v.value = val + v.isSet = true +} + +func (v NullablePublicIp) IsSet() bool { + return v.isSet +} + +func (v *NullablePublicIp) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePublicIp(val *PublicIp) *NullablePublicIp { + return &NullablePublicIp{value: val, isSet: true} +} + +func (v NullablePublicIp) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePublicIp) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go new file mode 100644 index 000000000..ef70c71d5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// PublicIpLight Information about the public IP. +type PublicIpLight struct { + // The External IP address (EIP) associated with the NAT service. + PublicIp *string `json:"PublicIp,omitempty"` + // The allocation ID of the EIP associated with the NAT service. + PublicIpId *string `json:"PublicIpId,omitempty"` +} + +// NewPublicIpLight instantiates a new PublicIpLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPublicIpLight() *PublicIpLight { + this := PublicIpLight{} + return &this +} + +// NewPublicIpLightWithDefaults instantiates a new PublicIpLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPublicIpLightWithDefaults() *PublicIpLight { + this := PublicIpLight{} + return &this +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *PublicIpLight) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIpLight) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *PublicIpLight) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *PublicIpLight) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. +func (o *PublicIpLight) GetPublicIpId() string { + if o == nil || o.PublicIpId == nil { + var ret string + return ret + } + return *o.PublicIpId +} + +// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PublicIpLight) GetPublicIpIdOk() (*string, bool) { + if o == nil || o.PublicIpId == nil { + return nil, false + } + return o.PublicIpId, true +} + +// HasPublicIpId returns a boolean if a field has been set. +func (o *PublicIpLight) HasPublicIpId() bool { + if o != nil && o.PublicIpId != nil { + return true + } + + return false +} + +// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. +func (o *PublicIpLight) SetPublicIpId(v string) { + o.PublicIpId = &v +} + +func (o PublicIpLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.PublicIpId != nil { + toSerialize["PublicIpId"] = o.PublicIpId + } + return json.Marshal(toSerialize) +} + +type NullablePublicIpLight struct { + value *PublicIpLight + isSet bool +} + +func (v NullablePublicIpLight) Get() *PublicIpLight { + return v.value +} + +func (v *NullablePublicIpLight) Set(val *PublicIpLight) { + v.value = val + v.isSet = true +} + +func (v NullablePublicIpLight) IsSet() bool { + return v.isSet +} + +func (v *NullablePublicIpLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePublicIpLight(val *PublicIpLight) *NullablePublicIpLight { + return &NullablePublicIpLight{value: val, isSet: true} +} + +func (v NullablePublicIpLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePublicIpLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go new file mode 100644 index 000000000..8ba973474 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Quota Information about the quota. +type Quota struct { + // The account ID of the owner of the quotas. + AccountId *string `json:"AccountId,omitempty"` + // The description of the quota. + Description *string `json:"Description,omitempty"` + // The maximum value of the quota for the 3DS OUTSCALE user account (if there is no limit, `0`). + MaxValue *int32 `json:"MaxValue,omitempty"` + // The unique name of the quota. + Name *string `json:"Name,omitempty"` + // The group name of the quota. + QuotaCollection *string `json:"QuotaCollection,omitempty"` + // The description of the quota. + ShortDescription *string `json:"ShortDescription,omitempty"` + // The limit value currently used by the 3DS OUTSCALE user account. + UsedValue *int32 `json:"UsedValue,omitempty"` +} + +// NewQuota instantiates a new Quota object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewQuota() *Quota { + this := Quota{} + return &this +} + +// NewQuotaWithDefaults instantiates a new Quota object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewQuotaWithDefaults() *Quota { + this := Quota{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Quota) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Quota) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Quota) SetAccountId(v string) { + o.AccountId = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *Quota) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *Quota) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *Quota) SetDescription(v string) { + o.Description = &v +} + +// GetMaxValue returns the MaxValue field value if set, zero value otherwise. +func (o *Quota) GetMaxValue() int32 { + if o == nil || o.MaxValue == nil { + var ret int32 + return ret + } + return *o.MaxValue +} + +// GetMaxValueOk returns a tuple with the MaxValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetMaxValueOk() (*int32, bool) { + if o == nil || o.MaxValue == nil { + return nil, false + } + return o.MaxValue, true +} + +// HasMaxValue returns a boolean if a field has been set. +func (o *Quota) HasMaxValue() bool { + if o != nil && o.MaxValue != nil { + return true + } + + return false +} + +// SetMaxValue gets a reference to the given int32 and assigns it to the MaxValue field. +func (o *Quota) SetMaxValue(v int32) { + o.MaxValue = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *Quota) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetNameOk() (*string, bool) { + if o == nil || o.Name == nil { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *Quota) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *Quota) SetName(v string) { + o.Name = &v +} + +// GetQuotaCollection returns the QuotaCollection field value if set, zero value otherwise. +func (o *Quota) GetQuotaCollection() string { + if o == nil || o.QuotaCollection == nil { + var ret string + return ret + } + return *o.QuotaCollection +} + +// GetQuotaCollectionOk returns a tuple with the QuotaCollection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetQuotaCollectionOk() (*string, bool) { + if o == nil || o.QuotaCollection == nil { + return nil, false + } + return o.QuotaCollection, true +} + +// HasQuotaCollection returns a boolean if a field has been set. +func (o *Quota) HasQuotaCollection() bool { + if o != nil && o.QuotaCollection != nil { + return true + } + + return false +} + +// SetQuotaCollection gets a reference to the given string and assigns it to the QuotaCollection field. +func (o *Quota) SetQuotaCollection(v string) { + o.QuotaCollection = &v +} + +// GetShortDescription returns the ShortDescription field value if set, zero value otherwise. +func (o *Quota) GetShortDescription() string { + if o == nil || o.ShortDescription == nil { + var ret string + return ret + } + return *o.ShortDescription +} + +// GetShortDescriptionOk returns a tuple with the ShortDescription field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetShortDescriptionOk() (*string, bool) { + if o == nil || o.ShortDescription == nil { + return nil, false + } + return o.ShortDescription, true +} + +// HasShortDescription returns a boolean if a field has been set. +func (o *Quota) HasShortDescription() bool { + if o != nil && o.ShortDescription != nil { + return true + } + + return false +} + +// SetShortDescription gets a reference to the given string and assigns it to the ShortDescription field. +func (o *Quota) SetShortDescription(v string) { + o.ShortDescription = &v +} + +// GetUsedValue returns the UsedValue field value if set, zero value otherwise. +func (o *Quota) GetUsedValue() int32 { + if o == nil || o.UsedValue == nil { + var ret int32 + return ret + } + return *o.UsedValue +} + +// GetUsedValueOk returns a tuple with the UsedValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Quota) GetUsedValueOk() (*int32, bool) { + if o == nil || o.UsedValue == nil { + return nil, false + } + return o.UsedValue, true +} + +// HasUsedValue returns a boolean if a field has been set. +func (o *Quota) HasUsedValue() bool { + if o != nil && o.UsedValue != nil { + return true + } + + return false +} + +// SetUsedValue gets a reference to the given int32 and assigns it to the UsedValue field. +func (o *Quota) SetUsedValue(v int32) { + o.UsedValue = &v +} + +func (o Quota) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.MaxValue != nil { + toSerialize["MaxValue"] = o.MaxValue + } + if o.Name != nil { + toSerialize["Name"] = o.Name + } + if o.QuotaCollection != nil { + toSerialize["QuotaCollection"] = o.QuotaCollection + } + if o.ShortDescription != nil { + toSerialize["ShortDescription"] = o.ShortDescription + } + if o.UsedValue != nil { + toSerialize["UsedValue"] = o.UsedValue + } + return json.Marshal(toSerialize) +} + +type NullableQuota struct { + value *Quota + isSet bool +} + +func (v NullableQuota) Get() *Quota { + return v.value +} + +func (v *NullableQuota) Set(val *Quota) { + v.value = val + v.isSet = true +} + +func (v NullableQuota) IsSet() bool { + return v.isSet +} + +func (v *NullableQuota) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableQuota(val *Quota) *NullableQuota { + return &NullableQuota{value: val, isSet: true} +} + +func (v NullableQuota) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableQuota) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go new file mode 100644 index 000000000..c427647e9 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// QuotaTypes One or more quotas. +type QuotaTypes struct { + // The resource ID if it is a resource-specific quota, `global` if it is not. + QuotaType *string `json:"QuotaType,omitempty"` + // One or more quotas associated with the user. + Quotas *[]Quota `json:"Quotas,omitempty"` +} + +// NewQuotaTypes instantiates a new QuotaTypes object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewQuotaTypes() *QuotaTypes { + this := QuotaTypes{} + return &this +} + +// NewQuotaTypesWithDefaults instantiates a new QuotaTypes object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewQuotaTypesWithDefaults() *QuotaTypes { + this := QuotaTypes{} + return &this +} + +// GetQuotaType returns the QuotaType field value if set, zero value otherwise. +func (o *QuotaTypes) GetQuotaType() string { + if o == nil || o.QuotaType == nil { + var ret string + return ret + } + return *o.QuotaType +} + +// GetQuotaTypeOk returns a tuple with the QuotaType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *QuotaTypes) GetQuotaTypeOk() (*string, bool) { + if o == nil || o.QuotaType == nil { + return nil, false + } + return o.QuotaType, true +} + +// HasQuotaType returns a boolean if a field has been set. +func (o *QuotaTypes) HasQuotaType() bool { + if o != nil && o.QuotaType != nil { + return true + } + + return false +} + +// SetQuotaType gets a reference to the given string and assigns it to the QuotaType field. +func (o *QuotaTypes) SetQuotaType(v string) { + o.QuotaType = &v +} + +// GetQuotas returns the Quotas field value if set, zero value otherwise. +func (o *QuotaTypes) GetQuotas() []Quota { + if o == nil || o.Quotas == nil { + var ret []Quota + return ret + } + return *o.Quotas +} + +// GetQuotasOk returns a tuple with the Quotas field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *QuotaTypes) GetQuotasOk() (*[]Quota, bool) { + if o == nil || o.Quotas == nil { + return nil, false + } + return o.Quotas, true +} + +// HasQuotas returns a boolean if a field has been set. +func (o *QuotaTypes) HasQuotas() bool { + if o != nil && o.Quotas != nil { + return true + } + + return false +} + +// SetQuotas gets a reference to the given []Quota and assigns it to the Quotas field. +func (o *QuotaTypes) SetQuotas(v []Quota) { + o.Quotas = &v +} + +func (o QuotaTypes) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.QuotaType != nil { + toSerialize["QuotaType"] = o.QuotaType + } + if o.Quotas != nil { + toSerialize["Quotas"] = o.Quotas + } + return json.Marshal(toSerialize) +} + +type NullableQuotaTypes struct { + value *QuotaTypes + isSet bool +} + +func (v NullableQuotaTypes) Get() *QuotaTypes { + return v.value +} + +func (v *NullableQuotaTypes) Set(val *QuotaTypes) { + v.value = val + v.isSet = true +} + +func (v NullableQuotaTypes) IsSet() bool { + return v.isSet +} + +func (v *NullableQuotaTypes) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableQuotaTypes(val *QuotaTypes) *NullableQuotaTypes { + return &NullableQuotaTypes{value: val, isSet: true} +} + +func (v NullableQuotaTypes) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableQuotaTypes) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go new file mode 100644 index 000000000..c21d4389f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAccessKeysRequest struct for ReadAccessKeysRequest +type ReadAccessKeysRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersAccessKeys `json:"Filters,omitempty"` +} + +// NewReadAccessKeysRequest instantiates a new ReadAccessKeysRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAccessKeysRequest() *ReadAccessKeysRequest { + this := ReadAccessKeysRequest{} + return &this +} + +// NewReadAccessKeysRequestWithDefaults instantiates a new ReadAccessKeysRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAccessKeysRequestWithDefaults() *ReadAccessKeysRequest { + this := ReadAccessKeysRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadAccessKeysRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccessKeysRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadAccessKeysRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadAccessKeysRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadAccessKeysRequest) GetFilters() FiltersAccessKeys { + if o == nil || o.Filters == nil { + var ret FiltersAccessKeys + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccessKeysRequest) GetFiltersOk() (*FiltersAccessKeys, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadAccessKeysRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersAccessKeys and assigns it to the Filters field. +func (o *ReadAccessKeysRequest) SetFilters(v FiltersAccessKeys) { + o.Filters = &v +} + +func (o ReadAccessKeysRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadAccessKeysRequest struct { + value *ReadAccessKeysRequest + isSet bool +} + +func (v NullableReadAccessKeysRequest) Get() *ReadAccessKeysRequest { + return v.value +} + +func (v *NullableReadAccessKeysRequest) Set(val *ReadAccessKeysRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadAccessKeysRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAccessKeysRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAccessKeysRequest(val *ReadAccessKeysRequest) *NullableReadAccessKeysRequest { + return &NullableReadAccessKeysRequest{value: val, isSet: true} +} + +func (v NullableReadAccessKeysRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAccessKeysRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go new file mode 100644 index 000000000..57c89cdc8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAccessKeysResponse struct for ReadAccessKeysResponse +type ReadAccessKeysResponse struct { + // A list of access keys. + AccessKeys *[]AccessKey `json:"AccessKeys,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadAccessKeysResponse instantiates a new ReadAccessKeysResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAccessKeysResponse() *ReadAccessKeysResponse { + this := ReadAccessKeysResponse{} + return &this +} + +// NewReadAccessKeysResponseWithDefaults instantiates a new ReadAccessKeysResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAccessKeysResponseWithDefaults() *ReadAccessKeysResponse { + this := ReadAccessKeysResponse{} + return &this +} + +// GetAccessKeys returns the AccessKeys field value if set, zero value otherwise. +func (o *ReadAccessKeysResponse) GetAccessKeys() []AccessKey { + if o == nil || o.AccessKeys == nil { + var ret []AccessKey + return ret + } + return *o.AccessKeys +} + +// GetAccessKeysOk returns a tuple with the AccessKeys field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccessKeysResponse) GetAccessKeysOk() (*[]AccessKey, bool) { + if o == nil || o.AccessKeys == nil { + return nil, false + } + return o.AccessKeys, true +} + +// HasAccessKeys returns a boolean if a field has been set. +func (o *ReadAccessKeysResponse) HasAccessKeys() bool { + if o != nil && o.AccessKeys != nil { + return true + } + + return false +} + +// SetAccessKeys gets a reference to the given []AccessKey and assigns it to the AccessKeys field. +func (o *ReadAccessKeysResponse) SetAccessKeys(v []AccessKey) { + o.AccessKeys = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadAccessKeysResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccessKeysResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadAccessKeysResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadAccessKeysResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadAccessKeysResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKeys != nil { + toSerialize["AccessKeys"] = o.AccessKeys + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadAccessKeysResponse struct { + value *ReadAccessKeysResponse + isSet bool +} + +func (v NullableReadAccessKeysResponse) Get() *ReadAccessKeysResponse { + return v.value +} + +func (v *NullableReadAccessKeysResponse) Set(val *ReadAccessKeysResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadAccessKeysResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAccessKeysResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAccessKeysResponse(val *ReadAccessKeysResponse) *NullableReadAccessKeysResponse { + return &NullableReadAccessKeysResponse{value: val, isSet: true} +} + +func (v NullableReadAccessKeysResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAccessKeysResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go new file mode 100644 index 000000000..534cfb2e8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAccountsRequest struct for ReadAccountsRequest +type ReadAccountsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadAccountsRequest instantiates a new ReadAccountsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAccountsRequest() *ReadAccountsRequest { + this := ReadAccountsRequest{} + return &this +} + +// NewReadAccountsRequestWithDefaults instantiates a new ReadAccountsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAccountsRequestWithDefaults() *ReadAccountsRequest { + this := ReadAccountsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadAccountsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccountsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadAccountsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadAccountsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadAccountsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadAccountsRequest struct { + value *ReadAccountsRequest + isSet bool +} + +func (v NullableReadAccountsRequest) Get() *ReadAccountsRequest { + return v.value +} + +func (v *NullableReadAccountsRequest) Set(val *ReadAccountsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadAccountsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAccountsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAccountsRequest(val *ReadAccountsRequest) *NullableReadAccountsRequest { + return &NullableReadAccountsRequest{value: val, isSet: true} +} + +func (v NullableReadAccountsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAccountsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go new file mode 100644 index 000000000..c2075120f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAccountsResponse struct for ReadAccountsResponse +type ReadAccountsResponse struct { + // The list of the accounts. + Accounts *[]Account `json:"Accounts,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadAccountsResponse instantiates a new ReadAccountsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAccountsResponse() *ReadAccountsResponse { + this := ReadAccountsResponse{} + return &this +} + +// NewReadAccountsResponseWithDefaults instantiates a new ReadAccountsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAccountsResponseWithDefaults() *ReadAccountsResponse { + this := ReadAccountsResponse{} + return &this +} + +// GetAccounts returns the Accounts field value if set, zero value otherwise. +func (o *ReadAccountsResponse) GetAccounts() []Account { + if o == nil || o.Accounts == nil { + var ret []Account + return ret + } + return *o.Accounts +} + +// GetAccountsOk returns a tuple with the Accounts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccountsResponse) GetAccountsOk() (*[]Account, bool) { + if o == nil || o.Accounts == nil { + return nil, false + } + return o.Accounts, true +} + +// HasAccounts returns a boolean if a field has been set. +func (o *ReadAccountsResponse) HasAccounts() bool { + if o != nil && o.Accounts != nil { + return true + } + + return false +} + +// SetAccounts gets a reference to the given []Account and assigns it to the Accounts field. +func (o *ReadAccountsResponse) SetAccounts(v []Account) { + o.Accounts = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadAccountsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAccountsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadAccountsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadAccountsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadAccountsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Accounts != nil { + toSerialize["Accounts"] = o.Accounts + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadAccountsResponse struct { + value *ReadAccountsResponse + isSet bool +} + +func (v NullableReadAccountsResponse) Get() *ReadAccountsResponse { + return v.value +} + +func (v *NullableReadAccountsResponse) Set(val *ReadAccountsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadAccountsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAccountsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAccountsResponse(val *ReadAccountsResponse) *NullableReadAccountsResponse { + return &NullableReadAccountsResponse{value: val, isSet: true} +} + +func (v NullableReadAccountsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAccountsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go new file mode 100644 index 000000000..0ba44b0c0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAdminPasswordRequest struct for ReadAdminPasswordRequest +type ReadAdminPasswordRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the VM. + VmId string `json:"VmId"` +} + +// NewReadAdminPasswordRequest instantiates a new ReadAdminPasswordRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAdminPasswordRequest(vmId string, ) *ReadAdminPasswordRequest { + this := ReadAdminPasswordRequest{} + this.VmId = vmId + return &this +} + +// NewReadAdminPasswordRequestWithDefaults instantiates a new ReadAdminPasswordRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAdminPasswordRequestWithDefaults() *ReadAdminPasswordRequest { + this := ReadAdminPasswordRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadAdminPasswordRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAdminPasswordRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadAdminPasswordRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadAdminPasswordRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmId returns the VmId field value +func (o *ReadAdminPasswordRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *ReadAdminPasswordRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *ReadAdminPasswordRequest) SetVmId(v string) { + o.VmId = v +} + +func (o ReadAdminPasswordRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableReadAdminPasswordRequest struct { + value *ReadAdminPasswordRequest + isSet bool +} + +func (v NullableReadAdminPasswordRequest) Get() *ReadAdminPasswordRequest { + return v.value +} + +func (v *NullableReadAdminPasswordRequest) Set(val *ReadAdminPasswordRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadAdminPasswordRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAdminPasswordRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAdminPasswordRequest(val *ReadAdminPasswordRequest) *NullableReadAdminPasswordRequest { + return &NullableReadAdminPasswordRequest{value: val, isSet: true} +} + +func (v NullableReadAdminPasswordRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAdminPasswordRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go new file mode 100644 index 000000000..ffd2278e4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go @@ -0,0 +1,190 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadAdminPasswordResponse struct for ReadAdminPasswordResponse +type ReadAdminPasswordResponse struct { + // The password of the VM. After the first boot, returns an empty string. + AdminPassword *string `json:"AdminPassword,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` +} + +// NewReadAdminPasswordResponse instantiates a new ReadAdminPasswordResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadAdminPasswordResponse() *ReadAdminPasswordResponse { + this := ReadAdminPasswordResponse{} + return &this +} + +// NewReadAdminPasswordResponseWithDefaults instantiates a new ReadAdminPasswordResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadAdminPasswordResponseWithDefaults() *ReadAdminPasswordResponse { + this := ReadAdminPasswordResponse{} + return &this +} + +// GetAdminPassword returns the AdminPassword field value if set, zero value otherwise. +func (o *ReadAdminPasswordResponse) GetAdminPassword() string { + if o == nil || o.AdminPassword == nil { + var ret string + return ret + } + return *o.AdminPassword +} + +// GetAdminPasswordOk returns a tuple with the AdminPassword field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAdminPasswordResponse) GetAdminPasswordOk() (*string, bool) { + if o == nil || o.AdminPassword == nil { + return nil, false + } + return o.AdminPassword, true +} + +// HasAdminPassword returns a boolean if a field has been set. +func (o *ReadAdminPasswordResponse) HasAdminPassword() bool { + if o != nil && o.AdminPassword != nil { + return true + } + + return false +} + +// SetAdminPassword gets a reference to the given string and assigns it to the AdminPassword field. +func (o *ReadAdminPasswordResponse) SetAdminPassword(v string) { + o.AdminPassword = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadAdminPasswordResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAdminPasswordResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadAdminPasswordResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadAdminPasswordResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *ReadAdminPasswordResponse) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadAdminPasswordResponse) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *ReadAdminPasswordResponse) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *ReadAdminPasswordResponse) SetVmId(v string) { + o.VmId = &v +} + +func (o ReadAdminPasswordResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AdminPassword != nil { + toSerialize["AdminPassword"] = o.AdminPassword + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableReadAdminPasswordResponse struct { + value *ReadAdminPasswordResponse + isSet bool +} + +func (v NullableReadAdminPasswordResponse) Get() *ReadAdminPasswordResponse { + return v.value +} + +func (v *NullableReadAdminPasswordResponse) Set(val *ReadAdminPasswordResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadAdminPasswordResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadAdminPasswordResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadAdminPasswordResponse(val *ReadAdminPasswordResponse) *NullableReadAdminPasswordResponse { + return &NullableReadAdminPasswordResponse{value: val, isSet: true} +} + +func (v NullableReadAdminPasswordResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadAdminPasswordResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go new file mode 100644 index 000000000..58d5eb897 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go @@ -0,0 +1,263 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadApiLogsRequest struct for ReadApiLogsRequest +type ReadApiLogsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersApiLog `json:"Filters,omitempty"` + // The token to request the next page of results. + NextPageToken *string `json:"NextPageToken,omitempty"` + // The maximum number of items returned in a single page. By default, 100. + ResultsPerPage *int32 `json:"ResultsPerPage,omitempty"` + With *With `json:"With,omitempty"` +} + +// NewReadApiLogsRequest instantiates a new ReadApiLogsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadApiLogsRequest() *ReadApiLogsRequest { + this := ReadApiLogsRequest{} + return &this +} + +// NewReadApiLogsRequestWithDefaults instantiates a new ReadApiLogsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadApiLogsRequestWithDefaults() *ReadApiLogsRequest { + this := ReadApiLogsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadApiLogsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadApiLogsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadApiLogsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadApiLogsRequest) GetFilters() FiltersApiLog { + if o == nil || o.Filters == nil { + var ret FiltersApiLog + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsRequest) GetFiltersOk() (*FiltersApiLog, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadApiLogsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersApiLog and assigns it to the Filters field. +func (o *ReadApiLogsRequest) SetFilters(v FiltersApiLog) { + o.Filters = &v +} + +// GetNextPageToken returns the NextPageToken field value if set, zero value otherwise. +func (o *ReadApiLogsRequest) GetNextPageToken() string { + if o == nil || o.NextPageToken == nil { + var ret string + return ret + } + return *o.NextPageToken +} + +// GetNextPageTokenOk returns a tuple with the NextPageToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsRequest) GetNextPageTokenOk() (*string, bool) { + if o == nil || o.NextPageToken == nil { + return nil, false + } + return o.NextPageToken, true +} + +// HasNextPageToken returns a boolean if a field has been set. +func (o *ReadApiLogsRequest) HasNextPageToken() bool { + if o != nil && o.NextPageToken != nil { + return true + } + + return false +} + +// SetNextPageToken gets a reference to the given string and assigns it to the NextPageToken field. +func (o *ReadApiLogsRequest) SetNextPageToken(v string) { + o.NextPageToken = &v +} + +// GetResultsPerPage returns the ResultsPerPage field value if set, zero value otherwise. +func (o *ReadApiLogsRequest) GetResultsPerPage() int32 { + if o == nil || o.ResultsPerPage == nil { + var ret int32 + return ret + } + return *o.ResultsPerPage +} + +// GetResultsPerPageOk returns a tuple with the ResultsPerPage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsRequest) GetResultsPerPageOk() (*int32, bool) { + if o == nil || o.ResultsPerPage == nil { + return nil, false + } + return o.ResultsPerPage, true +} + +// HasResultsPerPage returns a boolean if a field has been set. +func (o *ReadApiLogsRequest) HasResultsPerPage() bool { + if o != nil && o.ResultsPerPage != nil { + return true + } + + return false +} + +// SetResultsPerPage gets a reference to the given int32 and assigns it to the ResultsPerPage field. +func (o *ReadApiLogsRequest) SetResultsPerPage(v int32) { + o.ResultsPerPage = &v +} + +// GetWith returns the With field value if set, zero value otherwise. +func (o *ReadApiLogsRequest) GetWith() With { + if o == nil || o.With == nil { + var ret With + return ret + } + return *o.With +} + +// GetWithOk returns a tuple with the With field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsRequest) GetWithOk() (*With, bool) { + if o == nil || o.With == nil { + return nil, false + } + return o.With, true +} + +// HasWith returns a boolean if a field has been set. +func (o *ReadApiLogsRequest) HasWith() bool { + if o != nil && o.With != nil { + return true + } + + return false +} + +// SetWith gets a reference to the given With and assigns it to the With field. +func (o *ReadApiLogsRequest) SetWith(v With) { + o.With = &v +} + +func (o ReadApiLogsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + if o.NextPageToken != nil { + toSerialize["NextPageToken"] = o.NextPageToken + } + if o.ResultsPerPage != nil { + toSerialize["ResultsPerPage"] = o.ResultsPerPage + } + if o.With != nil { + toSerialize["With"] = o.With + } + return json.Marshal(toSerialize) +} + +type NullableReadApiLogsRequest struct { + value *ReadApiLogsRequest + isSet bool +} + +func (v NullableReadApiLogsRequest) Get() *ReadApiLogsRequest { + return v.value +} + +func (v *NullableReadApiLogsRequest) Set(val *ReadApiLogsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadApiLogsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadApiLogsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadApiLogsRequest(val *ReadApiLogsRequest) *NullableReadApiLogsRequest { + return &NullableReadApiLogsRequest{value: val, isSet: true} +} + +func (v NullableReadApiLogsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadApiLogsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go new file mode 100644 index 000000000..f4d315c87 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go @@ -0,0 +1,190 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadApiLogsResponse struct for ReadApiLogsResponse +type ReadApiLogsResponse struct { + // Information displayed in one or more API logs. + Logs *[]Log `json:"Logs,omitempty"` + // The token to request the next page of results. + NextPageToken *string `json:"NextPageToken,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadApiLogsResponse instantiates a new ReadApiLogsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadApiLogsResponse() *ReadApiLogsResponse { + this := ReadApiLogsResponse{} + return &this +} + +// NewReadApiLogsResponseWithDefaults instantiates a new ReadApiLogsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadApiLogsResponseWithDefaults() *ReadApiLogsResponse { + this := ReadApiLogsResponse{} + return &this +} + +// GetLogs returns the Logs field value if set, zero value otherwise. +func (o *ReadApiLogsResponse) GetLogs() []Log { + if o == nil || o.Logs == nil { + var ret []Log + return ret + } + return *o.Logs +} + +// GetLogsOk returns a tuple with the Logs field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsResponse) GetLogsOk() (*[]Log, bool) { + if o == nil || o.Logs == nil { + return nil, false + } + return o.Logs, true +} + +// HasLogs returns a boolean if a field has been set. +func (o *ReadApiLogsResponse) HasLogs() bool { + if o != nil && o.Logs != nil { + return true + } + + return false +} + +// SetLogs gets a reference to the given []Log and assigns it to the Logs field. +func (o *ReadApiLogsResponse) SetLogs(v []Log) { + o.Logs = &v +} + +// GetNextPageToken returns the NextPageToken field value if set, zero value otherwise. +func (o *ReadApiLogsResponse) GetNextPageToken() string { + if o == nil || o.NextPageToken == nil { + var ret string + return ret + } + return *o.NextPageToken +} + +// GetNextPageTokenOk returns a tuple with the NextPageToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsResponse) GetNextPageTokenOk() (*string, bool) { + if o == nil || o.NextPageToken == nil { + return nil, false + } + return o.NextPageToken, true +} + +// HasNextPageToken returns a boolean if a field has been set. +func (o *ReadApiLogsResponse) HasNextPageToken() bool { + if o != nil && o.NextPageToken != nil { + return true + } + + return false +} + +// SetNextPageToken gets a reference to the given string and assigns it to the NextPageToken field. +func (o *ReadApiLogsResponse) SetNextPageToken(v string) { + o.NextPageToken = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadApiLogsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadApiLogsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadApiLogsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadApiLogsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadApiLogsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Logs != nil { + toSerialize["Logs"] = o.Logs + } + if o.NextPageToken != nil { + toSerialize["NextPageToken"] = o.NextPageToken + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadApiLogsResponse struct { + value *ReadApiLogsResponse + isSet bool +} + +func (v NullableReadApiLogsResponse) Get() *ReadApiLogsResponse { + return v.value +} + +func (v *NullableReadApiLogsResponse) Set(val *ReadApiLogsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadApiLogsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadApiLogsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadApiLogsResponse(val *ReadApiLogsResponse) *NullableReadApiLogsResponse { + return &NullableReadApiLogsResponse{value: val, isSet: true} +} + +func (v NullableReadApiLogsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadApiLogsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go new file mode 100644 index 000000000..c1bc33fac --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadClientGatewaysRequest struct for ReadClientGatewaysRequest +type ReadClientGatewaysRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersClientGateway `json:"Filters,omitempty"` +} + +// NewReadClientGatewaysRequest instantiates a new ReadClientGatewaysRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadClientGatewaysRequest() *ReadClientGatewaysRequest { + this := ReadClientGatewaysRequest{} + return &this +} + +// NewReadClientGatewaysRequestWithDefaults instantiates a new ReadClientGatewaysRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadClientGatewaysRequestWithDefaults() *ReadClientGatewaysRequest { + this := ReadClientGatewaysRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadClientGatewaysRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadClientGatewaysRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadClientGatewaysRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadClientGatewaysRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadClientGatewaysRequest) GetFilters() FiltersClientGateway { + if o == nil || o.Filters == nil { + var ret FiltersClientGateway + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadClientGatewaysRequest) GetFiltersOk() (*FiltersClientGateway, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadClientGatewaysRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersClientGateway and assigns it to the Filters field. +func (o *ReadClientGatewaysRequest) SetFilters(v FiltersClientGateway) { + o.Filters = &v +} + +func (o ReadClientGatewaysRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadClientGatewaysRequest struct { + value *ReadClientGatewaysRequest + isSet bool +} + +func (v NullableReadClientGatewaysRequest) Get() *ReadClientGatewaysRequest { + return v.value +} + +func (v *NullableReadClientGatewaysRequest) Set(val *ReadClientGatewaysRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadClientGatewaysRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadClientGatewaysRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadClientGatewaysRequest(val *ReadClientGatewaysRequest) *NullableReadClientGatewaysRequest { + return &NullableReadClientGatewaysRequest{value: val, isSet: true} +} + +func (v NullableReadClientGatewaysRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadClientGatewaysRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go new file mode 100644 index 000000000..1ff6aa675 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadClientGatewaysResponse struct for ReadClientGatewaysResponse +type ReadClientGatewaysResponse struct { + // Information about one or more client gateways. + ClientGateways *[]ClientGateway `json:"ClientGateways,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadClientGatewaysResponse instantiates a new ReadClientGatewaysResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadClientGatewaysResponse() *ReadClientGatewaysResponse { + this := ReadClientGatewaysResponse{} + return &this +} + +// NewReadClientGatewaysResponseWithDefaults instantiates a new ReadClientGatewaysResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadClientGatewaysResponseWithDefaults() *ReadClientGatewaysResponse { + this := ReadClientGatewaysResponse{} + return &this +} + +// GetClientGateways returns the ClientGateways field value if set, zero value otherwise. +func (o *ReadClientGatewaysResponse) GetClientGateways() []ClientGateway { + if o == nil || o.ClientGateways == nil { + var ret []ClientGateway + return ret + } + return *o.ClientGateways +} + +// GetClientGatewaysOk returns a tuple with the ClientGateways field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadClientGatewaysResponse) GetClientGatewaysOk() (*[]ClientGateway, bool) { + if o == nil || o.ClientGateways == nil { + return nil, false + } + return o.ClientGateways, true +} + +// HasClientGateways returns a boolean if a field has been set. +func (o *ReadClientGatewaysResponse) HasClientGateways() bool { + if o != nil && o.ClientGateways != nil { + return true + } + + return false +} + +// SetClientGateways gets a reference to the given []ClientGateway and assigns it to the ClientGateways field. +func (o *ReadClientGatewaysResponse) SetClientGateways(v []ClientGateway) { + o.ClientGateways = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadClientGatewaysResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadClientGatewaysResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadClientGatewaysResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadClientGatewaysResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadClientGatewaysResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClientGateways != nil { + toSerialize["ClientGateways"] = o.ClientGateways + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadClientGatewaysResponse struct { + value *ReadClientGatewaysResponse + isSet bool +} + +func (v NullableReadClientGatewaysResponse) Get() *ReadClientGatewaysResponse { + return v.value +} + +func (v *NullableReadClientGatewaysResponse) Set(val *ReadClientGatewaysResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadClientGatewaysResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadClientGatewaysResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadClientGatewaysResponse(val *ReadClientGatewaysResponse) *NullableReadClientGatewaysResponse { + return &NullableReadClientGatewaysResponse{value: val, isSet: true} +} + +func (v NullableReadClientGatewaysResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadClientGatewaysResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go new file mode 100644 index 000000000..7e3e305d8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadConsoleOutputRequest struct for ReadConsoleOutputRequest +type ReadConsoleOutputRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the VM. + VmId string `json:"VmId"` +} + +// NewReadConsoleOutputRequest instantiates a new ReadConsoleOutputRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadConsoleOutputRequest(vmId string, ) *ReadConsoleOutputRequest { + this := ReadConsoleOutputRequest{} + this.VmId = vmId + return &this +} + +// NewReadConsoleOutputRequestWithDefaults instantiates a new ReadConsoleOutputRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadConsoleOutputRequestWithDefaults() *ReadConsoleOutputRequest { + this := ReadConsoleOutputRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadConsoleOutputRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsoleOutputRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadConsoleOutputRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadConsoleOutputRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmId returns the VmId field value +func (o *ReadConsoleOutputRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *ReadConsoleOutputRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *ReadConsoleOutputRequest) SetVmId(v string) { + o.VmId = v +} + +func (o ReadConsoleOutputRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableReadConsoleOutputRequest struct { + value *ReadConsoleOutputRequest + isSet bool +} + +func (v NullableReadConsoleOutputRequest) Get() *ReadConsoleOutputRequest { + return v.value +} + +func (v *NullableReadConsoleOutputRequest) Set(val *ReadConsoleOutputRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadConsoleOutputRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadConsoleOutputRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadConsoleOutputRequest(val *ReadConsoleOutputRequest) *NullableReadConsoleOutputRequest { + return &NullableReadConsoleOutputRequest{value: val, isSet: true} +} + +func (v NullableReadConsoleOutputRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadConsoleOutputRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go new file mode 100644 index 000000000..08322e33a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go @@ -0,0 +1,190 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadConsoleOutputResponse struct for ReadConsoleOutputResponse +type ReadConsoleOutputResponse struct { + // The Base64-encoded output of the console. If a command line tool is used, the output is decoded by the tool. + ConsoleOutput *string `json:"ConsoleOutput,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` +} + +// NewReadConsoleOutputResponse instantiates a new ReadConsoleOutputResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadConsoleOutputResponse() *ReadConsoleOutputResponse { + this := ReadConsoleOutputResponse{} + return &this +} + +// NewReadConsoleOutputResponseWithDefaults instantiates a new ReadConsoleOutputResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadConsoleOutputResponseWithDefaults() *ReadConsoleOutputResponse { + this := ReadConsoleOutputResponse{} + return &this +} + +// GetConsoleOutput returns the ConsoleOutput field value if set, zero value otherwise. +func (o *ReadConsoleOutputResponse) GetConsoleOutput() string { + if o == nil || o.ConsoleOutput == nil { + var ret string + return ret + } + return *o.ConsoleOutput +} + +// GetConsoleOutputOk returns a tuple with the ConsoleOutput field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsoleOutputResponse) GetConsoleOutputOk() (*string, bool) { + if o == nil || o.ConsoleOutput == nil { + return nil, false + } + return o.ConsoleOutput, true +} + +// HasConsoleOutput returns a boolean if a field has been set. +func (o *ReadConsoleOutputResponse) HasConsoleOutput() bool { + if o != nil && o.ConsoleOutput != nil { + return true + } + + return false +} + +// SetConsoleOutput gets a reference to the given string and assigns it to the ConsoleOutput field. +func (o *ReadConsoleOutputResponse) SetConsoleOutput(v string) { + o.ConsoleOutput = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadConsoleOutputResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsoleOutputResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadConsoleOutputResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadConsoleOutputResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *ReadConsoleOutputResponse) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsoleOutputResponse) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *ReadConsoleOutputResponse) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *ReadConsoleOutputResponse) SetVmId(v string) { + o.VmId = &v +} + +func (o ReadConsoleOutputResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ConsoleOutput != nil { + toSerialize["ConsoleOutput"] = o.ConsoleOutput + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableReadConsoleOutputResponse struct { + value *ReadConsoleOutputResponse + isSet bool +} + +func (v NullableReadConsoleOutputResponse) Get() *ReadConsoleOutputResponse { + return v.value +} + +func (v *NullableReadConsoleOutputResponse) Set(val *ReadConsoleOutputResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadConsoleOutputResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadConsoleOutputResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadConsoleOutputResponse(val *ReadConsoleOutputResponse) *NullableReadConsoleOutputResponse { + return &NullableReadConsoleOutputResponse{value: val, isSet: true} +} + +func (v NullableReadConsoleOutputResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadConsoleOutputResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go new file mode 100644 index 000000000..140c6fdc4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadConsumptionAccountRequest struct for ReadConsumptionAccountRequest +type ReadConsumptionAccountRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The beginning of the time period, in ISO 8601 date-time format (for example, `2017-06-14` or `2017-06-14T00:00:00Z`). + FromDate string `json:"FromDate"` + // The end of the time period, in ISO 8601 date-time format (for example, `2017-06-30` or `2017-06-30T00:00:00Z`). + ToDate string `json:"ToDate"` +} + +// NewReadConsumptionAccountRequest instantiates a new ReadConsumptionAccountRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadConsumptionAccountRequest(fromDate string, toDate string, ) *ReadConsumptionAccountRequest { + this := ReadConsumptionAccountRequest{} + this.FromDate = fromDate + this.ToDate = toDate + return &this +} + +// NewReadConsumptionAccountRequestWithDefaults instantiates a new ReadConsumptionAccountRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadConsumptionAccountRequestWithDefaults() *ReadConsumptionAccountRequest { + this := ReadConsumptionAccountRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadConsumptionAccountRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsumptionAccountRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadConsumptionAccountRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadConsumptionAccountRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFromDate returns the FromDate field value +func (o *ReadConsumptionAccountRequest) GetFromDate() string { + if o == nil { + var ret string + return ret + } + + return o.FromDate +} + +// GetFromDateOk returns a tuple with the FromDate field value +// and a boolean to check if the value has been set. +func (o *ReadConsumptionAccountRequest) GetFromDateOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FromDate, true +} + +// SetFromDate sets field value +func (o *ReadConsumptionAccountRequest) SetFromDate(v string) { + o.FromDate = v +} + +// GetToDate returns the ToDate field value +func (o *ReadConsumptionAccountRequest) GetToDate() string { + if o == nil { + var ret string + return ret + } + + return o.ToDate +} + +// GetToDateOk returns a tuple with the ToDate field value +// and a boolean to check if the value has been set. +func (o *ReadConsumptionAccountRequest) GetToDateOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ToDate, true +} + +// SetToDate sets field value +func (o *ReadConsumptionAccountRequest) SetToDate(v string) { + o.ToDate = v +} + +func (o ReadConsumptionAccountRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["FromDate"] = o.FromDate + } + if true { + toSerialize["ToDate"] = o.ToDate + } + return json.Marshal(toSerialize) +} + +type NullableReadConsumptionAccountRequest struct { + value *ReadConsumptionAccountRequest + isSet bool +} + +func (v NullableReadConsumptionAccountRequest) Get() *ReadConsumptionAccountRequest { + return v.value +} + +func (v *NullableReadConsumptionAccountRequest) Set(val *ReadConsumptionAccountRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadConsumptionAccountRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadConsumptionAccountRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadConsumptionAccountRequest(val *ReadConsumptionAccountRequest) *NullableReadConsumptionAccountRequest { + return &NullableReadConsumptionAccountRequest{value: val, isSet: true} +} + +func (v NullableReadConsumptionAccountRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadConsumptionAccountRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go new file mode 100644 index 000000000..0ff5a7d2f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadConsumptionAccountResponse struct for ReadConsumptionAccountResponse +type ReadConsumptionAccountResponse struct { + // Information about the resources consumed during the specified time period. + ConsumptionEntries *[]ConsumptionEntry `json:"ConsumptionEntries,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadConsumptionAccountResponse instantiates a new ReadConsumptionAccountResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadConsumptionAccountResponse() *ReadConsumptionAccountResponse { + this := ReadConsumptionAccountResponse{} + return &this +} + +// NewReadConsumptionAccountResponseWithDefaults instantiates a new ReadConsumptionAccountResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadConsumptionAccountResponseWithDefaults() *ReadConsumptionAccountResponse { + this := ReadConsumptionAccountResponse{} + return &this +} + +// GetConsumptionEntries returns the ConsumptionEntries field value if set, zero value otherwise. +func (o *ReadConsumptionAccountResponse) GetConsumptionEntries() []ConsumptionEntry { + if o == nil || o.ConsumptionEntries == nil { + var ret []ConsumptionEntry + return ret + } + return *o.ConsumptionEntries +} + +// GetConsumptionEntriesOk returns a tuple with the ConsumptionEntries field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsumptionAccountResponse) GetConsumptionEntriesOk() (*[]ConsumptionEntry, bool) { + if o == nil || o.ConsumptionEntries == nil { + return nil, false + } + return o.ConsumptionEntries, true +} + +// HasConsumptionEntries returns a boolean if a field has been set. +func (o *ReadConsumptionAccountResponse) HasConsumptionEntries() bool { + if o != nil && o.ConsumptionEntries != nil { + return true + } + + return false +} + +// SetConsumptionEntries gets a reference to the given []ConsumptionEntry and assigns it to the ConsumptionEntries field. +func (o *ReadConsumptionAccountResponse) SetConsumptionEntries(v []ConsumptionEntry) { + o.ConsumptionEntries = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadConsumptionAccountResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadConsumptionAccountResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadConsumptionAccountResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadConsumptionAccountResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadConsumptionAccountResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ConsumptionEntries != nil { + toSerialize["ConsumptionEntries"] = o.ConsumptionEntries + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadConsumptionAccountResponse struct { + value *ReadConsumptionAccountResponse + isSet bool +} + +func (v NullableReadConsumptionAccountResponse) Get() *ReadConsumptionAccountResponse { + return v.value +} + +func (v *NullableReadConsumptionAccountResponse) Set(val *ReadConsumptionAccountResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadConsumptionAccountResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadConsumptionAccountResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadConsumptionAccountResponse(val *ReadConsumptionAccountResponse) *NullableReadConsumptionAccountResponse { + return &NullableReadConsumptionAccountResponse{value: val, isSet: true} +} + +func (v NullableReadConsumptionAccountResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadConsumptionAccountResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go new file mode 100644 index 000000000..6ea45e5e2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDhcpOptionsRequest struct for ReadDhcpOptionsRequest +type ReadDhcpOptionsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersDhcpOptions `json:"Filters,omitempty"` +} + +// NewReadDhcpOptionsRequest instantiates a new ReadDhcpOptionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDhcpOptionsRequest() *ReadDhcpOptionsRequest { + this := ReadDhcpOptionsRequest{} + return &this +} + +// NewReadDhcpOptionsRequestWithDefaults instantiates a new ReadDhcpOptionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDhcpOptionsRequestWithDefaults() *ReadDhcpOptionsRequest { + this := ReadDhcpOptionsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadDhcpOptionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDhcpOptionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadDhcpOptionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadDhcpOptionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadDhcpOptionsRequest) GetFilters() FiltersDhcpOptions { + if o == nil || o.Filters == nil { + var ret FiltersDhcpOptions + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDhcpOptionsRequest) GetFiltersOk() (*FiltersDhcpOptions, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadDhcpOptionsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersDhcpOptions and assigns it to the Filters field. +func (o *ReadDhcpOptionsRequest) SetFilters(v FiltersDhcpOptions) { + o.Filters = &v +} + +func (o ReadDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadDhcpOptionsRequest struct { + value *ReadDhcpOptionsRequest + isSet bool +} + +func (v NullableReadDhcpOptionsRequest) Get() *ReadDhcpOptionsRequest { + return v.value +} + +func (v *NullableReadDhcpOptionsRequest) Set(val *ReadDhcpOptionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadDhcpOptionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDhcpOptionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDhcpOptionsRequest(val *ReadDhcpOptionsRequest) *NullableReadDhcpOptionsRequest { + return &NullableReadDhcpOptionsRequest{value: val, isSet: true} +} + +func (v NullableReadDhcpOptionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDhcpOptionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go new file mode 100644 index 000000000..4cab2e825 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDhcpOptionsResponse struct for ReadDhcpOptionsResponse +type ReadDhcpOptionsResponse struct { + // Information about one or more DHCP options sets. + DhcpOptionsSets *[]DhcpOptionsSet `json:"DhcpOptionsSets,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadDhcpOptionsResponse instantiates a new ReadDhcpOptionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDhcpOptionsResponse() *ReadDhcpOptionsResponse { + this := ReadDhcpOptionsResponse{} + return &this +} + +// NewReadDhcpOptionsResponseWithDefaults instantiates a new ReadDhcpOptionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDhcpOptionsResponseWithDefaults() *ReadDhcpOptionsResponse { + this := ReadDhcpOptionsResponse{} + return &this +} + +// GetDhcpOptionsSets returns the DhcpOptionsSets field value if set, zero value otherwise. +func (o *ReadDhcpOptionsResponse) GetDhcpOptionsSets() []DhcpOptionsSet { + if o == nil || o.DhcpOptionsSets == nil { + var ret []DhcpOptionsSet + return ret + } + return *o.DhcpOptionsSets +} + +// GetDhcpOptionsSetsOk returns a tuple with the DhcpOptionsSets field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDhcpOptionsResponse) GetDhcpOptionsSetsOk() (*[]DhcpOptionsSet, bool) { + if o == nil || o.DhcpOptionsSets == nil { + return nil, false + } + return o.DhcpOptionsSets, true +} + +// HasDhcpOptionsSets returns a boolean if a field has been set. +func (o *ReadDhcpOptionsResponse) HasDhcpOptionsSets() bool { + if o != nil && o.DhcpOptionsSets != nil { + return true + } + + return false +} + +// SetDhcpOptionsSets gets a reference to the given []DhcpOptionsSet and assigns it to the DhcpOptionsSets field. +func (o *ReadDhcpOptionsResponse) SetDhcpOptionsSets(v []DhcpOptionsSet) { + o.DhcpOptionsSets = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadDhcpOptionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDhcpOptionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadDhcpOptionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadDhcpOptionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DhcpOptionsSets != nil { + toSerialize["DhcpOptionsSets"] = o.DhcpOptionsSets + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadDhcpOptionsResponse struct { + value *ReadDhcpOptionsResponse + isSet bool +} + +func (v NullableReadDhcpOptionsResponse) Get() *ReadDhcpOptionsResponse { + return v.value +} + +func (v *NullableReadDhcpOptionsResponse) Set(val *ReadDhcpOptionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadDhcpOptionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDhcpOptionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDhcpOptionsResponse(val *ReadDhcpOptionsResponse) *NullableReadDhcpOptionsResponse { + return &NullableReadDhcpOptionsResponse{value: val, isSet: true} +} + +func (v NullableReadDhcpOptionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDhcpOptionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go new file mode 100644 index 000000000..3e81fcc70 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDirectLinkInterfacesRequest struct for ReadDirectLinkInterfacesRequest +type ReadDirectLinkInterfacesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersDirectLinkInterface `json:"Filters,omitempty"` +} + +// NewReadDirectLinkInterfacesRequest instantiates a new ReadDirectLinkInterfacesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDirectLinkInterfacesRequest() *ReadDirectLinkInterfacesRequest { + this := ReadDirectLinkInterfacesRequest{} + return &this +} + +// NewReadDirectLinkInterfacesRequestWithDefaults instantiates a new ReadDirectLinkInterfacesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDirectLinkInterfacesRequestWithDefaults() *ReadDirectLinkInterfacesRequest { + this := ReadDirectLinkInterfacesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadDirectLinkInterfacesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinkInterfacesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadDirectLinkInterfacesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadDirectLinkInterfacesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadDirectLinkInterfacesRequest) GetFilters() FiltersDirectLinkInterface { + if o == nil || o.Filters == nil { + var ret FiltersDirectLinkInterface + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinkInterfacesRequest) GetFiltersOk() (*FiltersDirectLinkInterface, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadDirectLinkInterfacesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersDirectLinkInterface and assigns it to the Filters field. +func (o *ReadDirectLinkInterfacesRequest) SetFilters(v FiltersDirectLinkInterface) { + o.Filters = &v +} + +func (o ReadDirectLinkInterfacesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadDirectLinkInterfacesRequest struct { + value *ReadDirectLinkInterfacesRequest + isSet bool +} + +func (v NullableReadDirectLinkInterfacesRequest) Get() *ReadDirectLinkInterfacesRequest { + return v.value +} + +func (v *NullableReadDirectLinkInterfacesRequest) Set(val *ReadDirectLinkInterfacesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadDirectLinkInterfacesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDirectLinkInterfacesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDirectLinkInterfacesRequest(val *ReadDirectLinkInterfacesRequest) *NullableReadDirectLinkInterfacesRequest { + return &NullableReadDirectLinkInterfacesRequest{value: val, isSet: true} +} + +func (v NullableReadDirectLinkInterfacesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDirectLinkInterfacesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go new file mode 100644 index 000000000..5bd51d01a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDirectLinkInterfacesResponse struct for ReadDirectLinkInterfacesResponse +type ReadDirectLinkInterfacesResponse struct { + // Information about one or more DirectLink interfaces. + DirectLinkInterfaces *[]DirectLinkInterfaces `json:"DirectLinkInterfaces,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadDirectLinkInterfacesResponse instantiates a new ReadDirectLinkInterfacesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDirectLinkInterfacesResponse() *ReadDirectLinkInterfacesResponse { + this := ReadDirectLinkInterfacesResponse{} + return &this +} + +// NewReadDirectLinkInterfacesResponseWithDefaults instantiates a new ReadDirectLinkInterfacesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDirectLinkInterfacesResponseWithDefaults() *ReadDirectLinkInterfacesResponse { + this := ReadDirectLinkInterfacesResponse{} + return &this +} + +// GetDirectLinkInterfaces returns the DirectLinkInterfaces field value if set, zero value otherwise. +func (o *ReadDirectLinkInterfacesResponse) GetDirectLinkInterfaces() []DirectLinkInterfaces { + if o == nil || o.DirectLinkInterfaces == nil { + var ret []DirectLinkInterfaces + return ret + } + return *o.DirectLinkInterfaces +} + +// GetDirectLinkInterfacesOk returns a tuple with the DirectLinkInterfaces field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinkInterfacesResponse) GetDirectLinkInterfacesOk() (*[]DirectLinkInterfaces, bool) { + if o == nil || o.DirectLinkInterfaces == nil { + return nil, false + } + return o.DirectLinkInterfaces, true +} + +// HasDirectLinkInterfaces returns a boolean if a field has been set. +func (o *ReadDirectLinkInterfacesResponse) HasDirectLinkInterfaces() bool { + if o != nil && o.DirectLinkInterfaces != nil { + return true + } + + return false +} + +// SetDirectLinkInterfaces gets a reference to the given []DirectLinkInterfaces and assigns it to the DirectLinkInterfaces field. +func (o *ReadDirectLinkInterfacesResponse) SetDirectLinkInterfaces(v []DirectLinkInterfaces) { + o.DirectLinkInterfaces = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadDirectLinkInterfacesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinkInterfacesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadDirectLinkInterfacesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadDirectLinkInterfacesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadDirectLinkInterfacesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLinkInterfaces != nil { + toSerialize["DirectLinkInterfaces"] = o.DirectLinkInterfaces + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadDirectLinkInterfacesResponse struct { + value *ReadDirectLinkInterfacesResponse + isSet bool +} + +func (v NullableReadDirectLinkInterfacesResponse) Get() *ReadDirectLinkInterfacesResponse { + return v.value +} + +func (v *NullableReadDirectLinkInterfacesResponse) Set(val *ReadDirectLinkInterfacesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadDirectLinkInterfacesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDirectLinkInterfacesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDirectLinkInterfacesResponse(val *ReadDirectLinkInterfacesResponse) *NullableReadDirectLinkInterfacesResponse { + return &NullableReadDirectLinkInterfacesResponse{value: val, isSet: true} +} + +func (v NullableReadDirectLinkInterfacesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDirectLinkInterfacesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go new file mode 100644 index 000000000..05d65c7d3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDirectLinksRequest struct for ReadDirectLinksRequest +type ReadDirectLinksRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersDirectLink `json:"Filters,omitempty"` +} + +// NewReadDirectLinksRequest instantiates a new ReadDirectLinksRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDirectLinksRequest() *ReadDirectLinksRequest { + this := ReadDirectLinksRequest{} + return &this +} + +// NewReadDirectLinksRequestWithDefaults instantiates a new ReadDirectLinksRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDirectLinksRequestWithDefaults() *ReadDirectLinksRequest { + this := ReadDirectLinksRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadDirectLinksRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinksRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadDirectLinksRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadDirectLinksRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadDirectLinksRequest) GetFilters() FiltersDirectLink { + if o == nil || o.Filters == nil { + var ret FiltersDirectLink + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinksRequest) GetFiltersOk() (*FiltersDirectLink, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadDirectLinksRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersDirectLink and assigns it to the Filters field. +func (o *ReadDirectLinksRequest) SetFilters(v FiltersDirectLink) { + o.Filters = &v +} + +func (o ReadDirectLinksRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadDirectLinksRequest struct { + value *ReadDirectLinksRequest + isSet bool +} + +func (v NullableReadDirectLinksRequest) Get() *ReadDirectLinksRequest { + return v.value +} + +func (v *NullableReadDirectLinksRequest) Set(val *ReadDirectLinksRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadDirectLinksRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDirectLinksRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDirectLinksRequest(val *ReadDirectLinksRequest) *NullableReadDirectLinksRequest { + return &NullableReadDirectLinksRequest{value: val, isSet: true} +} + +func (v NullableReadDirectLinksRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDirectLinksRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go new file mode 100644 index 000000000..52ead4e2f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadDirectLinksResponse struct for ReadDirectLinksResponse +type ReadDirectLinksResponse struct { + // Information about one or more DirectLinks. + DirectLinks *[]DirectLink `json:"DirectLinks,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadDirectLinksResponse instantiates a new ReadDirectLinksResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadDirectLinksResponse() *ReadDirectLinksResponse { + this := ReadDirectLinksResponse{} + return &this +} + +// NewReadDirectLinksResponseWithDefaults instantiates a new ReadDirectLinksResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadDirectLinksResponseWithDefaults() *ReadDirectLinksResponse { + this := ReadDirectLinksResponse{} + return &this +} + +// GetDirectLinks returns the DirectLinks field value if set, zero value otherwise. +func (o *ReadDirectLinksResponse) GetDirectLinks() []DirectLink { + if o == nil || o.DirectLinks == nil { + var ret []DirectLink + return ret + } + return *o.DirectLinks +} + +// GetDirectLinksOk returns a tuple with the DirectLinks field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinksResponse) GetDirectLinksOk() (*[]DirectLink, bool) { + if o == nil || o.DirectLinks == nil { + return nil, false + } + return o.DirectLinks, true +} + +// HasDirectLinks returns a boolean if a field has been set. +func (o *ReadDirectLinksResponse) HasDirectLinks() bool { + if o != nil && o.DirectLinks != nil { + return true + } + + return false +} + +// SetDirectLinks gets a reference to the given []DirectLink and assigns it to the DirectLinks field. +func (o *ReadDirectLinksResponse) SetDirectLinks(v []DirectLink) { + o.DirectLinks = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadDirectLinksResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadDirectLinksResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadDirectLinksResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadDirectLinksResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadDirectLinksResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DirectLinks != nil { + toSerialize["DirectLinks"] = o.DirectLinks + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadDirectLinksResponse struct { + value *ReadDirectLinksResponse + isSet bool +} + +func (v NullableReadDirectLinksResponse) Get() *ReadDirectLinksResponse { + return v.value +} + +func (v *NullableReadDirectLinksResponse) Set(val *ReadDirectLinksResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadDirectLinksResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadDirectLinksResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadDirectLinksResponse(val *ReadDirectLinksResponse) *NullableReadDirectLinksResponse { + return &NullableReadDirectLinksResponse{value: val, isSet: true} +} + +func (v NullableReadDirectLinksResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadDirectLinksResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go new file mode 100644 index 000000000..6bd8c9fd5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadFlexibleGpuCatalogRequest struct for ReadFlexibleGpuCatalogRequest +type ReadFlexibleGpuCatalogRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadFlexibleGpuCatalogRequest instantiates a new ReadFlexibleGpuCatalogRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadFlexibleGpuCatalogRequest() *ReadFlexibleGpuCatalogRequest { + this := ReadFlexibleGpuCatalogRequest{} + return &this +} + +// NewReadFlexibleGpuCatalogRequestWithDefaults instantiates a new ReadFlexibleGpuCatalogRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadFlexibleGpuCatalogRequestWithDefaults() *ReadFlexibleGpuCatalogRequest { + this := ReadFlexibleGpuCatalogRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadFlexibleGpuCatalogRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpuCatalogRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadFlexibleGpuCatalogRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadFlexibleGpuCatalogRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadFlexibleGpuCatalogRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadFlexibleGpuCatalogRequest struct { + value *ReadFlexibleGpuCatalogRequest + isSet bool +} + +func (v NullableReadFlexibleGpuCatalogRequest) Get() *ReadFlexibleGpuCatalogRequest { + return v.value +} + +func (v *NullableReadFlexibleGpuCatalogRequest) Set(val *ReadFlexibleGpuCatalogRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadFlexibleGpuCatalogRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadFlexibleGpuCatalogRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadFlexibleGpuCatalogRequest(val *ReadFlexibleGpuCatalogRequest) *NullableReadFlexibleGpuCatalogRequest { + return &NullableReadFlexibleGpuCatalogRequest{value: val, isSet: true} +} + +func (v NullableReadFlexibleGpuCatalogRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadFlexibleGpuCatalogRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go new file mode 100644 index 000000000..6ecddabf3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadFlexibleGpuCatalogResponse struct for ReadFlexibleGpuCatalogResponse +type ReadFlexibleGpuCatalogResponse struct { + // Information about one or more fGPUs available in the public catalog. + FlexibleGpuCatalog *[]FlexibleGpuCatalog `json:"FlexibleGpuCatalog,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadFlexibleGpuCatalogResponse instantiates a new ReadFlexibleGpuCatalogResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadFlexibleGpuCatalogResponse() *ReadFlexibleGpuCatalogResponse { + this := ReadFlexibleGpuCatalogResponse{} + return &this +} + +// NewReadFlexibleGpuCatalogResponseWithDefaults instantiates a new ReadFlexibleGpuCatalogResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadFlexibleGpuCatalogResponseWithDefaults() *ReadFlexibleGpuCatalogResponse { + this := ReadFlexibleGpuCatalogResponse{} + return &this +} + +// GetFlexibleGpuCatalog returns the FlexibleGpuCatalog field value if set, zero value otherwise. +func (o *ReadFlexibleGpuCatalogResponse) GetFlexibleGpuCatalog() []FlexibleGpuCatalog { + if o == nil || o.FlexibleGpuCatalog == nil { + var ret []FlexibleGpuCatalog + return ret + } + return *o.FlexibleGpuCatalog +} + +// GetFlexibleGpuCatalogOk returns a tuple with the FlexibleGpuCatalog field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpuCatalogResponse) GetFlexibleGpuCatalogOk() (*[]FlexibleGpuCatalog, bool) { + if o == nil || o.FlexibleGpuCatalog == nil { + return nil, false + } + return o.FlexibleGpuCatalog, true +} + +// HasFlexibleGpuCatalog returns a boolean if a field has been set. +func (o *ReadFlexibleGpuCatalogResponse) HasFlexibleGpuCatalog() bool { + if o != nil && o.FlexibleGpuCatalog != nil { + return true + } + + return false +} + +// SetFlexibleGpuCatalog gets a reference to the given []FlexibleGpuCatalog and assigns it to the FlexibleGpuCatalog field. +func (o *ReadFlexibleGpuCatalogResponse) SetFlexibleGpuCatalog(v []FlexibleGpuCatalog) { + o.FlexibleGpuCatalog = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadFlexibleGpuCatalogResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpuCatalogResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadFlexibleGpuCatalogResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadFlexibleGpuCatalogResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadFlexibleGpuCatalogResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.FlexibleGpuCatalog != nil { + toSerialize["FlexibleGpuCatalog"] = o.FlexibleGpuCatalog + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadFlexibleGpuCatalogResponse struct { + value *ReadFlexibleGpuCatalogResponse + isSet bool +} + +func (v NullableReadFlexibleGpuCatalogResponse) Get() *ReadFlexibleGpuCatalogResponse { + return v.value +} + +func (v *NullableReadFlexibleGpuCatalogResponse) Set(val *ReadFlexibleGpuCatalogResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadFlexibleGpuCatalogResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadFlexibleGpuCatalogResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadFlexibleGpuCatalogResponse(val *ReadFlexibleGpuCatalogResponse) *NullableReadFlexibleGpuCatalogResponse { + return &NullableReadFlexibleGpuCatalogResponse{value: val, isSet: true} +} + +func (v NullableReadFlexibleGpuCatalogResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadFlexibleGpuCatalogResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go new file mode 100644 index 000000000..79c9c492b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadFlexibleGpusRequest struct for ReadFlexibleGpusRequest +type ReadFlexibleGpusRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersFlexibleGpu `json:"Filters,omitempty"` +} + +// NewReadFlexibleGpusRequest instantiates a new ReadFlexibleGpusRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadFlexibleGpusRequest() *ReadFlexibleGpusRequest { + this := ReadFlexibleGpusRequest{} + return &this +} + +// NewReadFlexibleGpusRequestWithDefaults instantiates a new ReadFlexibleGpusRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadFlexibleGpusRequestWithDefaults() *ReadFlexibleGpusRequest { + this := ReadFlexibleGpusRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadFlexibleGpusRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpusRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadFlexibleGpusRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadFlexibleGpusRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadFlexibleGpusRequest) GetFilters() FiltersFlexibleGpu { + if o == nil || o.Filters == nil { + var ret FiltersFlexibleGpu + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpusRequest) GetFiltersOk() (*FiltersFlexibleGpu, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadFlexibleGpusRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersFlexibleGpu and assigns it to the Filters field. +func (o *ReadFlexibleGpusRequest) SetFilters(v FiltersFlexibleGpu) { + o.Filters = &v +} + +func (o ReadFlexibleGpusRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadFlexibleGpusRequest struct { + value *ReadFlexibleGpusRequest + isSet bool +} + +func (v NullableReadFlexibleGpusRequest) Get() *ReadFlexibleGpusRequest { + return v.value +} + +func (v *NullableReadFlexibleGpusRequest) Set(val *ReadFlexibleGpusRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadFlexibleGpusRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadFlexibleGpusRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadFlexibleGpusRequest(val *ReadFlexibleGpusRequest) *NullableReadFlexibleGpusRequest { + return &NullableReadFlexibleGpusRequest{value: val, isSet: true} +} + +func (v NullableReadFlexibleGpusRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadFlexibleGpusRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go new file mode 100644 index 000000000..72a25b19b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadFlexibleGpusResponse struct for ReadFlexibleGpusResponse +type ReadFlexibleGpusResponse struct { + // Information about one or more fGPUs. + FlexibleGpus *[]FlexibleGpu `json:"FlexibleGpus,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadFlexibleGpusResponse instantiates a new ReadFlexibleGpusResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadFlexibleGpusResponse() *ReadFlexibleGpusResponse { + this := ReadFlexibleGpusResponse{} + return &this +} + +// NewReadFlexibleGpusResponseWithDefaults instantiates a new ReadFlexibleGpusResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadFlexibleGpusResponseWithDefaults() *ReadFlexibleGpusResponse { + this := ReadFlexibleGpusResponse{} + return &this +} + +// GetFlexibleGpus returns the FlexibleGpus field value if set, zero value otherwise. +func (o *ReadFlexibleGpusResponse) GetFlexibleGpus() []FlexibleGpu { + if o == nil || o.FlexibleGpus == nil { + var ret []FlexibleGpu + return ret + } + return *o.FlexibleGpus +} + +// GetFlexibleGpusOk returns a tuple with the FlexibleGpus field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpusResponse) GetFlexibleGpusOk() (*[]FlexibleGpu, bool) { + if o == nil || o.FlexibleGpus == nil { + return nil, false + } + return o.FlexibleGpus, true +} + +// HasFlexibleGpus returns a boolean if a field has been set. +func (o *ReadFlexibleGpusResponse) HasFlexibleGpus() bool { + if o != nil && o.FlexibleGpus != nil { + return true + } + + return false +} + +// SetFlexibleGpus gets a reference to the given []FlexibleGpu and assigns it to the FlexibleGpus field. +func (o *ReadFlexibleGpusResponse) SetFlexibleGpus(v []FlexibleGpu) { + o.FlexibleGpus = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadFlexibleGpusResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadFlexibleGpusResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadFlexibleGpusResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadFlexibleGpusResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadFlexibleGpusResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.FlexibleGpus != nil { + toSerialize["FlexibleGpus"] = o.FlexibleGpus + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadFlexibleGpusResponse struct { + value *ReadFlexibleGpusResponse + isSet bool +} + +func (v NullableReadFlexibleGpusResponse) Get() *ReadFlexibleGpusResponse { + return v.value +} + +func (v *NullableReadFlexibleGpusResponse) Set(val *ReadFlexibleGpusResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadFlexibleGpusResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadFlexibleGpusResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadFlexibleGpusResponse(val *ReadFlexibleGpusResponse) *NullableReadFlexibleGpusResponse { + return &NullableReadFlexibleGpusResponse{value: val, isSet: true} +} + +func (v NullableReadFlexibleGpusResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadFlexibleGpusResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go new file mode 100644 index 000000000..8e293f315 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadImageExportTasksRequest struct for ReadImageExportTasksRequest +type ReadImageExportTasksRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersExportTask `json:"Filters,omitempty"` +} + +// NewReadImageExportTasksRequest instantiates a new ReadImageExportTasksRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadImageExportTasksRequest() *ReadImageExportTasksRequest { + this := ReadImageExportTasksRequest{} + return &this +} + +// NewReadImageExportTasksRequestWithDefaults instantiates a new ReadImageExportTasksRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadImageExportTasksRequestWithDefaults() *ReadImageExportTasksRequest { + this := ReadImageExportTasksRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadImageExportTasksRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImageExportTasksRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadImageExportTasksRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadImageExportTasksRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadImageExportTasksRequest) GetFilters() FiltersExportTask { + if o == nil || o.Filters == nil { + var ret FiltersExportTask + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImageExportTasksRequest) GetFiltersOk() (*FiltersExportTask, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadImageExportTasksRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersExportTask and assigns it to the Filters field. +func (o *ReadImageExportTasksRequest) SetFilters(v FiltersExportTask) { + o.Filters = &v +} + +func (o ReadImageExportTasksRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadImageExportTasksRequest struct { + value *ReadImageExportTasksRequest + isSet bool +} + +func (v NullableReadImageExportTasksRequest) Get() *ReadImageExportTasksRequest { + return v.value +} + +func (v *NullableReadImageExportTasksRequest) Set(val *ReadImageExportTasksRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadImageExportTasksRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadImageExportTasksRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadImageExportTasksRequest(val *ReadImageExportTasksRequest) *NullableReadImageExportTasksRequest { + return &NullableReadImageExportTasksRequest{value: val, isSet: true} +} + +func (v NullableReadImageExportTasksRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadImageExportTasksRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go new file mode 100644 index 000000000..992f212ef --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadImageExportTasksResponse struct for ReadImageExportTasksResponse +type ReadImageExportTasksResponse struct { + // Information about one or more image export tasks. + ImageExportTasks *[]ImageExportTask `json:"ImageExportTasks,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadImageExportTasksResponse instantiates a new ReadImageExportTasksResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadImageExportTasksResponse() *ReadImageExportTasksResponse { + this := ReadImageExportTasksResponse{} + return &this +} + +// NewReadImageExportTasksResponseWithDefaults instantiates a new ReadImageExportTasksResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadImageExportTasksResponseWithDefaults() *ReadImageExportTasksResponse { + this := ReadImageExportTasksResponse{} + return &this +} + +// GetImageExportTasks returns the ImageExportTasks field value if set, zero value otherwise. +func (o *ReadImageExportTasksResponse) GetImageExportTasks() []ImageExportTask { + if o == nil || o.ImageExportTasks == nil { + var ret []ImageExportTask + return ret + } + return *o.ImageExportTasks +} + +// GetImageExportTasksOk returns a tuple with the ImageExportTasks field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImageExportTasksResponse) GetImageExportTasksOk() (*[]ImageExportTask, bool) { + if o == nil || o.ImageExportTasks == nil { + return nil, false + } + return o.ImageExportTasks, true +} + +// HasImageExportTasks returns a boolean if a field has been set. +func (o *ReadImageExportTasksResponse) HasImageExportTasks() bool { + if o != nil && o.ImageExportTasks != nil { + return true + } + + return false +} + +// SetImageExportTasks gets a reference to the given []ImageExportTask and assigns it to the ImageExportTasks field. +func (o *ReadImageExportTasksResponse) SetImageExportTasks(v []ImageExportTask) { + o.ImageExportTasks = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadImageExportTasksResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImageExportTasksResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadImageExportTasksResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadImageExportTasksResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadImageExportTasksResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ImageExportTasks != nil { + toSerialize["ImageExportTasks"] = o.ImageExportTasks + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadImageExportTasksResponse struct { + value *ReadImageExportTasksResponse + isSet bool +} + +func (v NullableReadImageExportTasksResponse) Get() *ReadImageExportTasksResponse { + return v.value +} + +func (v *NullableReadImageExportTasksResponse) Set(val *ReadImageExportTasksResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadImageExportTasksResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadImageExportTasksResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadImageExportTasksResponse(val *ReadImageExportTasksResponse) *NullableReadImageExportTasksResponse { + return &NullableReadImageExportTasksResponse{value: val, isSet: true} +} + +func (v NullableReadImageExportTasksResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadImageExportTasksResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go new file mode 100644 index 000000000..2a4b56602 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadImagesRequest struct for ReadImagesRequest +type ReadImagesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersImage `json:"Filters,omitempty"` +} + +// NewReadImagesRequest instantiates a new ReadImagesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadImagesRequest() *ReadImagesRequest { + this := ReadImagesRequest{} + return &this +} + +// NewReadImagesRequestWithDefaults instantiates a new ReadImagesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadImagesRequestWithDefaults() *ReadImagesRequest { + this := ReadImagesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadImagesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImagesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadImagesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadImagesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadImagesRequest) GetFilters() FiltersImage { + if o == nil || o.Filters == nil { + var ret FiltersImage + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImagesRequest) GetFiltersOk() (*FiltersImage, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadImagesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersImage and assigns it to the Filters field. +func (o *ReadImagesRequest) SetFilters(v FiltersImage) { + o.Filters = &v +} + +func (o ReadImagesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadImagesRequest struct { + value *ReadImagesRequest + isSet bool +} + +func (v NullableReadImagesRequest) Get() *ReadImagesRequest { + return v.value +} + +func (v *NullableReadImagesRequest) Set(val *ReadImagesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadImagesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadImagesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadImagesRequest(val *ReadImagesRequest) *NullableReadImagesRequest { + return &NullableReadImagesRequest{value: val, isSet: true} +} + +func (v NullableReadImagesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadImagesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go new file mode 100644 index 000000000..a499536ae --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadImagesResponse struct for ReadImagesResponse +type ReadImagesResponse struct { + // Information about one or more OMIs. + Images *[]Image `json:"Images,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadImagesResponse instantiates a new ReadImagesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadImagesResponse() *ReadImagesResponse { + this := ReadImagesResponse{} + return &this +} + +// NewReadImagesResponseWithDefaults instantiates a new ReadImagesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadImagesResponseWithDefaults() *ReadImagesResponse { + this := ReadImagesResponse{} + return &this +} + +// GetImages returns the Images field value if set, zero value otherwise. +func (o *ReadImagesResponse) GetImages() []Image { + if o == nil || o.Images == nil { + var ret []Image + return ret + } + return *o.Images +} + +// GetImagesOk returns a tuple with the Images field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImagesResponse) GetImagesOk() (*[]Image, bool) { + if o == nil || o.Images == nil { + return nil, false + } + return o.Images, true +} + +// HasImages returns a boolean if a field has been set. +func (o *ReadImagesResponse) HasImages() bool { + if o != nil && o.Images != nil { + return true + } + + return false +} + +// SetImages gets a reference to the given []Image and assigns it to the Images field. +func (o *ReadImagesResponse) SetImages(v []Image) { + o.Images = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadImagesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadImagesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadImagesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadImagesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadImagesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Images != nil { + toSerialize["Images"] = o.Images + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadImagesResponse struct { + value *ReadImagesResponse + isSet bool +} + +func (v NullableReadImagesResponse) Get() *ReadImagesResponse { + return v.value +} + +func (v *NullableReadImagesResponse) Set(val *ReadImagesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadImagesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadImagesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadImagesResponse(val *ReadImagesResponse) *NullableReadImagesResponse { + return &NullableReadImagesResponse{value: val, isSet: true} +} + +func (v NullableReadImagesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadImagesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go new file mode 100644 index 000000000..0935fbff7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadInternetServicesRequest struct for ReadInternetServicesRequest +type ReadInternetServicesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersInternetService `json:"Filters,omitempty"` +} + +// NewReadInternetServicesRequest instantiates a new ReadInternetServicesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadInternetServicesRequest() *ReadInternetServicesRequest { + this := ReadInternetServicesRequest{} + return &this +} + +// NewReadInternetServicesRequestWithDefaults instantiates a new ReadInternetServicesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadInternetServicesRequestWithDefaults() *ReadInternetServicesRequest { + this := ReadInternetServicesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadInternetServicesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadInternetServicesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadInternetServicesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadInternetServicesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadInternetServicesRequest) GetFilters() FiltersInternetService { + if o == nil || o.Filters == nil { + var ret FiltersInternetService + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadInternetServicesRequest) GetFiltersOk() (*FiltersInternetService, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadInternetServicesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersInternetService and assigns it to the Filters field. +func (o *ReadInternetServicesRequest) SetFilters(v FiltersInternetService) { + o.Filters = &v +} + +func (o ReadInternetServicesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadInternetServicesRequest struct { + value *ReadInternetServicesRequest + isSet bool +} + +func (v NullableReadInternetServicesRequest) Get() *ReadInternetServicesRequest { + return v.value +} + +func (v *NullableReadInternetServicesRequest) Set(val *ReadInternetServicesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadInternetServicesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadInternetServicesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadInternetServicesRequest(val *ReadInternetServicesRequest) *NullableReadInternetServicesRequest { + return &NullableReadInternetServicesRequest{value: val, isSet: true} +} + +func (v NullableReadInternetServicesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadInternetServicesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go new file mode 100644 index 000000000..b4a974120 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadInternetServicesResponse struct for ReadInternetServicesResponse +type ReadInternetServicesResponse struct { + // Information about one or more Internet services. + InternetServices *[]InternetService `json:"InternetServices,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadInternetServicesResponse instantiates a new ReadInternetServicesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadInternetServicesResponse() *ReadInternetServicesResponse { + this := ReadInternetServicesResponse{} + return &this +} + +// NewReadInternetServicesResponseWithDefaults instantiates a new ReadInternetServicesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadInternetServicesResponseWithDefaults() *ReadInternetServicesResponse { + this := ReadInternetServicesResponse{} + return &this +} + +// GetInternetServices returns the InternetServices field value if set, zero value otherwise. +func (o *ReadInternetServicesResponse) GetInternetServices() []InternetService { + if o == nil || o.InternetServices == nil { + var ret []InternetService + return ret + } + return *o.InternetServices +} + +// GetInternetServicesOk returns a tuple with the InternetServices field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadInternetServicesResponse) GetInternetServicesOk() (*[]InternetService, bool) { + if o == nil || o.InternetServices == nil { + return nil, false + } + return o.InternetServices, true +} + +// HasInternetServices returns a boolean if a field has been set. +func (o *ReadInternetServicesResponse) HasInternetServices() bool { + if o != nil && o.InternetServices != nil { + return true + } + + return false +} + +// SetInternetServices gets a reference to the given []InternetService and assigns it to the InternetServices field. +func (o *ReadInternetServicesResponse) SetInternetServices(v []InternetService) { + o.InternetServices = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadInternetServicesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadInternetServicesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadInternetServicesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadInternetServicesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadInternetServicesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.InternetServices != nil { + toSerialize["InternetServices"] = o.InternetServices + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadInternetServicesResponse struct { + value *ReadInternetServicesResponse + isSet bool +} + +func (v NullableReadInternetServicesResponse) Get() *ReadInternetServicesResponse { + return v.value +} + +func (v *NullableReadInternetServicesResponse) Set(val *ReadInternetServicesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadInternetServicesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadInternetServicesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadInternetServicesResponse(val *ReadInternetServicesResponse) *NullableReadInternetServicesResponse { + return &NullableReadInternetServicesResponse{value: val, isSet: true} +} + +func (v NullableReadInternetServicesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadInternetServicesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go new file mode 100644 index 000000000..aa62b8754 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadKeypairsRequest struct for ReadKeypairsRequest +type ReadKeypairsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersKeypair `json:"Filters,omitempty"` +} + +// NewReadKeypairsRequest instantiates a new ReadKeypairsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadKeypairsRequest() *ReadKeypairsRequest { + this := ReadKeypairsRequest{} + return &this +} + +// NewReadKeypairsRequestWithDefaults instantiates a new ReadKeypairsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadKeypairsRequestWithDefaults() *ReadKeypairsRequest { + this := ReadKeypairsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadKeypairsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadKeypairsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadKeypairsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadKeypairsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadKeypairsRequest) GetFilters() FiltersKeypair { + if o == nil || o.Filters == nil { + var ret FiltersKeypair + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadKeypairsRequest) GetFiltersOk() (*FiltersKeypair, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadKeypairsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersKeypair and assigns it to the Filters field. +func (o *ReadKeypairsRequest) SetFilters(v FiltersKeypair) { + o.Filters = &v +} + +func (o ReadKeypairsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadKeypairsRequest struct { + value *ReadKeypairsRequest + isSet bool +} + +func (v NullableReadKeypairsRequest) Get() *ReadKeypairsRequest { + return v.value +} + +func (v *NullableReadKeypairsRequest) Set(val *ReadKeypairsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadKeypairsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadKeypairsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadKeypairsRequest(val *ReadKeypairsRequest) *NullableReadKeypairsRequest { + return &NullableReadKeypairsRequest{value: val, isSet: true} +} + +func (v NullableReadKeypairsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadKeypairsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go new file mode 100644 index 000000000..44ac6f2f6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadKeypairsResponse struct for ReadKeypairsResponse +type ReadKeypairsResponse struct { + // Information about one or more keypairs. + Keypairs *[]Keypair `json:"Keypairs,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadKeypairsResponse instantiates a new ReadKeypairsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadKeypairsResponse() *ReadKeypairsResponse { + this := ReadKeypairsResponse{} + return &this +} + +// NewReadKeypairsResponseWithDefaults instantiates a new ReadKeypairsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadKeypairsResponseWithDefaults() *ReadKeypairsResponse { + this := ReadKeypairsResponse{} + return &this +} + +// GetKeypairs returns the Keypairs field value if set, zero value otherwise. +func (o *ReadKeypairsResponse) GetKeypairs() []Keypair { + if o == nil || o.Keypairs == nil { + var ret []Keypair + return ret + } + return *o.Keypairs +} + +// GetKeypairsOk returns a tuple with the Keypairs field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadKeypairsResponse) GetKeypairsOk() (*[]Keypair, bool) { + if o == nil || o.Keypairs == nil { + return nil, false + } + return o.Keypairs, true +} + +// HasKeypairs returns a boolean if a field has been set. +func (o *ReadKeypairsResponse) HasKeypairs() bool { + if o != nil && o.Keypairs != nil { + return true + } + + return false +} + +// SetKeypairs gets a reference to the given []Keypair and assigns it to the Keypairs field. +func (o *ReadKeypairsResponse) SetKeypairs(v []Keypair) { + o.Keypairs = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadKeypairsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadKeypairsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadKeypairsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadKeypairsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadKeypairsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Keypairs != nil { + toSerialize["Keypairs"] = o.Keypairs + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadKeypairsResponse struct { + value *ReadKeypairsResponse + isSet bool +} + +func (v NullableReadKeypairsResponse) Get() *ReadKeypairsResponse { + return v.value +} + +func (v *NullableReadKeypairsResponse) Set(val *ReadKeypairsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadKeypairsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadKeypairsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadKeypairsResponse(val *ReadKeypairsResponse) *NullableReadKeypairsResponse { + return &NullableReadKeypairsResponse{value: val, isSet: true} +} + +func (v NullableReadKeypairsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadKeypairsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go new file mode 100644 index 000000000..1cbee21a1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadListenerRulesRequest struct for ReadListenerRulesRequest +type ReadListenerRulesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersListenerRule `json:"Filters,omitempty"` +} + +// NewReadListenerRulesRequest instantiates a new ReadListenerRulesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadListenerRulesRequest() *ReadListenerRulesRequest { + this := ReadListenerRulesRequest{} + return &this +} + +// NewReadListenerRulesRequestWithDefaults instantiates a new ReadListenerRulesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadListenerRulesRequestWithDefaults() *ReadListenerRulesRequest { + this := ReadListenerRulesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadListenerRulesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadListenerRulesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadListenerRulesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadListenerRulesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadListenerRulesRequest) GetFilters() FiltersListenerRule { + if o == nil || o.Filters == nil { + var ret FiltersListenerRule + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadListenerRulesRequest) GetFiltersOk() (*FiltersListenerRule, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadListenerRulesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersListenerRule and assigns it to the Filters field. +func (o *ReadListenerRulesRequest) SetFilters(v FiltersListenerRule) { + o.Filters = &v +} + +func (o ReadListenerRulesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadListenerRulesRequest struct { + value *ReadListenerRulesRequest + isSet bool +} + +func (v NullableReadListenerRulesRequest) Get() *ReadListenerRulesRequest { + return v.value +} + +func (v *NullableReadListenerRulesRequest) Set(val *ReadListenerRulesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadListenerRulesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadListenerRulesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadListenerRulesRequest(val *ReadListenerRulesRequest) *NullableReadListenerRulesRequest { + return &NullableReadListenerRulesRequest{value: val, isSet: true} +} + +func (v NullableReadListenerRulesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadListenerRulesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go new file mode 100644 index 000000000..ec476cda6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadListenerRulesResponse struct for ReadListenerRulesResponse +type ReadListenerRulesResponse struct { + // The list of the rules to describe. + ListenerRules *[]ListenerRule `json:"ListenerRules,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadListenerRulesResponse instantiates a new ReadListenerRulesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadListenerRulesResponse() *ReadListenerRulesResponse { + this := ReadListenerRulesResponse{} + return &this +} + +// NewReadListenerRulesResponseWithDefaults instantiates a new ReadListenerRulesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadListenerRulesResponseWithDefaults() *ReadListenerRulesResponse { + this := ReadListenerRulesResponse{} + return &this +} + +// GetListenerRules returns the ListenerRules field value if set, zero value otherwise. +func (o *ReadListenerRulesResponse) GetListenerRules() []ListenerRule { + if o == nil || o.ListenerRules == nil { + var ret []ListenerRule + return ret + } + return *o.ListenerRules +} + +// GetListenerRulesOk returns a tuple with the ListenerRules field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadListenerRulesResponse) GetListenerRulesOk() (*[]ListenerRule, bool) { + if o == nil || o.ListenerRules == nil { + return nil, false + } + return o.ListenerRules, true +} + +// HasListenerRules returns a boolean if a field has been set. +func (o *ReadListenerRulesResponse) HasListenerRules() bool { + if o != nil && o.ListenerRules != nil { + return true + } + + return false +} + +// SetListenerRules gets a reference to the given []ListenerRule and assigns it to the ListenerRules field. +func (o *ReadListenerRulesResponse) SetListenerRules(v []ListenerRule) { + o.ListenerRules = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadListenerRulesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadListenerRulesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadListenerRulesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadListenerRulesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadListenerRulesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ListenerRules != nil { + toSerialize["ListenerRules"] = o.ListenerRules + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadListenerRulesResponse struct { + value *ReadListenerRulesResponse + isSet bool +} + +func (v NullableReadListenerRulesResponse) Get() *ReadListenerRulesResponse { + return v.value +} + +func (v *NullableReadListenerRulesResponse) Set(val *ReadListenerRulesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadListenerRulesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadListenerRulesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadListenerRulesResponse(val *ReadListenerRulesResponse) *NullableReadListenerRulesResponse { + return &NullableReadListenerRulesResponse{value: val, isSet: true} +} + +func (v NullableReadListenerRulesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadListenerRulesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go new file mode 100644 index 000000000..79ca2fffd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLoadBalancerTagsRequest struct for ReadLoadBalancerTagsRequest +type ReadLoadBalancerTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more load balancer names. + LoadBalancerNames []string `json:"LoadBalancerNames"` +} + +// NewReadLoadBalancerTagsRequest instantiates a new ReadLoadBalancerTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLoadBalancerTagsRequest(loadBalancerNames []string, ) *ReadLoadBalancerTagsRequest { + this := ReadLoadBalancerTagsRequest{} + this.LoadBalancerNames = loadBalancerNames + return &this +} + +// NewReadLoadBalancerTagsRequestWithDefaults instantiates a new ReadLoadBalancerTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLoadBalancerTagsRequestWithDefaults() *ReadLoadBalancerTagsRequest { + this := ReadLoadBalancerTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadLoadBalancerTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancerTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadLoadBalancerTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadLoadBalancerTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerNames returns the LoadBalancerNames field value +func (o *ReadLoadBalancerTagsRequest) GetLoadBalancerNames() []string { + if o == nil { + var ret []string + return ret + } + + return o.LoadBalancerNames +} + +// GetLoadBalancerNamesOk returns a tuple with the LoadBalancerNames field value +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancerTagsRequest) GetLoadBalancerNamesOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerNames, true +} + +// SetLoadBalancerNames sets field value +func (o *ReadLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { + o.LoadBalancerNames = v +} + +func (o ReadLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerNames"] = o.LoadBalancerNames + } + return json.Marshal(toSerialize) +} + +type NullableReadLoadBalancerTagsRequest struct { + value *ReadLoadBalancerTagsRequest + isSet bool +} + +func (v NullableReadLoadBalancerTagsRequest) Get() *ReadLoadBalancerTagsRequest { + return v.value +} + +func (v *NullableReadLoadBalancerTagsRequest) Set(val *ReadLoadBalancerTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadLoadBalancerTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLoadBalancerTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLoadBalancerTagsRequest(val *ReadLoadBalancerTagsRequest) *NullableReadLoadBalancerTagsRequest { + return &NullableReadLoadBalancerTagsRequest{value: val, isSet: true} +} + +func (v NullableReadLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go new file mode 100644 index 000000000..b044343f2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLoadBalancerTagsResponse struct for ReadLoadBalancerTagsResponse +type ReadLoadBalancerTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more load balancer tags. + Tags *[]LoadBalancerTag `json:"Tags,omitempty"` +} + +// NewReadLoadBalancerTagsResponse instantiates a new ReadLoadBalancerTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLoadBalancerTagsResponse() *ReadLoadBalancerTagsResponse { + this := ReadLoadBalancerTagsResponse{} + return &this +} + +// NewReadLoadBalancerTagsResponseWithDefaults instantiates a new ReadLoadBalancerTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLoadBalancerTagsResponseWithDefaults() *ReadLoadBalancerTagsResponse { + this := ReadLoadBalancerTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadLoadBalancerTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancerTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadLoadBalancerTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *ReadLoadBalancerTagsResponse) GetTags() []LoadBalancerTag { + if o == nil || o.Tags == nil { + var ret []LoadBalancerTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancerTagsResponse) GetTagsOk() (*[]LoadBalancerTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *ReadLoadBalancerTagsResponse) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []LoadBalancerTag and assigns it to the Tags field. +func (o *ReadLoadBalancerTagsResponse) SetTags(v []LoadBalancerTag) { + o.Tags = &v +} + +func (o ReadLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableReadLoadBalancerTagsResponse struct { + value *ReadLoadBalancerTagsResponse + isSet bool +} + +func (v NullableReadLoadBalancerTagsResponse) Get() *ReadLoadBalancerTagsResponse { + return v.value +} + +func (v *NullableReadLoadBalancerTagsResponse) Set(val *ReadLoadBalancerTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadLoadBalancerTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLoadBalancerTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLoadBalancerTagsResponse(val *ReadLoadBalancerTagsResponse) *NullableReadLoadBalancerTagsResponse { + return &NullableReadLoadBalancerTagsResponse{value: val, isSet: true} +} + +func (v NullableReadLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go new file mode 100644 index 000000000..06863a7a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLoadBalancersRequest struct for ReadLoadBalancersRequest +type ReadLoadBalancersRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersLoadBalancer `json:"Filters,omitempty"` +} + +// NewReadLoadBalancersRequest instantiates a new ReadLoadBalancersRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLoadBalancersRequest() *ReadLoadBalancersRequest { + this := ReadLoadBalancersRequest{} + return &this +} + +// NewReadLoadBalancersRequestWithDefaults instantiates a new ReadLoadBalancersRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLoadBalancersRequestWithDefaults() *ReadLoadBalancersRequest { + this := ReadLoadBalancersRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadLoadBalancersRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancersRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadLoadBalancersRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadLoadBalancersRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadLoadBalancersRequest) GetFilters() FiltersLoadBalancer { + if o == nil || o.Filters == nil { + var ret FiltersLoadBalancer + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancersRequest) GetFiltersOk() (*FiltersLoadBalancer, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadLoadBalancersRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersLoadBalancer and assigns it to the Filters field. +func (o *ReadLoadBalancersRequest) SetFilters(v FiltersLoadBalancer) { + o.Filters = &v +} + +func (o ReadLoadBalancersRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadLoadBalancersRequest struct { + value *ReadLoadBalancersRequest + isSet bool +} + +func (v NullableReadLoadBalancersRequest) Get() *ReadLoadBalancersRequest { + return v.value +} + +func (v *NullableReadLoadBalancersRequest) Set(val *ReadLoadBalancersRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadLoadBalancersRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLoadBalancersRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLoadBalancersRequest(val *ReadLoadBalancersRequest) *NullableReadLoadBalancersRequest { + return &NullableReadLoadBalancersRequest{value: val, isSet: true} +} + +func (v NullableReadLoadBalancersRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLoadBalancersRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go new file mode 100644 index 000000000..e3ddb2d4f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLoadBalancersResponse struct for ReadLoadBalancersResponse +type ReadLoadBalancersResponse struct { + // Information about one or more load balancers. + LoadBalancers *[]LoadBalancer `json:"LoadBalancers,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadLoadBalancersResponse instantiates a new ReadLoadBalancersResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLoadBalancersResponse() *ReadLoadBalancersResponse { + this := ReadLoadBalancersResponse{} + return &this +} + +// NewReadLoadBalancersResponseWithDefaults instantiates a new ReadLoadBalancersResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLoadBalancersResponseWithDefaults() *ReadLoadBalancersResponse { + this := ReadLoadBalancersResponse{} + return &this +} + +// GetLoadBalancers returns the LoadBalancers field value if set, zero value otherwise. +func (o *ReadLoadBalancersResponse) GetLoadBalancers() []LoadBalancer { + if o == nil || o.LoadBalancers == nil { + var ret []LoadBalancer + return ret + } + return *o.LoadBalancers +} + +// GetLoadBalancersOk returns a tuple with the LoadBalancers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancersResponse) GetLoadBalancersOk() (*[]LoadBalancer, bool) { + if o == nil || o.LoadBalancers == nil { + return nil, false + } + return o.LoadBalancers, true +} + +// HasLoadBalancers returns a boolean if a field has been set. +func (o *ReadLoadBalancersResponse) HasLoadBalancers() bool { + if o != nil && o.LoadBalancers != nil { + return true + } + + return false +} + +// SetLoadBalancers gets a reference to the given []LoadBalancer and assigns it to the LoadBalancers field. +func (o *ReadLoadBalancersResponse) SetLoadBalancers(v []LoadBalancer) { + o.LoadBalancers = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadLoadBalancersResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLoadBalancersResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadLoadBalancersResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadLoadBalancersResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadLoadBalancersResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancers != nil { + toSerialize["LoadBalancers"] = o.LoadBalancers + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadLoadBalancersResponse struct { + value *ReadLoadBalancersResponse + isSet bool +} + +func (v NullableReadLoadBalancersResponse) Get() *ReadLoadBalancersResponse { + return v.value +} + +func (v *NullableReadLoadBalancersResponse) Set(val *ReadLoadBalancersResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadLoadBalancersResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLoadBalancersResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLoadBalancersResponse(val *ReadLoadBalancersResponse) *NullableReadLoadBalancersResponse { + return &NullableReadLoadBalancersResponse{value: val, isSet: true} +} + +func (v NullableReadLoadBalancersResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLoadBalancersResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go new file mode 100644 index 000000000..d2a4ab555 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLocationsRequest struct for ReadLocationsRequest +type ReadLocationsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadLocationsRequest instantiates a new ReadLocationsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLocationsRequest() *ReadLocationsRequest { + this := ReadLocationsRequest{} + return &this +} + +// NewReadLocationsRequestWithDefaults instantiates a new ReadLocationsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLocationsRequestWithDefaults() *ReadLocationsRequest { + this := ReadLocationsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadLocationsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLocationsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadLocationsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadLocationsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadLocationsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadLocationsRequest struct { + value *ReadLocationsRequest + isSet bool +} + +func (v NullableReadLocationsRequest) Get() *ReadLocationsRequest { + return v.value +} + +func (v *NullableReadLocationsRequest) Set(val *ReadLocationsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadLocationsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLocationsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLocationsRequest(val *ReadLocationsRequest) *NullableReadLocationsRequest { + return &NullableReadLocationsRequest{value: val, isSet: true} +} + +func (v NullableReadLocationsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLocationsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go new file mode 100644 index 000000000..f1db049cc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadLocationsResponse struct for ReadLocationsResponse +type ReadLocationsResponse struct { + // Information about one or more locations. + Locations *[]Location `json:"Locations,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadLocationsResponse instantiates a new ReadLocationsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadLocationsResponse() *ReadLocationsResponse { + this := ReadLocationsResponse{} + return &this +} + +// NewReadLocationsResponseWithDefaults instantiates a new ReadLocationsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadLocationsResponseWithDefaults() *ReadLocationsResponse { + this := ReadLocationsResponse{} + return &this +} + +// GetLocations returns the Locations field value if set, zero value otherwise. +func (o *ReadLocationsResponse) GetLocations() []Location { + if o == nil || o.Locations == nil { + var ret []Location + return ret + } + return *o.Locations +} + +// GetLocationsOk returns a tuple with the Locations field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLocationsResponse) GetLocationsOk() (*[]Location, bool) { + if o == nil || o.Locations == nil { + return nil, false + } + return o.Locations, true +} + +// HasLocations returns a boolean if a field has been set. +func (o *ReadLocationsResponse) HasLocations() bool { + if o != nil && o.Locations != nil { + return true + } + + return false +} + +// SetLocations gets a reference to the given []Location and assigns it to the Locations field. +func (o *ReadLocationsResponse) SetLocations(v []Location) { + o.Locations = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadLocationsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadLocationsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadLocationsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadLocationsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadLocationsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Locations != nil { + toSerialize["Locations"] = o.Locations + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadLocationsResponse struct { + value *ReadLocationsResponse + isSet bool +} + +func (v NullableReadLocationsResponse) Get() *ReadLocationsResponse { + return v.value +} + +func (v *NullableReadLocationsResponse) Set(val *ReadLocationsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadLocationsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadLocationsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadLocationsResponse(val *ReadLocationsResponse) *NullableReadLocationsResponse { + return &NullableReadLocationsResponse{value: val, isSet: true} +} + +func (v NullableReadLocationsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadLocationsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go new file mode 100644 index 000000000..e47d936a2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNatServicesRequest struct for ReadNatServicesRequest +type ReadNatServicesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersNatService `json:"Filters,omitempty"` +} + +// NewReadNatServicesRequest instantiates a new ReadNatServicesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNatServicesRequest() *ReadNatServicesRequest { + this := ReadNatServicesRequest{} + return &this +} + +// NewReadNatServicesRequestWithDefaults instantiates a new ReadNatServicesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNatServicesRequestWithDefaults() *ReadNatServicesRequest { + this := ReadNatServicesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNatServicesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNatServicesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNatServicesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNatServicesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNatServicesRequest) GetFilters() FiltersNatService { + if o == nil || o.Filters == nil { + var ret FiltersNatService + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNatServicesRequest) GetFiltersOk() (*FiltersNatService, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNatServicesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersNatService and assigns it to the Filters field. +func (o *ReadNatServicesRequest) SetFilters(v FiltersNatService) { + o.Filters = &v +} + +func (o ReadNatServicesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNatServicesRequest struct { + value *ReadNatServicesRequest + isSet bool +} + +func (v NullableReadNatServicesRequest) Get() *ReadNatServicesRequest { + return v.value +} + +func (v *NullableReadNatServicesRequest) Set(val *ReadNatServicesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNatServicesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNatServicesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNatServicesRequest(val *ReadNatServicesRequest) *NullableReadNatServicesRequest { + return &NullableReadNatServicesRequest{value: val, isSet: true} +} + +func (v NullableReadNatServicesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNatServicesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go new file mode 100644 index 000000000..999ab8d21 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNatServicesResponse struct for ReadNatServicesResponse +type ReadNatServicesResponse struct { + // Information about one or more NAT services. + NatServices *[]NatService `json:"NatServices,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadNatServicesResponse instantiates a new ReadNatServicesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNatServicesResponse() *ReadNatServicesResponse { + this := ReadNatServicesResponse{} + return &this +} + +// NewReadNatServicesResponseWithDefaults instantiates a new ReadNatServicesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNatServicesResponseWithDefaults() *ReadNatServicesResponse { + this := ReadNatServicesResponse{} + return &this +} + +// GetNatServices returns the NatServices field value if set, zero value otherwise. +func (o *ReadNatServicesResponse) GetNatServices() []NatService { + if o == nil || o.NatServices == nil { + var ret []NatService + return ret + } + return *o.NatServices +} + +// GetNatServicesOk returns a tuple with the NatServices field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNatServicesResponse) GetNatServicesOk() (*[]NatService, bool) { + if o == nil || o.NatServices == nil { + return nil, false + } + return o.NatServices, true +} + +// HasNatServices returns a boolean if a field has been set. +func (o *ReadNatServicesResponse) HasNatServices() bool { + if o != nil && o.NatServices != nil { + return true + } + + return false +} + +// SetNatServices gets a reference to the given []NatService and assigns it to the NatServices field. +func (o *ReadNatServicesResponse) SetNatServices(v []NatService) { + o.NatServices = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNatServicesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNatServicesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNatServicesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNatServicesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadNatServicesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NatServices != nil { + toSerialize["NatServices"] = o.NatServices + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadNatServicesResponse struct { + value *ReadNatServicesResponse + isSet bool +} + +func (v NullableReadNatServicesResponse) Get() *ReadNatServicesResponse { + return v.value +} + +func (v *NullableReadNatServicesResponse) Set(val *ReadNatServicesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNatServicesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNatServicesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNatServicesResponse(val *ReadNatServicesResponse) *NullableReadNatServicesResponse { + return &NullableReadNatServicesResponse{value: val, isSet: true} +} + +func (v NullableReadNatServicesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNatServicesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go new file mode 100644 index 000000000..e85456458 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetAccessPointServicesRequest struct for ReadNetAccessPointServicesRequest +type ReadNetAccessPointServicesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersService `json:"Filters,omitempty"` +} + +// NewReadNetAccessPointServicesRequest instantiates a new ReadNetAccessPointServicesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetAccessPointServicesRequest() *ReadNetAccessPointServicesRequest { + this := ReadNetAccessPointServicesRequest{} + return &this +} + +// NewReadNetAccessPointServicesRequestWithDefaults instantiates a new ReadNetAccessPointServicesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetAccessPointServicesRequestWithDefaults() *ReadNetAccessPointServicesRequest { + this := ReadNetAccessPointServicesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNetAccessPointServicesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointServicesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNetAccessPointServicesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNetAccessPointServicesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNetAccessPointServicesRequest) GetFilters() FiltersService { + if o == nil || o.Filters == nil { + var ret FiltersService + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointServicesRequest) GetFiltersOk() (*FiltersService, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNetAccessPointServicesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersService and assigns it to the Filters field. +func (o *ReadNetAccessPointServicesRequest) SetFilters(v FiltersService) { + o.Filters = &v +} + +func (o ReadNetAccessPointServicesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNetAccessPointServicesRequest struct { + value *ReadNetAccessPointServicesRequest + isSet bool +} + +func (v NullableReadNetAccessPointServicesRequest) Get() *ReadNetAccessPointServicesRequest { + return v.value +} + +func (v *NullableReadNetAccessPointServicesRequest) Set(val *ReadNetAccessPointServicesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetAccessPointServicesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetAccessPointServicesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetAccessPointServicesRequest(val *ReadNetAccessPointServicesRequest) *NullableReadNetAccessPointServicesRequest { + return &NullableReadNetAccessPointServicesRequest{value: val, isSet: true} +} + +func (v NullableReadNetAccessPointServicesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetAccessPointServicesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go new file mode 100644 index 000000000..7b74b76f8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetAccessPointServicesResponse struct for ReadNetAccessPointServicesResponse +type ReadNetAccessPointServicesResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // The names of the services you can use for Net access points. + Services *[]Service `json:"Services,omitempty"` +} + +// NewReadNetAccessPointServicesResponse instantiates a new ReadNetAccessPointServicesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetAccessPointServicesResponse() *ReadNetAccessPointServicesResponse { + this := ReadNetAccessPointServicesResponse{} + return &this +} + +// NewReadNetAccessPointServicesResponseWithDefaults instantiates a new ReadNetAccessPointServicesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetAccessPointServicesResponseWithDefaults() *ReadNetAccessPointServicesResponse { + this := ReadNetAccessPointServicesResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNetAccessPointServicesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointServicesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNetAccessPointServicesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNetAccessPointServicesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetServices returns the Services field value if set, zero value otherwise. +func (o *ReadNetAccessPointServicesResponse) GetServices() []Service { + if o == nil || o.Services == nil { + var ret []Service + return ret + } + return *o.Services +} + +// GetServicesOk returns a tuple with the Services field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointServicesResponse) GetServicesOk() (*[]Service, bool) { + if o == nil || o.Services == nil { + return nil, false + } + return o.Services, true +} + +// HasServices returns a boolean if a field has been set. +func (o *ReadNetAccessPointServicesResponse) HasServices() bool { + if o != nil && o.Services != nil { + return true + } + + return false +} + +// SetServices gets a reference to the given []Service and assigns it to the Services field. +func (o *ReadNetAccessPointServicesResponse) SetServices(v []Service) { + o.Services = &v +} + +func (o ReadNetAccessPointServicesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Services != nil { + toSerialize["Services"] = o.Services + } + return json.Marshal(toSerialize) +} + +type NullableReadNetAccessPointServicesResponse struct { + value *ReadNetAccessPointServicesResponse + isSet bool +} + +func (v NullableReadNetAccessPointServicesResponse) Get() *ReadNetAccessPointServicesResponse { + return v.value +} + +func (v *NullableReadNetAccessPointServicesResponse) Set(val *ReadNetAccessPointServicesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetAccessPointServicesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetAccessPointServicesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetAccessPointServicesResponse(val *ReadNetAccessPointServicesResponse) *NullableReadNetAccessPointServicesResponse { + return &NullableReadNetAccessPointServicesResponse{value: val, isSet: true} +} + +func (v NullableReadNetAccessPointServicesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetAccessPointServicesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go new file mode 100644 index 000000000..6fb8220db --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetAccessPointsRequest struct for ReadNetAccessPointsRequest +type ReadNetAccessPointsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersNetAccessPoint `json:"Filters,omitempty"` +} + +// NewReadNetAccessPointsRequest instantiates a new ReadNetAccessPointsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetAccessPointsRequest() *ReadNetAccessPointsRequest { + this := ReadNetAccessPointsRequest{} + return &this +} + +// NewReadNetAccessPointsRequestWithDefaults instantiates a new ReadNetAccessPointsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetAccessPointsRequestWithDefaults() *ReadNetAccessPointsRequest { + this := ReadNetAccessPointsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNetAccessPointsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNetAccessPointsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNetAccessPointsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNetAccessPointsRequest) GetFilters() FiltersNetAccessPoint { + if o == nil || o.Filters == nil { + var ret FiltersNetAccessPoint + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointsRequest) GetFiltersOk() (*FiltersNetAccessPoint, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNetAccessPointsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersNetAccessPoint and assigns it to the Filters field. +func (o *ReadNetAccessPointsRequest) SetFilters(v FiltersNetAccessPoint) { + o.Filters = &v +} + +func (o ReadNetAccessPointsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNetAccessPointsRequest struct { + value *ReadNetAccessPointsRequest + isSet bool +} + +func (v NullableReadNetAccessPointsRequest) Get() *ReadNetAccessPointsRequest { + return v.value +} + +func (v *NullableReadNetAccessPointsRequest) Set(val *ReadNetAccessPointsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetAccessPointsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetAccessPointsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetAccessPointsRequest(val *ReadNetAccessPointsRequest) *NullableReadNetAccessPointsRequest { + return &NullableReadNetAccessPointsRequest{value: val, isSet: true} +} + +func (v NullableReadNetAccessPointsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetAccessPointsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go new file mode 100644 index 000000000..b39fb6ecc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetAccessPointsResponse struct for ReadNetAccessPointsResponse +type ReadNetAccessPointsResponse struct { + // One or more Net access points. + NetAccessPoints *[]NetAccessPoint `json:"NetAccessPoints,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadNetAccessPointsResponse instantiates a new ReadNetAccessPointsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetAccessPointsResponse() *ReadNetAccessPointsResponse { + this := ReadNetAccessPointsResponse{} + return &this +} + +// NewReadNetAccessPointsResponseWithDefaults instantiates a new ReadNetAccessPointsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetAccessPointsResponseWithDefaults() *ReadNetAccessPointsResponse { + this := ReadNetAccessPointsResponse{} + return &this +} + +// GetNetAccessPoints returns the NetAccessPoints field value if set, zero value otherwise. +func (o *ReadNetAccessPointsResponse) GetNetAccessPoints() []NetAccessPoint { + if o == nil || o.NetAccessPoints == nil { + var ret []NetAccessPoint + return ret + } + return *o.NetAccessPoints +} + +// GetNetAccessPointsOk returns a tuple with the NetAccessPoints field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointsResponse) GetNetAccessPointsOk() (*[]NetAccessPoint, bool) { + if o == nil || o.NetAccessPoints == nil { + return nil, false + } + return o.NetAccessPoints, true +} + +// HasNetAccessPoints returns a boolean if a field has been set. +func (o *ReadNetAccessPointsResponse) HasNetAccessPoints() bool { + if o != nil && o.NetAccessPoints != nil { + return true + } + + return false +} + +// SetNetAccessPoints gets a reference to the given []NetAccessPoint and assigns it to the NetAccessPoints field. +func (o *ReadNetAccessPointsResponse) SetNetAccessPoints(v []NetAccessPoint) { + o.NetAccessPoints = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNetAccessPointsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetAccessPointsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNetAccessPointsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNetAccessPointsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadNetAccessPointsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetAccessPoints != nil { + toSerialize["NetAccessPoints"] = o.NetAccessPoints + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadNetAccessPointsResponse struct { + value *ReadNetAccessPointsResponse + isSet bool +} + +func (v NullableReadNetAccessPointsResponse) Get() *ReadNetAccessPointsResponse { + return v.value +} + +func (v *NullableReadNetAccessPointsResponse) Set(val *ReadNetAccessPointsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetAccessPointsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetAccessPointsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetAccessPointsResponse(val *ReadNetAccessPointsResponse) *NullableReadNetAccessPointsResponse { + return &NullableReadNetAccessPointsResponse{value: val, isSet: true} +} + +func (v NullableReadNetAccessPointsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetAccessPointsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go new file mode 100644 index 000000000..e35cc8ca3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetPeeringsRequest struct for ReadNetPeeringsRequest +type ReadNetPeeringsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersNetPeering `json:"Filters,omitempty"` +} + +// NewReadNetPeeringsRequest instantiates a new ReadNetPeeringsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetPeeringsRequest() *ReadNetPeeringsRequest { + this := ReadNetPeeringsRequest{} + return &this +} + +// NewReadNetPeeringsRequestWithDefaults instantiates a new ReadNetPeeringsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetPeeringsRequestWithDefaults() *ReadNetPeeringsRequest { + this := ReadNetPeeringsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNetPeeringsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetPeeringsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNetPeeringsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNetPeeringsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNetPeeringsRequest) GetFilters() FiltersNetPeering { + if o == nil || o.Filters == nil { + var ret FiltersNetPeering + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetPeeringsRequest) GetFiltersOk() (*FiltersNetPeering, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNetPeeringsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersNetPeering and assigns it to the Filters field. +func (o *ReadNetPeeringsRequest) SetFilters(v FiltersNetPeering) { + o.Filters = &v +} + +func (o ReadNetPeeringsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNetPeeringsRequest struct { + value *ReadNetPeeringsRequest + isSet bool +} + +func (v NullableReadNetPeeringsRequest) Get() *ReadNetPeeringsRequest { + return v.value +} + +func (v *NullableReadNetPeeringsRequest) Set(val *ReadNetPeeringsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetPeeringsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetPeeringsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetPeeringsRequest(val *ReadNetPeeringsRequest) *NullableReadNetPeeringsRequest { + return &NullableReadNetPeeringsRequest{value: val, isSet: true} +} + +func (v NullableReadNetPeeringsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetPeeringsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go new file mode 100644 index 000000000..42ca287a2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetPeeringsResponse struct for ReadNetPeeringsResponse +type ReadNetPeeringsResponse struct { + // Information about one or more Net peering connections. + NetPeerings *[]NetPeering `json:"NetPeerings,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadNetPeeringsResponse instantiates a new ReadNetPeeringsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetPeeringsResponse() *ReadNetPeeringsResponse { + this := ReadNetPeeringsResponse{} + return &this +} + +// NewReadNetPeeringsResponseWithDefaults instantiates a new ReadNetPeeringsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetPeeringsResponseWithDefaults() *ReadNetPeeringsResponse { + this := ReadNetPeeringsResponse{} + return &this +} + +// GetNetPeerings returns the NetPeerings field value if set, zero value otherwise. +func (o *ReadNetPeeringsResponse) GetNetPeerings() []NetPeering { + if o == nil || o.NetPeerings == nil { + var ret []NetPeering + return ret + } + return *o.NetPeerings +} + +// GetNetPeeringsOk returns a tuple with the NetPeerings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetPeeringsResponse) GetNetPeeringsOk() (*[]NetPeering, bool) { + if o == nil || o.NetPeerings == nil { + return nil, false + } + return o.NetPeerings, true +} + +// HasNetPeerings returns a boolean if a field has been set. +func (o *ReadNetPeeringsResponse) HasNetPeerings() bool { + if o != nil && o.NetPeerings != nil { + return true + } + + return false +} + +// SetNetPeerings gets a reference to the given []NetPeering and assigns it to the NetPeerings field. +func (o *ReadNetPeeringsResponse) SetNetPeerings(v []NetPeering) { + o.NetPeerings = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNetPeeringsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetPeeringsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNetPeeringsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNetPeeringsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadNetPeeringsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetPeerings != nil { + toSerialize["NetPeerings"] = o.NetPeerings + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadNetPeeringsResponse struct { + value *ReadNetPeeringsResponse + isSet bool +} + +func (v NullableReadNetPeeringsResponse) Get() *ReadNetPeeringsResponse { + return v.value +} + +func (v *NullableReadNetPeeringsResponse) Set(val *ReadNetPeeringsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetPeeringsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetPeeringsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetPeeringsResponse(val *ReadNetPeeringsResponse) *NullableReadNetPeeringsResponse { + return &NullableReadNetPeeringsResponse{value: val, isSet: true} +} + +func (v NullableReadNetPeeringsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetPeeringsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go new file mode 100644 index 000000000..3771bb78e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetsRequest struct for ReadNetsRequest +type ReadNetsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersNet `json:"Filters,omitempty"` +} + +// NewReadNetsRequest instantiates a new ReadNetsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetsRequest() *ReadNetsRequest { + this := ReadNetsRequest{} + return &this +} + +// NewReadNetsRequestWithDefaults instantiates a new ReadNetsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetsRequestWithDefaults() *ReadNetsRequest { + this := ReadNetsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNetsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNetsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNetsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNetsRequest) GetFilters() FiltersNet { + if o == nil || o.Filters == nil { + var ret FiltersNet + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetsRequest) GetFiltersOk() (*FiltersNet, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNetsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersNet and assigns it to the Filters field. +func (o *ReadNetsRequest) SetFilters(v FiltersNet) { + o.Filters = &v +} + +func (o ReadNetsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNetsRequest struct { + value *ReadNetsRequest + isSet bool +} + +func (v NullableReadNetsRequest) Get() *ReadNetsRequest { + return v.value +} + +func (v *NullableReadNetsRequest) Set(val *ReadNetsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetsRequest(val *ReadNetsRequest) *NullableReadNetsRequest { + return &NullableReadNetsRequest{value: val, isSet: true} +} + +func (v NullableReadNetsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go new file mode 100644 index 000000000..8c7babf71 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNetsResponse struct for ReadNetsResponse +type ReadNetsResponse struct { + // Information about the described Nets. + Nets *[]Net `json:"Nets,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadNetsResponse instantiates a new ReadNetsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNetsResponse() *ReadNetsResponse { + this := ReadNetsResponse{} + return &this +} + +// NewReadNetsResponseWithDefaults instantiates a new ReadNetsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNetsResponseWithDefaults() *ReadNetsResponse { + this := ReadNetsResponse{} + return &this +} + +// GetNets returns the Nets field value if set, zero value otherwise. +func (o *ReadNetsResponse) GetNets() []Net { + if o == nil || o.Nets == nil { + var ret []Net + return ret + } + return *o.Nets +} + +// GetNetsOk returns a tuple with the Nets field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetsResponse) GetNetsOk() (*[]Net, bool) { + if o == nil || o.Nets == nil { + return nil, false + } + return o.Nets, true +} + +// HasNets returns a boolean if a field has been set. +func (o *ReadNetsResponse) HasNets() bool { + if o != nil && o.Nets != nil { + return true + } + + return false +} + +// SetNets gets a reference to the given []Net and assigns it to the Nets field. +func (o *ReadNetsResponse) SetNets(v []Net) { + o.Nets = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNetsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNetsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNetsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNetsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadNetsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Nets != nil { + toSerialize["Nets"] = o.Nets + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadNetsResponse struct { + value *ReadNetsResponse + isSet bool +} + +func (v NullableReadNetsResponse) Get() *ReadNetsResponse { + return v.value +} + +func (v *NullableReadNetsResponse) Set(val *ReadNetsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNetsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNetsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNetsResponse(val *ReadNetsResponse) *NullableReadNetsResponse { + return &NullableReadNetsResponse{value: val, isSet: true} +} + +func (v NullableReadNetsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNetsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go new file mode 100644 index 000000000..51ad0f960 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNicsRequest struct for ReadNicsRequest +type ReadNicsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersNic `json:"Filters,omitempty"` +} + +// NewReadNicsRequest instantiates a new ReadNicsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNicsRequest() *ReadNicsRequest { + this := ReadNicsRequest{} + return &this +} + +// NewReadNicsRequestWithDefaults instantiates a new ReadNicsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNicsRequestWithDefaults() *ReadNicsRequest { + this := ReadNicsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadNicsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNicsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadNicsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadNicsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadNicsRequest) GetFilters() FiltersNic { + if o == nil || o.Filters == nil { + var ret FiltersNic + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNicsRequest) GetFiltersOk() (*FiltersNic, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadNicsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersNic and assigns it to the Filters field. +func (o *ReadNicsRequest) SetFilters(v FiltersNic) { + o.Filters = &v +} + +func (o ReadNicsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadNicsRequest struct { + value *ReadNicsRequest + isSet bool +} + +func (v NullableReadNicsRequest) Get() *ReadNicsRequest { + return v.value +} + +func (v *NullableReadNicsRequest) Set(val *ReadNicsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadNicsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNicsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNicsRequest(val *ReadNicsRequest) *NullableReadNicsRequest { + return &NullableReadNicsRequest{value: val, isSet: true} +} + +func (v NullableReadNicsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNicsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go new file mode 100644 index 000000000..49c510ead --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadNicsResponse struct for ReadNicsResponse +type ReadNicsResponse struct { + // Information about one or more NICs. + Nics *[]Nic `json:"Nics,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadNicsResponse instantiates a new ReadNicsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadNicsResponse() *ReadNicsResponse { + this := ReadNicsResponse{} + return &this +} + +// NewReadNicsResponseWithDefaults instantiates a new ReadNicsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadNicsResponseWithDefaults() *ReadNicsResponse { + this := ReadNicsResponse{} + return &this +} + +// GetNics returns the Nics field value if set, zero value otherwise. +func (o *ReadNicsResponse) GetNics() []Nic { + if o == nil || o.Nics == nil { + var ret []Nic + return ret + } + return *o.Nics +} + +// GetNicsOk returns a tuple with the Nics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNicsResponse) GetNicsOk() (*[]Nic, bool) { + if o == nil || o.Nics == nil { + return nil, false + } + return o.Nics, true +} + +// HasNics returns a boolean if a field has been set. +func (o *ReadNicsResponse) HasNics() bool { + if o != nil && o.Nics != nil { + return true + } + + return false +} + +// SetNics gets a reference to the given []Nic and assigns it to the Nics field. +func (o *ReadNicsResponse) SetNics(v []Nic) { + o.Nics = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadNicsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadNicsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadNicsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadNicsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadNicsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Nics != nil { + toSerialize["Nics"] = o.Nics + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadNicsResponse struct { + value *ReadNicsResponse + isSet bool +} + +func (v NullableReadNicsResponse) Get() *ReadNicsResponse { + return v.value +} + +func (v *NullableReadNicsResponse) Set(val *ReadNicsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadNicsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadNicsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadNicsResponse(val *ReadNicsResponse) *NullableReadNicsResponse { + return &NullableReadNicsResponse{value: val, isSet: true} +} + +func (v NullableReadNicsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadNicsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go new file mode 100644 index 000000000..523f5a3bb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadProductTypesRequest struct for ReadProductTypesRequest +type ReadProductTypesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersProductType `json:"Filters,omitempty"` +} + +// NewReadProductTypesRequest instantiates a new ReadProductTypesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadProductTypesRequest() *ReadProductTypesRequest { + this := ReadProductTypesRequest{} + return &this +} + +// NewReadProductTypesRequestWithDefaults instantiates a new ReadProductTypesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadProductTypesRequestWithDefaults() *ReadProductTypesRequest { + this := ReadProductTypesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadProductTypesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadProductTypesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadProductTypesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadProductTypesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadProductTypesRequest) GetFilters() FiltersProductType { + if o == nil || o.Filters == nil { + var ret FiltersProductType + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadProductTypesRequest) GetFiltersOk() (*FiltersProductType, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadProductTypesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersProductType and assigns it to the Filters field. +func (o *ReadProductTypesRequest) SetFilters(v FiltersProductType) { + o.Filters = &v +} + +func (o ReadProductTypesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadProductTypesRequest struct { + value *ReadProductTypesRequest + isSet bool +} + +func (v NullableReadProductTypesRequest) Get() *ReadProductTypesRequest { + return v.value +} + +func (v *NullableReadProductTypesRequest) Set(val *ReadProductTypesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadProductTypesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadProductTypesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadProductTypesRequest(val *ReadProductTypesRequest) *NullableReadProductTypesRequest { + return &NullableReadProductTypesRequest{value: val, isSet: true} +} + +func (v NullableReadProductTypesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadProductTypesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go new file mode 100644 index 000000000..161f312df --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadProductTypesResponse struct for ReadProductTypesResponse +type ReadProductTypesResponse struct { + // Information about one or more product types. + ProductTypes *[]ProductType `json:"ProductTypes,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadProductTypesResponse instantiates a new ReadProductTypesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadProductTypesResponse() *ReadProductTypesResponse { + this := ReadProductTypesResponse{} + return &this +} + +// NewReadProductTypesResponseWithDefaults instantiates a new ReadProductTypesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadProductTypesResponseWithDefaults() *ReadProductTypesResponse { + this := ReadProductTypesResponse{} + return &this +} + +// GetProductTypes returns the ProductTypes field value if set, zero value otherwise. +func (o *ReadProductTypesResponse) GetProductTypes() []ProductType { + if o == nil || o.ProductTypes == nil { + var ret []ProductType + return ret + } + return *o.ProductTypes +} + +// GetProductTypesOk returns a tuple with the ProductTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadProductTypesResponse) GetProductTypesOk() (*[]ProductType, bool) { + if o == nil || o.ProductTypes == nil { + return nil, false + } + return o.ProductTypes, true +} + +// HasProductTypes returns a boolean if a field has been set. +func (o *ReadProductTypesResponse) HasProductTypes() bool { + if o != nil && o.ProductTypes != nil { + return true + } + + return false +} + +// SetProductTypes gets a reference to the given []ProductType and assigns it to the ProductTypes field. +func (o *ReadProductTypesResponse) SetProductTypes(v []ProductType) { + o.ProductTypes = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadProductTypesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadProductTypesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadProductTypesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadProductTypesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadProductTypesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ProductTypes != nil { + toSerialize["ProductTypes"] = o.ProductTypes + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadProductTypesResponse struct { + value *ReadProductTypesResponse + isSet bool +} + +func (v NullableReadProductTypesResponse) Get() *ReadProductTypesResponse { + return v.value +} + +func (v *NullableReadProductTypesResponse) Set(val *ReadProductTypesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadProductTypesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadProductTypesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadProductTypesResponse(val *ReadProductTypesResponse) *NullableReadProductTypesResponse { + return &NullableReadProductTypesResponse{value: val, isSet: true} +} + +func (v NullableReadProductTypesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadProductTypesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go new file mode 100644 index 000000000..e69aee529 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadPublicIpRangesRequest struct for ReadPublicIpRangesRequest +type ReadPublicIpRangesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadPublicIpRangesRequest instantiates a new ReadPublicIpRangesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadPublicIpRangesRequest() *ReadPublicIpRangesRequest { + this := ReadPublicIpRangesRequest{} + return &this +} + +// NewReadPublicIpRangesRequestWithDefaults instantiates a new ReadPublicIpRangesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadPublicIpRangesRequestWithDefaults() *ReadPublicIpRangesRequest { + this := ReadPublicIpRangesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadPublicIpRangesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpRangesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadPublicIpRangesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadPublicIpRangesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadPublicIpRangesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadPublicIpRangesRequest struct { + value *ReadPublicIpRangesRequest + isSet bool +} + +func (v NullableReadPublicIpRangesRequest) Get() *ReadPublicIpRangesRequest { + return v.value +} + +func (v *NullableReadPublicIpRangesRequest) Set(val *ReadPublicIpRangesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadPublicIpRangesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadPublicIpRangesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadPublicIpRangesRequest(val *ReadPublicIpRangesRequest) *NullableReadPublicIpRangesRequest { + return &NullableReadPublicIpRangesRequest{value: val, isSet: true} +} + +func (v NullableReadPublicIpRangesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadPublicIpRangesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go new file mode 100644 index 000000000..697b83e5a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadPublicIpRangesResponse struct for ReadPublicIpRangesResponse +type ReadPublicIpRangesResponse struct { + // The list of public IPv4 addresses used in the Region, in CIDR notation. + PublicIps *[]string `json:"PublicIps,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadPublicIpRangesResponse instantiates a new ReadPublicIpRangesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadPublicIpRangesResponse() *ReadPublicIpRangesResponse { + this := ReadPublicIpRangesResponse{} + return &this +} + +// NewReadPublicIpRangesResponseWithDefaults instantiates a new ReadPublicIpRangesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadPublicIpRangesResponseWithDefaults() *ReadPublicIpRangesResponse { + this := ReadPublicIpRangesResponse{} + return &this +} + +// GetPublicIps returns the PublicIps field value if set, zero value otherwise. +func (o *ReadPublicIpRangesResponse) GetPublicIps() []string { + if o == nil || o.PublicIps == nil { + var ret []string + return ret + } + return *o.PublicIps +} + +// GetPublicIpsOk returns a tuple with the PublicIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpRangesResponse) GetPublicIpsOk() (*[]string, bool) { + if o == nil || o.PublicIps == nil { + return nil, false + } + return o.PublicIps, true +} + +// HasPublicIps returns a boolean if a field has been set. +func (o *ReadPublicIpRangesResponse) HasPublicIps() bool { + if o != nil && o.PublicIps != nil { + return true + } + + return false +} + +// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. +func (o *ReadPublicIpRangesResponse) SetPublicIps(v []string) { + o.PublicIps = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadPublicIpRangesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpRangesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadPublicIpRangesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadPublicIpRangesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadPublicIpRangesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PublicIps != nil { + toSerialize["PublicIps"] = o.PublicIps + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadPublicIpRangesResponse struct { + value *ReadPublicIpRangesResponse + isSet bool +} + +func (v NullableReadPublicIpRangesResponse) Get() *ReadPublicIpRangesResponse { + return v.value +} + +func (v *NullableReadPublicIpRangesResponse) Set(val *ReadPublicIpRangesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadPublicIpRangesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadPublicIpRangesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadPublicIpRangesResponse(val *ReadPublicIpRangesResponse) *NullableReadPublicIpRangesResponse { + return &NullableReadPublicIpRangesResponse{value: val, isSet: true} +} + +func (v NullableReadPublicIpRangesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadPublicIpRangesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go new file mode 100644 index 000000000..4973a8a4a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadPublicIpsRequest struct for ReadPublicIpsRequest +type ReadPublicIpsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersPublicIp `json:"Filters,omitempty"` +} + +// NewReadPublicIpsRequest instantiates a new ReadPublicIpsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadPublicIpsRequest() *ReadPublicIpsRequest { + this := ReadPublicIpsRequest{} + return &this +} + +// NewReadPublicIpsRequestWithDefaults instantiates a new ReadPublicIpsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadPublicIpsRequestWithDefaults() *ReadPublicIpsRequest { + this := ReadPublicIpsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadPublicIpsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadPublicIpsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadPublicIpsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadPublicIpsRequest) GetFilters() FiltersPublicIp { + if o == nil || o.Filters == nil { + var ret FiltersPublicIp + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpsRequest) GetFiltersOk() (*FiltersPublicIp, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadPublicIpsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersPublicIp and assigns it to the Filters field. +func (o *ReadPublicIpsRequest) SetFilters(v FiltersPublicIp) { + o.Filters = &v +} + +func (o ReadPublicIpsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadPublicIpsRequest struct { + value *ReadPublicIpsRequest + isSet bool +} + +func (v NullableReadPublicIpsRequest) Get() *ReadPublicIpsRequest { + return v.value +} + +func (v *NullableReadPublicIpsRequest) Set(val *ReadPublicIpsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadPublicIpsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadPublicIpsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadPublicIpsRequest(val *ReadPublicIpsRequest) *NullableReadPublicIpsRequest { + return &NullableReadPublicIpsRequest{value: val, isSet: true} +} + +func (v NullableReadPublicIpsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadPublicIpsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go new file mode 100644 index 000000000..186f8bc00 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadPublicIpsResponse struct for ReadPublicIpsResponse +type ReadPublicIpsResponse struct { + // Information about one or more EIPs. + PublicIps *[]PublicIp `json:"PublicIps,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadPublicIpsResponse instantiates a new ReadPublicIpsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadPublicIpsResponse() *ReadPublicIpsResponse { + this := ReadPublicIpsResponse{} + return &this +} + +// NewReadPublicIpsResponseWithDefaults instantiates a new ReadPublicIpsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadPublicIpsResponseWithDefaults() *ReadPublicIpsResponse { + this := ReadPublicIpsResponse{} + return &this +} + +// GetPublicIps returns the PublicIps field value if set, zero value otherwise. +func (o *ReadPublicIpsResponse) GetPublicIps() []PublicIp { + if o == nil || o.PublicIps == nil { + var ret []PublicIp + return ret + } + return *o.PublicIps +} + +// GetPublicIpsOk returns a tuple with the PublicIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpsResponse) GetPublicIpsOk() (*[]PublicIp, bool) { + if o == nil || o.PublicIps == nil { + return nil, false + } + return o.PublicIps, true +} + +// HasPublicIps returns a boolean if a field has been set. +func (o *ReadPublicIpsResponse) HasPublicIps() bool { + if o != nil && o.PublicIps != nil { + return true + } + + return false +} + +// SetPublicIps gets a reference to the given []PublicIp and assigns it to the PublicIps field. +func (o *ReadPublicIpsResponse) SetPublicIps(v []PublicIp) { + o.PublicIps = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadPublicIpsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadPublicIpsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadPublicIpsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadPublicIpsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadPublicIpsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.PublicIps != nil { + toSerialize["PublicIps"] = o.PublicIps + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadPublicIpsResponse struct { + value *ReadPublicIpsResponse + isSet bool +} + +func (v NullableReadPublicIpsResponse) Get() *ReadPublicIpsResponse { + return v.value +} + +func (v *NullableReadPublicIpsResponse) Set(val *ReadPublicIpsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadPublicIpsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadPublicIpsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadPublicIpsResponse(val *ReadPublicIpsResponse) *NullableReadPublicIpsResponse { + return &NullableReadPublicIpsResponse{value: val, isSet: true} +} + +func (v NullableReadPublicIpsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadPublicIpsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go new file mode 100644 index 000000000..5836016a8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadQuotasRequest struct for ReadQuotasRequest +type ReadQuotasRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersQuota `json:"Filters,omitempty"` +} + +// NewReadQuotasRequest instantiates a new ReadQuotasRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadQuotasRequest() *ReadQuotasRequest { + this := ReadQuotasRequest{} + return &this +} + +// NewReadQuotasRequestWithDefaults instantiates a new ReadQuotasRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadQuotasRequestWithDefaults() *ReadQuotasRequest { + this := ReadQuotasRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadQuotasRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadQuotasRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadQuotasRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadQuotasRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadQuotasRequest) GetFilters() FiltersQuota { + if o == nil || o.Filters == nil { + var ret FiltersQuota + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadQuotasRequest) GetFiltersOk() (*FiltersQuota, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadQuotasRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersQuota and assigns it to the Filters field. +func (o *ReadQuotasRequest) SetFilters(v FiltersQuota) { + o.Filters = &v +} + +func (o ReadQuotasRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadQuotasRequest struct { + value *ReadQuotasRequest + isSet bool +} + +func (v NullableReadQuotasRequest) Get() *ReadQuotasRequest { + return v.value +} + +func (v *NullableReadQuotasRequest) Set(val *ReadQuotasRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadQuotasRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadQuotasRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadQuotasRequest(val *ReadQuotasRequest) *NullableReadQuotasRequest { + return &NullableReadQuotasRequest{value: val, isSet: true} +} + +func (v NullableReadQuotasRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadQuotasRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go new file mode 100644 index 000000000..a6112d053 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadQuotasResponse struct for ReadQuotasResponse +type ReadQuotasResponse struct { + // Information about one or more quotas. + QuotaTypes *[]QuotaTypes `json:"QuotaTypes,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadQuotasResponse instantiates a new ReadQuotasResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadQuotasResponse() *ReadQuotasResponse { + this := ReadQuotasResponse{} + return &this +} + +// NewReadQuotasResponseWithDefaults instantiates a new ReadQuotasResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadQuotasResponseWithDefaults() *ReadQuotasResponse { + this := ReadQuotasResponse{} + return &this +} + +// GetQuotaTypes returns the QuotaTypes field value if set, zero value otherwise. +func (o *ReadQuotasResponse) GetQuotaTypes() []QuotaTypes { + if o == nil || o.QuotaTypes == nil { + var ret []QuotaTypes + return ret + } + return *o.QuotaTypes +} + +// GetQuotaTypesOk returns a tuple with the QuotaTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadQuotasResponse) GetQuotaTypesOk() (*[]QuotaTypes, bool) { + if o == nil || o.QuotaTypes == nil { + return nil, false + } + return o.QuotaTypes, true +} + +// HasQuotaTypes returns a boolean if a field has been set. +func (o *ReadQuotasResponse) HasQuotaTypes() bool { + if o != nil && o.QuotaTypes != nil { + return true + } + + return false +} + +// SetQuotaTypes gets a reference to the given []QuotaTypes and assigns it to the QuotaTypes field. +func (o *ReadQuotasResponse) SetQuotaTypes(v []QuotaTypes) { + o.QuotaTypes = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadQuotasResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadQuotasResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadQuotasResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadQuotasResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadQuotasResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.QuotaTypes != nil { + toSerialize["QuotaTypes"] = o.QuotaTypes + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadQuotasResponse struct { + value *ReadQuotasResponse + isSet bool +} + +func (v NullableReadQuotasResponse) Get() *ReadQuotasResponse { + return v.value +} + +func (v *NullableReadQuotasResponse) Set(val *ReadQuotasResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadQuotasResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadQuotasResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadQuotasResponse(val *ReadQuotasResponse) *NullableReadQuotasResponse { + return &NullableReadQuotasResponse{value: val, isSet: true} +} + +func (v NullableReadQuotasResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadQuotasResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go new file mode 100644 index 000000000..4b14bf9d2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadRegionsRequest struct for ReadRegionsRequest +type ReadRegionsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadRegionsRequest instantiates a new ReadRegionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadRegionsRequest() *ReadRegionsRequest { + this := ReadRegionsRequest{} + return &this +} + +// NewReadRegionsRequestWithDefaults instantiates a new ReadRegionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadRegionsRequestWithDefaults() *ReadRegionsRequest { + this := ReadRegionsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadRegionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRegionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadRegionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadRegionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadRegionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadRegionsRequest struct { + value *ReadRegionsRequest + isSet bool +} + +func (v NullableReadRegionsRequest) Get() *ReadRegionsRequest { + return v.value +} + +func (v *NullableReadRegionsRequest) Set(val *ReadRegionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadRegionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadRegionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadRegionsRequest(val *ReadRegionsRequest) *NullableReadRegionsRequest { + return &NullableReadRegionsRequest{value: val, isSet: true} +} + +func (v NullableReadRegionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadRegionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go new file mode 100644 index 000000000..d48c6e246 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadRegionsResponse struct for ReadRegionsResponse +type ReadRegionsResponse struct { + // Information about one or more Regions. + Regions *[]Region `json:"Regions,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadRegionsResponse instantiates a new ReadRegionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadRegionsResponse() *ReadRegionsResponse { + this := ReadRegionsResponse{} + return &this +} + +// NewReadRegionsResponseWithDefaults instantiates a new ReadRegionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadRegionsResponseWithDefaults() *ReadRegionsResponse { + this := ReadRegionsResponse{} + return &this +} + +// GetRegions returns the Regions field value if set, zero value otherwise. +func (o *ReadRegionsResponse) GetRegions() []Region { + if o == nil || o.Regions == nil { + var ret []Region + return ret + } + return *o.Regions +} + +// GetRegionsOk returns a tuple with the Regions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRegionsResponse) GetRegionsOk() (*[]Region, bool) { + if o == nil || o.Regions == nil { + return nil, false + } + return o.Regions, true +} + +// HasRegions returns a boolean if a field has been set. +func (o *ReadRegionsResponse) HasRegions() bool { + if o != nil && o.Regions != nil { + return true + } + + return false +} + +// SetRegions gets a reference to the given []Region and assigns it to the Regions field. +func (o *ReadRegionsResponse) SetRegions(v []Region) { + o.Regions = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadRegionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRegionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadRegionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadRegionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadRegionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Regions != nil { + toSerialize["Regions"] = o.Regions + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadRegionsResponse struct { + value *ReadRegionsResponse + isSet bool +} + +func (v NullableReadRegionsResponse) Get() *ReadRegionsResponse { + return v.value +} + +func (v *NullableReadRegionsResponse) Set(val *ReadRegionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadRegionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadRegionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadRegionsResponse(val *ReadRegionsResponse) *NullableReadRegionsResponse { + return &NullableReadRegionsResponse{value: val, isSet: true} +} + +func (v NullableReadRegionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadRegionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go new file mode 100644 index 000000000..82a7183d6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadRouteTablesRequest struct for ReadRouteTablesRequest +type ReadRouteTablesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersRouteTable `json:"Filters,omitempty"` +} + +// NewReadRouteTablesRequest instantiates a new ReadRouteTablesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadRouteTablesRequest() *ReadRouteTablesRequest { + this := ReadRouteTablesRequest{} + return &this +} + +// NewReadRouteTablesRequestWithDefaults instantiates a new ReadRouteTablesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadRouteTablesRequestWithDefaults() *ReadRouteTablesRequest { + this := ReadRouteTablesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadRouteTablesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRouteTablesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadRouteTablesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadRouteTablesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadRouteTablesRequest) GetFilters() FiltersRouteTable { + if o == nil || o.Filters == nil { + var ret FiltersRouteTable + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRouteTablesRequest) GetFiltersOk() (*FiltersRouteTable, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadRouteTablesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersRouteTable and assigns it to the Filters field. +func (o *ReadRouteTablesRequest) SetFilters(v FiltersRouteTable) { + o.Filters = &v +} + +func (o ReadRouteTablesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadRouteTablesRequest struct { + value *ReadRouteTablesRequest + isSet bool +} + +func (v NullableReadRouteTablesRequest) Get() *ReadRouteTablesRequest { + return v.value +} + +func (v *NullableReadRouteTablesRequest) Set(val *ReadRouteTablesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadRouteTablesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadRouteTablesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadRouteTablesRequest(val *ReadRouteTablesRequest) *NullableReadRouteTablesRequest { + return &NullableReadRouteTablesRequest{value: val, isSet: true} +} + +func (v NullableReadRouteTablesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadRouteTablesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go new file mode 100644 index 000000000..afffc2852 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadRouteTablesResponse struct for ReadRouteTablesResponse +type ReadRouteTablesResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more route tables. + RouteTables *[]RouteTable `json:"RouteTables,omitempty"` +} + +// NewReadRouteTablesResponse instantiates a new ReadRouteTablesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadRouteTablesResponse() *ReadRouteTablesResponse { + this := ReadRouteTablesResponse{} + return &this +} + +// NewReadRouteTablesResponseWithDefaults instantiates a new ReadRouteTablesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadRouteTablesResponseWithDefaults() *ReadRouteTablesResponse { + this := ReadRouteTablesResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadRouteTablesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRouteTablesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadRouteTablesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadRouteTablesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTables returns the RouteTables field value if set, zero value otherwise. +func (o *ReadRouteTablesResponse) GetRouteTables() []RouteTable { + if o == nil || o.RouteTables == nil { + var ret []RouteTable + return ret + } + return *o.RouteTables +} + +// GetRouteTablesOk returns a tuple with the RouteTables field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadRouteTablesResponse) GetRouteTablesOk() (*[]RouteTable, bool) { + if o == nil || o.RouteTables == nil { + return nil, false + } + return o.RouteTables, true +} + +// HasRouteTables returns a boolean if a field has been set. +func (o *ReadRouteTablesResponse) HasRouteTables() bool { + if o != nil && o.RouteTables != nil { + return true + } + + return false +} + +// SetRouteTables gets a reference to the given []RouteTable and assigns it to the RouteTables field. +func (o *ReadRouteTablesResponse) SetRouteTables(v []RouteTable) { + o.RouteTables = &v +} + +func (o ReadRouteTablesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTables != nil { + toSerialize["RouteTables"] = o.RouteTables + } + return json.Marshal(toSerialize) +} + +type NullableReadRouteTablesResponse struct { + value *ReadRouteTablesResponse + isSet bool +} + +func (v NullableReadRouteTablesResponse) Get() *ReadRouteTablesResponse { + return v.value +} + +func (v *NullableReadRouteTablesResponse) Set(val *ReadRouteTablesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadRouteTablesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadRouteTablesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadRouteTablesResponse(val *ReadRouteTablesResponse) *NullableReadRouteTablesResponse { + return &NullableReadRouteTablesResponse{value: val, isSet: true} +} + +func (v NullableReadRouteTablesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadRouteTablesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go new file mode 100644 index 000000000..1c1d048f1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSecretAccessKeyRequest struct for ReadSecretAccessKeyRequest +type ReadSecretAccessKeyRequest struct { + // The ID of the access key. + AccessKeyId string `json:"AccessKeyId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` +} + +// NewReadSecretAccessKeyRequest instantiates a new ReadSecretAccessKeyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSecretAccessKeyRequest(accessKeyId string, ) *ReadSecretAccessKeyRequest { + this := ReadSecretAccessKeyRequest{} + this.AccessKeyId = accessKeyId + return &this +} + +// NewReadSecretAccessKeyRequestWithDefaults instantiates a new ReadSecretAccessKeyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSecretAccessKeyRequestWithDefaults() *ReadSecretAccessKeyRequest { + this := ReadSecretAccessKeyRequest{} + return &this +} + +// GetAccessKeyId returns the AccessKeyId field value +func (o *ReadSecretAccessKeyRequest) GetAccessKeyId() string { + if o == nil { + var ret string + return ret + } + + return o.AccessKeyId +} + +// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value +// and a boolean to check if the value has been set. +func (o *ReadSecretAccessKeyRequest) GetAccessKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.AccessKeyId, true +} + +// SetAccessKeyId sets field value +func (o *ReadSecretAccessKeyRequest) SetAccessKeyId(v string) { + o.AccessKeyId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSecretAccessKeyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecretAccessKeyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSecretAccessKeyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSecretAccessKeyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +func (o ReadSecretAccessKeyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["AccessKeyId"] = o.AccessKeyId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + return json.Marshal(toSerialize) +} + +type NullableReadSecretAccessKeyRequest struct { + value *ReadSecretAccessKeyRequest + isSet bool +} + +func (v NullableReadSecretAccessKeyRequest) Get() *ReadSecretAccessKeyRequest { + return v.value +} + +func (v *NullableReadSecretAccessKeyRequest) Set(val *ReadSecretAccessKeyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSecretAccessKeyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSecretAccessKeyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSecretAccessKeyRequest(val *ReadSecretAccessKeyRequest) *NullableReadSecretAccessKeyRequest { + return &NullableReadSecretAccessKeyRequest{value: val, isSet: true} +} + +func (v NullableReadSecretAccessKeyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSecretAccessKeyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go new file mode 100644 index 000000000..079aee2e1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSecretAccessKeyResponse struct for ReadSecretAccessKeyResponse +type ReadSecretAccessKeyResponse struct { + AccessKey *AccessKeySecretKey `json:"AccessKey,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadSecretAccessKeyResponse instantiates a new ReadSecretAccessKeyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSecretAccessKeyResponse() *ReadSecretAccessKeyResponse { + this := ReadSecretAccessKeyResponse{} + return &this +} + +// NewReadSecretAccessKeyResponseWithDefaults instantiates a new ReadSecretAccessKeyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSecretAccessKeyResponseWithDefaults() *ReadSecretAccessKeyResponse { + this := ReadSecretAccessKeyResponse{} + return &this +} + +// GetAccessKey returns the AccessKey field value if set, zero value otherwise. +func (o *ReadSecretAccessKeyResponse) GetAccessKey() AccessKeySecretKey { + if o == nil || o.AccessKey == nil { + var ret AccessKeySecretKey + return ret + } + return *o.AccessKey +} + +// GetAccessKeyOk returns a tuple with the AccessKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecretAccessKeyResponse) GetAccessKeyOk() (*AccessKeySecretKey, bool) { + if o == nil || o.AccessKey == nil { + return nil, false + } + return o.AccessKey, true +} + +// HasAccessKey returns a boolean if a field has been set. +func (o *ReadSecretAccessKeyResponse) HasAccessKey() bool { + if o != nil && o.AccessKey != nil { + return true + } + + return false +} + +// SetAccessKey gets a reference to the given AccessKeySecretKey and assigns it to the AccessKey field. +func (o *ReadSecretAccessKeyResponse) SetAccessKey(v AccessKeySecretKey) { + o.AccessKey = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSecretAccessKeyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecretAccessKeyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSecretAccessKeyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSecretAccessKeyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadSecretAccessKeyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKey != nil { + toSerialize["AccessKey"] = o.AccessKey + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadSecretAccessKeyResponse struct { + value *ReadSecretAccessKeyResponse + isSet bool +} + +func (v NullableReadSecretAccessKeyResponse) Get() *ReadSecretAccessKeyResponse { + return v.value +} + +func (v *NullableReadSecretAccessKeyResponse) Set(val *ReadSecretAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSecretAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSecretAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSecretAccessKeyResponse(val *ReadSecretAccessKeyResponse) *NullableReadSecretAccessKeyResponse { + return &NullableReadSecretAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableReadSecretAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSecretAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go new file mode 100644 index 000000000..3eb5ae982 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSecurityGroupsRequest struct for ReadSecurityGroupsRequest +type ReadSecurityGroupsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersSecurityGroup `json:"Filters,omitempty"` +} + +// NewReadSecurityGroupsRequest instantiates a new ReadSecurityGroupsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSecurityGroupsRequest() *ReadSecurityGroupsRequest { + this := ReadSecurityGroupsRequest{} + return &this +} + +// NewReadSecurityGroupsRequestWithDefaults instantiates a new ReadSecurityGroupsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSecurityGroupsRequestWithDefaults() *ReadSecurityGroupsRequest { + this := ReadSecurityGroupsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSecurityGroupsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecurityGroupsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSecurityGroupsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSecurityGroupsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadSecurityGroupsRequest) GetFilters() FiltersSecurityGroup { + if o == nil || o.Filters == nil { + var ret FiltersSecurityGroup + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecurityGroupsRequest) GetFiltersOk() (*FiltersSecurityGroup, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadSecurityGroupsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersSecurityGroup and assigns it to the Filters field. +func (o *ReadSecurityGroupsRequest) SetFilters(v FiltersSecurityGroup) { + o.Filters = &v +} + +func (o ReadSecurityGroupsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadSecurityGroupsRequest struct { + value *ReadSecurityGroupsRequest + isSet bool +} + +func (v NullableReadSecurityGroupsRequest) Get() *ReadSecurityGroupsRequest { + return v.value +} + +func (v *NullableReadSecurityGroupsRequest) Set(val *ReadSecurityGroupsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSecurityGroupsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSecurityGroupsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSecurityGroupsRequest(val *ReadSecurityGroupsRequest) *NullableReadSecurityGroupsRequest { + return &NullableReadSecurityGroupsRequest{value: val, isSet: true} +} + +func (v NullableReadSecurityGroupsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSecurityGroupsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go new file mode 100644 index 000000000..b8f14fad7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSecurityGroupsResponse struct for ReadSecurityGroupsResponse +type ReadSecurityGroupsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more security groups. + SecurityGroups *[]SecurityGroup `json:"SecurityGroups,omitempty"` +} + +// NewReadSecurityGroupsResponse instantiates a new ReadSecurityGroupsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSecurityGroupsResponse() *ReadSecurityGroupsResponse { + this := ReadSecurityGroupsResponse{} + return &this +} + +// NewReadSecurityGroupsResponseWithDefaults instantiates a new ReadSecurityGroupsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSecurityGroupsResponseWithDefaults() *ReadSecurityGroupsResponse { + this := ReadSecurityGroupsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSecurityGroupsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecurityGroupsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSecurityGroupsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSecurityGroupsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *ReadSecurityGroupsResponse) GetSecurityGroups() []SecurityGroup { + if o == nil || o.SecurityGroups == nil { + var ret []SecurityGroup + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSecurityGroupsResponse) GetSecurityGroupsOk() (*[]SecurityGroup, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *ReadSecurityGroupsResponse) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []SecurityGroup and assigns it to the SecurityGroups field. +func (o *ReadSecurityGroupsResponse) SetSecurityGroups(v []SecurityGroup) { + o.SecurityGroups = &v +} + +func (o ReadSecurityGroupsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + return json.Marshal(toSerialize) +} + +type NullableReadSecurityGroupsResponse struct { + value *ReadSecurityGroupsResponse + isSet bool +} + +func (v NullableReadSecurityGroupsResponse) Get() *ReadSecurityGroupsResponse { + return v.value +} + +func (v *NullableReadSecurityGroupsResponse) Set(val *ReadSecurityGroupsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSecurityGroupsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSecurityGroupsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSecurityGroupsResponse(val *ReadSecurityGroupsResponse) *NullableReadSecurityGroupsResponse { + return &NullableReadSecurityGroupsResponse{value: val, isSet: true} +} + +func (v NullableReadSecurityGroupsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSecurityGroupsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go new file mode 100644 index 000000000..73011ca6a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadServerCertificatesRequest struct for ReadServerCertificatesRequest +type ReadServerCertificatesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersServerCertificate `json:"Filters,omitempty"` +} + +// NewReadServerCertificatesRequest instantiates a new ReadServerCertificatesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadServerCertificatesRequest() *ReadServerCertificatesRequest { + this := ReadServerCertificatesRequest{} + return &this +} + +// NewReadServerCertificatesRequestWithDefaults instantiates a new ReadServerCertificatesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadServerCertificatesRequestWithDefaults() *ReadServerCertificatesRequest { + this := ReadServerCertificatesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadServerCertificatesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadServerCertificatesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadServerCertificatesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadServerCertificatesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadServerCertificatesRequest) GetFilters() FiltersServerCertificate { + if o == nil || o.Filters == nil { + var ret FiltersServerCertificate + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadServerCertificatesRequest) GetFiltersOk() (*FiltersServerCertificate, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadServerCertificatesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersServerCertificate and assigns it to the Filters field. +func (o *ReadServerCertificatesRequest) SetFilters(v FiltersServerCertificate) { + o.Filters = &v +} + +func (o ReadServerCertificatesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadServerCertificatesRequest struct { + value *ReadServerCertificatesRequest + isSet bool +} + +func (v NullableReadServerCertificatesRequest) Get() *ReadServerCertificatesRequest { + return v.value +} + +func (v *NullableReadServerCertificatesRequest) Set(val *ReadServerCertificatesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadServerCertificatesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadServerCertificatesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadServerCertificatesRequest(val *ReadServerCertificatesRequest) *NullableReadServerCertificatesRequest { + return &NullableReadServerCertificatesRequest{value: val, isSet: true} +} + +func (v NullableReadServerCertificatesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadServerCertificatesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go new file mode 100644 index 000000000..cf00b3b60 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadServerCertificatesResponse struct for ReadServerCertificatesResponse +type ReadServerCertificatesResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more server certificates. + ServerCertificates *[]ServerCertificate `json:"ServerCertificates,omitempty"` +} + +// NewReadServerCertificatesResponse instantiates a new ReadServerCertificatesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadServerCertificatesResponse() *ReadServerCertificatesResponse { + this := ReadServerCertificatesResponse{} + return &this +} + +// NewReadServerCertificatesResponseWithDefaults instantiates a new ReadServerCertificatesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadServerCertificatesResponseWithDefaults() *ReadServerCertificatesResponse { + this := ReadServerCertificatesResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadServerCertificatesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadServerCertificatesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadServerCertificatesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadServerCertificatesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetServerCertificates returns the ServerCertificates field value if set, zero value otherwise. +func (o *ReadServerCertificatesResponse) GetServerCertificates() []ServerCertificate { + if o == nil || o.ServerCertificates == nil { + var ret []ServerCertificate + return ret + } + return *o.ServerCertificates +} + +// GetServerCertificatesOk returns a tuple with the ServerCertificates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadServerCertificatesResponse) GetServerCertificatesOk() (*[]ServerCertificate, bool) { + if o == nil || o.ServerCertificates == nil { + return nil, false + } + return o.ServerCertificates, true +} + +// HasServerCertificates returns a boolean if a field has been set. +func (o *ReadServerCertificatesResponse) HasServerCertificates() bool { + if o != nil && o.ServerCertificates != nil { + return true + } + + return false +} + +// SetServerCertificates gets a reference to the given []ServerCertificate and assigns it to the ServerCertificates field. +func (o *ReadServerCertificatesResponse) SetServerCertificates(v []ServerCertificate) { + o.ServerCertificates = &v +} + +func (o ReadServerCertificatesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.ServerCertificates != nil { + toSerialize["ServerCertificates"] = o.ServerCertificates + } + return json.Marshal(toSerialize) +} + +type NullableReadServerCertificatesResponse struct { + value *ReadServerCertificatesResponse + isSet bool +} + +func (v NullableReadServerCertificatesResponse) Get() *ReadServerCertificatesResponse { + return v.value +} + +func (v *NullableReadServerCertificatesResponse) Set(val *ReadServerCertificatesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadServerCertificatesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadServerCertificatesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadServerCertificatesResponse(val *ReadServerCertificatesResponse) *NullableReadServerCertificatesResponse { + return &NullableReadServerCertificatesResponse{value: val, isSet: true} +} + +func (v NullableReadServerCertificatesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadServerCertificatesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go new file mode 100644 index 000000000..bceb0ec6a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSnapshotExportTasksRequest struct for ReadSnapshotExportTasksRequest +type ReadSnapshotExportTasksRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersExportTask `json:"Filters,omitempty"` +} + +// NewReadSnapshotExportTasksRequest instantiates a new ReadSnapshotExportTasksRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSnapshotExportTasksRequest() *ReadSnapshotExportTasksRequest { + this := ReadSnapshotExportTasksRequest{} + return &this +} + +// NewReadSnapshotExportTasksRequestWithDefaults instantiates a new ReadSnapshotExportTasksRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSnapshotExportTasksRequestWithDefaults() *ReadSnapshotExportTasksRequest { + this := ReadSnapshotExportTasksRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSnapshotExportTasksRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotExportTasksRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSnapshotExportTasksRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSnapshotExportTasksRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadSnapshotExportTasksRequest) GetFilters() FiltersExportTask { + if o == nil || o.Filters == nil { + var ret FiltersExportTask + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotExportTasksRequest) GetFiltersOk() (*FiltersExportTask, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadSnapshotExportTasksRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersExportTask and assigns it to the Filters field. +func (o *ReadSnapshotExportTasksRequest) SetFilters(v FiltersExportTask) { + o.Filters = &v +} + +func (o ReadSnapshotExportTasksRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadSnapshotExportTasksRequest struct { + value *ReadSnapshotExportTasksRequest + isSet bool +} + +func (v NullableReadSnapshotExportTasksRequest) Get() *ReadSnapshotExportTasksRequest { + return v.value +} + +func (v *NullableReadSnapshotExportTasksRequest) Set(val *ReadSnapshotExportTasksRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSnapshotExportTasksRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSnapshotExportTasksRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSnapshotExportTasksRequest(val *ReadSnapshotExportTasksRequest) *NullableReadSnapshotExportTasksRequest { + return &NullableReadSnapshotExportTasksRequest{value: val, isSet: true} +} + +func (v NullableReadSnapshotExportTasksRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSnapshotExportTasksRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go new file mode 100644 index 000000000..358c26d95 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSnapshotExportTasksResponse struct for ReadSnapshotExportTasksResponse +type ReadSnapshotExportTasksResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more snapshot export tasks. + SnapshotExportTasks *[]SnapshotExportTask `json:"SnapshotExportTasks,omitempty"` +} + +// NewReadSnapshotExportTasksResponse instantiates a new ReadSnapshotExportTasksResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSnapshotExportTasksResponse() *ReadSnapshotExportTasksResponse { + this := ReadSnapshotExportTasksResponse{} + return &this +} + +// NewReadSnapshotExportTasksResponseWithDefaults instantiates a new ReadSnapshotExportTasksResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSnapshotExportTasksResponseWithDefaults() *ReadSnapshotExportTasksResponse { + this := ReadSnapshotExportTasksResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSnapshotExportTasksResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotExportTasksResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSnapshotExportTasksResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSnapshotExportTasksResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSnapshotExportTasks returns the SnapshotExportTasks field value if set, zero value otherwise. +func (o *ReadSnapshotExportTasksResponse) GetSnapshotExportTasks() []SnapshotExportTask { + if o == nil || o.SnapshotExportTasks == nil { + var ret []SnapshotExportTask + return ret + } + return *o.SnapshotExportTasks +} + +// GetSnapshotExportTasksOk returns a tuple with the SnapshotExportTasks field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotExportTasksResponse) GetSnapshotExportTasksOk() (*[]SnapshotExportTask, bool) { + if o == nil || o.SnapshotExportTasks == nil { + return nil, false + } + return o.SnapshotExportTasks, true +} + +// HasSnapshotExportTasks returns a boolean if a field has been set. +func (o *ReadSnapshotExportTasksResponse) HasSnapshotExportTasks() bool { + if o != nil && o.SnapshotExportTasks != nil { + return true + } + + return false +} + +// SetSnapshotExportTasks gets a reference to the given []SnapshotExportTask and assigns it to the SnapshotExportTasks field. +func (o *ReadSnapshotExportTasksResponse) SetSnapshotExportTasks(v []SnapshotExportTask) { + o.SnapshotExportTasks = &v +} + +func (o ReadSnapshotExportTasksResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.SnapshotExportTasks != nil { + toSerialize["SnapshotExportTasks"] = o.SnapshotExportTasks + } + return json.Marshal(toSerialize) +} + +type NullableReadSnapshotExportTasksResponse struct { + value *ReadSnapshotExportTasksResponse + isSet bool +} + +func (v NullableReadSnapshotExportTasksResponse) Get() *ReadSnapshotExportTasksResponse { + return v.value +} + +func (v *NullableReadSnapshotExportTasksResponse) Set(val *ReadSnapshotExportTasksResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSnapshotExportTasksResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSnapshotExportTasksResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSnapshotExportTasksResponse(val *ReadSnapshotExportTasksResponse) *NullableReadSnapshotExportTasksResponse { + return &NullableReadSnapshotExportTasksResponse{value: val, isSet: true} +} + +func (v NullableReadSnapshotExportTasksResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSnapshotExportTasksResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go new file mode 100644 index 000000000..7e7f124ca --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSnapshotsRequest struct for ReadSnapshotsRequest +type ReadSnapshotsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersSnapshot `json:"Filters,omitempty"` +} + +// NewReadSnapshotsRequest instantiates a new ReadSnapshotsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSnapshotsRequest() *ReadSnapshotsRequest { + this := ReadSnapshotsRequest{} + return &this +} + +// NewReadSnapshotsRequestWithDefaults instantiates a new ReadSnapshotsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSnapshotsRequestWithDefaults() *ReadSnapshotsRequest { + this := ReadSnapshotsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSnapshotsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSnapshotsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSnapshotsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadSnapshotsRequest) GetFilters() FiltersSnapshot { + if o == nil || o.Filters == nil { + var ret FiltersSnapshot + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotsRequest) GetFiltersOk() (*FiltersSnapshot, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadSnapshotsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersSnapshot and assigns it to the Filters field. +func (o *ReadSnapshotsRequest) SetFilters(v FiltersSnapshot) { + o.Filters = &v +} + +func (o ReadSnapshotsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadSnapshotsRequest struct { + value *ReadSnapshotsRequest + isSet bool +} + +func (v NullableReadSnapshotsRequest) Get() *ReadSnapshotsRequest { + return v.value +} + +func (v *NullableReadSnapshotsRequest) Set(val *ReadSnapshotsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSnapshotsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSnapshotsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSnapshotsRequest(val *ReadSnapshotsRequest) *NullableReadSnapshotsRequest { + return &NullableReadSnapshotsRequest{value: val, isSet: true} +} + +func (v NullableReadSnapshotsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSnapshotsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go new file mode 100644 index 000000000..f2d16cb8f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSnapshotsResponse struct for ReadSnapshotsResponse +type ReadSnapshotsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more snapshots and their permissions. + Snapshots *[]Snapshot `json:"Snapshots,omitempty"` +} + +// NewReadSnapshotsResponse instantiates a new ReadSnapshotsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSnapshotsResponse() *ReadSnapshotsResponse { + this := ReadSnapshotsResponse{} + return &this +} + +// NewReadSnapshotsResponseWithDefaults instantiates a new ReadSnapshotsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSnapshotsResponseWithDefaults() *ReadSnapshotsResponse { + this := ReadSnapshotsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSnapshotsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSnapshotsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSnapshotsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSnapshots returns the Snapshots field value if set, zero value otherwise. +func (o *ReadSnapshotsResponse) GetSnapshots() []Snapshot { + if o == nil || o.Snapshots == nil { + var ret []Snapshot + return ret + } + return *o.Snapshots +} + +// GetSnapshotsOk returns a tuple with the Snapshots field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSnapshotsResponse) GetSnapshotsOk() (*[]Snapshot, bool) { + if o == nil || o.Snapshots == nil { + return nil, false + } + return o.Snapshots, true +} + +// HasSnapshots returns a boolean if a field has been set. +func (o *ReadSnapshotsResponse) HasSnapshots() bool { + if o != nil && o.Snapshots != nil { + return true + } + + return false +} + +// SetSnapshots gets a reference to the given []Snapshot and assigns it to the Snapshots field. +func (o *ReadSnapshotsResponse) SetSnapshots(v []Snapshot) { + o.Snapshots = &v +} + +func (o ReadSnapshotsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Snapshots != nil { + toSerialize["Snapshots"] = o.Snapshots + } + return json.Marshal(toSerialize) +} + +type NullableReadSnapshotsResponse struct { + value *ReadSnapshotsResponse + isSet bool +} + +func (v NullableReadSnapshotsResponse) Get() *ReadSnapshotsResponse { + return v.value +} + +func (v *NullableReadSnapshotsResponse) Set(val *ReadSnapshotsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSnapshotsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSnapshotsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSnapshotsResponse(val *ReadSnapshotsResponse) *NullableReadSnapshotsResponse { + return &NullableReadSnapshotsResponse{value: val, isSet: true} +} + +func (v NullableReadSnapshotsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSnapshotsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go new file mode 100644 index 000000000..73987d441 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSubnetsRequest struct for ReadSubnetsRequest +type ReadSubnetsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersSubnet `json:"Filters,omitempty"` +} + +// NewReadSubnetsRequest instantiates a new ReadSubnetsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSubnetsRequest() *ReadSubnetsRequest { + this := ReadSubnetsRequest{} + return &this +} + +// NewReadSubnetsRequestWithDefaults instantiates a new ReadSubnetsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSubnetsRequestWithDefaults() *ReadSubnetsRequest { + this := ReadSubnetsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSubnetsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubnetsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSubnetsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSubnetsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadSubnetsRequest) GetFilters() FiltersSubnet { + if o == nil || o.Filters == nil { + var ret FiltersSubnet + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubnetsRequest) GetFiltersOk() (*FiltersSubnet, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadSubnetsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersSubnet and assigns it to the Filters field. +func (o *ReadSubnetsRequest) SetFilters(v FiltersSubnet) { + o.Filters = &v +} + +func (o ReadSubnetsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadSubnetsRequest struct { + value *ReadSubnetsRequest + isSet bool +} + +func (v NullableReadSubnetsRequest) Get() *ReadSubnetsRequest { + return v.value +} + +func (v *NullableReadSubnetsRequest) Set(val *ReadSubnetsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSubnetsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSubnetsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSubnetsRequest(val *ReadSubnetsRequest) *NullableReadSubnetsRequest { + return &NullableReadSubnetsRequest{value: val, isSet: true} +} + +func (v NullableReadSubnetsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSubnetsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go new file mode 100644 index 000000000..3c64ac4dd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSubnetsResponse struct for ReadSubnetsResponse +type ReadSubnetsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more Subnets. + Subnets *[]Subnet `json:"Subnets,omitempty"` +} + +// NewReadSubnetsResponse instantiates a new ReadSubnetsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSubnetsResponse() *ReadSubnetsResponse { + this := ReadSubnetsResponse{} + return &this +} + +// NewReadSubnetsResponseWithDefaults instantiates a new ReadSubnetsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSubnetsResponseWithDefaults() *ReadSubnetsResponse { + this := ReadSubnetsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSubnetsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubnetsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSubnetsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSubnetsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSubnets returns the Subnets field value if set, zero value otherwise. +func (o *ReadSubnetsResponse) GetSubnets() []Subnet { + if o == nil || o.Subnets == nil { + var ret []Subnet + return ret + } + return *o.Subnets +} + +// GetSubnetsOk returns a tuple with the Subnets field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubnetsResponse) GetSubnetsOk() (*[]Subnet, bool) { + if o == nil || o.Subnets == nil { + return nil, false + } + return o.Subnets, true +} + +// HasSubnets returns a boolean if a field has been set. +func (o *ReadSubnetsResponse) HasSubnets() bool { + if o != nil && o.Subnets != nil { + return true + } + + return false +} + +// SetSubnets gets a reference to the given []Subnet and assigns it to the Subnets field. +func (o *ReadSubnetsResponse) SetSubnets(v []Subnet) { + o.Subnets = &v +} + +func (o ReadSubnetsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Subnets != nil { + toSerialize["Subnets"] = o.Subnets + } + return json.Marshal(toSerialize) +} + +type NullableReadSubnetsResponse struct { + value *ReadSubnetsResponse + isSet bool +} + +func (v NullableReadSubnetsResponse) Get() *ReadSubnetsResponse { + return v.value +} + +func (v *NullableReadSubnetsResponse) Set(val *ReadSubnetsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSubnetsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSubnetsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSubnetsResponse(val *ReadSubnetsResponse) *NullableReadSubnetsResponse { + return &NullableReadSubnetsResponse{value: val, isSet: true} +} + +func (v NullableReadSubnetsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSubnetsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go new file mode 100644 index 000000000..9e0ecb7a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSubregionsRequest struct for ReadSubregionsRequest +type ReadSubregionsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersSubregion `json:"Filters,omitempty"` +} + +// NewReadSubregionsRequest instantiates a new ReadSubregionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSubregionsRequest() *ReadSubregionsRequest { + this := ReadSubregionsRequest{} + return &this +} + +// NewReadSubregionsRequestWithDefaults instantiates a new ReadSubregionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSubregionsRequestWithDefaults() *ReadSubregionsRequest { + this := ReadSubregionsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadSubregionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubregionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadSubregionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadSubregionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadSubregionsRequest) GetFilters() FiltersSubregion { + if o == nil || o.Filters == nil { + var ret FiltersSubregion + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubregionsRequest) GetFiltersOk() (*FiltersSubregion, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadSubregionsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersSubregion and assigns it to the Filters field. +func (o *ReadSubregionsRequest) SetFilters(v FiltersSubregion) { + o.Filters = &v +} + +func (o ReadSubregionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadSubregionsRequest struct { + value *ReadSubregionsRequest + isSet bool +} + +func (v NullableReadSubregionsRequest) Get() *ReadSubregionsRequest { + return v.value +} + +func (v *NullableReadSubregionsRequest) Set(val *ReadSubregionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadSubregionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSubregionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSubregionsRequest(val *ReadSubregionsRequest) *NullableReadSubregionsRequest { + return &NullableReadSubregionsRequest{value: val, isSet: true} +} + +func (v NullableReadSubregionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSubregionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go new file mode 100644 index 000000000..f66b70027 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadSubregionsResponse struct for ReadSubregionsResponse +type ReadSubregionsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more Subregions. + Subregions *[]Subregion `json:"Subregions,omitempty"` +} + +// NewReadSubregionsResponse instantiates a new ReadSubregionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadSubregionsResponse() *ReadSubregionsResponse { + this := ReadSubregionsResponse{} + return &this +} + +// NewReadSubregionsResponseWithDefaults instantiates a new ReadSubregionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadSubregionsResponseWithDefaults() *ReadSubregionsResponse { + this := ReadSubregionsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadSubregionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubregionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadSubregionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadSubregionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSubregions returns the Subregions field value if set, zero value otherwise. +func (o *ReadSubregionsResponse) GetSubregions() []Subregion { + if o == nil || o.Subregions == nil { + var ret []Subregion + return ret + } + return *o.Subregions +} + +// GetSubregionsOk returns a tuple with the Subregions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadSubregionsResponse) GetSubregionsOk() (*[]Subregion, bool) { + if o == nil || o.Subregions == nil { + return nil, false + } + return o.Subregions, true +} + +// HasSubregions returns a boolean if a field has been set. +func (o *ReadSubregionsResponse) HasSubregions() bool { + if o != nil && o.Subregions != nil { + return true + } + + return false +} + +// SetSubregions gets a reference to the given []Subregion and assigns it to the Subregions field. +func (o *ReadSubregionsResponse) SetSubregions(v []Subregion) { + o.Subregions = &v +} + +func (o ReadSubregionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Subregions != nil { + toSerialize["Subregions"] = o.Subregions + } + return json.Marshal(toSerialize) +} + +type NullableReadSubregionsResponse struct { + value *ReadSubregionsResponse + isSet bool +} + +func (v NullableReadSubregionsResponse) Get() *ReadSubregionsResponse { + return v.value +} + +func (v *NullableReadSubregionsResponse) Set(val *ReadSubregionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadSubregionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadSubregionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadSubregionsResponse(val *ReadSubregionsResponse) *NullableReadSubregionsResponse { + return &NullableReadSubregionsResponse{value: val, isSet: true} +} + +func (v NullableReadSubregionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadSubregionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go new file mode 100644 index 000000000..ca756084f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadTagsRequest struct for ReadTagsRequest +type ReadTagsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersTag `json:"Filters,omitempty"` +} + +// NewReadTagsRequest instantiates a new ReadTagsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadTagsRequest() *ReadTagsRequest { + this := ReadTagsRequest{} + return &this +} + +// NewReadTagsRequestWithDefaults instantiates a new ReadTagsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadTagsRequestWithDefaults() *ReadTagsRequest { + this := ReadTagsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadTagsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadTagsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadTagsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadTagsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadTagsRequest) GetFilters() FiltersTag { + if o == nil || o.Filters == nil { + var ret FiltersTag + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadTagsRequest) GetFiltersOk() (*FiltersTag, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadTagsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersTag and assigns it to the Filters field. +func (o *ReadTagsRequest) SetFilters(v FiltersTag) { + o.Filters = &v +} + +func (o ReadTagsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadTagsRequest struct { + value *ReadTagsRequest + isSet bool +} + +func (v NullableReadTagsRequest) Get() *ReadTagsRequest { + return v.value +} + +func (v *NullableReadTagsRequest) Set(val *ReadTagsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadTagsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadTagsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadTagsRequest(val *ReadTagsRequest) *NullableReadTagsRequest { + return &NullableReadTagsRequest{value: val, isSet: true} +} + +func (v NullableReadTagsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadTagsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go new file mode 100644 index 000000000..cfbc6d3a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadTagsResponse struct for ReadTagsResponse +type ReadTagsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more tags. + Tags *[]Tag `json:"Tags,omitempty"` +} + +// NewReadTagsResponse instantiates a new ReadTagsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadTagsResponse() *ReadTagsResponse { + this := ReadTagsResponse{} + return &this +} + +// NewReadTagsResponseWithDefaults instantiates a new ReadTagsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadTagsResponseWithDefaults() *ReadTagsResponse { + this := ReadTagsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadTagsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadTagsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadTagsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadTagsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *ReadTagsResponse) GetTags() []Tag { + if o == nil || o.Tags == nil { + var ret []Tag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadTagsResponse) GetTagsOk() (*[]Tag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *ReadTagsResponse) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []Tag and assigns it to the Tags field. +func (o *ReadTagsResponse) SetTags(v []Tag) { + o.Tags = &v +} + +func (o ReadTagsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableReadTagsResponse struct { + value *ReadTagsResponse + isSet bool +} + +func (v NullableReadTagsResponse) Get() *ReadTagsResponse { + return v.value +} + +func (v *NullableReadTagsResponse) Set(val *ReadTagsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadTagsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadTagsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadTagsResponse(val *ReadTagsResponse) *NullableReadTagsResponse { + return &NullableReadTagsResponse{value: val, isSet: true} +} + +func (v NullableReadTagsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadTagsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go new file mode 100644 index 000000000..e8acb6ad1 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVirtualGatewaysRequest struct for ReadVirtualGatewaysRequest +type ReadVirtualGatewaysRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVirtualGateway `json:"Filters,omitempty"` +} + +// NewReadVirtualGatewaysRequest instantiates a new ReadVirtualGatewaysRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVirtualGatewaysRequest() *ReadVirtualGatewaysRequest { + this := ReadVirtualGatewaysRequest{} + return &this +} + +// NewReadVirtualGatewaysRequestWithDefaults instantiates a new ReadVirtualGatewaysRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVirtualGatewaysRequestWithDefaults() *ReadVirtualGatewaysRequest { + this := ReadVirtualGatewaysRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVirtualGatewaysRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVirtualGatewaysRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVirtualGatewaysRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVirtualGatewaysRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVirtualGatewaysRequest) GetFilters() FiltersVirtualGateway { + if o == nil || o.Filters == nil { + var ret FiltersVirtualGateway + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVirtualGatewaysRequest) GetFiltersOk() (*FiltersVirtualGateway, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVirtualGatewaysRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVirtualGateway and assigns it to the Filters field. +func (o *ReadVirtualGatewaysRequest) SetFilters(v FiltersVirtualGateway) { + o.Filters = &v +} + +func (o ReadVirtualGatewaysRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVirtualGatewaysRequest struct { + value *ReadVirtualGatewaysRequest + isSet bool +} + +func (v NullableReadVirtualGatewaysRequest) Get() *ReadVirtualGatewaysRequest { + return v.value +} + +func (v *NullableReadVirtualGatewaysRequest) Set(val *ReadVirtualGatewaysRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVirtualGatewaysRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVirtualGatewaysRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVirtualGatewaysRequest(val *ReadVirtualGatewaysRequest) *NullableReadVirtualGatewaysRequest { + return &NullableReadVirtualGatewaysRequest{value: val, isSet: true} +} + +func (v NullableReadVirtualGatewaysRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVirtualGatewaysRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go new file mode 100644 index 000000000..fc6ac46e5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVirtualGatewaysResponse struct for ReadVirtualGatewaysResponse +type ReadVirtualGatewaysResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more virtual gateways. + VirtualGateways *[]VirtualGateway `json:"VirtualGateways,omitempty"` +} + +// NewReadVirtualGatewaysResponse instantiates a new ReadVirtualGatewaysResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVirtualGatewaysResponse() *ReadVirtualGatewaysResponse { + this := ReadVirtualGatewaysResponse{} + return &this +} + +// NewReadVirtualGatewaysResponseWithDefaults instantiates a new ReadVirtualGatewaysResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVirtualGatewaysResponseWithDefaults() *ReadVirtualGatewaysResponse { + this := ReadVirtualGatewaysResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVirtualGatewaysResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVirtualGatewaysResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVirtualGatewaysResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVirtualGatewaysResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVirtualGateways returns the VirtualGateways field value if set, zero value otherwise. +func (o *ReadVirtualGatewaysResponse) GetVirtualGateways() []VirtualGateway { + if o == nil || o.VirtualGateways == nil { + var ret []VirtualGateway + return ret + } + return *o.VirtualGateways +} + +// GetVirtualGatewaysOk returns a tuple with the VirtualGateways field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVirtualGatewaysResponse) GetVirtualGatewaysOk() (*[]VirtualGateway, bool) { + if o == nil || o.VirtualGateways == nil { + return nil, false + } + return o.VirtualGateways, true +} + +// HasVirtualGateways returns a boolean if a field has been set. +func (o *ReadVirtualGatewaysResponse) HasVirtualGateways() bool { + if o != nil && o.VirtualGateways != nil { + return true + } + + return false +} + +// SetVirtualGateways gets a reference to the given []VirtualGateway and assigns it to the VirtualGateways field. +func (o *ReadVirtualGatewaysResponse) SetVirtualGateways(v []VirtualGateway) { + o.VirtualGateways = &v +} + +func (o ReadVirtualGatewaysResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VirtualGateways != nil { + toSerialize["VirtualGateways"] = o.VirtualGateways + } + return json.Marshal(toSerialize) +} + +type NullableReadVirtualGatewaysResponse struct { + value *ReadVirtualGatewaysResponse + isSet bool +} + +func (v NullableReadVirtualGatewaysResponse) Get() *ReadVirtualGatewaysResponse { + return v.value +} + +func (v *NullableReadVirtualGatewaysResponse) Set(val *ReadVirtualGatewaysResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVirtualGatewaysResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVirtualGatewaysResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVirtualGatewaysResponse(val *ReadVirtualGatewaysResponse) *NullableReadVirtualGatewaysResponse { + return &NullableReadVirtualGatewaysResponse{value: val, isSet: true} +} + +func (v NullableReadVirtualGatewaysResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVirtualGatewaysResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go new file mode 100644 index 000000000..06f803c8b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmTypesRequest struct for ReadVmTypesRequest +type ReadVmTypesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVmType `json:"Filters,omitempty"` +} + +// NewReadVmTypesRequest instantiates a new ReadVmTypesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmTypesRequest() *ReadVmTypesRequest { + this := ReadVmTypesRequest{} + return &this +} + +// NewReadVmTypesRequestWithDefaults instantiates a new ReadVmTypesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmTypesRequestWithDefaults() *ReadVmTypesRequest { + this := ReadVmTypesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVmTypesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmTypesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVmTypesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVmTypesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVmTypesRequest) GetFilters() FiltersVmType { + if o == nil || o.Filters == nil { + var ret FiltersVmType + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmTypesRequest) GetFiltersOk() (*FiltersVmType, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVmTypesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVmType and assigns it to the Filters field. +func (o *ReadVmTypesRequest) SetFilters(v FiltersVmType) { + o.Filters = &v +} + +func (o ReadVmTypesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVmTypesRequest struct { + value *ReadVmTypesRequest + isSet bool +} + +func (v NullableReadVmTypesRequest) Get() *ReadVmTypesRequest { + return v.value +} + +func (v *NullableReadVmTypesRequest) Set(val *ReadVmTypesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmTypesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmTypesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmTypesRequest(val *ReadVmTypesRequest) *NullableReadVmTypesRequest { + return &NullableReadVmTypesRequest{value: val, isSet: true} +} + +func (v NullableReadVmTypesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmTypesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go new file mode 100644 index 000000000..6010ab950 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmTypesResponse struct for ReadVmTypesResponse +type ReadVmTypesResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more VM types. + VmTypes *[]VmType `json:"VmTypes,omitempty"` +} + +// NewReadVmTypesResponse instantiates a new ReadVmTypesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmTypesResponse() *ReadVmTypesResponse { + this := ReadVmTypesResponse{} + return &this +} + +// NewReadVmTypesResponseWithDefaults instantiates a new ReadVmTypesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmTypesResponseWithDefaults() *ReadVmTypesResponse { + this := ReadVmTypesResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVmTypesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmTypesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVmTypesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVmTypesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVmTypes returns the VmTypes field value if set, zero value otherwise. +func (o *ReadVmTypesResponse) GetVmTypes() []VmType { + if o == nil || o.VmTypes == nil { + var ret []VmType + return ret + } + return *o.VmTypes +} + +// GetVmTypesOk returns a tuple with the VmTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmTypesResponse) GetVmTypesOk() (*[]VmType, bool) { + if o == nil || o.VmTypes == nil { + return nil, false + } + return o.VmTypes, true +} + +// HasVmTypes returns a boolean if a field has been set. +func (o *ReadVmTypesResponse) HasVmTypes() bool { + if o != nil && o.VmTypes != nil { + return true + } + + return false +} + +// SetVmTypes gets a reference to the given []VmType and assigns it to the VmTypes field. +func (o *ReadVmTypesResponse) SetVmTypes(v []VmType) { + o.VmTypes = &v +} + +func (o ReadVmTypesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VmTypes != nil { + toSerialize["VmTypes"] = o.VmTypes + } + return json.Marshal(toSerialize) +} + +type NullableReadVmTypesResponse struct { + value *ReadVmTypesResponse + isSet bool +} + +func (v NullableReadVmTypesResponse) Get() *ReadVmTypesResponse { + return v.value +} + +func (v *NullableReadVmTypesResponse) Set(val *ReadVmTypesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmTypesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmTypesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmTypesResponse(val *ReadVmTypesResponse) *NullableReadVmTypesResponse { + return &NullableReadVmTypesResponse{value: val, isSet: true} +} + +func (v NullableReadVmTypesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmTypesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go new file mode 100644 index 000000000..c6881b211 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsHealthRequest struct for ReadVmsHealthRequest +type ReadVmsHealthRequest struct { + // One or more IDs of back-end VMs. + BackendVmIds *[]string `json:"BackendVmIds,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer. + LoadBalancerName string `json:"LoadBalancerName"` +} + +// NewReadVmsHealthRequest instantiates a new ReadVmsHealthRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsHealthRequest(loadBalancerName string, ) *ReadVmsHealthRequest { + this := ReadVmsHealthRequest{} + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewReadVmsHealthRequestWithDefaults instantiates a new ReadVmsHealthRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsHealthRequestWithDefaults() *ReadVmsHealthRequest { + this := ReadVmsHealthRequest{} + return &this +} + +// GetBackendVmIds returns the BackendVmIds field value if set, zero value otherwise. +func (o *ReadVmsHealthRequest) GetBackendVmIds() []string { + if o == nil || o.BackendVmIds == nil { + var ret []string + return ret + } + return *o.BackendVmIds +} + +// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsHealthRequest) GetBackendVmIdsOk() (*[]string, bool) { + if o == nil || o.BackendVmIds == nil { + return nil, false + } + return o.BackendVmIds, true +} + +// HasBackendVmIds returns a boolean if a field has been set. +func (o *ReadVmsHealthRequest) HasBackendVmIds() bool { + if o != nil && o.BackendVmIds != nil { + return true + } + + return false +} + +// SetBackendVmIds gets a reference to the given []string and assigns it to the BackendVmIds field. +func (o *ReadVmsHealthRequest) SetBackendVmIds(v []string) { + o.BackendVmIds = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVmsHealthRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsHealthRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVmsHealthRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVmsHealthRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *ReadVmsHealthRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *ReadVmsHealthRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *ReadVmsHealthRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +func (o ReadVmsHealthRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BackendVmIds != nil { + toSerialize["BackendVmIds"] = o.BackendVmIds + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsHealthRequest struct { + value *ReadVmsHealthRequest + isSet bool +} + +func (v NullableReadVmsHealthRequest) Get() *ReadVmsHealthRequest { + return v.value +} + +func (v *NullableReadVmsHealthRequest) Set(val *ReadVmsHealthRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsHealthRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsHealthRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsHealthRequest(val *ReadVmsHealthRequest) *NullableReadVmsHealthRequest { + return &NullableReadVmsHealthRequest{value: val, isSet: true} +} + +func (v NullableReadVmsHealthRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsHealthRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go new file mode 100644 index 000000000..fccdc7199 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsHealthResponse struct for ReadVmsHealthResponse +type ReadVmsHealthResponse struct { + // Information about the health of one or more back-end VMs. + BackendVmHealth *[]BackendVmHealth `json:"BackendVmHealth,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewReadVmsHealthResponse instantiates a new ReadVmsHealthResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsHealthResponse() *ReadVmsHealthResponse { + this := ReadVmsHealthResponse{} + return &this +} + +// NewReadVmsHealthResponseWithDefaults instantiates a new ReadVmsHealthResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsHealthResponseWithDefaults() *ReadVmsHealthResponse { + this := ReadVmsHealthResponse{} + return &this +} + +// GetBackendVmHealth returns the BackendVmHealth field value if set, zero value otherwise. +func (o *ReadVmsHealthResponse) GetBackendVmHealth() []BackendVmHealth { + if o == nil || o.BackendVmHealth == nil { + var ret []BackendVmHealth + return ret + } + return *o.BackendVmHealth +} + +// GetBackendVmHealthOk returns a tuple with the BackendVmHealth field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsHealthResponse) GetBackendVmHealthOk() (*[]BackendVmHealth, bool) { + if o == nil || o.BackendVmHealth == nil { + return nil, false + } + return o.BackendVmHealth, true +} + +// HasBackendVmHealth returns a boolean if a field has been set. +func (o *ReadVmsHealthResponse) HasBackendVmHealth() bool { + if o != nil && o.BackendVmHealth != nil { + return true + } + + return false +} + +// SetBackendVmHealth gets a reference to the given []BackendVmHealth and assigns it to the BackendVmHealth field. +func (o *ReadVmsHealthResponse) SetBackendVmHealth(v []BackendVmHealth) { + o.BackendVmHealth = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVmsHealthResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsHealthResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVmsHealthResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVmsHealthResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ReadVmsHealthResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BackendVmHealth != nil { + toSerialize["BackendVmHealth"] = o.BackendVmHealth + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsHealthResponse struct { + value *ReadVmsHealthResponse + isSet bool +} + +func (v NullableReadVmsHealthResponse) Get() *ReadVmsHealthResponse { + return v.value +} + +func (v *NullableReadVmsHealthResponse) Set(val *ReadVmsHealthResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsHealthResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsHealthResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsHealthResponse(val *ReadVmsHealthResponse) *NullableReadVmsHealthResponse { + return &NullableReadVmsHealthResponse{value: val, isSet: true} +} + +func (v NullableReadVmsHealthResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsHealthResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go new file mode 100644 index 000000000..c9db87462 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsRequest struct for ReadVmsRequest +type ReadVmsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVm `json:"Filters,omitempty"` +} + +// NewReadVmsRequest instantiates a new ReadVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsRequest() *ReadVmsRequest { + this := ReadVmsRequest{} + return &this +} + +// NewReadVmsRequestWithDefaults instantiates a new ReadVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsRequestWithDefaults() *ReadVmsRequest { + this := ReadVmsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVmsRequest) GetFilters() FiltersVm { + if o == nil || o.Filters == nil { + var ret FiltersVm + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsRequest) GetFiltersOk() (*FiltersVm, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVmsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVm and assigns it to the Filters field. +func (o *ReadVmsRequest) SetFilters(v FiltersVm) { + o.Filters = &v +} + +func (o ReadVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsRequest struct { + value *ReadVmsRequest + isSet bool +} + +func (v NullableReadVmsRequest) Get() *ReadVmsRequest { + return v.value +} + +func (v *NullableReadVmsRequest) Set(val *ReadVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsRequest(val *ReadVmsRequest) *NullableReadVmsRequest { + return &NullableReadVmsRequest{value: val, isSet: true} +} + +func (v NullableReadVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go new file mode 100644 index 000000000..48d573766 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsResponse struct for ReadVmsResponse +type ReadVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more VMs. + Vms *[]Vm `json:"Vms,omitempty"` +} + +// NewReadVmsResponse instantiates a new ReadVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsResponse() *ReadVmsResponse { + this := ReadVmsResponse{} + return &this +} + +// NewReadVmsResponseWithDefaults instantiates a new ReadVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsResponseWithDefaults() *ReadVmsResponse { + this := ReadVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVms returns the Vms field value if set, zero value otherwise. +func (o *ReadVmsResponse) GetVms() []Vm { + if o == nil || o.Vms == nil { + var ret []Vm + return ret + } + return *o.Vms +} + +// GetVmsOk returns a tuple with the Vms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsResponse) GetVmsOk() (*[]Vm, bool) { + if o == nil || o.Vms == nil { + return nil, false + } + return o.Vms, true +} + +// HasVms returns a boolean if a field has been set. +func (o *ReadVmsResponse) HasVms() bool { + if o != nil && o.Vms != nil { + return true + } + + return false +} + +// SetVms gets a reference to the given []Vm and assigns it to the Vms field. +func (o *ReadVmsResponse) SetVms(v []Vm) { + o.Vms = &v +} + +func (o ReadVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vms != nil { + toSerialize["Vms"] = o.Vms + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsResponse struct { + value *ReadVmsResponse + isSet bool +} + +func (v NullableReadVmsResponse) Get() *ReadVmsResponse { + return v.value +} + +func (v *NullableReadVmsResponse) Set(val *ReadVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsResponse(val *ReadVmsResponse) *NullableReadVmsResponse { + return &NullableReadVmsResponse{value: val, isSet: true} +} + +func (v NullableReadVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go new file mode 100644 index 000000000..55d11b7cc --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go @@ -0,0 +1,190 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsStateRequest struct for ReadVmsStateRequest +type ReadVmsStateRequest struct { + // If `true`, includes the status of all VMs. By default or if set to `false`, only includes the status of running VMs. + AllVms *bool `json:"AllVms,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVmsState `json:"Filters,omitempty"` +} + +// NewReadVmsStateRequest instantiates a new ReadVmsStateRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsStateRequest() *ReadVmsStateRequest { + this := ReadVmsStateRequest{} + return &this +} + +// NewReadVmsStateRequestWithDefaults instantiates a new ReadVmsStateRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsStateRequestWithDefaults() *ReadVmsStateRequest { + this := ReadVmsStateRequest{} + return &this +} + +// GetAllVms returns the AllVms field value if set, zero value otherwise. +func (o *ReadVmsStateRequest) GetAllVms() bool { + if o == nil || o.AllVms == nil { + var ret bool + return ret + } + return *o.AllVms +} + +// GetAllVmsOk returns a tuple with the AllVms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsStateRequest) GetAllVmsOk() (*bool, bool) { + if o == nil || o.AllVms == nil { + return nil, false + } + return o.AllVms, true +} + +// HasAllVms returns a boolean if a field has been set. +func (o *ReadVmsStateRequest) HasAllVms() bool { + if o != nil && o.AllVms != nil { + return true + } + + return false +} + +// SetAllVms gets a reference to the given bool and assigns it to the AllVms field. +func (o *ReadVmsStateRequest) SetAllVms(v bool) { + o.AllVms = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVmsStateRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsStateRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVmsStateRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVmsStateRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVmsStateRequest) GetFilters() FiltersVmsState { + if o == nil || o.Filters == nil { + var ret FiltersVmsState + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsStateRequest) GetFiltersOk() (*FiltersVmsState, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVmsStateRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVmsState and assigns it to the Filters field. +func (o *ReadVmsStateRequest) SetFilters(v FiltersVmsState) { + o.Filters = &v +} + +func (o ReadVmsStateRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AllVms != nil { + toSerialize["AllVms"] = o.AllVms + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsStateRequest struct { + value *ReadVmsStateRequest + isSet bool +} + +func (v NullableReadVmsStateRequest) Get() *ReadVmsStateRequest { + return v.value +} + +func (v *NullableReadVmsStateRequest) Set(val *ReadVmsStateRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsStateRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsStateRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsStateRequest(val *ReadVmsStateRequest) *NullableReadVmsStateRequest { + return &NullableReadVmsStateRequest{value: val, isSet: true} +} + +func (v NullableReadVmsStateRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsStateRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go new file mode 100644 index 000000000..e063b489b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVmsStateResponse struct for ReadVmsStateResponse +type ReadVmsStateResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more VM states. + VmStates *[]VmStates `json:"VmStates,omitempty"` +} + +// NewReadVmsStateResponse instantiates a new ReadVmsStateResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVmsStateResponse() *ReadVmsStateResponse { + this := ReadVmsStateResponse{} + return &this +} + +// NewReadVmsStateResponseWithDefaults instantiates a new ReadVmsStateResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVmsStateResponseWithDefaults() *ReadVmsStateResponse { + this := ReadVmsStateResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVmsStateResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsStateResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVmsStateResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVmsStateResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVmStates returns the VmStates field value if set, zero value otherwise. +func (o *ReadVmsStateResponse) GetVmStates() []VmStates { + if o == nil || o.VmStates == nil { + var ret []VmStates + return ret + } + return *o.VmStates +} + +// GetVmStatesOk returns a tuple with the VmStates field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVmsStateResponse) GetVmStatesOk() (*[]VmStates, bool) { + if o == nil || o.VmStates == nil { + return nil, false + } + return o.VmStates, true +} + +// HasVmStates returns a boolean if a field has been set. +func (o *ReadVmsStateResponse) HasVmStates() bool { + if o != nil && o.VmStates != nil { + return true + } + + return false +} + +// SetVmStates gets a reference to the given []VmStates and assigns it to the VmStates field. +func (o *ReadVmsStateResponse) SetVmStates(v []VmStates) { + o.VmStates = &v +} + +func (o ReadVmsStateResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VmStates != nil { + toSerialize["VmStates"] = o.VmStates + } + return json.Marshal(toSerialize) +} + +type NullableReadVmsStateResponse struct { + value *ReadVmsStateResponse + isSet bool +} + +func (v NullableReadVmsStateResponse) Get() *ReadVmsStateResponse { + return v.value +} + +func (v *NullableReadVmsStateResponse) Set(val *ReadVmsStateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVmsStateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVmsStateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVmsStateResponse(val *ReadVmsStateResponse) *NullableReadVmsStateResponse { + return &NullableReadVmsStateResponse{value: val, isSet: true} +} + +func (v NullableReadVmsStateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVmsStateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go new file mode 100644 index 000000000..f773cd723 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVolumesRequest struct for ReadVolumesRequest +type ReadVolumesRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVolume `json:"Filters,omitempty"` +} + +// NewReadVolumesRequest instantiates a new ReadVolumesRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVolumesRequest() *ReadVolumesRequest { + this := ReadVolumesRequest{} + return &this +} + +// NewReadVolumesRequestWithDefaults instantiates a new ReadVolumesRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVolumesRequestWithDefaults() *ReadVolumesRequest { + this := ReadVolumesRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVolumesRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVolumesRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVolumesRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVolumesRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVolumesRequest) GetFilters() FiltersVolume { + if o == nil || o.Filters == nil { + var ret FiltersVolume + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVolumesRequest) GetFiltersOk() (*FiltersVolume, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVolumesRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVolume and assigns it to the Filters field. +func (o *ReadVolumesRequest) SetFilters(v FiltersVolume) { + o.Filters = &v +} + +func (o ReadVolumesRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVolumesRequest struct { + value *ReadVolumesRequest + isSet bool +} + +func (v NullableReadVolumesRequest) Get() *ReadVolumesRequest { + return v.value +} + +func (v *NullableReadVolumesRequest) Set(val *ReadVolumesRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVolumesRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVolumesRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVolumesRequest(val *ReadVolumesRequest) *NullableReadVolumesRequest { + return &NullableReadVolumesRequest{value: val, isSet: true} +} + +func (v NullableReadVolumesRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVolumesRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go new file mode 100644 index 000000000..055e64f34 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVolumesResponse struct for ReadVolumesResponse +type ReadVolumesResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more volumes. + Volumes *[]Volume `json:"Volumes,omitempty"` +} + +// NewReadVolumesResponse instantiates a new ReadVolumesResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVolumesResponse() *ReadVolumesResponse { + this := ReadVolumesResponse{} + return &this +} + +// NewReadVolumesResponseWithDefaults instantiates a new ReadVolumesResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVolumesResponseWithDefaults() *ReadVolumesResponse { + this := ReadVolumesResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVolumesResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVolumesResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVolumesResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVolumesResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVolumes returns the Volumes field value if set, zero value otherwise. +func (o *ReadVolumesResponse) GetVolumes() []Volume { + if o == nil || o.Volumes == nil { + var ret []Volume + return ret + } + return *o.Volumes +} + +// GetVolumesOk returns a tuple with the Volumes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVolumesResponse) GetVolumesOk() (*[]Volume, bool) { + if o == nil || o.Volumes == nil { + return nil, false + } + return o.Volumes, true +} + +// HasVolumes returns a boolean if a field has been set. +func (o *ReadVolumesResponse) HasVolumes() bool { + if o != nil && o.Volumes != nil { + return true + } + + return false +} + +// SetVolumes gets a reference to the given []Volume and assigns it to the Volumes field. +func (o *ReadVolumesResponse) SetVolumes(v []Volume) { + o.Volumes = &v +} + +func (o ReadVolumesResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Volumes != nil { + toSerialize["Volumes"] = o.Volumes + } + return json.Marshal(toSerialize) +} + +type NullableReadVolumesResponse struct { + value *ReadVolumesResponse + isSet bool +} + +func (v NullableReadVolumesResponse) Get() *ReadVolumesResponse { + return v.value +} + +func (v *NullableReadVolumesResponse) Set(val *ReadVolumesResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVolumesResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVolumesResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVolumesResponse(val *ReadVolumesResponse) *NullableReadVolumesResponse { + return &NullableReadVolumesResponse{value: val, isSet: true} +} + +func (v NullableReadVolumesResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVolumesResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go new file mode 100644 index 000000000..d63ac5e95 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVpnConnectionsRequest struct for ReadVpnConnectionsRequest +type ReadVpnConnectionsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + Filters *FiltersVpnConnection `json:"Filters,omitempty"` +} + +// NewReadVpnConnectionsRequest instantiates a new ReadVpnConnectionsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVpnConnectionsRequest() *ReadVpnConnectionsRequest { + this := ReadVpnConnectionsRequest{} + return &this +} + +// NewReadVpnConnectionsRequestWithDefaults instantiates a new ReadVpnConnectionsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVpnConnectionsRequestWithDefaults() *ReadVpnConnectionsRequest { + this := ReadVpnConnectionsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ReadVpnConnectionsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVpnConnectionsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ReadVpnConnectionsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ReadVpnConnectionsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *ReadVpnConnectionsRequest) GetFilters() FiltersVpnConnection { + if o == nil || o.Filters == nil { + var ret FiltersVpnConnection + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVpnConnectionsRequest) GetFiltersOk() (*FiltersVpnConnection, bool) { + if o == nil || o.Filters == nil { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *ReadVpnConnectionsRequest) HasFilters() bool { + if o != nil && o.Filters != nil { + return true + } + + return false +} + +// SetFilters gets a reference to the given FiltersVpnConnection and assigns it to the Filters field. +func (o *ReadVpnConnectionsRequest) SetFilters(v FiltersVpnConnection) { + o.Filters = &v +} + +func (o ReadVpnConnectionsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Filters != nil { + toSerialize["Filters"] = o.Filters + } + return json.Marshal(toSerialize) +} + +type NullableReadVpnConnectionsRequest struct { + value *ReadVpnConnectionsRequest + isSet bool +} + +func (v NullableReadVpnConnectionsRequest) Get() *ReadVpnConnectionsRequest { + return v.value +} + +func (v *NullableReadVpnConnectionsRequest) Set(val *ReadVpnConnectionsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableReadVpnConnectionsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVpnConnectionsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVpnConnectionsRequest(val *ReadVpnConnectionsRequest) *NullableReadVpnConnectionsRequest { + return &NullableReadVpnConnectionsRequest{value: val, isSet: true} +} + +func (v NullableReadVpnConnectionsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVpnConnectionsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go new file mode 100644 index 000000000..4f39290cf --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ReadVpnConnectionsResponse struct for ReadVpnConnectionsResponse +type ReadVpnConnectionsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more VPN connections. + VpnConnections *[]VpnConnection `json:"VpnConnections,omitempty"` +} + +// NewReadVpnConnectionsResponse instantiates a new ReadVpnConnectionsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewReadVpnConnectionsResponse() *ReadVpnConnectionsResponse { + this := ReadVpnConnectionsResponse{} + return &this +} + +// NewReadVpnConnectionsResponseWithDefaults instantiates a new ReadVpnConnectionsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewReadVpnConnectionsResponseWithDefaults() *ReadVpnConnectionsResponse { + this := ReadVpnConnectionsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ReadVpnConnectionsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVpnConnectionsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ReadVpnConnectionsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ReadVpnConnectionsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVpnConnections returns the VpnConnections field value if set, zero value otherwise. +func (o *ReadVpnConnectionsResponse) GetVpnConnections() []VpnConnection { + if o == nil || o.VpnConnections == nil { + var ret []VpnConnection + return ret + } + return *o.VpnConnections +} + +// GetVpnConnectionsOk returns a tuple with the VpnConnections field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ReadVpnConnectionsResponse) GetVpnConnectionsOk() (*[]VpnConnection, bool) { + if o == nil || o.VpnConnections == nil { + return nil, false + } + return o.VpnConnections, true +} + +// HasVpnConnections returns a boolean if a field has been set. +func (o *ReadVpnConnectionsResponse) HasVpnConnections() bool { + if o != nil && o.VpnConnections != nil { + return true + } + + return false +} + +// SetVpnConnections gets a reference to the given []VpnConnection and assigns it to the VpnConnections field. +func (o *ReadVpnConnectionsResponse) SetVpnConnections(v []VpnConnection) { + o.VpnConnections = &v +} + +func (o ReadVpnConnectionsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.VpnConnections != nil { + toSerialize["VpnConnections"] = o.VpnConnections + } + return json.Marshal(toSerialize) +} + +type NullableReadVpnConnectionsResponse struct { + value *ReadVpnConnectionsResponse + isSet bool +} + +func (v NullableReadVpnConnectionsResponse) Get() *ReadVpnConnectionsResponse { + return v.value +} + +func (v *NullableReadVpnConnectionsResponse) Set(val *ReadVpnConnectionsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableReadVpnConnectionsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableReadVpnConnectionsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableReadVpnConnectionsResponse(val *ReadVpnConnectionsResponse) *NullableReadVpnConnectionsResponse { + return &NullableReadVpnConnectionsResponse{value: val, isSet: true} +} + +func (v NullableReadVpnConnectionsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableReadVpnConnectionsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go new file mode 100644 index 000000000..6efbbb14b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RebootVmsRequest struct for RebootVmsRequest +type RebootVmsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more IDs of the VMs you want to reboot. + VmIds []string `json:"VmIds"` +} + +// NewRebootVmsRequest instantiates a new RebootVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRebootVmsRequest(vmIds []string, ) *RebootVmsRequest { + this := RebootVmsRequest{} + this.VmIds = vmIds + return &this +} + +// NewRebootVmsRequestWithDefaults instantiates a new RebootVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRebootVmsRequestWithDefaults() *RebootVmsRequest { + this := RebootVmsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *RebootVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RebootVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *RebootVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *RebootVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmIds returns the VmIds field value +func (o *RebootVmsRequest) GetVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value +// and a boolean to check if the value has been set. +func (o *RebootVmsRequest) GetVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.VmIds, true +} + +// SetVmIds sets field value +func (o *RebootVmsRequest) SetVmIds(v []string) { + o.VmIds = v +} + +func (o RebootVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableRebootVmsRequest struct { + value *RebootVmsRequest + isSet bool +} + +func (v NullableRebootVmsRequest) Get() *RebootVmsRequest { + return v.value +} + +func (v *NullableRebootVmsRequest) Set(val *RebootVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableRebootVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableRebootVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRebootVmsRequest(val *RebootVmsRequest) *NullableRebootVmsRequest { + return &NullableRebootVmsRequest{value: val, isSet: true} +} + +func (v NullableRebootVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRebootVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go new file mode 100644 index 000000000..fd9e1871c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RebootVmsResponse struct for RebootVmsResponse +type RebootVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewRebootVmsResponse instantiates a new RebootVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRebootVmsResponse() *RebootVmsResponse { + this := RebootVmsResponse{} + return &this +} + +// NewRebootVmsResponseWithDefaults instantiates a new RebootVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRebootVmsResponseWithDefaults() *RebootVmsResponse { + this := RebootVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *RebootVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RebootVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *RebootVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *RebootVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o RebootVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableRebootVmsResponse struct { + value *RebootVmsResponse + isSet bool +} + +func (v NullableRebootVmsResponse) Get() *RebootVmsResponse { + return v.value +} + +func (v *NullableRebootVmsResponse) Set(val *RebootVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableRebootVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableRebootVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRebootVmsResponse(val *RebootVmsResponse) *NullableRebootVmsResponse { + return &NullableRebootVmsResponse{value: val, isSet: true} +} + +func (v NullableRebootVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRebootVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_region.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_region.go new file mode 100644 index 000000000..0ae1ac42c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_region.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Region Information about the Region. +type Region struct { + // The hostname of the gateway to access the Region. + Endpoint *string `json:"Endpoint,omitempty"` + // The administrative name of the Region. + RegionName *string `json:"RegionName,omitempty"` +} + +// NewRegion instantiates a new Region object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRegion() *Region { + this := Region{} + return &this +} + +// NewRegionWithDefaults instantiates a new Region object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRegionWithDefaults() *Region { + this := Region{} + return &this +} + +// GetEndpoint returns the Endpoint field value if set, zero value otherwise. +func (o *Region) GetEndpoint() string { + if o == nil || o.Endpoint == nil { + var ret string + return ret + } + return *o.Endpoint +} + +// GetEndpointOk returns a tuple with the Endpoint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Region) GetEndpointOk() (*string, bool) { + if o == nil || o.Endpoint == nil { + return nil, false + } + return o.Endpoint, true +} + +// HasEndpoint returns a boolean if a field has been set. +func (o *Region) HasEndpoint() bool { + if o != nil && o.Endpoint != nil { + return true + } + + return false +} + +// SetEndpoint gets a reference to the given string and assigns it to the Endpoint field. +func (o *Region) SetEndpoint(v string) { + o.Endpoint = &v +} + +// GetRegionName returns the RegionName field value if set, zero value otherwise. +func (o *Region) GetRegionName() string { + if o == nil || o.RegionName == nil { + var ret string + return ret + } + return *o.RegionName +} + +// GetRegionNameOk returns a tuple with the RegionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Region) GetRegionNameOk() (*string, bool) { + if o == nil || o.RegionName == nil { + return nil, false + } + return o.RegionName, true +} + +// HasRegionName returns a boolean if a field has been set. +func (o *Region) HasRegionName() bool { + if o != nil && o.RegionName != nil { + return true + } + + return false +} + +// SetRegionName gets a reference to the given string and assigns it to the RegionName field. +func (o *Region) SetRegionName(v string) { + o.RegionName = &v +} + +func (o Region) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Endpoint != nil { + toSerialize["Endpoint"] = o.Endpoint + } + if o.RegionName != nil { + toSerialize["RegionName"] = o.RegionName + } + return json.Marshal(toSerialize) +} + +type NullableRegion struct { + value *Region + isSet bool +} + +func (v NullableRegion) Get() *Region { + return v.value +} + +func (v *NullableRegion) Set(val *Region) { + v.value = val + v.isSet = true +} + +func (v NullableRegion) IsSet() bool { + return v.isSet +} + +func (v *NullableRegion) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRegion(val *Region) *NullableRegion { + return &NullableRegion{value: val, isSet: true} +} + +func (v NullableRegion) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRegion) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go new file mode 100644 index 000000000..775e0412a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RegisterVmsInLoadBalancerRequest struct for RegisterVmsInLoadBalancerRequest +type RegisterVmsInLoadBalancerRequest struct { + // One or more IDs of back-end VMs.
Specifying the same ID several times has no effect as each back-end VM has equal weight. + BackendVmIds []string `json:"BackendVmIds"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the load balancer. + LoadBalancerName string `json:"LoadBalancerName"` +} + +// NewRegisterVmsInLoadBalancerRequest instantiates a new RegisterVmsInLoadBalancerRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRegisterVmsInLoadBalancerRequest(backendVmIds []string, loadBalancerName string, ) *RegisterVmsInLoadBalancerRequest { + this := RegisterVmsInLoadBalancerRequest{} + this.BackendVmIds = backendVmIds + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewRegisterVmsInLoadBalancerRequestWithDefaults instantiates a new RegisterVmsInLoadBalancerRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRegisterVmsInLoadBalancerRequestWithDefaults() *RegisterVmsInLoadBalancerRequest { + this := RegisterVmsInLoadBalancerRequest{} + return &this +} + +// GetBackendVmIds returns the BackendVmIds field value +func (o *RegisterVmsInLoadBalancerRequest) GetBackendVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.BackendVmIds +} + +// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value +// and a boolean to check if the value has been set. +func (o *RegisterVmsInLoadBalancerRequest) GetBackendVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.BackendVmIds, true +} + +// SetBackendVmIds sets field value +func (o *RegisterVmsInLoadBalancerRequest) SetBackendVmIds(v []string) { + o.BackendVmIds = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *RegisterVmsInLoadBalancerRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RegisterVmsInLoadBalancerRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *RegisterVmsInLoadBalancerRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *RegisterVmsInLoadBalancerRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *RegisterVmsInLoadBalancerRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *RegisterVmsInLoadBalancerRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *RegisterVmsInLoadBalancerRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +func (o RegisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["BackendVmIds"] = o.BackendVmIds + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + return json.Marshal(toSerialize) +} + +type NullableRegisterVmsInLoadBalancerRequest struct { + value *RegisterVmsInLoadBalancerRequest + isSet bool +} + +func (v NullableRegisterVmsInLoadBalancerRequest) Get() *RegisterVmsInLoadBalancerRequest { + return v.value +} + +func (v *NullableRegisterVmsInLoadBalancerRequest) Set(val *RegisterVmsInLoadBalancerRequest) { + v.value = val + v.isSet = true +} + +func (v NullableRegisterVmsInLoadBalancerRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableRegisterVmsInLoadBalancerRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRegisterVmsInLoadBalancerRequest(val *RegisterVmsInLoadBalancerRequest) *NullableRegisterVmsInLoadBalancerRequest { + return &NullableRegisterVmsInLoadBalancerRequest{value: val, isSet: true} +} + +func (v NullableRegisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRegisterVmsInLoadBalancerRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go new file mode 100644 index 000000000..3685cbd1a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RegisterVmsInLoadBalancerResponse struct for RegisterVmsInLoadBalancerResponse +type RegisterVmsInLoadBalancerResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewRegisterVmsInLoadBalancerResponse instantiates a new RegisterVmsInLoadBalancerResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRegisterVmsInLoadBalancerResponse() *RegisterVmsInLoadBalancerResponse { + this := RegisterVmsInLoadBalancerResponse{} + return &this +} + +// NewRegisterVmsInLoadBalancerResponseWithDefaults instantiates a new RegisterVmsInLoadBalancerResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRegisterVmsInLoadBalancerResponseWithDefaults() *RegisterVmsInLoadBalancerResponse { + this := RegisterVmsInLoadBalancerResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *RegisterVmsInLoadBalancerResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RegisterVmsInLoadBalancerResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *RegisterVmsInLoadBalancerResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *RegisterVmsInLoadBalancerResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o RegisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableRegisterVmsInLoadBalancerResponse struct { + value *RegisterVmsInLoadBalancerResponse + isSet bool +} + +func (v NullableRegisterVmsInLoadBalancerResponse) Get() *RegisterVmsInLoadBalancerResponse { + return v.value +} + +func (v *NullableRegisterVmsInLoadBalancerResponse) Set(val *RegisterVmsInLoadBalancerResponse) { + v.value = val + v.isSet = true +} + +func (v NullableRegisterVmsInLoadBalancerResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableRegisterVmsInLoadBalancerResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRegisterVmsInLoadBalancerResponse(val *RegisterVmsInLoadBalancerResponse) *NullableRegisterVmsInLoadBalancerResponse { + return &NullableRegisterVmsInLoadBalancerResponse{value: val, isSet: true} +} + +func (v NullableRegisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRegisterVmsInLoadBalancerResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go new file mode 100644 index 000000000..7b9033f7b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RejectNetPeeringRequest struct for RejectNetPeeringRequest +type RejectNetPeeringRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net peering connection you want to reject. + NetPeeringId string `json:"NetPeeringId"` +} + +// NewRejectNetPeeringRequest instantiates a new RejectNetPeeringRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRejectNetPeeringRequest(netPeeringId string, ) *RejectNetPeeringRequest { + this := RejectNetPeeringRequest{} + this.NetPeeringId = netPeeringId + return &this +} + +// NewRejectNetPeeringRequestWithDefaults instantiates a new RejectNetPeeringRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRejectNetPeeringRequestWithDefaults() *RejectNetPeeringRequest { + this := RejectNetPeeringRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *RejectNetPeeringRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RejectNetPeeringRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *RejectNetPeeringRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *RejectNetPeeringRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetPeeringId returns the NetPeeringId field value +func (o *RejectNetPeeringRequest) GetNetPeeringId() string { + if o == nil { + var ret string + return ret + } + + return o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value +// and a boolean to check if the value has been set. +func (o *RejectNetPeeringRequest) GetNetPeeringIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetPeeringId, true +} + +// SetNetPeeringId sets field value +func (o *RejectNetPeeringRequest) SetNetPeeringId(v string) { + o.NetPeeringId = v +} + +func (o RejectNetPeeringRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + return json.Marshal(toSerialize) +} + +type NullableRejectNetPeeringRequest struct { + value *RejectNetPeeringRequest + isSet bool +} + +func (v NullableRejectNetPeeringRequest) Get() *RejectNetPeeringRequest { + return v.value +} + +func (v *NullableRejectNetPeeringRequest) Set(val *RejectNetPeeringRequest) { + v.value = val + v.isSet = true +} + +func (v NullableRejectNetPeeringRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableRejectNetPeeringRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRejectNetPeeringRequest(val *RejectNetPeeringRequest) *NullableRejectNetPeeringRequest { + return &NullableRejectNetPeeringRequest{value: val, isSet: true} +} + +func (v NullableRejectNetPeeringRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRejectNetPeeringRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go new file mode 100644 index 000000000..07dd5b382 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RejectNetPeeringResponse struct for RejectNetPeeringResponse +type RejectNetPeeringResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewRejectNetPeeringResponse instantiates a new RejectNetPeeringResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRejectNetPeeringResponse() *RejectNetPeeringResponse { + this := RejectNetPeeringResponse{} + return &this +} + +// NewRejectNetPeeringResponseWithDefaults instantiates a new RejectNetPeeringResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRejectNetPeeringResponseWithDefaults() *RejectNetPeeringResponse { + this := RejectNetPeeringResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *RejectNetPeeringResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RejectNetPeeringResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *RejectNetPeeringResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *RejectNetPeeringResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o RejectNetPeeringResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableRejectNetPeeringResponse struct { + value *RejectNetPeeringResponse + isSet bool +} + +func (v NullableRejectNetPeeringResponse) Get() *RejectNetPeeringResponse { + return v.value +} + +func (v *NullableRejectNetPeeringResponse) Set(val *RejectNetPeeringResponse) { + v.value = val + v.isSet = true +} + +func (v NullableRejectNetPeeringResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableRejectNetPeeringResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRejectNetPeeringResponse(val *RejectNetPeeringResponse) *NullableRejectNetPeeringResponse { + return &NullableRejectNetPeeringResponse{value: val, isSet: true} +} + +func (v NullableRejectNetPeeringResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRejectNetPeeringResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go new file mode 100644 index 000000000..55f27ce92 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ResetAccountPasswordRequest struct for ResetAccountPasswordRequest +type ResetAccountPasswordRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The new password for the account. + Password string `json:"Password"` + // The token you received at the email address provided for the account. + Token string `json:"Token"` +} + +// NewResetAccountPasswordRequest instantiates a new ResetAccountPasswordRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewResetAccountPasswordRequest(password string, token string, ) *ResetAccountPasswordRequest { + this := ResetAccountPasswordRequest{} + this.Password = password + this.Token = token + return &this +} + +// NewResetAccountPasswordRequestWithDefaults instantiates a new ResetAccountPasswordRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewResetAccountPasswordRequestWithDefaults() *ResetAccountPasswordRequest { + this := ResetAccountPasswordRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *ResetAccountPasswordRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ResetAccountPasswordRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *ResetAccountPasswordRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *ResetAccountPasswordRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPassword returns the Password field value +func (o *ResetAccountPasswordRequest) GetPassword() string { + if o == nil { + var ret string + return ret + } + + return o.Password +} + +// GetPasswordOk returns a tuple with the Password field value +// and a boolean to check if the value has been set. +func (o *ResetAccountPasswordRequest) GetPasswordOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Password, true +} + +// SetPassword sets field value +func (o *ResetAccountPasswordRequest) SetPassword(v string) { + o.Password = v +} + +// GetToken returns the Token field value +func (o *ResetAccountPasswordRequest) GetToken() string { + if o == nil { + var ret string + return ret + } + + return o.Token +} + +// GetTokenOk returns a tuple with the Token field value +// and a boolean to check if the value has been set. +func (o *ResetAccountPasswordRequest) GetTokenOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Token, true +} + +// SetToken sets field value +func (o *ResetAccountPasswordRequest) SetToken(v string) { + o.Token = v +} + +func (o ResetAccountPasswordRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Password"] = o.Password + } + if true { + toSerialize["Token"] = o.Token + } + return json.Marshal(toSerialize) +} + +type NullableResetAccountPasswordRequest struct { + value *ResetAccountPasswordRequest + isSet bool +} + +func (v NullableResetAccountPasswordRequest) Get() *ResetAccountPasswordRequest { + return v.value +} + +func (v *NullableResetAccountPasswordRequest) Set(val *ResetAccountPasswordRequest) { + v.value = val + v.isSet = true +} + +func (v NullableResetAccountPasswordRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableResetAccountPasswordRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResetAccountPasswordRequest(val *ResetAccountPasswordRequest) *NullableResetAccountPasswordRequest { + return &NullableResetAccountPasswordRequest{value: val, isSet: true} +} + +func (v NullableResetAccountPasswordRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResetAccountPasswordRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go new file mode 100644 index 000000000..f1a9a183e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ResetAccountPasswordResponse struct for ResetAccountPasswordResponse +type ResetAccountPasswordResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewResetAccountPasswordResponse instantiates a new ResetAccountPasswordResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewResetAccountPasswordResponse() *ResetAccountPasswordResponse { + this := ResetAccountPasswordResponse{} + return &this +} + +// NewResetAccountPasswordResponseWithDefaults instantiates a new ResetAccountPasswordResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewResetAccountPasswordResponseWithDefaults() *ResetAccountPasswordResponse { + this := ResetAccountPasswordResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *ResetAccountPasswordResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ResetAccountPasswordResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *ResetAccountPasswordResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *ResetAccountPasswordResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o ResetAccountPasswordResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableResetAccountPasswordResponse struct { + value *ResetAccountPasswordResponse + isSet bool +} + +func (v NullableResetAccountPasswordResponse) Get() *ResetAccountPasswordResponse { + return v.value +} + +func (v *NullableResetAccountPasswordResponse) Set(val *ResetAccountPasswordResponse) { + v.value = val + v.isSet = true +} + +func (v NullableResetAccountPasswordResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableResetAccountPasswordResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResetAccountPasswordResponse(val *ResetAccountPasswordResponse) *NullableResetAccountPasswordResponse { + return &NullableResetAccountPasswordResponse{value: val, isSet: true} +} + +func (v NullableResetAccountPasswordResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResetAccountPasswordResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go new file mode 100644 index 000000000..90a7845a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ResourceLoadBalancerTag Information about the tag. +type ResourceLoadBalancerTag struct { + // The key of the tag, with a minimum of 1 character. + Key *string `json:"Key,omitempty"` +} + +// NewResourceLoadBalancerTag instantiates a new ResourceLoadBalancerTag object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewResourceLoadBalancerTag() *ResourceLoadBalancerTag { + this := ResourceLoadBalancerTag{} + return &this +} + +// NewResourceLoadBalancerTagWithDefaults instantiates a new ResourceLoadBalancerTag object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewResourceLoadBalancerTagWithDefaults() *ResourceLoadBalancerTag { + this := ResourceLoadBalancerTag{} + return &this +} + +// GetKey returns the Key field value if set, zero value otherwise. +func (o *ResourceLoadBalancerTag) GetKey() string { + if o == nil || o.Key == nil { + var ret string + return ret + } + return *o.Key +} + +// GetKeyOk returns a tuple with the Key field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ResourceLoadBalancerTag) GetKeyOk() (*string, bool) { + if o == nil || o.Key == nil { + return nil, false + } + return o.Key, true +} + +// HasKey returns a boolean if a field has been set. +func (o *ResourceLoadBalancerTag) HasKey() bool { + if o != nil && o.Key != nil { + return true + } + + return false +} + +// SetKey gets a reference to the given string and assigns it to the Key field. +func (o *ResourceLoadBalancerTag) SetKey(v string) { + o.Key = &v +} + +func (o ResourceLoadBalancerTag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Key != nil { + toSerialize["Key"] = o.Key + } + return json.Marshal(toSerialize) +} + +type NullableResourceLoadBalancerTag struct { + value *ResourceLoadBalancerTag + isSet bool +} + +func (v NullableResourceLoadBalancerTag) Get() *ResourceLoadBalancerTag { + return v.value +} + +func (v *NullableResourceLoadBalancerTag) Set(val *ResourceLoadBalancerTag) { + v.value = val + v.isSet = true +} + +func (v NullableResourceLoadBalancerTag) IsSet() bool { + return v.isSet +} + +func (v *NullableResourceLoadBalancerTag) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResourceLoadBalancerTag(val *ResourceLoadBalancerTag) *NullableResourceLoadBalancerTag { + return &NullableResourceLoadBalancerTag{value: val, isSet: true} +} + +func (v NullableResourceLoadBalancerTag) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResourceLoadBalancerTag) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go new file mode 100644 index 000000000..a58520284 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go @@ -0,0 +1,140 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ResourceTag Information about the tag. +type ResourceTag struct { + // The key of the tag, with a minimum of 1 character. + Key string `json:"Key"` + // The value of the tag, between 0 and 255 characters. + Value string `json:"Value"` +} + +// NewResourceTag instantiates a new ResourceTag object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewResourceTag(key string, value string, ) *ResourceTag { + this := ResourceTag{} + this.Key = key + this.Value = value + return &this +} + +// NewResourceTagWithDefaults instantiates a new ResourceTag object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewResourceTagWithDefaults() *ResourceTag { + this := ResourceTag{} + return &this +} + +// GetKey returns the Key field value +func (o *ResourceTag) GetKey() string { + if o == nil { + var ret string + return ret + } + + return o.Key +} + +// GetKeyOk returns a tuple with the Key field value +// and a boolean to check if the value has been set. +func (o *ResourceTag) GetKeyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Key, true +} + +// SetKey sets field value +func (o *ResourceTag) SetKey(v string) { + o.Key = v +} + +// GetValue returns the Value field value +func (o *ResourceTag) GetValue() string { + if o == nil { + var ret string + return ret + } + + return o.Value +} + +// GetValueOk returns a tuple with the Value field value +// and a boolean to check if the value has been set. +func (o *ResourceTag) GetValueOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Value, true +} + +// SetValue sets field value +func (o *ResourceTag) SetValue(v string) { + o.Value = v +} + +func (o ResourceTag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["Key"] = o.Key + } + if true { + toSerialize["Value"] = o.Value + } + return json.Marshal(toSerialize) +} + +type NullableResourceTag struct { + value *ResourceTag + isSet bool +} + +func (v NullableResourceTag) Get() *ResourceTag { + return v.value +} + +func (v *NullableResourceTag) Set(val *ResourceTag) { + v.value = val + v.isSet = true +} + +func (v NullableResourceTag) IsSet() bool { + return v.isSet +} + +func (v *NullableResourceTag) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResourceTag(val *ResourceTag) *NullableResourceTag { + return &NullableResourceTag{value: val, isSet: true} +} + +func (v NullableResourceTag) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResourceTag) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go new file mode 100644 index 000000000..6036365aa --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ResponseContext Information about the context of the response. +type ResponseContext struct { + // The ID of the request. + RequestId *string `json:"RequestId,omitempty"` +} + +// NewResponseContext instantiates a new ResponseContext object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewResponseContext() *ResponseContext { + this := ResponseContext{} + return &this +} + +// NewResponseContextWithDefaults instantiates a new ResponseContext object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewResponseContextWithDefaults() *ResponseContext { + this := ResponseContext{} + return &this +} + +// GetRequestId returns the RequestId field value if set, zero value otherwise. +func (o *ResponseContext) GetRequestId() string { + if o == nil || o.RequestId == nil { + var ret string + return ret + } + return *o.RequestId +} + +// GetRequestIdOk returns a tuple with the RequestId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ResponseContext) GetRequestIdOk() (*string, bool) { + if o == nil || o.RequestId == nil { + return nil, false + } + return o.RequestId, true +} + +// HasRequestId returns a boolean if a field has been set. +func (o *ResponseContext) HasRequestId() bool { + if o != nil && o.RequestId != nil { + return true + } + + return false +} + +// SetRequestId gets a reference to the given string and assigns it to the RequestId field. +func (o *ResponseContext) SetRequestId(v string) { + o.RequestId = &v +} + +func (o ResponseContext) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.RequestId != nil { + toSerialize["RequestId"] = o.RequestId + } + return json.Marshal(toSerialize) +} + +type NullableResponseContext struct { + value *ResponseContext + isSet bool +} + +func (v NullableResponseContext) Get() *ResponseContext { + return v.value +} + +func (v *NullableResponseContext) Set(val *ResponseContext) { + v.value = val + v.isSet = true +} + +func (v NullableResponseContext) IsSet() bool { + return v.isSet +} + +func (v *NullableResponseContext) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableResponseContext(val *ResponseContext) *NullableResponseContext { + return &NullableResponseContext{value: val, isSet: true} +} + +func (v NullableResponseContext) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableResponseContext) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_route.go new file mode 100644 index 000000000..09185c2ba --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_route.go @@ -0,0 +1,487 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Route Information about the route. +type Route struct { + // The method used to create the route. + CreationMethod *string `json:"CreationMethod,omitempty"` + // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + DestinationIpRange *string `json:"DestinationIpRange,omitempty"` + // The ID of the 3DS OUTSCALE service. + DestinationServiceId *string `json:"DestinationServiceId,omitempty"` + // The ID of the Internet service or virtual gateway attached to the Net. + GatewayId *string `json:"GatewayId,omitempty"` + // The ID of a NAT service attached to the Net. + NatServiceId *string `json:"NatServiceId,omitempty"` + // The ID of the Net access point. + NetAccessPointId *string `json:"NetAccessPointId,omitempty"` + // The ID of the Net peering connection. + NetPeeringId *string `json:"NetPeeringId,omitempty"` + // The ID of the NIC. + NicId *string `json:"NicId,omitempty"` + // The state of a route in the route table (`active` \\| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + State *string `json:"State,omitempty"` + // The account ID of the owner of the VM. + VmAccountId *string `json:"VmAccountId,omitempty"` + // The ID of a VM specified in a route in the table. + VmId *string `json:"VmId,omitempty"` +} + +// NewRoute instantiates a new Route object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRoute() *Route { + this := Route{} + return &this +} + +// NewRouteWithDefaults instantiates a new Route object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRouteWithDefaults() *Route { + this := Route{} + return &this +} + +// GetCreationMethod returns the CreationMethod field value if set, zero value otherwise. +func (o *Route) GetCreationMethod() string { + if o == nil || o.CreationMethod == nil { + var ret string + return ret + } + return *o.CreationMethod +} + +// GetCreationMethodOk returns a tuple with the CreationMethod field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetCreationMethodOk() (*string, bool) { + if o == nil || o.CreationMethod == nil { + return nil, false + } + return o.CreationMethod, true +} + +// HasCreationMethod returns a boolean if a field has been set. +func (o *Route) HasCreationMethod() bool { + if o != nil && o.CreationMethod != nil { + return true + } + + return false +} + +// SetCreationMethod gets a reference to the given string and assigns it to the CreationMethod field. +func (o *Route) SetCreationMethod(v string) { + o.CreationMethod = &v +} + +// GetDestinationIpRange returns the DestinationIpRange field value if set, zero value otherwise. +func (o *Route) GetDestinationIpRange() string { + if o == nil || o.DestinationIpRange == nil { + var ret string + return ret + } + return *o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetDestinationIpRangeOk() (*string, bool) { + if o == nil || o.DestinationIpRange == nil { + return nil, false + } + return o.DestinationIpRange, true +} + +// HasDestinationIpRange returns a boolean if a field has been set. +func (o *Route) HasDestinationIpRange() bool { + if o != nil && o.DestinationIpRange != nil { + return true + } + + return false +} + +// SetDestinationIpRange gets a reference to the given string and assigns it to the DestinationIpRange field. +func (o *Route) SetDestinationIpRange(v string) { + o.DestinationIpRange = &v +} + +// GetDestinationServiceId returns the DestinationServiceId field value if set, zero value otherwise. +func (o *Route) GetDestinationServiceId() string { + if o == nil || o.DestinationServiceId == nil { + var ret string + return ret + } + return *o.DestinationServiceId +} + +// GetDestinationServiceIdOk returns a tuple with the DestinationServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetDestinationServiceIdOk() (*string, bool) { + if o == nil || o.DestinationServiceId == nil { + return nil, false + } + return o.DestinationServiceId, true +} + +// HasDestinationServiceId returns a boolean if a field has been set. +func (o *Route) HasDestinationServiceId() bool { + if o != nil && o.DestinationServiceId != nil { + return true + } + + return false +} + +// SetDestinationServiceId gets a reference to the given string and assigns it to the DestinationServiceId field. +func (o *Route) SetDestinationServiceId(v string) { + o.DestinationServiceId = &v +} + +// GetGatewayId returns the GatewayId field value if set, zero value otherwise. +func (o *Route) GetGatewayId() string { + if o == nil || o.GatewayId == nil { + var ret string + return ret + } + return *o.GatewayId +} + +// GetGatewayIdOk returns a tuple with the GatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetGatewayIdOk() (*string, bool) { + if o == nil || o.GatewayId == nil { + return nil, false + } + return o.GatewayId, true +} + +// HasGatewayId returns a boolean if a field has been set. +func (o *Route) HasGatewayId() bool { + if o != nil && o.GatewayId != nil { + return true + } + + return false +} + +// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. +func (o *Route) SetGatewayId(v string) { + o.GatewayId = &v +} + +// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. +func (o *Route) GetNatServiceId() string { + if o == nil || o.NatServiceId == nil { + var ret string + return ret + } + return *o.NatServiceId +} + +// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetNatServiceIdOk() (*string, bool) { + if o == nil || o.NatServiceId == nil { + return nil, false + } + return o.NatServiceId, true +} + +// HasNatServiceId returns a boolean if a field has been set. +func (o *Route) HasNatServiceId() bool { + if o != nil && o.NatServiceId != nil { + return true + } + + return false +} + +// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. +func (o *Route) SetNatServiceId(v string) { + o.NatServiceId = &v +} + +// GetNetAccessPointId returns the NetAccessPointId field value if set, zero value otherwise. +func (o *Route) GetNetAccessPointId() string { + if o == nil || o.NetAccessPointId == nil { + var ret string + return ret + } + return *o.NetAccessPointId +} + +// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetNetAccessPointIdOk() (*string, bool) { + if o == nil || o.NetAccessPointId == nil { + return nil, false + } + return o.NetAccessPointId, true +} + +// HasNetAccessPointId returns a boolean if a field has been set. +func (o *Route) HasNetAccessPointId() bool { + if o != nil && o.NetAccessPointId != nil { + return true + } + + return false +} + +// SetNetAccessPointId gets a reference to the given string and assigns it to the NetAccessPointId field. +func (o *Route) SetNetAccessPointId(v string) { + o.NetAccessPointId = &v +} + +// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. +func (o *Route) GetNetPeeringId() string { + if o == nil || o.NetPeeringId == nil { + var ret string + return ret + } + return *o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetNetPeeringIdOk() (*string, bool) { + if o == nil || o.NetPeeringId == nil { + return nil, false + } + return o.NetPeeringId, true +} + +// HasNetPeeringId returns a boolean if a field has been set. +func (o *Route) HasNetPeeringId() bool { + if o != nil && o.NetPeeringId != nil { + return true + } + + return false +} + +// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. +func (o *Route) SetNetPeeringId(v string) { + o.NetPeeringId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *Route) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *Route) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *Route) SetNicId(v string) { + o.NicId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Route) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Route) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Route) SetState(v string) { + o.State = &v +} + +// GetVmAccountId returns the VmAccountId field value if set, zero value otherwise. +func (o *Route) GetVmAccountId() string { + if o == nil || o.VmAccountId == nil { + var ret string + return ret + } + return *o.VmAccountId +} + +// GetVmAccountIdOk returns a tuple with the VmAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetVmAccountIdOk() (*string, bool) { + if o == nil || o.VmAccountId == nil { + return nil, false + } + return o.VmAccountId, true +} + +// HasVmAccountId returns a boolean if a field has been set. +func (o *Route) HasVmAccountId() bool { + if o != nil && o.VmAccountId != nil { + return true + } + + return false +} + +// SetVmAccountId gets a reference to the given string and assigns it to the VmAccountId field. +func (o *Route) SetVmAccountId(v string) { + o.VmAccountId = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *Route) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Route) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *Route) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *Route) SetVmId(v string) { + o.VmId = &v +} + +func (o Route) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.CreationMethod != nil { + toSerialize["CreationMethod"] = o.CreationMethod + } + if o.DestinationIpRange != nil { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DestinationServiceId != nil { + toSerialize["DestinationServiceId"] = o.DestinationServiceId + } + if o.GatewayId != nil { + toSerialize["GatewayId"] = o.GatewayId + } + if o.NatServiceId != nil { + toSerialize["NatServiceId"] = o.NatServiceId + } + if o.NetAccessPointId != nil { + toSerialize["NetAccessPointId"] = o.NetAccessPointId + } + if o.NetPeeringId != nil { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.VmAccountId != nil { + toSerialize["VmAccountId"] = o.VmAccountId + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableRoute struct { + value *Route + isSet bool +} + +func (v NullableRoute) Get() *Route { + return v.value +} + +func (v *NullableRoute) Set(val *Route) { + v.value = val + v.isSet = true +} + +func (v NullableRoute) IsSet() bool { + return v.isSet +} + +func (v *NullableRoute) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRoute(val *Route) *NullableRoute { + return &NullableRoute{value: val, isSet: true} +} + +func (v NullableRoute) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRoute) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go new file mode 100644 index 000000000..1530efe27 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RouteLight Information about the route. +type RouteLight struct { + // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + DestinationIpRange *string `json:"DestinationIpRange,omitempty"` + // The type of route (always `static`). + RouteType *string `json:"RouteType,omitempty"` + // The current state of the static route (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` +} + +// NewRouteLight instantiates a new RouteLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRouteLight() *RouteLight { + this := RouteLight{} + return &this +} + +// NewRouteLightWithDefaults instantiates a new RouteLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRouteLightWithDefaults() *RouteLight { + this := RouteLight{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value if set, zero value otherwise. +func (o *RouteLight) GetDestinationIpRange() string { + if o == nil || o.DestinationIpRange == nil { + var ret string + return ret + } + return *o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteLight) GetDestinationIpRangeOk() (*string, bool) { + if o == nil || o.DestinationIpRange == nil { + return nil, false + } + return o.DestinationIpRange, true +} + +// HasDestinationIpRange returns a boolean if a field has been set. +func (o *RouteLight) HasDestinationIpRange() bool { + if o != nil && o.DestinationIpRange != nil { + return true + } + + return false +} + +// SetDestinationIpRange gets a reference to the given string and assigns it to the DestinationIpRange field. +func (o *RouteLight) SetDestinationIpRange(v string) { + o.DestinationIpRange = &v +} + +// GetRouteType returns the RouteType field value if set, zero value otherwise. +func (o *RouteLight) GetRouteType() string { + if o == nil || o.RouteType == nil { + var ret string + return ret + } + return *o.RouteType +} + +// GetRouteTypeOk returns a tuple with the RouteType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteLight) GetRouteTypeOk() (*string, bool) { + if o == nil || o.RouteType == nil { + return nil, false + } + return o.RouteType, true +} + +// HasRouteType returns a boolean if a field has been set. +func (o *RouteLight) HasRouteType() bool { + if o != nil && o.RouteType != nil { + return true + } + + return false +} + +// SetRouteType gets a reference to the given string and assigns it to the RouteType field. +func (o *RouteLight) SetRouteType(v string) { + o.RouteType = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *RouteLight) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteLight) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *RouteLight) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *RouteLight) SetState(v string) { + o.State = &v +} + +func (o RouteLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DestinationIpRange != nil { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.RouteType != nil { + toSerialize["RouteType"] = o.RouteType + } + if o.State != nil { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableRouteLight struct { + value *RouteLight + isSet bool +} + +func (v NullableRouteLight) Get() *RouteLight { + return v.value +} + +func (v *NullableRouteLight) Set(val *RouteLight) { + v.value = val + v.isSet = true +} + +func (v NullableRouteLight) IsSet() bool { + return v.isSet +} + +func (v *NullableRouteLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRouteLight(val *RouteLight) *NullableRouteLight { + return &NullableRouteLight{value: val, isSet: true} +} + +func (v NullableRouteLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRouteLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go new file mode 100644 index 000000000..34f194319 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go @@ -0,0 +1,117 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RoutePropagatingVirtualGateway Information about the route propagating virtual gateway. +type RoutePropagatingVirtualGateway struct { + // The ID of the virtual gateway. + VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` +} + +// NewRoutePropagatingVirtualGateway instantiates a new RoutePropagatingVirtualGateway object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRoutePropagatingVirtualGateway() *RoutePropagatingVirtualGateway { + this := RoutePropagatingVirtualGateway{} + return &this +} + +// NewRoutePropagatingVirtualGatewayWithDefaults instantiates a new RoutePropagatingVirtualGateway object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRoutePropagatingVirtualGatewayWithDefaults() *RoutePropagatingVirtualGateway { + this := RoutePropagatingVirtualGateway{} + return &this +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. +func (o *RoutePropagatingVirtualGateway) GetVirtualGatewayId() string { + if o == nil || o.VirtualGatewayId == nil { + var ret string + return ret + } + return *o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RoutePropagatingVirtualGateway) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil || o.VirtualGatewayId == nil { + return nil, false + } + return o.VirtualGatewayId, true +} + +// HasVirtualGatewayId returns a boolean if a field has been set. +func (o *RoutePropagatingVirtualGateway) HasVirtualGatewayId() bool { + if o != nil && o.VirtualGatewayId != nil { + return true + } + + return false +} + +// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. +func (o *RoutePropagatingVirtualGateway) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = &v +} + +func (o RoutePropagatingVirtualGateway) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.VirtualGatewayId != nil { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableRoutePropagatingVirtualGateway struct { + value *RoutePropagatingVirtualGateway + isSet bool +} + +func (v NullableRoutePropagatingVirtualGateway) Get() *RoutePropagatingVirtualGateway { + return v.value +} + +func (v *NullableRoutePropagatingVirtualGateway) Set(val *RoutePropagatingVirtualGateway) { + v.value = val + v.isSet = true +} + +func (v NullableRoutePropagatingVirtualGateway) IsSet() bool { + return v.isSet +} + +func (v *NullableRoutePropagatingVirtualGateway) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRoutePropagatingVirtualGateway(val *RoutePropagatingVirtualGateway) *NullableRoutePropagatingVirtualGateway { + return &NullableRoutePropagatingVirtualGateway{value: val, isSet: true} +} + +func (v NullableRoutePropagatingVirtualGateway) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRoutePropagatingVirtualGateway) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go new file mode 100644 index 000000000..922de88ab --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// RouteTable Information about the route table. +type RouteTable struct { + // One or more associations between the route table and Subnets. + LinkRouteTables *[]LinkRouteTable `json:"LinkRouteTables,omitempty"` + // The ID of the Net for the route table. + NetId *string `json:"NetId,omitempty"` + // Information about virtual gateways propagating routes. + RoutePropagatingVirtualGateways *[]RoutePropagatingVirtualGateway `json:"RoutePropagatingVirtualGateways,omitempty"` + // The ID of the route table. + RouteTableId *string `json:"RouteTableId,omitempty"` + // One or more routes in the route table. + Routes *[]Route `json:"Routes,omitempty"` + // One or more tags associated with the route table. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewRouteTable instantiates a new RouteTable object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRouteTable() *RouteTable { + this := RouteTable{} + return &this +} + +// NewRouteTableWithDefaults instantiates a new RouteTable object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRouteTableWithDefaults() *RouteTable { + this := RouteTable{} + return &this +} + +// GetLinkRouteTables returns the LinkRouteTables field value if set, zero value otherwise. +func (o *RouteTable) GetLinkRouteTables() []LinkRouteTable { + if o == nil || o.LinkRouteTables == nil { + var ret []LinkRouteTable + return ret + } + return *o.LinkRouteTables +} + +// GetLinkRouteTablesOk returns a tuple with the LinkRouteTables field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetLinkRouteTablesOk() (*[]LinkRouteTable, bool) { + if o == nil || o.LinkRouteTables == nil { + return nil, false + } + return o.LinkRouteTables, true +} + +// HasLinkRouteTables returns a boolean if a field has been set. +func (o *RouteTable) HasLinkRouteTables() bool { + if o != nil && o.LinkRouteTables != nil { + return true + } + + return false +} + +// SetLinkRouteTables gets a reference to the given []LinkRouteTable and assigns it to the LinkRouteTables field. +func (o *RouteTable) SetLinkRouteTables(v []LinkRouteTable) { + o.LinkRouteTables = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *RouteTable) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *RouteTable) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *RouteTable) SetNetId(v string) { + o.NetId = &v +} + +// GetRoutePropagatingVirtualGateways returns the RoutePropagatingVirtualGateways field value if set, zero value otherwise. +func (o *RouteTable) GetRoutePropagatingVirtualGateways() []RoutePropagatingVirtualGateway { + if o == nil || o.RoutePropagatingVirtualGateways == nil { + var ret []RoutePropagatingVirtualGateway + return ret + } + return *o.RoutePropagatingVirtualGateways +} + +// GetRoutePropagatingVirtualGatewaysOk returns a tuple with the RoutePropagatingVirtualGateways field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetRoutePropagatingVirtualGatewaysOk() (*[]RoutePropagatingVirtualGateway, bool) { + if o == nil || o.RoutePropagatingVirtualGateways == nil { + return nil, false + } + return o.RoutePropagatingVirtualGateways, true +} + +// HasRoutePropagatingVirtualGateways returns a boolean if a field has been set. +func (o *RouteTable) HasRoutePropagatingVirtualGateways() bool { + if o != nil && o.RoutePropagatingVirtualGateways != nil { + return true + } + + return false +} + +// SetRoutePropagatingVirtualGateways gets a reference to the given []RoutePropagatingVirtualGateway and assigns it to the RoutePropagatingVirtualGateways field. +func (o *RouteTable) SetRoutePropagatingVirtualGateways(v []RoutePropagatingVirtualGateway) { + o.RoutePropagatingVirtualGateways = &v +} + +// GetRouteTableId returns the RouteTableId field value if set, zero value otherwise. +func (o *RouteTable) GetRouteTableId() string { + if o == nil || o.RouteTableId == nil { + var ret string + return ret + } + return *o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetRouteTableIdOk() (*string, bool) { + if o == nil || o.RouteTableId == nil { + return nil, false + } + return o.RouteTableId, true +} + +// HasRouteTableId returns a boolean if a field has been set. +func (o *RouteTable) HasRouteTableId() bool { + if o != nil && o.RouteTableId != nil { + return true + } + + return false +} + +// SetRouteTableId gets a reference to the given string and assigns it to the RouteTableId field. +func (o *RouteTable) SetRouteTableId(v string) { + o.RouteTableId = &v +} + +// GetRoutes returns the Routes field value if set, zero value otherwise. +func (o *RouteTable) GetRoutes() []Route { + if o == nil || o.Routes == nil { + var ret []Route + return ret + } + return *o.Routes +} + +// GetRoutesOk returns a tuple with the Routes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetRoutesOk() (*[]Route, bool) { + if o == nil || o.Routes == nil { + return nil, false + } + return o.Routes, true +} + +// HasRoutes returns a boolean if a field has been set. +func (o *RouteTable) HasRoutes() bool { + if o != nil && o.Routes != nil { + return true + } + + return false +} + +// SetRoutes gets a reference to the given []Route and assigns it to the Routes field. +func (o *RouteTable) SetRoutes(v []Route) { + o.Routes = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *RouteTable) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RouteTable) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *RouteTable) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *RouteTable) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o RouteTable) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LinkRouteTables != nil { + toSerialize["LinkRouteTables"] = o.LinkRouteTables + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.RoutePropagatingVirtualGateways != nil { + toSerialize["RoutePropagatingVirtualGateways"] = o.RoutePropagatingVirtualGateways + } + if o.RouteTableId != nil { + toSerialize["RouteTableId"] = o.RouteTableId + } + if o.Routes != nil { + toSerialize["Routes"] = o.Routes + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableRouteTable struct { + value *RouteTable + isSet bool +} + +func (v NullableRouteTable) Get() *RouteTable { + return v.value +} + +func (v *NullableRouteTable) Set(val *RouteTable) { + v.value = val + v.isSet = true +} + +func (v NullableRouteTable) IsSet() bool { + return v.isSet +} + +func (v *NullableRouteTable) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRouteTable(val *RouteTable) *NullableRouteTable { + return &NullableRouteTable{value: val, isSet: true} +} + +func (v NullableRouteTable) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRouteTable) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go new file mode 100644 index 000000000..e2312fe63 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SecurityGroup Information about the security group. +type SecurityGroup struct { + // The account ID of a user that has been granted permission. + AccountId *string `json:"AccountId,omitempty"` + // The description of the security group. + Description *string `json:"Description,omitempty"` + // The inbound rules associated with the security group. + InboundRules *[]SecurityGroupRule `json:"InboundRules,omitempty"` + // The ID of the Net for the security group. + NetId *string `json:"NetId,omitempty"` + // The outbound rules associated with the security group. + OutboundRules *[]SecurityGroupRule `json:"OutboundRules,omitempty"` + // The ID of the security group. + SecurityGroupId *string `json:"SecurityGroupId,omitempty"` + // The name of the security group. + SecurityGroupName *string `json:"SecurityGroupName,omitempty"` + // One or more tags associated with the security group. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewSecurityGroup instantiates a new SecurityGroup object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSecurityGroup() *SecurityGroup { + this := SecurityGroup{} + return &this +} + +// NewSecurityGroupWithDefaults instantiates a new SecurityGroup object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSecurityGroupWithDefaults() *SecurityGroup { + this := SecurityGroup{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *SecurityGroup) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *SecurityGroup) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *SecurityGroup) SetAccountId(v string) { + o.AccountId = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *SecurityGroup) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *SecurityGroup) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *SecurityGroup) SetDescription(v string) { + o.Description = &v +} + +// GetInboundRules returns the InboundRules field value if set, zero value otherwise. +func (o *SecurityGroup) GetInboundRules() []SecurityGroupRule { + if o == nil || o.InboundRules == nil { + var ret []SecurityGroupRule + return ret + } + return *o.InboundRules +} + +// GetInboundRulesOk returns a tuple with the InboundRules field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetInboundRulesOk() (*[]SecurityGroupRule, bool) { + if o == nil || o.InboundRules == nil { + return nil, false + } + return o.InboundRules, true +} + +// HasInboundRules returns a boolean if a field has been set. +func (o *SecurityGroup) HasInboundRules() bool { + if o != nil && o.InboundRules != nil { + return true + } + + return false +} + +// SetInboundRules gets a reference to the given []SecurityGroupRule and assigns it to the InboundRules field. +func (o *SecurityGroup) SetInboundRules(v []SecurityGroupRule) { + o.InboundRules = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *SecurityGroup) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *SecurityGroup) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *SecurityGroup) SetNetId(v string) { + o.NetId = &v +} + +// GetOutboundRules returns the OutboundRules field value if set, zero value otherwise. +func (o *SecurityGroup) GetOutboundRules() []SecurityGroupRule { + if o == nil || o.OutboundRules == nil { + var ret []SecurityGroupRule + return ret + } + return *o.OutboundRules +} + +// GetOutboundRulesOk returns a tuple with the OutboundRules field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetOutboundRulesOk() (*[]SecurityGroupRule, bool) { + if o == nil || o.OutboundRules == nil { + return nil, false + } + return o.OutboundRules, true +} + +// HasOutboundRules returns a boolean if a field has been set. +func (o *SecurityGroup) HasOutboundRules() bool { + if o != nil && o.OutboundRules != nil { + return true + } + + return false +} + +// SetOutboundRules gets a reference to the given []SecurityGroupRule and assigns it to the OutboundRules field. +func (o *SecurityGroup) SetOutboundRules(v []SecurityGroupRule) { + o.OutboundRules = &v +} + +// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. +func (o *SecurityGroup) GetSecurityGroupId() string { + if o == nil || o.SecurityGroupId == nil { + var ret string + return ret + } + return *o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetSecurityGroupIdOk() (*string, bool) { + if o == nil || o.SecurityGroupId == nil { + return nil, false + } + return o.SecurityGroupId, true +} + +// HasSecurityGroupId returns a boolean if a field has been set. +func (o *SecurityGroup) HasSecurityGroupId() bool { + if o != nil && o.SecurityGroupId != nil { + return true + } + + return false +} + +// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. +func (o *SecurityGroup) SetSecurityGroupId(v string) { + o.SecurityGroupId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. +func (o *SecurityGroup) GetSecurityGroupName() string { + if o == nil || o.SecurityGroupName == nil { + var ret string + return ret + } + return *o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetSecurityGroupNameOk() (*string, bool) { + if o == nil || o.SecurityGroupName == nil { + return nil, false + } + return o.SecurityGroupName, true +} + +// HasSecurityGroupName returns a boolean if a field has been set. +func (o *SecurityGroup) HasSecurityGroupName() bool { + if o != nil && o.SecurityGroupName != nil { + return true + } + + return false +} + +// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. +func (o *SecurityGroup) SetSecurityGroupName(v string) { + o.SecurityGroupName = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *SecurityGroup) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroup) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *SecurityGroup) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *SecurityGroup) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o SecurityGroup) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.InboundRules != nil { + toSerialize["InboundRules"] = o.InboundRules + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.OutboundRules != nil { + toSerialize["OutboundRules"] = o.OutboundRules + } + if o.SecurityGroupId != nil { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupName != nil { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableSecurityGroup struct { + value *SecurityGroup + isSet bool +} + +func (v NullableSecurityGroup) Get() *SecurityGroup { + return v.value +} + +func (v *NullableSecurityGroup) Set(val *SecurityGroup) { + v.value = val + v.isSet = true +} + +func (v NullableSecurityGroup) IsSet() bool { + return v.isSet +} + +func (v *NullableSecurityGroup) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSecurityGroup(val *SecurityGroup) *NullableSecurityGroup { + return &NullableSecurityGroup{value: val, isSet: true} +} + +func (v NullableSecurityGroup) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSecurityGroup) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go new file mode 100644 index 000000000..3fb3f5564 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SecurityGroupLight Information about the security group. +type SecurityGroupLight struct { + // The ID of the security group. + SecurityGroupId *string `json:"SecurityGroupId,omitempty"` + // The name of the security group. + SecurityGroupName *string `json:"SecurityGroupName,omitempty"` +} + +// NewSecurityGroupLight instantiates a new SecurityGroupLight object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSecurityGroupLight() *SecurityGroupLight { + this := SecurityGroupLight{} + return &this +} + +// NewSecurityGroupLightWithDefaults instantiates a new SecurityGroupLight object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSecurityGroupLightWithDefaults() *SecurityGroupLight { + this := SecurityGroupLight{} + return &this +} + +// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. +func (o *SecurityGroupLight) GetSecurityGroupId() string { + if o == nil || o.SecurityGroupId == nil { + var ret string + return ret + } + return *o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupLight) GetSecurityGroupIdOk() (*string, bool) { + if o == nil || o.SecurityGroupId == nil { + return nil, false + } + return o.SecurityGroupId, true +} + +// HasSecurityGroupId returns a boolean if a field has been set. +func (o *SecurityGroupLight) HasSecurityGroupId() bool { + if o != nil && o.SecurityGroupId != nil { + return true + } + + return false +} + +// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. +func (o *SecurityGroupLight) SetSecurityGroupId(v string) { + o.SecurityGroupId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. +func (o *SecurityGroupLight) GetSecurityGroupName() string { + if o == nil || o.SecurityGroupName == nil { + var ret string + return ret + } + return *o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupLight) GetSecurityGroupNameOk() (*string, bool) { + if o == nil || o.SecurityGroupName == nil { + return nil, false + } + return o.SecurityGroupName, true +} + +// HasSecurityGroupName returns a boolean if a field has been set. +func (o *SecurityGroupLight) HasSecurityGroupName() bool { + if o != nil && o.SecurityGroupName != nil { + return true + } + + return false +} + +// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. +func (o *SecurityGroupLight) SetSecurityGroupName(v string) { + o.SecurityGroupName = &v +} + +func (o SecurityGroupLight) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SecurityGroupId != nil { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupName != nil { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + return json.Marshal(toSerialize) +} + +type NullableSecurityGroupLight struct { + value *SecurityGroupLight + isSet bool +} + +func (v NullableSecurityGroupLight) Get() *SecurityGroupLight { + return v.value +} + +func (v *NullableSecurityGroupLight) Set(val *SecurityGroupLight) { + v.value = val + v.isSet = true +} + +func (v NullableSecurityGroupLight) IsSet() bool { + return v.isSet +} + +func (v *NullableSecurityGroupLight) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSecurityGroupLight(val *SecurityGroupLight) *NullableSecurityGroupLight { + return &NullableSecurityGroupLight{value: val, isSet: true} +} + +func (v NullableSecurityGroupLight) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSecurityGroupLight) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go new file mode 100644 index 000000000..641274b2c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go @@ -0,0 +1,302 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SecurityGroupRule Information about the security group rule. +type SecurityGroupRule struct { + // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + FromPortRange *int32 `json:"FromPortRange,omitempty"` + // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + IpProtocol *string `json:"IpProtocol,omitempty"` + // One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + IpRanges *[]string `json:"IpRanges,omitempty"` + // Information about one or more members of a security group. + SecurityGroupsMembers *[]SecurityGroupsMember `json:"SecurityGroupsMembers,omitempty"` + // One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](#readnetaccesspointservices). + ServiceIds *[]string `json:"ServiceIds,omitempty"` + // The end of the port range for the TCP and UDP protocols, or an ICMP type number. + ToPortRange *int32 `json:"ToPortRange,omitempty"` +} + +// NewSecurityGroupRule instantiates a new SecurityGroupRule object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSecurityGroupRule() *SecurityGroupRule { + this := SecurityGroupRule{} + return &this +} + +// NewSecurityGroupRuleWithDefaults instantiates a new SecurityGroupRule object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSecurityGroupRuleWithDefaults() *SecurityGroupRule { + this := SecurityGroupRule{} + return &this +} + +// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetFromPortRange() int32 { + if o == nil || o.FromPortRange == nil { + var ret int32 + return ret + } + return *o.FromPortRange +} + +// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetFromPortRangeOk() (*int32, bool) { + if o == nil || o.FromPortRange == nil { + return nil, false + } + return o.FromPortRange, true +} + +// HasFromPortRange returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasFromPortRange() bool { + if o != nil && o.FromPortRange != nil { + return true + } + + return false +} + +// SetFromPortRange gets a reference to the given int32 and assigns it to the FromPortRange field. +func (o *SecurityGroupRule) SetFromPortRange(v int32) { + o.FromPortRange = &v +} + +// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetIpProtocol() string { + if o == nil || o.IpProtocol == nil { + var ret string + return ret + } + return *o.IpProtocol +} + +// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetIpProtocolOk() (*string, bool) { + if o == nil || o.IpProtocol == nil { + return nil, false + } + return o.IpProtocol, true +} + +// HasIpProtocol returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasIpProtocol() bool { + if o != nil && o.IpProtocol != nil { + return true + } + + return false +} + +// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. +func (o *SecurityGroupRule) SetIpProtocol(v string) { + o.IpProtocol = &v +} + +// GetIpRanges returns the IpRanges field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetIpRanges() []string { + if o == nil || o.IpRanges == nil { + var ret []string + return ret + } + return *o.IpRanges +} + +// GetIpRangesOk returns a tuple with the IpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetIpRangesOk() (*[]string, bool) { + if o == nil || o.IpRanges == nil { + return nil, false + } + return o.IpRanges, true +} + +// HasIpRanges returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasIpRanges() bool { + if o != nil && o.IpRanges != nil { + return true + } + + return false +} + +// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. +func (o *SecurityGroupRule) SetIpRanges(v []string) { + o.IpRanges = &v +} + +// GetSecurityGroupsMembers returns the SecurityGroupsMembers field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetSecurityGroupsMembers() []SecurityGroupsMember { + if o == nil || o.SecurityGroupsMembers == nil { + var ret []SecurityGroupsMember + return ret + } + return *o.SecurityGroupsMembers +} + +// GetSecurityGroupsMembersOk returns a tuple with the SecurityGroupsMembers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetSecurityGroupsMembersOk() (*[]SecurityGroupsMember, bool) { + if o == nil || o.SecurityGroupsMembers == nil { + return nil, false + } + return o.SecurityGroupsMembers, true +} + +// HasSecurityGroupsMembers returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasSecurityGroupsMembers() bool { + if o != nil && o.SecurityGroupsMembers != nil { + return true + } + + return false +} + +// SetSecurityGroupsMembers gets a reference to the given []SecurityGroupsMember and assigns it to the SecurityGroupsMembers field. +func (o *SecurityGroupRule) SetSecurityGroupsMembers(v []SecurityGroupsMember) { + o.SecurityGroupsMembers = &v +} + +// GetServiceIds returns the ServiceIds field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetServiceIds() []string { + if o == nil || o.ServiceIds == nil { + var ret []string + return ret + } + return *o.ServiceIds +} + +// GetServiceIdsOk returns a tuple with the ServiceIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetServiceIdsOk() (*[]string, bool) { + if o == nil || o.ServiceIds == nil { + return nil, false + } + return o.ServiceIds, true +} + +// HasServiceIds returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasServiceIds() bool { + if o != nil && o.ServiceIds != nil { + return true + } + + return false +} + +// SetServiceIds gets a reference to the given []string and assigns it to the ServiceIds field. +func (o *SecurityGroupRule) SetServiceIds(v []string) { + o.ServiceIds = &v +} + +// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. +func (o *SecurityGroupRule) GetToPortRange() int32 { + if o == nil || o.ToPortRange == nil { + var ret int32 + return ret + } + return *o.ToPortRange +} + +// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupRule) GetToPortRangeOk() (*int32, bool) { + if o == nil || o.ToPortRange == nil { + return nil, false + } + return o.ToPortRange, true +} + +// HasToPortRange returns a boolean if a field has been set. +func (o *SecurityGroupRule) HasToPortRange() bool { + if o != nil && o.ToPortRange != nil { + return true + } + + return false +} + +// SetToPortRange gets a reference to the given int32 and assigns it to the ToPortRange field. +func (o *SecurityGroupRule) SetToPortRange(v int32) { + o.ToPortRange = &v +} + +func (o SecurityGroupRule) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.FromPortRange != nil { + toSerialize["FromPortRange"] = o.FromPortRange + } + if o.IpProtocol != nil { + toSerialize["IpProtocol"] = o.IpProtocol + } + if o.IpRanges != nil { + toSerialize["IpRanges"] = o.IpRanges + } + if o.SecurityGroupsMembers != nil { + toSerialize["SecurityGroupsMembers"] = o.SecurityGroupsMembers + } + if o.ServiceIds != nil { + toSerialize["ServiceIds"] = o.ServiceIds + } + if o.ToPortRange != nil { + toSerialize["ToPortRange"] = o.ToPortRange + } + return json.Marshal(toSerialize) +} + +type NullableSecurityGroupRule struct { + value *SecurityGroupRule + isSet bool +} + +func (v NullableSecurityGroupRule) Get() *SecurityGroupRule { + return v.value +} + +func (v *NullableSecurityGroupRule) Set(val *SecurityGroupRule) { + v.value = val + v.isSet = true +} + +func (v NullableSecurityGroupRule) IsSet() bool { + return v.isSet +} + +func (v *NullableSecurityGroupRule) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSecurityGroupRule(val *SecurityGroupRule) *NullableSecurityGroupRule { + return &NullableSecurityGroupRule{value: val, isSet: true} +} + +func (v NullableSecurityGroupRule) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSecurityGroupRule) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go new file mode 100644 index 000000000..d8728c46e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SecurityGroupsMember Information about the member of a security group. +type SecurityGroupsMember struct { + // The account ID of a user. + AccountId *string `json:"AccountId,omitempty"` + // The ID of the security group. + SecurityGroupId *string `json:"SecurityGroupId,omitempty"` + // The name of the security group. + SecurityGroupName *string `json:"SecurityGroupName,omitempty"` +} + +// NewSecurityGroupsMember instantiates a new SecurityGroupsMember object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSecurityGroupsMember() *SecurityGroupsMember { + this := SecurityGroupsMember{} + return &this +} + +// NewSecurityGroupsMemberWithDefaults instantiates a new SecurityGroupsMember object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSecurityGroupsMemberWithDefaults() *SecurityGroupsMember { + this := SecurityGroupsMember{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *SecurityGroupsMember) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupsMember) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *SecurityGroupsMember) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *SecurityGroupsMember) SetAccountId(v string) { + o.AccountId = &v +} + +// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. +func (o *SecurityGroupsMember) GetSecurityGroupId() string { + if o == nil || o.SecurityGroupId == nil { + var ret string + return ret + } + return *o.SecurityGroupId +} + +// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupsMember) GetSecurityGroupIdOk() (*string, bool) { + if o == nil || o.SecurityGroupId == nil { + return nil, false + } + return o.SecurityGroupId, true +} + +// HasSecurityGroupId returns a boolean if a field has been set. +func (o *SecurityGroupsMember) HasSecurityGroupId() bool { + if o != nil && o.SecurityGroupId != nil { + return true + } + + return false +} + +// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. +func (o *SecurityGroupsMember) SetSecurityGroupId(v string) { + o.SecurityGroupId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. +func (o *SecurityGroupsMember) GetSecurityGroupName() string { + if o == nil || o.SecurityGroupName == nil { + var ret string + return ret + } + return *o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SecurityGroupsMember) GetSecurityGroupNameOk() (*string, bool) { + if o == nil || o.SecurityGroupName == nil { + return nil, false + } + return o.SecurityGroupName, true +} + +// HasSecurityGroupName returns a boolean if a field has been set. +func (o *SecurityGroupsMember) HasSecurityGroupName() bool { + if o != nil && o.SecurityGroupName != nil { + return true + } + + return false +} + +// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. +func (o *SecurityGroupsMember) SetSecurityGroupName(v string) { + o.SecurityGroupName = &v +} + +func (o SecurityGroupsMember) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.SecurityGroupId != nil { + toSerialize["SecurityGroupId"] = o.SecurityGroupId + } + if o.SecurityGroupName != nil { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + return json.Marshal(toSerialize) +} + +type NullableSecurityGroupsMember struct { + value *SecurityGroupsMember + isSet bool +} + +func (v NullableSecurityGroupsMember) Get() *SecurityGroupsMember { + return v.value +} + +func (v *NullableSecurityGroupsMember) Set(val *SecurityGroupsMember) { + v.value = val + v.isSet = true +} + +func (v NullableSecurityGroupsMember) IsSet() bool { + return v.isSet +} + +func (v *NullableSecurityGroupsMember) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSecurityGroupsMember(val *SecurityGroupsMember) *NullableSecurityGroupsMember { + return &NullableSecurityGroupsMember{value: val, isSet: true} +} + +func (v NullableSecurityGroupsMember) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSecurityGroupsMember) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go new file mode 100644 index 000000000..48aace9b7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SendResetPasswordEmailRequest struct for SendResetPasswordEmailRequest +type SendResetPasswordEmailRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The email address provided for the account. + Email string `json:"Email"` +} + +// NewSendResetPasswordEmailRequest instantiates a new SendResetPasswordEmailRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSendResetPasswordEmailRequest(email string, ) *SendResetPasswordEmailRequest { + this := SendResetPasswordEmailRequest{} + this.Email = email + return &this +} + +// NewSendResetPasswordEmailRequestWithDefaults instantiates a new SendResetPasswordEmailRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSendResetPasswordEmailRequestWithDefaults() *SendResetPasswordEmailRequest { + this := SendResetPasswordEmailRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *SendResetPasswordEmailRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SendResetPasswordEmailRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *SendResetPasswordEmailRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *SendResetPasswordEmailRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetEmail returns the Email field value +func (o *SendResetPasswordEmailRequest) GetEmail() string { + if o == nil { + var ret string + return ret + } + + return o.Email +} + +// GetEmailOk returns a tuple with the Email field value +// and a boolean to check if the value has been set. +func (o *SendResetPasswordEmailRequest) GetEmailOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Email, true +} + +// SetEmail sets field value +func (o *SendResetPasswordEmailRequest) SetEmail(v string) { + o.Email = v +} + +func (o SendResetPasswordEmailRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Email"] = o.Email + } + return json.Marshal(toSerialize) +} + +type NullableSendResetPasswordEmailRequest struct { + value *SendResetPasswordEmailRequest + isSet bool +} + +func (v NullableSendResetPasswordEmailRequest) Get() *SendResetPasswordEmailRequest { + return v.value +} + +func (v *NullableSendResetPasswordEmailRequest) Set(val *SendResetPasswordEmailRequest) { + v.value = val + v.isSet = true +} + +func (v NullableSendResetPasswordEmailRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableSendResetPasswordEmailRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSendResetPasswordEmailRequest(val *SendResetPasswordEmailRequest) *NullableSendResetPasswordEmailRequest { + return &NullableSendResetPasswordEmailRequest{value: val, isSet: true} +} + +func (v NullableSendResetPasswordEmailRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSendResetPasswordEmailRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go new file mode 100644 index 000000000..0c16c20de --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SendResetPasswordEmailResponse struct for SendResetPasswordEmailResponse +type SendResetPasswordEmailResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewSendResetPasswordEmailResponse instantiates a new SendResetPasswordEmailResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSendResetPasswordEmailResponse() *SendResetPasswordEmailResponse { + this := SendResetPasswordEmailResponse{} + return &this +} + +// NewSendResetPasswordEmailResponseWithDefaults instantiates a new SendResetPasswordEmailResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSendResetPasswordEmailResponseWithDefaults() *SendResetPasswordEmailResponse { + this := SendResetPasswordEmailResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *SendResetPasswordEmailResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SendResetPasswordEmailResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *SendResetPasswordEmailResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *SendResetPasswordEmailResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o SendResetPasswordEmailResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableSendResetPasswordEmailResponse struct { + value *SendResetPasswordEmailResponse + isSet bool +} + +func (v NullableSendResetPasswordEmailResponse) Get() *SendResetPasswordEmailResponse { + return v.value +} + +func (v *NullableSendResetPasswordEmailResponse) Set(val *SendResetPasswordEmailResponse) { + v.value = val + v.isSet = true +} + +func (v NullableSendResetPasswordEmailResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableSendResetPasswordEmailResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSendResetPasswordEmailResponse(val *SendResetPasswordEmailResponse) *NullableSendResetPasswordEmailResponse { + return &NullableSendResetPasswordEmailResponse{value: val, isSet: true} +} + +func (v NullableSendResetPasswordEmailResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSendResetPasswordEmailResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go new file mode 100644 index 000000000..3258f031e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// ServerCertificate Information about the server certificate. +type ServerCertificate struct { + // The date at which the server certificate expires. + ExpirationDate *string `json:"ExpirationDate,omitempty"` + // The ID of the server certificate. + Id *string `json:"Id,omitempty"` + // The name of the server certificate. + Name *string `json:"Name,omitempty"` + // The path to the server certificate. + Path *string `json:"Path,omitempty"` + // The date at which the server certificate has been uploaded. + UploadDate *string `json:"UploadDate,omitempty"` +} + +// NewServerCertificate instantiates a new ServerCertificate object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewServerCertificate() *ServerCertificate { + this := ServerCertificate{} + return &this +} + +// NewServerCertificateWithDefaults instantiates a new ServerCertificate object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewServerCertificateWithDefaults() *ServerCertificate { + this := ServerCertificate{} + return &this +} + +// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. +func (o *ServerCertificate) GetExpirationDate() string { + if o == nil || o.ExpirationDate == nil { + var ret string + return ret + } + return *o.ExpirationDate +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ServerCertificate) GetExpirationDateOk() (*string, bool) { + if o == nil || o.ExpirationDate == nil { + return nil, false + } + return o.ExpirationDate, true +} + +// HasExpirationDate returns a boolean if a field has been set. +func (o *ServerCertificate) HasExpirationDate() bool { + if o != nil && o.ExpirationDate != nil { + return true + } + + return false +} + +// SetExpirationDate gets a reference to the given string and assigns it to the ExpirationDate field. +func (o *ServerCertificate) SetExpirationDate(v string) { + o.ExpirationDate = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *ServerCertificate) GetId() string { + if o == nil || o.Id == nil { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ServerCertificate) GetIdOk() (*string, bool) { + if o == nil || o.Id == nil { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *ServerCertificate) HasId() bool { + if o != nil && o.Id != nil { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *ServerCertificate) SetId(v string) { + o.Id = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *ServerCertificate) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ServerCertificate) GetNameOk() (*string, bool) { + if o == nil || o.Name == nil { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *ServerCertificate) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *ServerCertificate) SetName(v string) { + o.Name = &v +} + +// GetPath returns the Path field value if set, zero value otherwise. +func (o *ServerCertificate) GetPath() string { + if o == nil || o.Path == nil { + var ret string + return ret + } + return *o.Path +} + +// GetPathOk returns a tuple with the Path field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ServerCertificate) GetPathOk() (*string, bool) { + if o == nil || o.Path == nil { + return nil, false + } + return o.Path, true +} + +// HasPath returns a boolean if a field has been set. +func (o *ServerCertificate) HasPath() bool { + if o != nil && o.Path != nil { + return true + } + + return false +} + +// SetPath gets a reference to the given string and assigns it to the Path field. +func (o *ServerCertificate) SetPath(v string) { + o.Path = &v +} + +// GetUploadDate returns the UploadDate field value if set, zero value otherwise. +func (o *ServerCertificate) GetUploadDate() string { + if o == nil || o.UploadDate == nil { + var ret string + return ret + } + return *o.UploadDate +} + +// GetUploadDateOk returns a tuple with the UploadDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ServerCertificate) GetUploadDateOk() (*string, bool) { + if o == nil || o.UploadDate == nil { + return nil, false + } + return o.UploadDate, true +} + +// HasUploadDate returns a boolean if a field has been set. +func (o *ServerCertificate) HasUploadDate() bool { + if o != nil && o.UploadDate != nil { + return true + } + + return false +} + +// SetUploadDate gets a reference to the given string and assigns it to the UploadDate field. +func (o *ServerCertificate) SetUploadDate(v string) { + o.UploadDate = &v +} + +func (o ServerCertificate) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ExpirationDate != nil { + toSerialize["ExpirationDate"] = o.ExpirationDate + } + if o.Id != nil { + toSerialize["Id"] = o.Id + } + if o.Name != nil { + toSerialize["Name"] = o.Name + } + if o.Path != nil { + toSerialize["Path"] = o.Path + } + if o.UploadDate != nil { + toSerialize["UploadDate"] = o.UploadDate + } + return json.Marshal(toSerialize) +} + +type NullableServerCertificate struct { + value *ServerCertificate + isSet bool +} + +func (v NullableServerCertificate) Get() *ServerCertificate { + return v.value +} + +func (v *NullableServerCertificate) Set(val *ServerCertificate) { + v.value = val + v.isSet = true +} + +func (v NullableServerCertificate) IsSet() bool { + return v.isSet +} + +func (v *NullableServerCertificate) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableServerCertificate(val *ServerCertificate) *NullableServerCertificate { + return &NullableServerCertificate{value: val, isSet: true} +} + +func (v NullableServerCertificate) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableServerCertificate) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_service.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_service.go new file mode 100644 index 000000000..8f758c6d2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_service.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Service Information about the service. +type Service struct { + // The list of network prefixes used by the service, in CIDR notation. + IpRanges *[]string `json:"IpRanges,omitempty"` + // The ID of the service. + ServiceId *string `json:"ServiceId,omitempty"` + // The name of the prefix list, which identifies the 3DS OUTSCALE service it is associated with. + ServiceName *string `json:"ServiceName,omitempty"` +} + +// NewService instantiates a new Service object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewService() *Service { + this := Service{} + return &this +} + +// NewServiceWithDefaults instantiates a new Service object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewServiceWithDefaults() *Service { + this := Service{} + return &this +} + +// GetIpRanges returns the IpRanges field value if set, zero value otherwise. +func (o *Service) GetIpRanges() []string { + if o == nil || o.IpRanges == nil { + var ret []string + return ret + } + return *o.IpRanges +} + +// GetIpRangesOk returns a tuple with the IpRanges field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Service) GetIpRangesOk() (*[]string, bool) { + if o == nil || o.IpRanges == nil { + return nil, false + } + return o.IpRanges, true +} + +// HasIpRanges returns a boolean if a field has been set. +func (o *Service) HasIpRanges() bool { + if o != nil && o.IpRanges != nil { + return true + } + + return false +} + +// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. +func (o *Service) SetIpRanges(v []string) { + o.IpRanges = &v +} + +// GetServiceId returns the ServiceId field value if set, zero value otherwise. +func (o *Service) GetServiceId() string { + if o == nil || o.ServiceId == nil { + var ret string + return ret + } + return *o.ServiceId +} + +// GetServiceIdOk returns a tuple with the ServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Service) GetServiceIdOk() (*string, bool) { + if o == nil || o.ServiceId == nil { + return nil, false + } + return o.ServiceId, true +} + +// HasServiceId returns a boolean if a field has been set. +func (o *Service) HasServiceId() bool { + if o != nil && o.ServiceId != nil { + return true + } + + return false +} + +// SetServiceId gets a reference to the given string and assigns it to the ServiceId field. +func (o *Service) SetServiceId(v string) { + o.ServiceId = &v +} + +// GetServiceName returns the ServiceName field value if set, zero value otherwise. +func (o *Service) GetServiceName() string { + if o == nil || o.ServiceName == nil { + var ret string + return ret + } + return *o.ServiceName +} + +// GetServiceNameOk returns a tuple with the ServiceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Service) GetServiceNameOk() (*string, bool) { + if o == nil || o.ServiceName == nil { + return nil, false + } + return o.ServiceName, true +} + +// HasServiceName returns a boolean if a field has been set. +func (o *Service) HasServiceName() bool { + if o != nil && o.ServiceName != nil { + return true + } + + return false +} + +// SetServiceName gets a reference to the given string and assigns it to the ServiceName field. +func (o *Service) SetServiceName(v string) { + o.ServiceName = &v +} + +func (o Service) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.IpRanges != nil { + toSerialize["IpRanges"] = o.IpRanges + } + if o.ServiceId != nil { + toSerialize["ServiceId"] = o.ServiceId + } + if o.ServiceName != nil { + toSerialize["ServiceName"] = o.ServiceName + } + return json.Marshal(toSerialize) +} + +type NullableService struct { + value *Service + isSet bool +} + +func (v NullableService) Get() *Service { + return v.value +} + +func (v *NullableService) Set(val *Service) { + v.value = val + v.isSet = true +} + +func (v NullableService) IsSet() bool { + return v.isSet +} + +func (v *NullableService) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableService(val *Service) *NullableService { + return &NullableService{value: val, isSet: true} +} + +func (v NullableService) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableService) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go new file mode 100644 index 000000000..8d1858a56 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go @@ -0,0 +1,449 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Snapshot Information about the snapshot. +type Snapshot struct { + // The account alias of the owner of the snapshot. + AccountAlias *string `json:"AccountAlias,omitempty"` + // The account ID of the owner of the snapshot. + AccountId *string `json:"AccountId,omitempty"` + // The description of the snapshot. + Description *string `json:"Description,omitempty"` + PermissionsToCreateVolume *PermissionsOnResource `json:"PermissionsToCreateVolume,omitempty"` + // The progress of the snapshot, as a percentage. + Progress *int32 `json:"Progress,omitempty"` + // The ID of the snapshot. + SnapshotId *string `json:"SnapshotId,omitempty"` + // The state of the snapshot (`in-queue` \\| `completed` \\| `error`). + State *string `json:"State,omitempty"` + // One or more tags associated with the snapshot. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the volume used to create the snapshot. + VolumeId *string `json:"VolumeId,omitempty"` + // The size of the volume used to create the snapshot, in gibibytes (GiB). + VolumeSize *int32 `json:"VolumeSize,omitempty"` +} + +// NewSnapshot instantiates a new Snapshot object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSnapshot() *Snapshot { + this := Snapshot{} + return &this +} + +// NewSnapshotWithDefaults instantiates a new Snapshot object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSnapshotWithDefaults() *Snapshot { + this := Snapshot{} + return &this +} + +// GetAccountAlias returns the AccountAlias field value if set, zero value otherwise. +func (o *Snapshot) GetAccountAlias() string { + if o == nil || o.AccountAlias == nil { + var ret string + return ret + } + return *o.AccountAlias +} + +// GetAccountAliasOk returns a tuple with the AccountAlias field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetAccountAliasOk() (*string, bool) { + if o == nil || o.AccountAlias == nil { + return nil, false + } + return o.AccountAlias, true +} + +// HasAccountAlias returns a boolean if a field has been set. +func (o *Snapshot) HasAccountAlias() bool { + if o != nil && o.AccountAlias != nil { + return true + } + + return false +} + +// SetAccountAlias gets a reference to the given string and assigns it to the AccountAlias field. +func (o *Snapshot) SetAccountAlias(v string) { + o.AccountAlias = &v +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *Snapshot) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *Snapshot) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *Snapshot) SetAccountId(v string) { + o.AccountId = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *Snapshot) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *Snapshot) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *Snapshot) SetDescription(v string) { + o.Description = &v +} + +// GetPermissionsToCreateVolume returns the PermissionsToCreateVolume field value if set, zero value otherwise. +func (o *Snapshot) GetPermissionsToCreateVolume() PermissionsOnResource { + if o == nil || o.PermissionsToCreateVolume == nil { + var ret PermissionsOnResource + return ret + } + return *o.PermissionsToCreateVolume +} + +// GetPermissionsToCreateVolumeOk returns a tuple with the PermissionsToCreateVolume field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetPermissionsToCreateVolumeOk() (*PermissionsOnResource, bool) { + if o == nil || o.PermissionsToCreateVolume == nil { + return nil, false + } + return o.PermissionsToCreateVolume, true +} + +// HasPermissionsToCreateVolume returns a boolean if a field has been set. +func (o *Snapshot) HasPermissionsToCreateVolume() bool { + if o != nil && o.PermissionsToCreateVolume != nil { + return true + } + + return false +} + +// SetPermissionsToCreateVolume gets a reference to the given PermissionsOnResource and assigns it to the PermissionsToCreateVolume field. +func (o *Snapshot) SetPermissionsToCreateVolume(v PermissionsOnResource) { + o.PermissionsToCreateVolume = &v +} + +// GetProgress returns the Progress field value if set, zero value otherwise. +func (o *Snapshot) GetProgress() int32 { + if o == nil || o.Progress == nil { + var ret int32 + return ret + } + return *o.Progress +} + +// GetProgressOk returns a tuple with the Progress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetProgressOk() (*int32, bool) { + if o == nil || o.Progress == nil { + return nil, false + } + return o.Progress, true +} + +// HasProgress returns a boolean if a field has been set. +func (o *Snapshot) HasProgress() bool { + if o != nil && o.Progress != nil { + return true + } + + return false +} + +// SetProgress gets a reference to the given int32 and assigns it to the Progress field. +func (o *Snapshot) SetProgress(v int32) { + o.Progress = &v +} + +// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. +func (o *Snapshot) GetSnapshotId() string { + if o == nil || o.SnapshotId == nil { + var ret string + return ret + } + return *o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetSnapshotIdOk() (*string, bool) { + if o == nil || o.SnapshotId == nil { + return nil, false + } + return o.SnapshotId, true +} + +// HasSnapshotId returns a boolean if a field has been set. +func (o *Snapshot) HasSnapshotId() bool { + if o != nil && o.SnapshotId != nil { + return true + } + + return false +} + +// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. +func (o *Snapshot) SetSnapshotId(v string) { + o.SnapshotId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Snapshot) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Snapshot) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Snapshot) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Snapshot) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Snapshot) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Snapshot) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *Snapshot) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *Snapshot) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *Snapshot) SetVolumeId(v string) { + o.VolumeId = &v +} + +// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. +func (o *Snapshot) GetVolumeSize() int32 { + if o == nil || o.VolumeSize == nil { + var ret int32 + return ret + } + return *o.VolumeSize +} + +// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Snapshot) GetVolumeSizeOk() (*int32, bool) { + if o == nil || o.VolumeSize == nil { + return nil, false + } + return o.VolumeSize, true +} + +// HasVolumeSize returns a boolean if a field has been set. +func (o *Snapshot) HasVolumeSize() bool { + if o != nil && o.VolumeSize != nil { + return true + } + + return false +} + +// SetVolumeSize gets a reference to the given int32 and assigns it to the VolumeSize field. +func (o *Snapshot) SetVolumeSize(v int32) { + o.VolumeSize = &v +} + +func (o Snapshot) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountAlias != nil { + toSerialize["AccountAlias"] = o.AccountAlias + } + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.PermissionsToCreateVolume != nil { + toSerialize["PermissionsToCreateVolume"] = o.PermissionsToCreateVolume + } + if o.Progress != nil { + toSerialize["Progress"] = o.Progress + } + if o.SnapshotId != nil { + toSerialize["SnapshotId"] = o.SnapshotId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + if o.VolumeSize != nil { + toSerialize["VolumeSize"] = o.VolumeSize + } + return json.Marshal(toSerialize) +} + +type NullableSnapshot struct { + value *Snapshot + isSet bool +} + +func (v NullableSnapshot) Get() *Snapshot { + return v.value +} + +func (v *NullableSnapshot) Set(val *Snapshot) { + v.value = val + v.isSet = true +} + +func (v NullableSnapshot) IsSet() bool { + return v.isSet +} + +func (v *NullableSnapshot) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSnapshot(val *Snapshot) *NullableSnapshot { + return &NullableSnapshot{value: val, isSet: true} +} + +func (v NullableSnapshot) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSnapshot) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go new file mode 100644 index 000000000..4d66c3aa9 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go @@ -0,0 +1,338 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SnapshotExportTask Information about the snapshot export task. +type SnapshotExportTask struct { + // If the snapshot export task fails, an error message appears. + Comment *string `json:"Comment,omitempty"` + OsuExport *OsuExport `json:"OsuExport,omitempty"` + // The progress of the snapshot export task, as a percentage. + Progress *int32 `json:"Progress,omitempty"` + // The ID of the snapshot to be exported. + SnapshotId *string `json:"SnapshotId,omitempty"` + // The state of the snapshot export task (`pending` \\| `active` \\| `completed` \\| `failed`). + State *string `json:"State,omitempty"` + // One or more tags associated with the snapshot export task. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the snapshot export task. + TaskId *string `json:"TaskId,omitempty"` +} + +// NewSnapshotExportTask instantiates a new SnapshotExportTask object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSnapshotExportTask() *SnapshotExportTask { + this := SnapshotExportTask{} + return &this +} + +// NewSnapshotExportTaskWithDefaults instantiates a new SnapshotExportTask object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSnapshotExportTaskWithDefaults() *SnapshotExportTask { + this := SnapshotExportTask{} + return &this +} + +// GetComment returns the Comment field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetComment() string { + if o == nil || o.Comment == nil { + var ret string + return ret + } + return *o.Comment +} + +// GetCommentOk returns a tuple with the Comment field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetCommentOk() (*string, bool) { + if o == nil || o.Comment == nil { + return nil, false + } + return o.Comment, true +} + +// HasComment returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasComment() bool { + if o != nil && o.Comment != nil { + return true + } + + return false +} + +// SetComment gets a reference to the given string and assigns it to the Comment field. +func (o *SnapshotExportTask) SetComment(v string) { + o.Comment = &v +} + +// GetOsuExport returns the OsuExport field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetOsuExport() OsuExport { + if o == nil || o.OsuExport == nil { + var ret OsuExport + return ret + } + return *o.OsuExport +} + +// GetOsuExportOk returns a tuple with the OsuExport field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetOsuExportOk() (*OsuExport, bool) { + if o == nil || o.OsuExport == nil { + return nil, false + } + return o.OsuExport, true +} + +// HasOsuExport returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasOsuExport() bool { + if o != nil && o.OsuExport != nil { + return true + } + + return false +} + +// SetOsuExport gets a reference to the given OsuExport and assigns it to the OsuExport field. +func (o *SnapshotExportTask) SetOsuExport(v OsuExport) { + o.OsuExport = &v +} + +// GetProgress returns the Progress field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetProgress() int32 { + if o == nil || o.Progress == nil { + var ret int32 + return ret + } + return *o.Progress +} + +// GetProgressOk returns a tuple with the Progress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetProgressOk() (*int32, bool) { + if o == nil || o.Progress == nil { + return nil, false + } + return o.Progress, true +} + +// HasProgress returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasProgress() bool { + if o != nil && o.Progress != nil { + return true + } + + return false +} + +// SetProgress gets a reference to the given int32 and assigns it to the Progress field. +func (o *SnapshotExportTask) SetProgress(v int32) { + o.Progress = &v +} + +// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetSnapshotId() string { + if o == nil || o.SnapshotId == nil { + var ret string + return ret + } + return *o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetSnapshotIdOk() (*string, bool) { + if o == nil || o.SnapshotId == nil { + return nil, false + } + return o.SnapshotId, true +} + +// HasSnapshotId returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasSnapshotId() bool { + if o != nil && o.SnapshotId != nil { + return true + } + + return false +} + +// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. +func (o *SnapshotExportTask) SetSnapshotId(v string) { + o.SnapshotId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *SnapshotExportTask) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *SnapshotExportTask) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetTaskId returns the TaskId field value if set, zero value otherwise. +func (o *SnapshotExportTask) GetTaskId() string { + if o == nil || o.TaskId == nil { + var ret string + return ret + } + return *o.TaskId +} + +// GetTaskIdOk returns a tuple with the TaskId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SnapshotExportTask) GetTaskIdOk() (*string, bool) { + if o == nil || o.TaskId == nil { + return nil, false + } + return o.TaskId, true +} + +// HasTaskId returns a boolean if a field has been set. +func (o *SnapshotExportTask) HasTaskId() bool { + if o != nil && o.TaskId != nil { + return true + } + + return false +} + +// SetTaskId gets a reference to the given string and assigns it to the TaskId field. +func (o *SnapshotExportTask) SetTaskId(v string) { + o.TaskId = &v +} + +func (o SnapshotExportTask) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Comment != nil { + toSerialize["Comment"] = o.Comment + } + if o.OsuExport != nil { + toSerialize["OsuExport"] = o.OsuExport + } + if o.Progress != nil { + toSerialize["Progress"] = o.Progress + } + if o.SnapshotId != nil { + toSerialize["SnapshotId"] = o.SnapshotId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.TaskId != nil { + toSerialize["TaskId"] = o.TaskId + } + return json.Marshal(toSerialize) +} + +type NullableSnapshotExportTask struct { + value *SnapshotExportTask + isSet bool +} + +func (v NullableSnapshotExportTask) Get() *SnapshotExportTask { + return v.value +} + +func (v *NullableSnapshotExportTask) Set(val *SnapshotExportTask) { + v.value = val + v.isSet = true +} + +func (v NullableSnapshotExportTask) IsSet() bool { + return v.isSet +} + +func (v *NullableSnapshotExportTask) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSnapshotExportTask(val *SnapshotExportTask) *NullableSnapshotExportTask { + return &NullableSnapshotExportTask{value: val, isSet: true} +} + +func (v NullableSnapshotExportTask) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSnapshotExportTask) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go new file mode 100644 index 000000000..41bc49f79 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SourceNet Information about the source Net. +type SourceNet struct { + // The account ID of the owner of the source Net. + AccountId *string `json:"AccountId,omitempty"` + // The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // The ID of the source Net. + NetId *string `json:"NetId,omitempty"` +} + +// NewSourceNet instantiates a new SourceNet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSourceNet() *SourceNet { + this := SourceNet{} + return &this +} + +// NewSourceNetWithDefaults instantiates a new SourceNet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSourceNetWithDefaults() *SourceNet { + this := SourceNet{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *SourceNet) GetAccountId() string { + if o == nil || o.AccountId == nil { + var ret string + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceNet) GetAccountIdOk() (*string, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *SourceNet) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given string and assigns it to the AccountId field. +func (o *SourceNet) SetAccountId(v string) { + o.AccountId = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *SourceNet) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceNet) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *SourceNet) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *SourceNet) SetIpRange(v string) { + o.IpRange = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *SourceNet) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceNet) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *SourceNet) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *SourceNet) SetNetId(v string) { + o.NetId = &v +} + +func (o SourceNet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableSourceNet struct { + value *SourceNet + isSet bool +} + +func (v NullableSourceNet) Get() *SourceNet { + return v.value +} + +func (v *NullableSourceNet) Set(val *SourceNet) { + v.value = val + v.isSet = true +} + +func (v NullableSourceNet) IsSet() bool { + return v.isSet +} + +func (v *NullableSourceNet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSourceNet(val *SourceNet) *NullableSourceNet { + return &NullableSourceNet{value: val, isSet: true} +} + +func (v NullableSourceNet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSourceNet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go new file mode 100644 index 000000000..6fbfc34c8 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// SourceSecurityGroup Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. +type SourceSecurityGroup struct { + // The account ID of the owner of the security group. + SecurityGroupAccountId *string `json:"SecurityGroupAccountId,omitempty"` + // The name of the security group. + SecurityGroupName *string `json:"SecurityGroupName,omitempty"` +} + +// NewSourceSecurityGroup instantiates a new SourceSecurityGroup object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSourceSecurityGroup() *SourceSecurityGroup { + this := SourceSecurityGroup{} + return &this +} + +// NewSourceSecurityGroupWithDefaults instantiates a new SourceSecurityGroup object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSourceSecurityGroupWithDefaults() *SourceSecurityGroup { + this := SourceSecurityGroup{} + return &this +} + +// GetSecurityGroupAccountId returns the SecurityGroupAccountId field value if set, zero value otherwise. +func (o *SourceSecurityGroup) GetSecurityGroupAccountId() string { + if o == nil || o.SecurityGroupAccountId == nil { + var ret string + return ret + } + return *o.SecurityGroupAccountId +} + +// GetSecurityGroupAccountIdOk returns a tuple with the SecurityGroupAccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceSecurityGroup) GetSecurityGroupAccountIdOk() (*string, bool) { + if o == nil || o.SecurityGroupAccountId == nil { + return nil, false + } + return o.SecurityGroupAccountId, true +} + +// HasSecurityGroupAccountId returns a boolean if a field has been set. +func (o *SourceSecurityGroup) HasSecurityGroupAccountId() bool { + if o != nil && o.SecurityGroupAccountId != nil { + return true + } + + return false +} + +// SetSecurityGroupAccountId gets a reference to the given string and assigns it to the SecurityGroupAccountId field. +func (o *SourceSecurityGroup) SetSecurityGroupAccountId(v string) { + o.SecurityGroupAccountId = &v +} + +// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. +func (o *SourceSecurityGroup) GetSecurityGroupName() string { + if o == nil || o.SecurityGroupName == nil { + var ret string + return ret + } + return *o.SecurityGroupName +} + +// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SourceSecurityGroup) GetSecurityGroupNameOk() (*string, bool) { + if o == nil || o.SecurityGroupName == nil { + return nil, false + } + return o.SecurityGroupName, true +} + +// HasSecurityGroupName returns a boolean if a field has been set. +func (o *SourceSecurityGroup) HasSecurityGroupName() bool { + if o != nil && o.SecurityGroupName != nil { + return true + } + + return false +} + +// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. +func (o *SourceSecurityGroup) SetSecurityGroupName(v string) { + o.SecurityGroupName = &v +} + +func (o SourceSecurityGroup) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.SecurityGroupAccountId != nil { + toSerialize["SecurityGroupAccountId"] = o.SecurityGroupAccountId + } + if o.SecurityGroupName != nil { + toSerialize["SecurityGroupName"] = o.SecurityGroupName + } + return json.Marshal(toSerialize) +} + +type NullableSourceSecurityGroup struct { + value *SourceSecurityGroup + isSet bool +} + +func (v NullableSourceSecurityGroup) Get() *SourceSecurityGroup { + return v.value +} + +func (v *NullableSourceSecurityGroup) Set(val *SourceSecurityGroup) { + v.value = val + v.isSet = true +} + +func (v NullableSourceSecurityGroup) IsSet() bool { + return v.isSet +} + +func (v *NullableSourceSecurityGroup) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSourceSecurityGroup(val *SourceSecurityGroup) *NullableSourceSecurityGroup { + return &NullableSourceSecurityGroup{value: val, isSet: true} +} + +func (v NullableSourceSecurityGroup) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSourceSecurityGroup) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go new file mode 100644 index 000000000..a23e69959 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// StartVmsRequest struct for StartVmsRequest +type StartVmsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // One or more IDs of VMs. + VmIds []string `json:"VmIds"` +} + +// NewStartVmsRequest instantiates a new StartVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewStartVmsRequest(vmIds []string, ) *StartVmsRequest { + this := StartVmsRequest{} + this.VmIds = vmIds + return &this +} + +// NewStartVmsRequestWithDefaults instantiates a new StartVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewStartVmsRequestWithDefaults() *StartVmsRequest { + this := StartVmsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *StartVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StartVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *StartVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *StartVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetVmIds returns the VmIds field value +func (o *StartVmsRequest) GetVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value +// and a boolean to check if the value has been set. +func (o *StartVmsRequest) GetVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.VmIds, true +} + +// SetVmIds sets field value +func (o *StartVmsRequest) SetVmIds(v []string) { + o.VmIds = v +} + +func (o StartVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableStartVmsRequest struct { + value *StartVmsRequest + isSet bool +} + +func (v NullableStartVmsRequest) Get() *StartVmsRequest { + return v.value +} + +func (v *NullableStartVmsRequest) Set(val *StartVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableStartVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableStartVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableStartVmsRequest(val *StartVmsRequest) *NullableStartVmsRequest { + return &NullableStartVmsRequest{value: val, isSet: true} +} + +func (v NullableStartVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableStartVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go new file mode 100644 index 000000000..3a3656744 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// StartVmsResponse struct for StartVmsResponse +type StartVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more started VMs. + Vms *[]VmState `json:"Vms,omitempty"` +} + +// NewStartVmsResponse instantiates a new StartVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewStartVmsResponse() *StartVmsResponse { + this := StartVmsResponse{} + return &this +} + +// NewStartVmsResponseWithDefaults instantiates a new StartVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewStartVmsResponseWithDefaults() *StartVmsResponse { + this := StartVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *StartVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StartVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *StartVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *StartVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVms returns the Vms field value if set, zero value otherwise. +func (o *StartVmsResponse) GetVms() []VmState { + if o == nil || o.Vms == nil { + var ret []VmState + return ret + } + return *o.Vms +} + +// GetVmsOk returns a tuple with the Vms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StartVmsResponse) GetVmsOk() (*[]VmState, bool) { + if o == nil || o.Vms == nil { + return nil, false + } + return o.Vms, true +} + +// HasVms returns a boolean if a field has been set. +func (o *StartVmsResponse) HasVms() bool { + if o != nil && o.Vms != nil { + return true + } + + return false +} + +// SetVms gets a reference to the given []VmState and assigns it to the Vms field. +func (o *StartVmsResponse) SetVms(v []VmState) { + o.Vms = &v +} + +func (o StartVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vms != nil { + toSerialize["Vms"] = o.Vms + } + return json.Marshal(toSerialize) +} + +type NullableStartVmsResponse struct { + value *StartVmsResponse + isSet bool +} + +func (v NullableStartVmsResponse) Get() *StartVmsResponse { + return v.value +} + +func (v *NullableStartVmsResponse) Set(val *StartVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableStartVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableStartVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableStartVmsResponse(val *StartVmsResponse) *NullableStartVmsResponse { + return &NullableStartVmsResponse{value: val, isSet: true} +} + +func (v NullableStartVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableStartVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go new file mode 100644 index 000000000..b5935ac22 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go @@ -0,0 +1,154 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// StateComment Information about the change of state. +type StateComment struct { + // The code of the change of state. + StateCode *string `json:"StateCode,omitempty"` + // A message explaining the change of state. + StateMessage *string `json:"StateMessage,omitempty"` +} + +// NewStateComment instantiates a new StateComment object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewStateComment() *StateComment { + this := StateComment{} + return &this +} + +// NewStateCommentWithDefaults instantiates a new StateComment object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewStateCommentWithDefaults() *StateComment { + this := StateComment{} + return &this +} + +// GetStateCode returns the StateCode field value if set, zero value otherwise. +func (o *StateComment) GetStateCode() string { + if o == nil || o.StateCode == nil { + var ret string + return ret + } + return *o.StateCode +} + +// GetStateCodeOk returns a tuple with the StateCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StateComment) GetStateCodeOk() (*string, bool) { + if o == nil || o.StateCode == nil { + return nil, false + } + return o.StateCode, true +} + +// HasStateCode returns a boolean if a field has been set. +func (o *StateComment) HasStateCode() bool { + if o != nil && o.StateCode != nil { + return true + } + + return false +} + +// SetStateCode gets a reference to the given string and assigns it to the StateCode field. +func (o *StateComment) SetStateCode(v string) { + o.StateCode = &v +} + +// GetStateMessage returns the StateMessage field value if set, zero value otherwise. +func (o *StateComment) GetStateMessage() string { + if o == nil || o.StateMessage == nil { + var ret string + return ret + } + return *o.StateMessage +} + +// GetStateMessageOk returns a tuple with the StateMessage field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StateComment) GetStateMessageOk() (*string, bool) { + if o == nil || o.StateMessage == nil { + return nil, false + } + return o.StateMessage, true +} + +// HasStateMessage returns a boolean if a field has been set. +func (o *StateComment) HasStateMessage() bool { + if o != nil && o.StateMessage != nil { + return true + } + + return false +} + +// SetStateMessage gets a reference to the given string and assigns it to the StateMessage field. +func (o *StateComment) SetStateMessage(v string) { + o.StateMessage = &v +} + +func (o StateComment) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.StateCode != nil { + toSerialize["StateCode"] = o.StateCode + } + if o.StateMessage != nil { + toSerialize["StateMessage"] = o.StateMessage + } + return json.Marshal(toSerialize) +} + +type NullableStateComment struct { + value *StateComment + isSet bool +} + +func (v NullableStateComment) Get() *StateComment { + return v.value +} + +func (v *NullableStateComment) Set(val *StateComment) { + v.value = val + v.isSet = true +} + +func (v NullableStateComment) IsSet() bool { + return v.isSet +} + +func (v *NullableStateComment) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableStateComment(val *StateComment) *NullableStateComment { + return &NullableStateComment{value: val, isSet: true} +} + +func (v NullableStateComment) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableStateComment) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go new file mode 100644 index 000000000..17d70586c --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// StopVmsRequest struct for StopVmsRequest +type StopVmsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // Forces the VM to stop. + ForceStop *bool `json:"ForceStop,omitempty"` + // One or more IDs of VMs. + VmIds []string `json:"VmIds"` +} + +// NewStopVmsRequest instantiates a new StopVmsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewStopVmsRequest(vmIds []string, ) *StopVmsRequest { + this := StopVmsRequest{} + this.VmIds = vmIds + return &this +} + +// NewStopVmsRequestWithDefaults instantiates a new StopVmsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewStopVmsRequestWithDefaults() *StopVmsRequest { + this := StopVmsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *StopVmsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StopVmsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *StopVmsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *StopVmsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetForceStop returns the ForceStop field value if set, zero value otherwise. +func (o *StopVmsRequest) GetForceStop() bool { + if o == nil || o.ForceStop == nil { + var ret bool + return ret + } + return *o.ForceStop +} + +// GetForceStopOk returns a tuple with the ForceStop field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StopVmsRequest) GetForceStopOk() (*bool, bool) { + if o == nil || o.ForceStop == nil { + return nil, false + } + return o.ForceStop, true +} + +// HasForceStop returns a boolean if a field has been set. +func (o *StopVmsRequest) HasForceStop() bool { + if o != nil && o.ForceStop != nil { + return true + } + + return false +} + +// SetForceStop gets a reference to the given bool and assigns it to the ForceStop field. +func (o *StopVmsRequest) SetForceStop(v bool) { + o.ForceStop = &v +} + +// GetVmIds returns the VmIds field value +func (o *StopVmsRequest) GetVmIds() []string { + if o == nil { + var ret []string + return ret + } + + return o.VmIds +} + +// GetVmIdsOk returns a tuple with the VmIds field value +// and a boolean to check if the value has been set. +func (o *StopVmsRequest) GetVmIdsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.VmIds, true +} + +// SetVmIds sets field value +func (o *StopVmsRequest) SetVmIds(v []string) { + o.VmIds = v +} + +func (o StopVmsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.ForceStop != nil { + toSerialize["ForceStop"] = o.ForceStop + } + if true { + toSerialize["VmIds"] = o.VmIds + } + return json.Marshal(toSerialize) +} + +type NullableStopVmsRequest struct { + value *StopVmsRequest + isSet bool +} + +func (v NullableStopVmsRequest) Get() *StopVmsRequest { + return v.value +} + +func (v *NullableStopVmsRequest) Set(val *StopVmsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableStopVmsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableStopVmsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableStopVmsRequest(val *StopVmsRequest) *NullableStopVmsRequest { + return &NullableStopVmsRequest{value: val, isSet: true} +} + +func (v NullableStopVmsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableStopVmsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go new file mode 100644 index 000000000..623468f91 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go @@ -0,0 +1,153 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// StopVmsResponse struct for StopVmsResponse +type StopVmsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + // Information about one or more stopped VMs. + Vms *[]VmState `json:"Vms,omitempty"` +} + +// NewStopVmsResponse instantiates a new StopVmsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewStopVmsResponse() *StopVmsResponse { + this := StopVmsResponse{} + return &this +} + +// NewStopVmsResponseWithDefaults instantiates a new StopVmsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewStopVmsResponseWithDefaults() *StopVmsResponse { + this := StopVmsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *StopVmsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StopVmsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *StopVmsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *StopVmsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVms returns the Vms field value if set, zero value otherwise. +func (o *StopVmsResponse) GetVms() []VmState { + if o == nil || o.Vms == nil { + var ret []VmState + return ret + } + return *o.Vms +} + +// GetVmsOk returns a tuple with the Vms field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *StopVmsResponse) GetVmsOk() (*[]VmState, bool) { + if o == nil || o.Vms == nil { + return nil, false + } + return o.Vms, true +} + +// HasVms returns a boolean if a field has been set. +func (o *StopVmsResponse) HasVms() bool { + if o != nil && o.Vms != nil { + return true + } + + return false +} + +// SetVms gets a reference to the given []VmState and assigns it to the Vms field. +func (o *StopVmsResponse) SetVms(v []VmState) { + o.Vms = &v +} + +func (o StopVmsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vms != nil { + toSerialize["Vms"] = o.Vms + } + return json.Marshal(toSerialize) +} + +type NullableStopVmsResponse struct { + value *StopVmsResponse + isSet bool +} + +func (v NullableStopVmsResponse) Get() *StopVmsResponse { + return v.value +} + +func (v *NullableStopVmsResponse) Set(val *StopVmsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableStopVmsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableStopVmsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableStopVmsResponse(val *StopVmsResponse) *NullableStopVmsResponse { + return &NullableStopVmsResponse{value: val, isSet: true} +} + +func (v NullableStopVmsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableStopVmsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go new file mode 100644 index 000000000..bad5b2973 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go @@ -0,0 +1,376 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Subnet Information about the Subnet. +type Subnet struct { + // The number of available IP addresses in the Subnets. + AvailableIpsCount *int32 `json:"AvailableIpsCount,omitempty"` + // The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). + IpRange *string `json:"IpRange,omitempty"` + // If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. + MapPublicIpOnLaunch *bool `json:"MapPublicIpOnLaunch,omitempty"` + // The ID of the Net in which the Subnet is. + NetId *string `json:"NetId,omitempty"` + // The state of the Subnet (`pending` \\| `available`). + State *string `json:"State,omitempty"` + // The ID of the Subnet. + SubnetId *string `json:"SubnetId,omitempty"` + // The name of the Subregion in which the Subnet is located. + SubregionName *string `json:"SubregionName,omitempty"` + // One or more tags associated with the Subnet. + Tags *[]ResourceTag `json:"Tags,omitempty"` +} + +// NewSubnet instantiates a new Subnet object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSubnet() *Subnet { + this := Subnet{} + return &this +} + +// NewSubnetWithDefaults instantiates a new Subnet object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSubnetWithDefaults() *Subnet { + this := Subnet{} + return &this +} + +// GetAvailableIpsCount returns the AvailableIpsCount field value if set, zero value otherwise. +func (o *Subnet) GetAvailableIpsCount() int32 { + if o == nil || o.AvailableIpsCount == nil { + var ret int32 + return ret + } + return *o.AvailableIpsCount +} + +// GetAvailableIpsCountOk returns a tuple with the AvailableIpsCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetAvailableIpsCountOk() (*int32, bool) { + if o == nil || o.AvailableIpsCount == nil { + return nil, false + } + return o.AvailableIpsCount, true +} + +// HasAvailableIpsCount returns a boolean if a field has been set. +func (o *Subnet) HasAvailableIpsCount() bool { + if o != nil && o.AvailableIpsCount != nil { + return true + } + + return false +} + +// SetAvailableIpsCount gets a reference to the given int32 and assigns it to the AvailableIpsCount field. +func (o *Subnet) SetAvailableIpsCount(v int32) { + o.AvailableIpsCount = &v +} + +// GetIpRange returns the IpRange field value if set, zero value otherwise. +func (o *Subnet) GetIpRange() string { + if o == nil || o.IpRange == nil { + var ret string + return ret + } + return *o.IpRange +} + +// GetIpRangeOk returns a tuple with the IpRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetIpRangeOk() (*string, bool) { + if o == nil || o.IpRange == nil { + return nil, false + } + return o.IpRange, true +} + +// HasIpRange returns a boolean if a field has been set. +func (o *Subnet) HasIpRange() bool { + if o != nil && o.IpRange != nil { + return true + } + + return false +} + +// SetIpRange gets a reference to the given string and assigns it to the IpRange field. +func (o *Subnet) SetIpRange(v string) { + o.IpRange = &v +} + +// GetMapPublicIpOnLaunch returns the MapPublicIpOnLaunch field value if set, zero value otherwise. +func (o *Subnet) GetMapPublicIpOnLaunch() bool { + if o == nil || o.MapPublicIpOnLaunch == nil { + var ret bool + return ret + } + return *o.MapPublicIpOnLaunch +} + +// GetMapPublicIpOnLaunchOk returns a tuple with the MapPublicIpOnLaunch field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetMapPublicIpOnLaunchOk() (*bool, bool) { + if o == nil || o.MapPublicIpOnLaunch == nil { + return nil, false + } + return o.MapPublicIpOnLaunch, true +} + +// HasMapPublicIpOnLaunch returns a boolean if a field has been set. +func (o *Subnet) HasMapPublicIpOnLaunch() bool { + if o != nil && o.MapPublicIpOnLaunch != nil { + return true + } + + return false +} + +// SetMapPublicIpOnLaunch gets a reference to the given bool and assigns it to the MapPublicIpOnLaunch field. +func (o *Subnet) SetMapPublicIpOnLaunch(v bool) { + o.MapPublicIpOnLaunch = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *Subnet) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *Subnet) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *Subnet) SetNetId(v string) { + o.NetId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Subnet) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Subnet) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Subnet) SetState(v string) { + o.State = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *Subnet) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *Subnet) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *Subnet) SetSubnetId(v string) { + o.SubnetId = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *Subnet) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *Subnet) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *Subnet) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Subnet) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subnet) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Subnet) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Subnet) SetTags(v []ResourceTag) { + o.Tags = &v +} + +func (o Subnet) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AvailableIpsCount != nil { + toSerialize["AvailableIpsCount"] = o.AvailableIpsCount + } + if o.IpRange != nil { + toSerialize["IpRange"] = o.IpRange + } + if o.MapPublicIpOnLaunch != nil { + toSerialize["MapPublicIpOnLaunch"] = o.MapPublicIpOnLaunch + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + return json.Marshal(toSerialize) +} + +type NullableSubnet struct { + value *Subnet + isSet bool +} + +func (v NullableSubnet) Get() *Subnet { + return v.value +} + +func (v *NullableSubnet) Set(val *Subnet) { + v.value = val + v.isSet = true +} + +func (v NullableSubnet) IsSet() bool { + return v.isSet +} + +func (v *NullableSubnet) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubnet(val *Subnet) *NullableSubnet { + return &NullableSubnet{value: val, isSet: true} +} + +func (v NullableSubnet) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubnet) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go new file mode 100644 index 000000000..8d5c2f70e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Subregion Information about the Subregion. +type Subregion struct { + // The name of the Region containing the Subregion. + RegionName *string `json:"RegionName,omitempty"` + // The state of the Subregion (`available` \\| `information` \\| `impaired` \\| `unavailable`). + State *string `json:"State,omitempty"` + // The name of the Subregion. + SubregionName *string `json:"SubregionName,omitempty"` +} + +// NewSubregion instantiates a new Subregion object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSubregion() *Subregion { + this := Subregion{} + return &this +} + +// NewSubregionWithDefaults instantiates a new Subregion object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSubregionWithDefaults() *Subregion { + this := Subregion{} + return &this +} + +// GetRegionName returns the RegionName field value if set, zero value otherwise. +func (o *Subregion) GetRegionName() string { + if o == nil || o.RegionName == nil { + var ret string + return ret + } + return *o.RegionName +} + +// GetRegionNameOk returns a tuple with the RegionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subregion) GetRegionNameOk() (*string, bool) { + if o == nil || o.RegionName == nil { + return nil, false + } + return o.RegionName, true +} + +// HasRegionName returns a boolean if a field has been set. +func (o *Subregion) HasRegionName() bool { + if o != nil && o.RegionName != nil { + return true + } + + return false +} + +// SetRegionName gets a reference to the given string and assigns it to the RegionName field. +func (o *Subregion) SetRegionName(v string) { + o.RegionName = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Subregion) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subregion) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Subregion) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Subregion) SetState(v string) { + o.State = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *Subregion) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Subregion) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *Subregion) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *Subregion) SetSubregionName(v string) { + o.SubregionName = &v +} + +func (o Subregion) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.RegionName != nil { + toSerialize["RegionName"] = o.RegionName + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + return json.Marshal(toSerialize) +} + +type NullableSubregion struct { + value *Subregion + isSet bool +} + +func (v NullableSubregion) Get() *Subregion { + return v.value +} + +func (v *NullableSubregion) Set(val *Subregion) { + v.value = val + v.isSet = true +} + +func (v NullableSubregion) IsSet() bool { + return v.isSet +} + +func (v *NullableSubregion) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSubregion(val *Subregion) *NullableSubregion { + return &NullableSubregion{value: val, isSet: true} +} + +func (v NullableSubregion) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSubregion) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go new file mode 100644 index 000000000..eead23b03 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Tag Information about the tag. +type Tag struct { + // The key of the tag, with a minimum of 1 character. + Key *string `json:"Key,omitempty"` + // The ID of the resource. + ResourceId *string `json:"ResourceId,omitempty"` + // The type of the resource. + ResourceType *string `json:"ResourceType,omitempty"` + // The value of the tag, between 0 and 255 characters. + Value *string `json:"Value,omitempty"` +} + +// NewTag instantiates a new Tag object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewTag() *Tag { + this := Tag{} + return &this +} + +// NewTagWithDefaults instantiates a new Tag object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewTagWithDefaults() *Tag { + this := Tag{} + return &this +} + +// GetKey returns the Key field value if set, zero value otherwise. +func (o *Tag) GetKey() string { + if o == nil || o.Key == nil { + var ret string + return ret + } + return *o.Key +} + +// GetKeyOk returns a tuple with the Key field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetKeyOk() (*string, bool) { + if o == nil || o.Key == nil { + return nil, false + } + return o.Key, true +} + +// HasKey returns a boolean if a field has been set. +func (o *Tag) HasKey() bool { + if o != nil && o.Key != nil { + return true + } + + return false +} + +// SetKey gets a reference to the given string and assigns it to the Key field. +func (o *Tag) SetKey(v string) { + o.Key = &v +} + +// GetResourceId returns the ResourceId field value if set, zero value otherwise. +func (o *Tag) GetResourceId() string { + if o == nil || o.ResourceId == nil { + var ret string + return ret + } + return *o.ResourceId +} + +// GetResourceIdOk returns a tuple with the ResourceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetResourceIdOk() (*string, bool) { + if o == nil || o.ResourceId == nil { + return nil, false + } + return o.ResourceId, true +} + +// HasResourceId returns a boolean if a field has been set. +func (o *Tag) HasResourceId() bool { + if o != nil && o.ResourceId != nil { + return true + } + + return false +} + +// SetResourceId gets a reference to the given string and assigns it to the ResourceId field. +func (o *Tag) SetResourceId(v string) { + o.ResourceId = &v +} + +// GetResourceType returns the ResourceType field value if set, zero value otherwise. +func (o *Tag) GetResourceType() string { + if o == nil || o.ResourceType == nil { + var ret string + return ret + } + return *o.ResourceType +} + +// GetResourceTypeOk returns a tuple with the ResourceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetResourceTypeOk() (*string, bool) { + if o == nil || o.ResourceType == nil { + return nil, false + } + return o.ResourceType, true +} + +// HasResourceType returns a boolean if a field has been set. +func (o *Tag) HasResourceType() bool { + if o != nil && o.ResourceType != nil { + return true + } + + return false +} + +// SetResourceType gets a reference to the given string and assigns it to the ResourceType field. +func (o *Tag) SetResourceType(v string) { + o.ResourceType = &v +} + +// GetValue returns the Value field value if set, zero value otherwise. +func (o *Tag) GetValue() string { + if o == nil || o.Value == nil { + var ret string + return ret + } + return *o.Value +} + +// GetValueOk returns a tuple with the Value field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Tag) GetValueOk() (*string, bool) { + if o == nil || o.Value == nil { + return nil, false + } + return o.Value, true +} + +// HasValue returns a boolean if a field has been set. +func (o *Tag) HasValue() bool { + if o != nil && o.Value != nil { + return true + } + + return false +} + +// SetValue gets a reference to the given string and assigns it to the Value field. +func (o *Tag) SetValue(v string) { + o.Value = &v +} + +func (o Tag) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Key != nil { + toSerialize["Key"] = o.Key + } + if o.ResourceId != nil { + toSerialize["ResourceId"] = o.ResourceId + } + if o.ResourceType != nil { + toSerialize["ResourceType"] = o.ResourceType + } + if o.Value != nil { + toSerialize["Value"] = o.Value + } + return json.Marshal(toSerialize) +} + +type NullableTag struct { + value *Tag + isSet bool +} + +func (v NullableTag) Get() *Tag { + return v.value +} + +func (v *NullableTag) Set(val *Tag) { + v.value = val + v.isSet = true +} + +func (v NullableTag) IsSet() bool { + return v.isSet +} + +func (v *NullableTag) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTag(val *Tag) *NullableTag { + return &NullableTag{value: val, isSet: true} +} + +func (v NullableTag) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTag) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go new file mode 100644 index 000000000..8ab8c344e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkFlexibleGpuRequest struct for UnlinkFlexibleGpuRequest +type UnlinkFlexibleGpuRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the fGPU you want to detach from your VM. + FlexibleGpuId string `json:"FlexibleGpuId"` +} + +// NewUnlinkFlexibleGpuRequest instantiates a new UnlinkFlexibleGpuRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkFlexibleGpuRequest(flexibleGpuId string, ) *UnlinkFlexibleGpuRequest { + this := UnlinkFlexibleGpuRequest{} + this.FlexibleGpuId = flexibleGpuId + return &this +} + +// NewUnlinkFlexibleGpuRequestWithDefaults instantiates a new UnlinkFlexibleGpuRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkFlexibleGpuRequestWithDefaults() *UnlinkFlexibleGpuRequest { + this := UnlinkFlexibleGpuRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkFlexibleGpuRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkFlexibleGpuRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkFlexibleGpuRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkFlexibleGpuRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlexibleGpuId returns the FlexibleGpuId field value +func (o *UnlinkFlexibleGpuRequest) GetFlexibleGpuId() string { + if o == nil { + var ret string + return ret + } + + return o.FlexibleGpuId +} + +// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value +// and a boolean to check if the value has been set. +func (o *UnlinkFlexibleGpuRequest) GetFlexibleGpuIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FlexibleGpuId, true +} + +// SetFlexibleGpuId sets field value +func (o *UnlinkFlexibleGpuRequest) SetFlexibleGpuId(v string) { + o.FlexibleGpuId = v +} + +func (o UnlinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["FlexibleGpuId"] = o.FlexibleGpuId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkFlexibleGpuRequest struct { + value *UnlinkFlexibleGpuRequest + isSet bool +} + +func (v NullableUnlinkFlexibleGpuRequest) Get() *UnlinkFlexibleGpuRequest { + return v.value +} + +func (v *NullableUnlinkFlexibleGpuRequest) Set(val *UnlinkFlexibleGpuRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkFlexibleGpuRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkFlexibleGpuRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkFlexibleGpuRequest(val *UnlinkFlexibleGpuRequest) *NullableUnlinkFlexibleGpuRequest { + return &NullableUnlinkFlexibleGpuRequest{value: val, isSet: true} +} + +func (v NullableUnlinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkFlexibleGpuRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go new file mode 100644 index 000000000..6ce8e77fd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkFlexibleGpuResponse struct for UnlinkFlexibleGpuResponse +type UnlinkFlexibleGpuResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkFlexibleGpuResponse instantiates a new UnlinkFlexibleGpuResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkFlexibleGpuResponse() *UnlinkFlexibleGpuResponse { + this := UnlinkFlexibleGpuResponse{} + return &this +} + +// NewUnlinkFlexibleGpuResponseWithDefaults instantiates a new UnlinkFlexibleGpuResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkFlexibleGpuResponseWithDefaults() *UnlinkFlexibleGpuResponse { + this := UnlinkFlexibleGpuResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkFlexibleGpuResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkFlexibleGpuResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkFlexibleGpuResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkFlexibleGpuResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkFlexibleGpuResponse struct { + value *UnlinkFlexibleGpuResponse + isSet bool +} + +func (v NullableUnlinkFlexibleGpuResponse) Get() *UnlinkFlexibleGpuResponse { + return v.value +} + +func (v *NullableUnlinkFlexibleGpuResponse) Set(val *UnlinkFlexibleGpuResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkFlexibleGpuResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkFlexibleGpuResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkFlexibleGpuResponse(val *UnlinkFlexibleGpuResponse) *NullableUnlinkFlexibleGpuResponse { + return &NullableUnlinkFlexibleGpuResponse{value: val, isSet: true} +} + +func (v NullableUnlinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkFlexibleGpuResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go new file mode 100644 index 000000000..587655775 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkInternetServiceRequest struct for UnlinkInternetServiceRequest +type UnlinkInternetServiceRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Internet service you want to detach. + InternetServiceId string `json:"InternetServiceId"` + // The ID of the Net from which you want to detach the Internet service. + NetId string `json:"NetId"` +} + +// NewUnlinkInternetServiceRequest instantiates a new UnlinkInternetServiceRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkInternetServiceRequest(internetServiceId string, netId string, ) *UnlinkInternetServiceRequest { + this := UnlinkInternetServiceRequest{} + this.InternetServiceId = internetServiceId + this.NetId = netId + return &this +} + +// NewUnlinkInternetServiceRequestWithDefaults instantiates a new UnlinkInternetServiceRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkInternetServiceRequestWithDefaults() *UnlinkInternetServiceRequest { + this := UnlinkInternetServiceRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkInternetServiceRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkInternetServiceRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkInternetServiceRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkInternetServiceRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetInternetServiceId returns the InternetServiceId field value +func (o *UnlinkInternetServiceRequest) GetInternetServiceId() string { + if o == nil { + var ret string + return ret + } + + return o.InternetServiceId +} + +// GetInternetServiceIdOk returns a tuple with the InternetServiceId field value +// and a boolean to check if the value has been set. +func (o *UnlinkInternetServiceRequest) GetInternetServiceIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.InternetServiceId, true +} + +// SetInternetServiceId sets field value +func (o *UnlinkInternetServiceRequest) SetInternetServiceId(v string) { + o.InternetServiceId = v +} + +// GetNetId returns the NetId field value +func (o *UnlinkInternetServiceRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *UnlinkInternetServiceRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *UnlinkInternetServiceRequest) SetNetId(v string) { + o.NetId = v +} + +func (o UnlinkInternetServiceRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["InternetServiceId"] = o.InternetServiceId + } + if true { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkInternetServiceRequest struct { + value *UnlinkInternetServiceRequest + isSet bool +} + +func (v NullableUnlinkInternetServiceRequest) Get() *UnlinkInternetServiceRequest { + return v.value +} + +func (v *NullableUnlinkInternetServiceRequest) Set(val *UnlinkInternetServiceRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkInternetServiceRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkInternetServiceRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkInternetServiceRequest(val *UnlinkInternetServiceRequest) *NullableUnlinkInternetServiceRequest { + return &NullableUnlinkInternetServiceRequest{value: val, isSet: true} +} + +func (v NullableUnlinkInternetServiceRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkInternetServiceRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go new file mode 100644 index 000000000..6aaa04487 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkInternetServiceResponse struct for UnlinkInternetServiceResponse +type UnlinkInternetServiceResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkInternetServiceResponse instantiates a new UnlinkInternetServiceResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkInternetServiceResponse() *UnlinkInternetServiceResponse { + this := UnlinkInternetServiceResponse{} + return &this +} + +// NewUnlinkInternetServiceResponseWithDefaults instantiates a new UnlinkInternetServiceResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkInternetServiceResponseWithDefaults() *UnlinkInternetServiceResponse { + this := UnlinkInternetServiceResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkInternetServiceResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkInternetServiceResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkInternetServiceResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkInternetServiceResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkInternetServiceResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkInternetServiceResponse struct { + value *UnlinkInternetServiceResponse + isSet bool +} + +func (v NullableUnlinkInternetServiceResponse) Get() *UnlinkInternetServiceResponse { + return v.value +} + +func (v *NullableUnlinkInternetServiceResponse) Set(val *UnlinkInternetServiceResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkInternetServiceResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkInternetServiceResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkInternetServiceResponse(val *UnlinkInternetServiceResponse) *NullableUnlinkInternetServiceResponse { + return &NullableUnlinkInternetServiceResponse{value: val, isSet: true} +} + +func (v NullableUnlinkInternetServiceResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkInternetServiceResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go new file mode 100644 index 000000000..25cba08b4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkNicRequest struct for UnlinkNicRequest +type UnlinkNicRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the attachment operation. + LinkNicId string `json:"LinkNicId"` +} + +// NewUnlinkNicRequest instantiates a new UnlinkNicRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkNicRequest(linkNicId string, ) *UnlinkNicRequest { + this := UnlinkNicRequest{} + this.LinkNicId = linkNicId + return &this +} + +// NewUnlinkNicRequestWithDefaults instantiates a new UnlinkNicRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkNicRequestWithDefaults() *UnlinkNicRequest { + this := UnlinkNicRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkNicRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkNicRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkNicRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkNicRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLinkNicId returns the LinkNicId field value +func (o *UnlinkNicRequest) GetLinkNicId() string { + if o == nil { + var ret string + return ret + } + + return o.LinkNicId +} + +// GetLinkNicIdOk returns a tuple with the LinkNicId field value +// and a boolean to check if the value has been set. +func (o *UnlinkNicRequest) GetLinkNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LinkNicId, true +} + +// SetLinkNicId sets field value +func (o *UnlinkNicRequest) SetLinkNicId(v string) { + o.LinkNicId = v +} + +func (o UnlinkNicRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LinkNicId"] = o.LinkNicId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkNicRequest struct { + value *UnlinkNicRequest + isSet bool +} + +func (v NullableUnlinkNicRequest) Get() *UnlinkNicRequest { + return v.value +} + +func (v *NullableUnlinkNicRequest) Set(val *UnlinkNicRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkNicRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkNicRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkNicRequest(val *UnlinkNicRequest) *NullableUnlinkNicRequest { + return &NullableUnlinkNicRequest{value: val, isSet: true} +} + +func (v NullableUnlinkNicRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkNicRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go new file mode 100644 index 000000000..125a33c6f --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkNicResponse struct for UnlinkNicResponse +type UnlinkNicResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkNicResponse instantiates a new UnlinkNicResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkNicResponse() *UnlinkNicResponse { + this := UnlinkNicResponse{} + return &this +} + +// NewUnlinkNicResponseWithDefaults instantiates a new UnlinkNicResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkNicResponseWithDefaults() *UnlinkNicResponse { + this := UnlinkNicResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkNicResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkNicResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkNicResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkNicResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkNicResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkNicResponse struct { + value *UnlinkNicResponse + isSet bool +} + +func (v NullableUnlinkNicResponse) Get() *UnlinkNicResponse { + return v.value +} + +func (v *NullableUnlinkNicResponse) Set(val *UnlinkNicResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkNicResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkNicResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkNicResponse(val *UnlinkNicResponse) *NullableUnlinkNicResponse { + return &NullableUnlinkNicResponse{value: val, isSet: true} +} + +func (v NullableUnlinkNicResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkNicResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go new file mode 100644 index 000000000..5a37f794d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkPrivateIpsRequest struct for UnlinkPrivateIpsRequest +type UnlinkPrivateIpsRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the NIC. + NicId string `json:"NicId"` + // One or more secondary private IP addresses you want to unassign from the NIC. + PrivateIps []string `json:"PrivateIps"` +} + +// NewUnlinkPrivateIpsRequest instantiates a new UnlinkPrivateIpsRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkPrivateIpsRequest(nicId string, privateIps []string, ) *UnlinkPrivateIpsRequest { + this := UnlinkPrivateIpsRequest{} + this.NicId = nicId + this.PrivateIps = privateIps + return &this +} + +// NewUnlinkPrivateIpsRequestWithDefaults instantiates a new UnlinkPrivateIpsRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkPrivateIpsRequestWithDefaults() *UnlinkPrivateIpsRequest { + this := UnlinkPrivateIpsRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkPrivateIpsRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPrivateIpsRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkPrivateIpsRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkPrivateIpsRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNicId returns the NicId field value +func (o *UnlinkPrivateIpsRequest) GetNicId() string { + if o == nil { + var ret string + return ret + } + + return o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value +// and a boolean to check if the value has been set. +func (o *UnlinkPrivateIpsRequest) GetNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NicId, true +} + +// SetNicId sets field value +func (o *UnlinkPrivateIpsRequest) SetNicId(v string) { + o.NicId = v +} + +// GetPrivateIps returns the PrivateIps field value +func (o *UnlinkPrivateIpsRequest) GetPrivateIps() []string { + if o == nil { + var ret []string + return ret + } + + return o.PrivateIps +} + +// GetPrivateIpsOk returns a tuple with the PrivateIps field value +// and a boolean to check if the value has been set. +func (o *UnlinkPrivateIpsRequest) GetPrivateIpsOk() (*[]string, bool) { + if o == nil { + return nil, false + } + return &o.PrivateIps, true +} + +// SetPrivateIps sets field value +func (o *UnlinkPrivateIpsRequest) SetPrivateIps(v []string) { + o.PrivateIps = v +} + +func (o UnlinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NicId"] = o.NicId + } + if true { + toSerialize["PrivateIps"] = o.PrivateIps + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkPrivateIpsRequest struct { + value *UnlinkPrivateIpsRequest + isSet bool +} + +func (v NullableUnlinkPrivateIpsRequest) Get() *UnlinkPrivateIpsRequest { + return v.value +} + +func (v *NullableUnlinkPrivateIpsRequest) Set(val *UnlinkPrivateIpsRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkPrivateIpsRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkPrivateIpsRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkPrivateIpsRequest(val *UnlinkPrivateIpsRequest) *NullableUnlinkPrivateIpsRequest { + return &NullableUnlinkPrivateIpsRequest{value: val, isSet: true} +} + +func (v NullableUnlinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkPrivateIpsRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go new file mode 100644 index 000000000..4cb3e3c99 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkPrivateIpsResponse struct for UnlinkPrivateIpsResponse +type UnlinkPrivateIpsResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkPrivateIpsResponse instantiates a new UnlinkPrivateIpsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkPrivateIpsResponse() *UnlinkPrivateIpsResponse { + this := UnlinkPrivateIpsResponse{} + return &this +} + +// NewUnlinkPrivateIpsResponseWithDefaults instantiates a new UnlinkPrivateIpsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkPrivateIpsResponseWithDefaults() *UnlinkPrivateIpsResponse { + this := UnlinkPrivateIpsResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkPrivateIpsResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPrivateIpsResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkPrivateIpsResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkPrivateIpsResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkPrivateIpsResponse struct { + value *UnlinkPrivateIpsResponse + isSet bool +} + +func (v NullableUnlinkPrivateIpsResponse) Get() *UnlinkPrivateIpsResponse { + return v.value +} + +func (v *NullableUnlinkPrivateIpsResponse) Set(val *UnlinkPrivateIpsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkPrivateIpsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkPrivateIpsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkPrivateIpsResponse(val *UnlinkPrivateIpsResponse) *NullableUnlinkPrivateIpsResponse { + return &NullableUnlinkPrivateIpsResponse{value: val, isSet: true} +} + +func (v NullableUnlinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkPrivateIpsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go new file mode 100644 index 000000000..025e8b123 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkPublicIpRequest struct for UnlinkPublicIpRequest +type UnlinkPublicIpRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` + // The External IP address. In the public Cloud, this parameter is required. + PublicIp *string `json:"PublicIp,omitempty"` +} + +// NewUnlinkPublicIpRequest instantiates a new UnlinkPublicIpRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkPublicIpRequest() *UnlinkPublicIpRequest { + this := UnlinkPublicIpRequest{} + return &this +} + +// NewUnlinkPublicIpRequestWithDefaults instantiates a new UnlinkPublicIpRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkPublicIpRequestWithDefaults() *UnlinkPublicIpRequest { + this := UnlinkPublicIpRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkPublicIpRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPublicIpRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkPublicIpRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkPublicIpRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. +func (o *UnlinkPublicIpRequest) GetLinkPublicIpId() string { + if o == nil || o.LinkPublicIpId == nil { + var ret string + return ret + } + return *o.LinkPublicIpId +} + +// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPublicIpRequest) GetLinkPublicIpIdOk() (*string, bool) { + if o == nil || o.LinkPublicIpId == nil { + return nil, false + } + return o.LinkPublicIpId, true +} + +// HasLinkPublicIpId returns a boolean if a field has been set. +func (o *UnlinkPublicIpRequest) HasLinkPublicIpId() bool { + if o != nil && o.LinkPublicIpId != nil { + return true + } + + return false +} + +// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. +func (o *UnlinkPublicIpRequest) SetLinkPublicIpId(v string) { + o.LinkPublicIpId = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *UnlinkPublicIpRequest) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPublicIpRequest) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *UnlinkPublicIpRequest) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *UnlinkPublicIpRequest) SetPublicIp(v string) { + o.PublicIp = &v +} + +func (o UnlinkPublicIpRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.LinkPublicIpId != nil { + toSerialize["LinkPublicIpId"] = o.LinkPublicIpId + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkPublicIpRequest struct { + value *UnlinkPublicIpRequest + isSet bool +} + +func (v NullableUnlinkPublicIpRequest) Get() *UnlinkPublicIpRequest { + return v.value +} + +func (v *NullableUnlinkPublicIpRequest) Set(val *UnlinkPublicIpRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkPublicIpRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkPublicIpRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkPublicIpRequest(val *UnlinkPublicIpRequest) *NullableUnlinkPublicIpRequest { + return &NullableUnlinkPublicIpRequest{value: val, isSet: true} +} + +func (v NullableUnlinkPublicIpRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkPublicIpRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go new file mode 100644 index 000000000..dc895c712 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkPublicIpResponse struct for UnlinkPublicIpResponse +type UnlinkPublicIpResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkPublicIpResponse instantiates a new UnlinkPublicIpResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkPublicIpResponse() *UnlinkPublicIpResponse { + this := UnlinkPublicIpResponse{} + return &this +} + +// NewUnlinkPublicIpResponseWithDefaults instantiates a new UnlinkPublicIpResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkPublicIpResponseWithDefaults() *UnlinkPublicIpResponse { + this := UnlinkPublicIpResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkPublicIpResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkPublicIpResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkPublicIpResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkPublicIpResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkPublicIpResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkPublicIpResponse struct { + value *UnlinkPublicIpResponse + isSet bool +} + +func (v NullableUnlinkPublicIpResponse) Get() *UnlinkPublicIpResponse { + return v.value +} + +func (v *NullableUnlinkPublicIpResponse) Set(val *UnlinkPublicIpResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkPublicIpResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkPublicIpResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkPublicIpResponse(val *UnlinkPublicIpResponse) *NullableUnlinkPublicIpResponse { + return &NullableUnlinkPublicIpResponse{value: val, isSet: true} +} + +func (v NullableUnlinkPublicIpResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkPublicIpResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go new file mode 100644 index 000000000..082fd6349 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go @@ -0,0 +1,147 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkRouteTableRequest struct for UnlinkRouteTableRequest +type UnlinkRouteTableRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the association between the route table and the Subnet. + LinkRouteTableId string `json:"LinkRouteTableId"` +} + +// NewUnlinkRouteTableRequest instantiates a new UnlinkRouteTableRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkRouteTableRequest(linkRouteTableId string, ) *UnlinkRouteTableRequest { + this := UnlinkRouteTableRequest{} + this.LinkRouteTableId = linkRouteTableId + return &this +} + +// NewUnlinkRouteTableRequestWithDefaults instantiates a new UnlinkRouteTableRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkRouteTableRequestWithDefaults() *UnlinkRouteTableRequest { + this := UnlinkRouteTableRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkRouteTableRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkRouteTableRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkRouteTableRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkRouteTableRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLinkRouteTableId returns the LinkRouteTableId field value +func (o *UnlinkRouteTableRequest) GetLinkRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.LinkRouteTableId +} + +// GetLinkRouteTableIdOk returns a tuple with the LinkRouteTableId field value +// and a boolean to check if the value has been set. +func (o *UnlinkRouteTableRequest) GetLinkRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LinkRouteTableId, true +} + +// SetLinkRouteTableId sets field value +func (o *UnlinkRouteTableRequest) SetLinkRouteTableId(v string) { + o.LinkRouteTableId = v +} + +func (o UnlinkRouteTableRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["LinkRouteTableId"] = o.LinkRouteTableId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkRouteTableRequest struct { + value *UnlinkRouteTableRequest + isSet bool +} + +func (v NullableUnlinkRouteTableRequest) Get() *UnlinkRouteTableRequest { + return v.value +} + +func (v *NullableUnlinkRouteTableRequest) Set(val *UnlinkRouteTableRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkRouteTableRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkRouteTableRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkRouteTableRequest(val *UnlinkRouteTableRequest) *NullableUnlinkRouteTableRequest { + return &NullableUnlinkRouteTableRequest{value: val, isSet: true} +} + +func (v NullableUnlinkRouteTableRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkRouteTableRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go new file mode 100644 index 000000000..c9147275e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkRouteTableResponse struct for UnlinkRouteTableResponse +type UnlinkRouteTableResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkRouteTableResponse instantiates a new UnlinkRouteTableResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkRouteTableResponse() *UnlinkRouteTableResponse { + this := UnlinkRouteTableResponse{} + return &this +} + +// NewUnlinkRouteTableResponseWithDefaults instantiates a new UnlinkRouteTableResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkRouteTableResponseWithDefaults() *UnlinkRouteTableResponse { + this := UnlinkRouteTableResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkRouteTableResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkRouteTableResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkRouteTableResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkRouteTableResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkRouteTableResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkRouteTableResponse struct { + value *UnlinkRouteTableResponse + isSet bool +} + +func (v NullableUnlinkRouteTableResponse) Get() *UnlinkRouteTableResponse { + return v.value +} + +func (v *NullableUnlinkRouteTableResponse) Set(val *UnlinkRouteTableResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkRouteTableResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkRouteTableResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkRouteTableResponse(val *UnlinkRouteTableResponse) *NullableUnlinkRouteTableResponse { + return &NullableUnlinkRouteTableResponse{value: val, isSet: true} +} + +func (v NullableUnlinkRouteTableResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkRouteTableResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go new file mode 100644 index 000000000..e3f6ed87a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkVirtualGatewayRequest struct for UnlinkVirtualGatewayRequest +type UnlinkVirtualGatewayRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net from which you want to detach the virtual gateway. + NetId string `json:"NetId"` + // The ID of the virtual gateway. + VirtualGatewayId string `json:"VirtualGatewayId"` +} + +// NewUnlinkVirtualGatewayRequest instantiates a new UnlinkVirtualGatewayRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkVirtualGatewayRequest(netId string, virtualGatewayId string, ) *UnlinkVirtualGatewayRequest { + this := UnlinkVirtualGatewayRequest{} + this.NetId = netId + this.VirtualGatewayId = virtualGatewayId + return &this +} + +// NewUnlinkVirtualGatewayRequestWithDefaults instantiates a new UnlinkVirtualGatewayRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkVirtualGatewayRequestWithDefaults() *UnlinkVirtualGatewayRequest { + this := UnlinkVirtualGatewayRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkVirtualGatewayRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkVirtualGatewayRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkVirtualGatewayRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkVirtualGatewayRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *UnlinkVirtualGatewayRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *UnlinkVirtualGatewayRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *UnlinkVirtualGatewayRequest) SetNetId(v string) { + o.NetId = v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *UnlinkVirtualGatewayRequest) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *UnlinkVirtualGatewayRequest) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *UnlinkVirtualGatewayRequest) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +func (o UnlinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkVirtualGatewayRequest struct { + value *UnlinkVirtualGatewayRequest + isSet bool +} + +func (v NullableUnlinkVirtualGatewayRequest) Get() *UnlinkVirtualGatewayRequest { + return v.value +} + +func (v *NullableUnlinkVirtualGatewayRequest) Set(val *UnlinkVirtualGatewayRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkVirtualGatewayRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkVirtualGatewayRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkVirtualGatewayRequest(val *UnlinkVirtualGatewayRequest) *NullableUnlinkVirtualGatewayRequest { + return &NullableUnlinkVirtualGatewayRequest{value: val, isSet: true} +} + +func (v NullableUnlinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkVirtualGatewayRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go new file mode 100644 index 000000000..dbed4a440 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkVirtualGatewayResponse struct for UnlinkVirtualGatewayResponse +type UnlinkVirtualGatewayResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkVirtualGatewayResponse instantiates a new UnlinkVirtualGatewayResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkVirtualGatewayResponse() *UnlinkVirtualGatewayResponse { + this := UnlinkVirtualGatewayResponse{} + return &this +} + +// NewUnlinkVirtualGatewayResponseWithDefaults instantiates a new UnlinkVirtualGatewayResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkVirtualGatewayResponseWithDefaults() *UnlinkVirtualGatewayResponse { + this := UnlinkVirtualGatewayResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkVirtualGatewayResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkVirtualGatewayResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkVirtualGatewayResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkVirtualGatewayResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkVirtualGatewayResponse struct { + value *UnlinkVirtualGatewayResponse + isSet bool +} + +func (v NullableUnlinkVirtualGatewayResponse) Get() *UnlinkVirtualGatewayResponse { + return v.value +} + +func (v *NullableUnlinkVirtualGatewayResponse) Set(val *UnlinkVirtualGatewayResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkVirtualGatewayResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkVirtualGatewayResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkVirtualGatewayResponse(val *UnlinkVirtualGatewayResponse) *NullableUnlinkVirtualGatewayResponse { + return &NullableUnlinkVirtualGatewayResponse{value: val, isSet: true} +} + +func (v NullableUnlinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkVirtualGatewayResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go new file mode 100644 index 000000000..9a2d3a4ef --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkVolumeRequest struct for UnlinkVolumeRequest +type UnlinkVolumeRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // Forces the detachment of the volume in case of previous failure. Important: This action may damage your data or file systems. + ForceUnlink *bool `json:"ForceUnlink,omitempty"` + // The ID of the volume you want to detach. + VolumeId string `json:"VolumeId"` +} + +// NewUnlinkVolumeRequest instantiates a new UnlinkVolumeRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkVolumeRequest(volumeId string, ) *UnlinkVolumeRequest { + this := UnlinkVolumeRequest{} + this.VolumeId = volumeId + return &this +} + +// NewUnlinkVolumeRequestWithDefaults instantiates a new UnlinkVolumeRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkVolumeRequestWithDefaults() *UnlinkVolumeRequest { + this := UnlinkVolumeRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UnlinkVolumeRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkVolumeRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UnlinkVolumeRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UnlinkVolumeRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetForceUnlink returns the ForceUnlink field value if set, zero value otherwise. +func (o *UnlinkVolumeRequest) GetForceUnlink() bool { + if o == nil || o.ForceUnlink == nil { + var ret bool + return ret + } + return *o.ForceUnlink +} + +// GetForceUnlinkOk returns a tuple with the ForceUnlink field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkVolumeRequest) GetForceUnlinkOk() (*bool, bool) { + if o == nil || o.ForceUnlink == nil { + return nil, false + } + return o.ForceUnlink, true +} + +// HasForceUnlink returns a boolean if a field has been set. +func (o *UnlinkVolumeRequest) HasForceUnlink() bool { + if o != nil && o.ForceUnlink != nil { + return true + } + + return false +} + +// SetForceUnlink gets a reference to the given bool and assigns it to the ForceUnlink field. +func (o *UnlinkVolumeRequest) SetForceUnlink(v bool) { + o.ForceUnlink = &v +} + +// GetVolumeId returns the VolumeId field value +func (o *UnlinkVolumeRequest) GetVolumeId() string { + if o == nil { + var ret string + return ret + } + + return o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value +// and a boolean to check if the value has been set. +func (o *UnlinkVolumeRequest) GetVolumeIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VolumeId, true +} + +// SetVolumeId sets field value +func (o *UnlinkVolumeRequest) SetVolumeId(v string) { + o.VolumeId = v +} + +func (o UnlinkVolumeRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.ForceUnlink != nil { + toSerialize["ForceUnlink"] = o.ForceUnlink + } + if true { + toSerialize["VolumeId"] = o.VolumeId + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkVolumeRequest struct { + value *UnlinkVolumeRequest + isSet bool +} + +func (v NullableUnlinkVolumeRequest) Get() *UnlinkVolumeRequest { + return v.value +} + +func (v *NullableUnlinkVolumeRequest) Set(val *UnlinkVolumeRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkVolumeRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkVolumeRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkVolumeRequest(val *UnlinkVolumeRequest) *NullableUnlinkVolumeRequest { + return &NullableUnlinkVolumeRequest{value: val, isSet: true} +} + +func (v NullableUnlinkVolumeRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkVolumeRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go new file mode 100644 index 000000000..b8783e8ea --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go @@ -0,0 +1,116 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UnlinkVolumeResponse struct for UnlinkVolumeResponse +type UnlinkVolumeResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUnlinkVolumeResponse instantiates a new UnlinkVolumeResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnlinkVolumeResponse() *UnlinkVolumeResponse { + this := UnlinkVolumeResponse{} + return &this +} + +// NewUnlinkVolumeResponseWithDefaults instantiates a new UnlinkVolumeResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnlinkVolumeResponseWithDefaults() *UnlinkVolumeResponse { + this := UnlinkVolumeResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UnlinkVolumeResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnlinkVolumeResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UnlinkVolumeResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UnlinkVolumeResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UnlinkVolumeResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUnlinkVolumeResponse struct { + value *UnlinkVolumeResponse + isSet bool +} + +func (v NullableUnlinkVolumeResponse) Get() *UnlinkVolumeResponse { + return v.value +} + +func (v *NullableUnlinkVolumeResponse) Set(val *UnlinkVolumeResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUnlinkVolumeResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUnlinkVolumeResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnlinkVolumeResponse(val *UnlinkVolumeResponse) *NullableUnlinkVolumeResponse { + return &NullableUnlinkVolumeResponse{value: val, isSet: true} +} + +func (v NullableUnlinkVolumeResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUnlinkVolumeResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go new file mode 100644 index 000000000..a9da2fca4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateAccessKeyRequest struct for UpdateAccessKeyRequest +type UpdateAccessKeyRequest struct { + // The ID of the access key. + AccessKeyId string `json:"AccessKeyId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The new state for the access key (`ACTIVE` \\| `INACTIVE`). + State string `json:"State"` +} + +// NewUpdateAccessKeyRequest instantiates a new UpdateAccessKeyRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateAccessKeyRequest(accessKeyId string, state string, ) *UpdateAccessKeyRequest { + this := UpdateAccessKeyRequest{} + this.AccessKeyId = accessKeyId + this.State = state + return &this +} + +// NewUpdateAccessKeyRequestWithDefaults instantiates a new UpdateAccessKeyRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateAccessKeyRequestWithDefaults() *UpdateAccessKeyRequest { + this := UpdateAccessKeyRequest{} + return &this +} + +// GetAccessKeyId returns the AccessKeyId field value +func (o *UpdateAccessKeyRequest) GetAccessKeyId() string { + if o == nil { + var ret string + return ret + } + + return o.AccessKeyId +} + +// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value +// and a boolean to check if the value has been set. +func (o *UpdateAccessKeyRequest) GetAccessKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.AccessKeyId, true +} + +// SetAccessKeyId sets field value +func (o *UpdateAccessKeyRequest) SetAccessKeyId(v string) { + o.AccessKeyId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateAccessKeyRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccessKeyRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateAccessKeyRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateAccessKeyRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetState returns the State field value +func (o *UpdateAccessKeyRequest) GetState() string { + if o == nil { + var ret string + return ret + } + + return o.State +} + +// GetStateOk returns a tuple with the State field value +// and a boolean to check if the value has been set. +func (o *UpdateAccessKeyRequest) GetStateOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.State, true +} + +// SetState sets field value +func (o *UpdateAccessKeyRequest) SetState(v string) { + o.State = v +} + +func (o UpdateAccessKeyRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["AccessKeyId"] = o.AccessKeyId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["State"] = o.State + } + return json.Marshal(toSerialize) +} + +type NullableUpdateAccessKeyRequest struct { + value *UpdateAccessKeyRequest + isSet bool +} + +func (v NullableUpdateAccessKeyRequest) Get() *UpdateAccessKeyRequest { + return v.value +} + +func (v *NullableUpdateAccessKeyRequest) Set(val *UpdateAccessKeyRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateAccessKeyRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateAccessKeyRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateAccessKeyRequest(val *UpdateAccessKeyRequest) *NullableUpdateAccessKeyRequest { + return &NullableUpdateAccessKeyRequest{value: val, isSet: true} +} + +func (v NullableUpdateAccessKeyRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateAccessKeyRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go new file mode 100644 index 000000000..7d4fd1896 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateAccessKeyResponse struct for UpdateAccessKeyResponse +type UpdateAccessKeyResponse struct { + AccessKey *AccessKey `json:"AccessKey,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateAccessKeyResponse instantiates a new UpdateAccessKeyResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateAccessKeyResponse() *UpdateAccessKeyResponse { + this := UpdateAccessKeyResponse{} + return &this +} + +// NewUpdateAccessKeyResponseWithDefaults instantiates a new UpdateAccessKeyResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateAccessKeyResponseWithDefaults() *UpdateAccessKeyResponse { + this := UpdateAccessKeyResponse{} + return &this +} + +// GetAccessKey returns the AccessKey field value if set, zero value otherwise. +func (o *UpdateAccessKeyResponse) GetAccessKey() AccessKey { + if o == nil || o.AccessKey == nil { + var ret AccessKey + return ret + } + return *o.AccessKey +} + +// GetAccessKeyOk returns a tuple with the AccessKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccessKeyResponse) GetAccessKeyOk() (*AccessKey, bool) { + if o == nil || o.AccessKey == nil { + return nil, false + } + return o.AccessKey, true +} + +// HasAccessKey returns a boolean if a field has been set. +func (o *UpdateAccessKeyResponse) HasAccessKey() bool { + if o != nil && o.AccessKey != nil { + return true + } + + return false +} + +// SetAccessKey gets a reference to the given AccessKey and assigns it to the AccessKey field. +func (o *UpdateAccessKeyResponse) SetAccessKey(v AccessKey) { + o.AccessKey = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateAccessKeyResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccessKeyResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateAccessKeyResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateAccessKeyResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateAccessKeyResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessKey != nil { + toSerialize["AccessKey"] = o.AccessKey + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateAccessKeyResponse struct { + value *UpdateAccessKeyResponse + isSet bool +} + +func (v NullableUpdateAccessKeyResponse) Get() *UpdateAccessKeyResponse { + return v.value +} + +func (v *NullableUpdateAccessKeyResponse) Set(val *UpdateAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateAccessKeyResponse(val *UpdateAccessKeyResponse) *NullableUpdateAccessKeyResponse { + return &NullableUpdateAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableUpdateAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go new file mode 100644 index 000000000..05e059e11 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go @@ -0,0 +1,561 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateAccountRequest struct for UpdateAccountRequest +type UpdateAccountRequest struct { + // The new city of the account owner. + City *string `json:"City,omitempty"` + // The new name of the company for the account. + CompanyName *string `json:"CompanyName,omitempty"` + // The new country of the account owner. + Country *string `json:"Country,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The new email address for the account. + Email *string `json:"Email,omitempty"` + // The new first name of the account owner. + FirstName *string `json:"FirstName,omitempty"` + // The new job title of the account owner. + JobTitle *string `json:"JobTitle,omitempty"` + // The new last name of the account owner. + LastName *string `json:"LastName,omitempty"` + // The new mobile phone number of the account owner. + MobileNumber *string `json:"MobileNumber,omitempty"` + // The new landline phone number of the account owner. + PhoneNumber *string `json:"PhoneNumber,omitempty"` + // The new state/province of the account owner. + StateProvince *string `json:"StateProvince,omitempty"` + // The new value added tax (VAT) number for the account. + VatNumber *string `json:"VatNumber,omitempty"` + // The new ZIP code of the city. + ZipCode *string `json:"ZipCode,omitempty"` +} + +// NewUpdateAccountRequest instantiates a new UpdateAccountRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateAccountRequest() *UpdateAccountRequest { + this := UpdateAccountRequest{} + return &this +} + +// NewUpdateAccountRequestWithDefaults instantiates a new UpdateAccountRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateAccountRequestWithDefaults() *UpdateAccountRequest { + this := UpdateAccountRequest{} + return &this +} + +// GetCity returns the City field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetCity() string { + if o == nil || o.City == nil { + var ret string + return ret + } + return *o.City +} + +// GetCityOk returns a tuple with the City field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetCityOk() (*string, bool) { + if o == nil || o.City == nil { + return nil, false + } + return o.City, true +} + +// HasCity returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasCity() bool { + if o != nil && o.City != nil { + return true + } + + return false +} + +// SetCity gets a reference to the given string and assigns it to the City field. +func (o *UpdateAccountRequest) SetCity(v string) { + o.City = &v +} + +// GetCompanyName returns the CompanyName field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetCompanyName() string { + if o == nil || o.CompanyName == nil { + var ret string + return ret + } + return *o.CompanyName +} + +// GetCompanyNameOk returns a tuple with the CompanyName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetCompanyNameOk() (*string, bool) { + if o == nil || o.CompanyName == nil { + return nil, false + } + return o.CompanyName, true +} + +// HasCompanyName returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasCompanyName() bool { + if o != nil && o.CompanyName != nil { + return true + } + + return false +} + +// SetCompanyName gets a reference to the given string and assigns it to the CompanyName field. +func (o *UpdateAccountRequest) SetCompanyName(v string) { + o.CompanyName = &v +} + +// GetCountry returns the Country field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetCountry() string { + if o == nil || o.Country == nil { + var ret string + return ret + } + return *o.Country +} + +// GetCountryOk returns a tuple with the Country field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetCountryOk() (*string, bool) { + if o == nil || o.Country == nil { + return nil, false + } + return o.Country, true +} + +// HasCountry returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasCountry() bool { + if o != nil && o.Country != nil { + return true + } + + return false +} + +// SetCountry gets a reference to the given string and assigns it to the Country field. +func (o *UpdateAccountRequest) SetCountry(v string) { + o.Country = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateAccountRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetEmail returns the Email field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetEmail() string { + if o == nil || o.Email == nil { + var ret string + return ret + } + return *o.Email +} + +// GetEmailOk returns a tuple with the Email field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetEmailOk() (*string, bool) { + if o == nil || o.Email == nil { + return nil, false + } + return o.Email, true +} + +// HasEmail returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasEmail() bool { + if o != nil && o.Email != nil { + return true + } + + return false +} + +// SetEmail gets a reference to the given string and assigns it to the Email field. +func (o *UpdateAccountRequest) SetEmail(v string) { + o.Email = &v +} + +// GetFirstName returns the FirstName field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetFirstName() string { + if o == nil || o.FirstName == nil { + var ret string + return ret + } + return *o.FirstName +} + +// GetFirstNameOk returns a tuple with the FirstName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetFirstNameOk() (*string, bool) { + if o == nil || o.FirstName == nil { + return nil, false + } + return o.FirstName, true +} + +// HasFirstName returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasFirstName() bool { + if o != nil && o.FirstName != nil { + return true + } + + return false +} + +// SetFirstName gets a reference to the given string and assigns it to the FirstName field. +func (o *UpdateAccountRequest) SetFirstName(v string) { + o.FirstName = &v +} + +// GetJobTitle returns the JobTitle field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetJobTitle() string { + if o == nil || o.JobTitle == nil { + var ret string + return ret + } + return *o.JobTitle +} + +// GetJobTitleOk returns a tuple with the JobTitle field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetJobTitleOk() (*string, bool) { + if o == nil || o.JobTitle == nil { + return nil, false + } + return o.JobTitle, true +} + +// HasJobTitle returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasJobTitle() bool { + if o != nil && o.JobTitle != nil { + return true + } + + return false +} + +// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. +func (o *UpdateAccountRequest) SetJobTitle(v string) { + o.JobTitle = &v +} + +// GetLastName returns the LastName field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetLastName() string { + if o == nil || o.LastName == nil { + var ret string + return ret + } + return *o.LastName +} + +// GetLastNameOk returns a tuple with the LastName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetLastNameOk() (*string, bool) { + if o == nil || o.LastName == nil { + return nil, false + } + return o.LastName, true +} + +// HasLastName returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasLastName() bool { + if o != nil && o.LastName != nil { + return true + } + + return false +} + +// SetLastName gets a reference to the given string and assigns it to the LastName field. +func (o *UpdateAccountRequest) SetLastName(v string) { + o.LastName = &v +} + +// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetMobileNumber() string { + if o == nil || o.MobileNumber == nil { + var ret string + return ret + } + return *o.MobileNumber +} + +// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetMobileNumberOk() (*string, bool) { + if o == nil || o.MobileNumber == nil { + return nil, false + } + return o.MobileNumber, true +} + +// HasMobileNumber returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasMobileNumber() bool { + if o != nil && o.MobileNumber != nil { + return true + } + + return false +} + +// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. +func (o *UpdateAccountRequest) SetMobileNumber(v string) { + o.MobileNumber = &v +} + +// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetPhoneNumber() string { + if o == nil || o.PhoneNumber == nil { + var ret string + return ret + } + return *o.PhoneNumber +} + +// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetPhoneNumberOk() (*string, bool) { + if o == nil || o.PhoneNumber == nil { + return nil, false + } + return o.PhoneNumber, true +} + +// HasPhoneNumber returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasPhoneNumber() bool { + if o != nil && o.PhoneNumber != nil { + return true + } + + return false +} + +// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. +func (o *UpdateAccountRequest) SetPhoneNumber(v string) { + o.PhoneNumber = &v +} + +// GetStateProvince returns the StateProvince field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetStateProvince() string { + if o == nil || o.StateProvince == nil { + var ret string + return ret + } + return *o.StateProvince +} + +// GetStateProvinceOk returns a tuple with the StateProvince field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetStateProvinceOk() (*string, bool) { + if o == nil || o.StateProvince == nil { + return nil, false + } + return o.StateProvince, true +} + +// HasStateProvince returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasStateProvince() bool { + if o != nil && o.StateProvince != nil { + return true + } + + return false +} + +// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. +func (o *UpdateAccountRequest) SetStateProvince(v string) { + o.StateProvince = &v +} + +// GetVatNumber returns the VatNumber field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetVatNumber() string { + if o == nil || o.VatNumber == nil { + var ret string + return ret + } + return *o.VatNumber +} + +// GetVatNumberOk returns a tuple with the VatNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetVatNumberOk() (*string, bool) { + if o == nil || o.VatNumber == nil { + return nil, false + } + return o.VatNumber, true +} + +// HasVatNumber returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasVatNumber() bool { + if o != nil && o.VatNumber != nil { + return true + } + + return false +} + +// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. +func (o *UpdateAccountRequest) SetVatNumber(v string) { + o.VatNumber = &v +} + +// GetZipCode returns the ZipCode field value if set, zero value otherwise. +func (o *UpdateAccountRequest) GetZipCode() string { + if o == nil || o.ZipCode == nil { + var ret string + return ret + } + return *o.ZipCode +} + +// GetZipCodeOk returns a tuple with the ZipCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountRequest) GetZipCodeOk() (*string, bool) { + if o == nil || o.ZipCode == nil { + return nil, false + } + return o.ZipCode, true +} + +// HasZipCode returns a boolean if a field has been set. +func (o *UpdateAccountRequest) HasZipCode() bool { + if o != nil && o.ZipCode != nil { + return true + } + + return false +} + +// SetZipCode gets a reference to the given string and assigns it to the ZipCode field. +func (o *UpdateAccountRequest) SetZipCode(v string) { + o.ZipCode = &v +} + +func (o UpdateAccountRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.City != nil { + toSerialize["City"] = o.City + } + if o.CompanyName != nil { + toSerialize["CompanyName"] = o.CompanyName + } + if o.Country != nil { + toSerialize["Country"] = o.Country + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Email != nil { + toSerialize["Email"] = o.Email + } + if o.FirstName != nil { + toSerialize["FirstName"] = o.FirstName + } + if o.JobTitle != nil { + toSerialize["JobTitle"] = o.JobTitle + } + if o.LastName != nil { + toSerialize["LastName"] = o.LastName + } + if o.MobileNumber != nil { + toSerialize["MobileNumber"] = o.MobileNumber + } + if o.PhoneNumber != nil { + toSerialize["PhoneNumber"] = o.PhoneNumber + } + if o.StateProvince != nil { + toSerialize["StateProvince"] = o.StateProvince + } + if o.VatNumber != nil { + toSerialize["VatNumber"] = o.VatNumber + } + if o.ZipCode != nil { + toSerialize["ZipCode"] = o.ZipCode + } + return json.Marshal(toSerialize) +} + +type NullableUpdateAccountRequest struct { + value *UpdateAccountRequest + isSet bool +} + +func (v NullableUpdateAccountRequest) Get() *UpdateAccountRequest { + return v.value +} + +func (v *NullableUpdateAccountRequest) Set(val *UpdateAccountRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateAccountRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateAccountRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateAccountRequest(val *UpdateAccountRequest) *NullableUpdateAccountRequest { + return &NullableUpdateAccountRequest{value: val, isSet: true} +} + +func (v NullableUpdateAccountRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateAccountRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go new file mode 100644 index 000000000..212ce1b7e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateAccountResponse struct for UpdateAccountResponse +type UpdateAccountResponse struct { + Account *Account `json:"Account,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateAccountResponse instantiates a new UpdateAccountResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateAccountResponse() *UpdateAccountResponse { + this := UpdateAccountResponse{} + return &this +} + +// NewUpdateAccountResponseWithDefaults instantiates a new UpdateAccountResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateAccountResponseWithDefaults() *UpdateAccountResponse { + this := UpdateAccountResponse{} + return &this +} + +// GetAccount returns the Account field value if set, zero value otherwise. +func (o *UpdateAccountResponse) GetAccount() Account { + if o == nil || o.Account == nil { + var ret Account + return ret + } + return *o.Account +} + +// GetAccountOk returns a tuple with the Account field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountResponse) GetAccountOk() (*Account, bool) { + if o == nil || o.Account == nil { + return nil, false + } + return o.Account, true +} + +// HasAccount returns a boolean if a field has been set. +func (o *UpdateAccountResponse) HasAccount() bool { + if o != nil && o.Account != nil { + return true + } + + return false +} + +// SetAccount gets a reference to the given Account and assigns it to the Account field. +func (o *UpdateAccountResponse) SetAccount(v Account) { + o.Account = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateAccountResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateAccountResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateAccountResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateAccountResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateAccountResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Account != nil { + toSerialize["Account"] = o.Account + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateAccountResponse struct { + value *UpdateAccountResponse + isSet bool +} + +func (v NullableUpdateAccountResponse) Get() *UpdateAccountResponse { + return v.value +} + +func (v *NullableUpdateAccountResponse) Set(val *UpdateAccountResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateAccountResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateAccountResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateAccountResponse(val *UpdateAccountResponse) *NullableUpdateAccountResponse { + return &NullableUpdateAccountResponse{value: val, isSet: true} +} + +func (v NullableUpdateAccountResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateAccountResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go new file mode 100644 index 000000000..0a188c405 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go @@ -0,0 +1,184 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateFlexibleGpuRequest struct for UpdateFlexibleGpuRequest +type UpdateFlexibleGpuRequest struct { + // If `true`, the fGPU is deleted when the VM is terminated. + DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the fGPU you want to modify. + FlexibleGpuId string `json:"FlexibleGpuId"` +} + +// NewUpdateFlexibleGpuRequest instantiates a new UpdateFlexibleGpuRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateFlexibleGpuRequest(flexibleGpuId string, ) *UpdateFlexibleGpuRequest { + this := UpdateFlexibleGpuRequest{} + this.FlexibleGpuId = flexibleGpuId + return &this +} + +// NewUpdateFlexibleGpuRequestWithDefaults instantiates a new UpdateFlexibleGpuRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateFlexibleGpuRequestWithDefaults() *UpdateFlexibleGpuRequest { + this := UpdateFlexibleGpuRequest{} + return &this +} + +// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. +func (o *UpdateFlexibleGpuRequest) GetDeleteOnVmDeletion() bool { + if o == nil || o.DeleteOnVmDeletion == nil { + var ret bool + return ret + } + return *o.DeleteOnVmDeletion +} + +// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateFlexibleGpuRequest) GetDeleteOnVmDeletionOk() (*bool, bool) { + if o == nil || o.DeleteOnVmDeletion == nil { + return nil, false + } + return o.DeleteOnVmDeletion, true +} + +// HasDeleteOnVmDeletion returns a boolean if a field has been set. +func (o *UpdateFlexibleGpuRequest) HasDeleteOnVmDeletion() bool { + if o != nil && o.DeleteOnVmDeletion != nil { + return true + } + + return false +} + +// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. +func (o *UpdateFlexibleGpuRequest) SetDeleteOnVmDeletion(v bool) { + o.DeleteOnVmDeletion = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateFlexibleGpuRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateFlexibleGpuRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateFlexibleGpuRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateFlexibleGpuRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetFlexibleGpuId returns the FlexibleGpuId field value +func (o *UpdateFlexibleGpuRequest) GetFlexibleGpuId() string { + if o == nil { + var ret string + return ret + } + + return o.FlexibleGpuId +} + +// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value +// and a boolean to check if the value has been set. +func (o *UpdateFlexibleGpuRequest) GetFlexibleGpuIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.FlexibleGpuId, true +} + +// SetFlexibleGpuId sets field value +func (o *UpdateFlexibleGpuRequest) SetFlexibleGpuId(v string) { + o.FlexibleGpuId = v +} + +func (o UpdateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DeleteOnVmDeletion != nil { + toSerialize["DeleteOnVmDeletion"] = o.DeleteOnVmDeletion + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["FlexibleGpuId"] = o.FlexibleGpuId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateFlexibleGpuRequest struct { + value *UpdateFlexibleGpuRequest + isSet bool +} + +func (v NullableUpdateFlexibleGpuRequest) Get() *UpdateFlexibleGpuRequest { + return v.value +} + +func (v *NullableUpdateFlexibleGpuRequest) Set(val *UpdateFlexibleGpuRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateFlexibleGpuRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateFlexibleGpuRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateFlexibleGpuRequest(val *UpdateFlexibleGpuRequest) *NullableUpdateFlexibleGpuRequest { + return &NullableUpdateFlexibleGpuRequest{value: val, isSet: true} +} + +func (v NullableUpdateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateFlexibleGpuRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go new file mode 100644 index 000000000..581a00755 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateFlexibleGpuResponse struct for UpdateFlexibleGpuResponse +type UpdateFlexibleGpuResponse struct { + FlexibleGpu *FlexibleGpu `json:"FlexibleGpu,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateFlexibleGpuResponse instantiates a new UpdateFlexibleGpuResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateFlexibleGpuResponse() *UpdateFlexibleGpuResponse { + this := UpdateFlexibleGpuResponse{} + return &this +} + +// NewUpdateFlexibleGpuResponseWithDefaults instantiates a new UpdateFlexibleGpuResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateFlexibleGpuResponseWithDefaults() *UpdateFlexibleGpuResponse { + this := UpdateFlexibleGpuResponse{} + return &this +} + +// GetFlexibleGpu returns the FlexibleGpu field value if set, zero value otherwise. +func (o *UpdateFlexibleGpuResponse) GetFlexibleGpu() FlexibleGpu { + if o == nil || o.FlexibleGpu == nil { + var ret FlexibleGpu + return ret + } + return *o.FlexibleGpu +} + +// GetFlexibleGpuOk returns a tuple with the FlexibleGpu field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateFlexibleGpuResponse) GetFlexibleGpuOk() (*FlexibleGpu, bool) { + if o == nil || o.FlexibleGpu == nil { + return nil, false + } + return o.FlexibleGpu, true +} + +// HasFlexibleGpu returns a boolean if a field has been set. +func (o *UpdateFlexibleGpuResponse) HasFlexibleGpu() bool { + if o != nil && o.FlexibleGpu != nil { + return true + } + + return false +} + +// SetFlexibleGpu gets a reference to the given FlexibleGpu and assigns it to the FlexibleGpu field. +func (o *UpdateFlexibleGpuResponse) SetFlexibleGpu(v FlexibleGpu) { + o.FlexibleGpu = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateFlexibleGpuResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateFlexibleGpuResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateFlexibleGpuResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateFlexibleGpuResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.FlexibleGpu != nil { + toSerialize["FlexibleGpu"] = o.FlexibleGpu + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateFlexibleGpuResponse struct { + value *UpdateFlexibleGpuResponse + isSet bool +} + +func (v NullableUpdateFlexibleGpuResponse) Get() *UpdateFlexibleGpuResponse { + return v.value +} + +func (v *NullableUpdateFlexibleGpuResponse) Set(val *UpdateFlexibleGpuResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateFlexibleGpuResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateFlexibleGpuResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateFlexibleGpuResponse(val *UpdateFlexibleGpuResponse) *NullableUpdateFlexibleGpuResponse { + return &NullableUpdateFlexibleGpuResponse{value: val, isSet: true} +} + +func (v NullableUpdateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateFlexibleGpuResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go new file mode 100644 index 000000000..f04ffd202 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go @@ -0,0 +1,176 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateImageRequest struct for UpdateImageRequest +type UpdateImageRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the OMI you want to modify. + ImageId string `json:"ImageId"` + PermissionsToLaunch PermissionsOnResourceCreation `json:"PermissionsToLaunch"` +} + +// NewUpdateImageRequest instantiates a new UpdateImageRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateImageRequest(imageId string, permissionsToLaunch PermissionsOnResourceCreation, ) *UpdateImageRequest { + this := UpdateImageRequest{} + this.ImageId = imageId + this.PermissionsToLaunch = permissionsToLaunch + return &this +} + +// NewUpdateImageRequestWithDefaults instantiates a new UpdateImageRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateImageRequestWithDefaults() *UpdateImageRequest { + this := UpdateImageRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateImageRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateImageRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateImageRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateImageRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetImageId returns the ImageId field value +func (o *UpdateImageRequest) GetImageId() string { + if o == nil { + var ret string + return ret + } + + return o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value +// and a boolean to check if the value has been set. +func (o *UpdateImageRequest) GetImageIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ImageId, true +} + +// SetImageId sets field value +func (o *UpdateImageRequest) SetImageId(v string) { + o.ImageId = v +} + +// GetPermissionsToLaunch returns the PermissionsToLaunch field value +func (o *UpdateImageRequest) GetPermissionsToLaunch() PermissionsOnResourceCreation { + if o == nil { + var ret PermissionsOnResourceCreation + return ret + } + + return o.PermissionsToLaunch +} + +// GetPermissionsToLaunchOk returns a tuple with the PermissionsToLaunch field value +// and a boolean to check if the value has been set. +func (o *UpdateImageRequest) GetPermissionsToLaunchOk() (*PermissionsOnResourceCreation, bool) { + if o == nil { + return nil, false + } + return &o.PermissionsToLaunch, true +} + +// SetPermissionsToLaunch sets field value +func (o *UpdateImageRequest) SetPermissionsToLaunch(v PermissionsOnResourceCreation) { + o.PermissionsToLaunch = v +} + +func (o UpdateImageRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["ImageId"] = o.ImageId + } + if true { + toSerialize["PermissionsToLaunch"] = o.PermissionsToLaunch + } + return json.Marshal(toSerialize) +} + +type NullableUpdateImageRequest struct { + value *UpdateImageRequest + isSet bool +} + +func (v NullableUpdateImageRequest) Get() *UpdateImageRequest { + return v.value +} + +func (v *NullableUpdateImageRequest) Set(val *UpdateImageRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateImageRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateImageRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateImageRequest(val *UpdateImageRequest) *NullableUpdateImageRequest { + return &NullableUpdateImageRequest{value: val, isSet: true} +} + +func (v NullableUpdateImageRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateImageRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go new file mode 100644 index 000000000..c011f5c70 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateImageResponse struct for UpdateImageResponse +type UpdateImageResponse struct { + Image *Image `json:"Image,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateImageResponse instantiates a new UpdateImageResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateImageResponse() *UpdateImageResponse { + this := UpdateImageResponse{} + return &this +} + +// NewUpdateImageResponseWithDefaults instantiates a new UpdateImageResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateImageResponseWithDefaults() *UpdateImageResponse { + this := UpdateImageResponse{} + return &this +} + +// GetImage returns the Image field value if set, zero value otherwise. +func (o *UpdateImageResponse) GetImage() Image { + if o == nil || o.Image == nil { + var ret Image + return ret + } + return *o.Image +} + +// GetImageOk returns a tuple with the Image field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateImageResponse) GetImageOk() (*Image, bool) { + if o == nil || o.Image == nil { + return nil, false + } + return o.Image, true +} + +// HasImage returns a boolean if a field has been set. +func (o *UpdateImageResponse) HasImage() bool { + if o != nil && o.Image != nil { + return true + } + + return false +} + +// SetImage gets a reference to the given Image and assigns it to the Image field. +func (o *UpdateImageResponse) SetImage(v Image) { + o.Image = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateImageResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateImageResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateImageResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateImageResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateImageResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Image != nil { + toSerialize["Image"] = o.Image + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateImageResponse struct { + value *UpdateImageResponse + isSet bool +} + +func (v NullableUpdateImageResponse) Get() *UpdateImageResponse { + return v.value +} + +func (v *NullableUpdateImageResponse) Set(val *UpdateImageResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateImageResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateImageResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateImageResponse(val *UpdateImageResponse) *NullableUpdateImageResponse { + return &NullableUpdateImageResponse{value: val, isSet: true} +} + +func (v NullableUpdateImageResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateImageResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go new file mode 100644 index 000000000..7cfd488e4 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go @@ -0,0 +1,221 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateListenerRuleRequest struct for UpdateListenerRuleRequest +type UpdateListenerRuleRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + HostPattern *string `json:"HostPattern,omitempty"` + // The name of the listener rule. + ListenerRuleName string `json:"ListenerRuleName"` + // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. + PathPattern *string `json:"PathPattern,omitempty"` +} + +// NewUpdateListenerRuleRequest instantiates a new UpdateListenerRuleRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateListenerRuleRequest(listenerRuleName string, ) *UpdateListenerRuleRequest { + this := UpdateListenerRuleRequest{} + this.ListenerRuleName = listenerRuleName + return &this +} + +// NewUpdateListenerRuleRequestWithDefaults instantiates a new UpdateListenerRuleRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateListenerRuleRequestWithDefaults() *UpdateListenerRuleRequest { + this := UpdateListenerRuleRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateListenerRuleRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateListenerRuleRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateListenerRuleRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetHostPattern returns the HostPattern field value if set, zero value otherwise. +func (o *UpdateListenerRuleRequest) GetHostPattern() string { + if o == nil || o.HostPattern == nil { + var ret string + return ret + } + return *o.HostPattern +} + +// GetHostPatternOk returns a tuple with the HostPattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleRequest) GetHostPatternOk() (*string, bool) { + if o == nil || o.HostPattern == nil { + return nil, false + } + return o.HostPattern, true +} + +// HasHostPattern returns a boolean if a field has been set. +func (o *UpdateListenerRuleRequest) HasHostPattern() bool { + if o != nil && o.HostPattern != nil { + return true + } + + return false +} + +// SetHostPattern gets a reference to the given string and assigns it to the HostPattern field. +func (o *UpdateListenerRuleRequest) SetHostPattern(v string) { + o.HostPattern = &v +} + +// GetListenerRuleName returns the ListenerRuleName field value +func (o *UpdateListenerRuleRequest) GetListenerRuleName() string { + if o == nil { + var ret string + return ret + } + + return o.ListenerRuleName +} + +// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleRequest) GetListenerRuleNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ListenerRuleName, true +} + +// SetListenerRuleName sets field value +func (o *UpdateListenerRuleRequest) SetListenerRuleName(v string) { + o.ListenerRuleName = v +} + +// GetPathPattern returns the PathPattern field value if set, zero value otherwise. +func (o *UpdateListenerRuleRequest) GetPathPattern() string { + if o == nil || o.PathPattern == nil { + var ret string + return ret + } + return *o.PathPattern +} + +// GetPathPatternOk returns a tuple with the PathPattern field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleRequest) GetPathPatternOk() (*string, bool) { + if o == nil || o.PathPattern == nil { + return nil, false + } + return o.PathPattern, true +} + +// HasPathPattern returns a boolean if a field has been set. +func (o *UpdateListenerRuleRequest) HasPathPattern() bool { + if o != nil && o.PathPattern != nil { + return true + } + + return false +} + +// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. +func (o *UpdateListenerRuleRequest) SetPathPattern(v string) { + o.PathPattern = &v +} + +func (o UpdateListenerRuleRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.HostPattern != nil { + toSerialize["HostPattern"] = o.HostPattern + } + if true { + toSerialize["ListenerRuleName"] = o.ListenerRuleName + } + if o.PathPattern != nil { + toSerialize["PathPattern"] = o.PathPattern + } + return json.Marshal(toSerialize) +} + +type NullableUpdateListenerRuleRequest struct { + value *UpdateListenerRuleRequest + isSet bool +} + +func (v NullableUpdateListenerRuleRequest) Get() *UpdateListenerRuleRequest { + return v.value +} + +func (v *NullableUpdateListenerRuleRequest) Set(val *UpdateListenerRuleRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateListenerRuleRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateListenerRuleRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateListenerRuleRequest(val *UpdateListenerRuleRequest) *NullableUpdateListenerRuleRequest { + return &NullableUpdateListenerRuleRequest{value: val, isSet: true} +} + +func (v NullableUpdateListenerRuleRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateListenerRuleRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go new file mode 100644 index 000000000..53fe80c20 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateListenerRuleResponse struct for UpdateListenerRuleResponse +type UpdateListenerRuleResponse struct { + ListenerRule *ListenerRule `json:"ListenerRule,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateListenerRuleResponse instantiates a new UpdateListenerRuleResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateListenerRuleResponse() *UpdateListenerRuleResponse { + this := UpdateListenerRuleResponse{} + return &this +} + +// NewUpdateListenerRuleResponseWithDefaults instantiates a new UpdateListenerRuleResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateListenerRuleResponseWithDefaults() *UpdateListenerRuleResponse { + this := UpdateListenerRuleResponse{} + return &this +} + +// GetListenerRule returns the ListenerRule field value if set, zero value otherwise. +func (o *UpdateListenerRuleResponse) GetListenerRule() ListenerRule { + if o == nil || o.ListenerRule == nil { + var ret ListenerRule + return ret + } + return *o.ListenerRule +} + +// GetListenerRuleOk returns a tuple with the ListenerRule field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleResponse) GetListenerRuleOk() (*ListenerRule, bool) { + if o == nil || o.ListenerRule == nil { + return nil, false + } + return o.ListenerRule, true +} + +// HasListenerRule returns a boolean if a field has been set. +func (o *UpdateListenerRuleResponse) HasListenerRule() bool { + if o != nil && o.ListenerRule != nil { + return true + } + + return false +} + +// SetListenerRule gets a reference to the given ListenerRule and assigns it to the ListenerRule field. +func (o *UpdateListenerRuleResponse) SetListenerRule(v ListenerRule) { + o.ListenerRule = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateListenerRuleResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateListenerRuleResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateListenerRuleResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateListenerRuleResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateListenerRuleResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ListenerRule != nil { + toSerialize["ListenerRule"] = o.ListenerRule + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateListenerRuleResponse struct { + value *UpdateListenerRuleResponse + isSet bool +} + +func (v NullableUpdateListenerRuleResponse) Get() *UpdateListenerRuleResponse { + return v.value +} + +func (v *NullableUpdateListenerRuleResponse) Set(val *UpdateListenerRuleResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateListenerRuleResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateListenerRuleResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateListenerRuleResponse(val *UpdateListenerRuleResponse) *NullableUpdateListenerRuleResponse { + return &NullableUpdateListenerRuleResponse{value: val, isSet: true} +} + +func (v NullableUpdateListenerRuleResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateListenerRuleResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go new file mode 100644 index 000000000..fce59010e --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go @@ -0,0 +1,330 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateLoadBalancerRequest struct for UpdateLoadBalancerRequest +type UpdateLoadBalancerRequest struct { + AccessLog *AccessLog `json:"AccessLog,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + HealthCheck *HealthCheck `json:"HealthCheck,omitempty"` + // The name of the load balancer. + LoadBalancerName string `json:"LoadBalancerName"` + // The port on which the load balancer is listening (between `1` and `65535`, both included). + LoadBalancerPort *int32 `json:"LoadBalancerPort,omitempty"` + // The list of policy names (must contain all the policies to be enabled). + PolicyNames *[]string `json:"PolicyNames,omitempty"` + // The Outscale Resource Name (ORN) of the SSL certificate. + ServerCertificateId *string `json:"ServerCertificateId,omitempty"` +} + +// NewUpdateLoadBalancerRequest instantiates a new UpdateLoadBalancerRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateLoadBalancerRequest(loadBalancerName string, ) *UpdateLoadBalancerRequest { + this := UpdateLoadBalancerRequest{} + this.LoadBalancerName = loadBalancerName + return &this +} + +// NewUpdateLoadBalancerRequestWithDefaults instantiates a new UpdateLoadBalancerRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateLoadBalancerRequestWithDefaults() *UpdateLoadBalancerRequest { + this := UpdateLoadBalancerRequest{} + return &this +} + +// GetAccessLog returns the AccessLog field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetAccessLog() AccessLog { + if o == nil || o.AccessLog == nil { + var ret AccessLog + return ret + } + return *o.AccessLog +} + +// GetAccessLogOk returns a tuple with the AccessLog field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetAccessLogOk() (*AccessLog, bool) { + if o == nil || o.AccessLog == nil { + return nil, false + } + return o.AccessLog, true +} + +// HasAccessLog returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasAccessLog() bool { + if o != nil && o.AccessLog != nil { + return true + } + + return false +} + +// SetAccessLog gets a reference to the given AccessLog and assigns it to the AccessLog field. +func (o *UpdateLoadBalancerRequest) SetAccessLog(v AccessLog) { + o.AccessLog = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateLoadBalancerRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetHealthCheck returns the HealthCheck field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetHealthCheck() HealthCheck { + if o == nil || o.HealthCheck == nil { + var ret HealthCheck + return ret + } + return *o.HealthCheck +} + +// GetHealthCheckOk returns a tuple with the HealthCheck field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetHealthCheckOk() (*HealthCheck, bool) { + if o == nil || o.HealthCheck == nil { + return nil, false + } + return o.HealthCheck, true +} + +// HasHealthCheck returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasHealthCheck() bool { + if o != nil && o.HealthCheck != nil { + return true + } + + return false +} + +// SetHealthCheck gets a reference to the given HealthCheck and assigns it to the HealthCheck field. +func (o *UpdateLoadBalancerRequest) SetHealthCheck(v HealthCheck) { + o.HealthCheck = &v +} + +// GetLoadBalancerName returns the LoadBalancerName field value +func (o *UpdateLoadBalancerRequest) GetLoadBalancerName() string { + if o == nil { + var ret string + return ret + } + + return o.LoadBalancerName +} + +// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetLoadBalancerNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.LoadBalancerName, true +} + +// SetLoadBalancerName sets field value +func (o *UpdateLoadBalancerRequest) SetLoadBalancerName(v string) { + o.LoadBalancerName = v +} + +// GetLoadBalancerPort returns the LoadBalancerPort field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetLoadBalancerPort() int32 { + if o == nil || o.LoadBalancerPort == nil { + var ret int32 + return ret + } + return *o.LoadBalancerPort +} + +// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetLoadBalancerPortOk() (*int32, bool) { + if o == nil || o.LoadBalancerPort == nil { + return nil, false + } + return o.LoadBalancerPort, true +} + +// HasLoadBalancerPort returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasLoadBalancerPort() bool { + if o != nil && o.LoadBalancerPort != nil { + return true + } + + return false +} + +// SetLoadBalancerPort gets a reference to the given int32 and assigns it to the LoadBalancerPort field. +func (o *UpdateLoadBalancerRequest) SetLoadBalancerPort(v int32) { + o.LoadBalancerPort = &v +} + +// GetPolicyNames returns the PolicyNames field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetPolicyNames() []string { + if o == nil || o.PolicyNames == nil { + var ret []string + return ret + } + return *o.PolicyNames +} + +// GetPolicyNamesOk returns a tuple with the PolicyNames field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetPolicyNamesOk() (*[]string, bool) { + if o == nil || o.PolicyNames == nil { + return nil, false + } + return o.PolicyNames, true +} + +// HasPolicyNames returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasPolicyNames() bool { + if o != nil && o.PolicyNames != nil { + return true + } + + return false +} + +// SetPolicyNames gets a reference to the given []string and assigns it to the PolicyNames field. +func (o *UpdateLoadBalancerRequest) SetPolicyNames(v []string) { + o.PolicyNames = &v +} + +// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. +func (o *UpdateLoadBalancerRequest) GetServerCertificateId() string { + if o == nil || o.ServerCertificateId == nil { + var ret string + return ret + } + return *o.ServerCertificateId +} + +// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerRequest) GetServerCertificateIdOk() (*string, bool) { + if o == nil || o.ServerCertificateId == nil { + return nil, false + } + return o.ServerCertificateId, true +} + +// HasServerCertificateId returns a boolean if a field has been set. +func (o *UpdateLoadBalancerRequest) HasServerCertificateId() bool { + if o != nil && o.ServerCertificateId != nil { + return true + } + + return false +} + +// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. +func (o *UpdateLoadBalancerRequest) SetServerCertificateId(v string) { + o.ServerCertificateId = &v +} + +func (o UpdateLoadBalancerRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccessLog != nil { + toSerialize["AccessLog"] = o.AccessLog + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.HealthCheck != nil { + toSerialize["HealthCheck"] = o.HealthCheck + } + if true { + toSerialize["LoadBalancerName"] = o.LoadBalancerName + } + if o.LoadBalancerPort != nil { + toSerialize["LoadBalancerPort"] = o.LoadBalancerPort + } + if o.PolicyNames != nil { + toSerialize["PolicyNames"] = o.PolicyNames + } + if o.ServerCertificateId != nil { + toSerialize["ServerCertificateId"] = o.ServerCertificateId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateLoadBalancerRequest struct { + value *UpdateLoadBalancerRequest + isSet bool +} + +func (v NullableUpdateLoadBalancerRequest) Get() *UpdateLoadBalancerRequest { + return v.value +} + +func (v *NullableUpdateLoadBalancerRequest) Set(val *UpdateLoadBalancerRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateLoadBalancerRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateLoadBalancerRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateLoadBalancerRequest(val *UpdateLoadBalancerRequest) *NullableUpdateLoadBalancerRequest { + return &NullableUpdateLoadBalancerRequest{value: val, isSet: true} +} + +func (v NullableUpdateLoadBalancerRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateLoadBalancerRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go new file mode 100644 index 000000000..5477bfdeb --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateLoadBalancerResponse struct for UpdateLoadBalancerResponse +type UpdateLoadBalancerResponse struct { + LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateLoadBalancerResponse instantiates a new UpdateLoadBalancerResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateLoadBalancerResponse() *UpdateLoadBalancerResponse { + this := UpdateLoadBalancerResponse{} + return &this +} + +// NewUpdateLoadBalancerResponseWithDefaults instantiates a new UpdateLoadBalancerResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateLoadBalancerResponseWithDefaults() *UpdateLoadBalancerResponse { + this := UpdateLoadBalancerResponse{} + return &this +} + +// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. +func (o *UpdateLoadBalancerResponse) GetLoadBalancer() LoadBalancer { + if o == nil || o.LoadBalancer == nil { + var ret LoadBalancer + return ret + } + return *o.LoadBalancer +} + +// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerResponse) GetLoadBalancerOk() (*LoadBalancer, bool) { + if o == nil || o.LoadBalancer == nil { + return nil, false + } + return o.LoadBalancer, true +} + +// HasLoadBalancer returns a boolean if a field has been set. +func (o *UpdateLoadBalancerResponse) HasLoadBalancer() bool { + if o != nil && o.LoadBalancer != nil { + return true + } + + return false +} + +// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. +func (o *UpdateLoadBalancerResponse) SetLoadBalancer(v LoadBalancer) { + o.LoadBalancer = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateLoadBalancerResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateLoadBalancerResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateLoadBalancerResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateLoadBalancerResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateLoadBalancerResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.LoadBalancer != nil { + toSerialize["LoadBalancer"] = o.LoadBalancer + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateLoadBalancerResponse struct { + value *UpdateLoadBalancerResponse + isSet bool +} + +func (v NullableUpdateLoadBalancerResponse) Get() *UpdateLoadBalancerResponse { + return v.value +} + +func (v *NullableUpdateLoadBalancerResponse) Set(val *UpdateLoadBalancerResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateLoadBalancerResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateLoadBalancerResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateLoadBalancerResponse(val *UpdateLoadBalancerResponse) *NullableUpdateLoadBalancerResponse { + return &NullableUpdateLoadBalancerResponse{value: val, isSet: true} +} + +func (v NullableUpdateLoadBalancerResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateLoadBalancerResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go new file mode 100644 index 000000000..57311f42b --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go @@ -0,0 +1,221 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNetAccessPointRequest struct for UpdateNetAccessPointRequest +type UpdateNetAccessPointRequest struct { + // One or more IDs of route tables to associate with the specified Net access point. + AddRouteTableIds *[]string `json:"AddRouteTableIds,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net access point. + NetAccessPointId string `json:"NetAccessPointId"` + // One or more IDs of route tables to disassociate from the specified Net access point. + RemoveRouteTableIds *[]string `json:"RemoveRouteTableIds,omitempty"` +} + +// NewUpdateNetAccessPointRequest instantiates a new UpdateNetAccessPointRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNetAccessPointRequest(netAccessPointId string, ) *UpdateNetAccessPointRequest { + this := UpdateNetAccessPointRequest{} + this.NetAccessPointId = netAccessPointId + return &this +} + +// NewUpdateNetAccessPointRequestWithDefaults instantiates a new UpdateNetAccessPointRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNetAccessPointRequestWithDefaults() *UpdateNetAccessPointRequest { + this := UpdateNetAccessPointRequest{} + return &this +} + +// GetAddRouteTableIds returns the AddRouteTableIds field value if set, zero value otherwise. +func (o *UpdateNetAccessPointRequest) GetAddRouteTableIds() []string { + if o == nil || o.AddRouteTableIds == nil { + var ret []string + return ret + } + return *o.AddRouteTableIds +} + +// GetAddRouteTableIdsOk returns a tuple with the AddRouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointRequest) GetAddRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.AddRouteTableIds == nil { + return nil, false + } + return o.AddRouteTableIds, true +} + +// HasAddRouteTableIds returns a boolean if a field has been set. +func (o *UpdateNetAccessPointRequest) HasAddRouteTableIds() bool { + if o != nil && o.AddRouteTableIds != nil { + return true + } + + return false +} + +// SetAddRouteTableIds gets a reference to the given []string and assigns it to the AddRouteTableIds field. +func (o *UpdateNetAccessPointRequest) SetAddRouteTableIds(v []string) { + o.AddRouteTableIds = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateNetAccessPointRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateNetAccessPointRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateNetAccessPointRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetAccessPointId returns the NetAccessPointId field value +func (o *UpdateNetAccessPointRequest) GetNetAccessPointId() string { + if o == nil { + var ret string + return ret + } + + return o.NetAccessPointId +} + +// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointRequest) GetNetAccessPointIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetAccessPointId, true +} + +// SetNetAccessPointId sets field value +func (o *UpdateNetAccessPointRequest) SetNetAccessPointId(v string) { + o.NetAccessPointId = v +} + +// GetRemoveRouteTableIds returns the RemoveRouteTableIds field value if set, zero value otherwise. +func (o *UpdateNetAccessPointRequest) GetRemoveRouteTableIds() []string { + if o == nil || o.RemoveRouteTableIds == nil { + var ret []string + return ret + } + return *o.RemoveRouteTableIds +} + +// GetRemoveRouteTableIdsOk returns a tuple with the RemoveRouteTableIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointRequest) GetRemoveRouteTableIdsOk() (*[]string, bool) { + if o == nil || o.RemoveRouteTableIds == nil { + return nil, false + } + return o.RemoveRouteTableIds, true +} + +// HasRemoveRouteTableIds returns a boolean if a field has been set. +func (o *UpdateNetAccessPointRequest) HasRemoveRouteTableIds() bool { + if o != nil && o.RemoveRouteTableIds != nil { + return true + } + + return false +} + +// SetRemoveRouteTableIds gets a reference to the given []string and assigns it to the RemoveRouteTableIds field. +func (o *UpdateNetAccessPointRequest) SetRemoveRouteTableIds(v []string) { + o.RemoveRouteTableIds = &v +} + +func (o UpdateNetAccessPointRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AddRouteTableIds != nil { + toSerialize["AddRouteTableIds"] = o.AddRouteTableIds + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetAccessPointId"] = o.NetAccessPointId + } + if o.RemoveRouteTableIds != nil { + toSerialize["RemoveRouteTableIds"] = o.RemoveRouteTableIds + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNetAccessPointRequest struct { + value *UpdateNetAccessPointRequest + isSet bool +} + +func (v NullableUpdateNetAccessPointRequest) Get() *UpdateNetAccessPointRequest { + return v.value +} + +func (v *NullableUpdateNetAccessPointRequest) Set(val *UpdateNetAccessPointRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNetAccessPointRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNetAccessPointRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNetAccessPointRequest(val *UpdateNetAccessPointRequest) *NullableUpdateNetAccessPointRequest { + return &NullableUpdateNetAccessPointRequest{value: val, isSet: true} +} + +func (v NullableUpdateNetAccessPointRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNetAccessPointRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go new file mode 100644 index 000000000..1bf034ff7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNetAccessPointResponse struct for UpdateNetAccessPointResponse +type UpdateNetAccessPointResponse struct { + NetAccessPoint *NetAccessPoint `json:"NetAccessPoint,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateNetAccessPointResponse instantiates a new UpdateNetAccessPointResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNetAccessPointResponse() *UpdateNetAccessPointResponse { + this := UpdateNetAccessPointResponse{} + return &this +} + +// NewUpdateNetAccessPointResponseWithDefaults instantiates a new UpdateNetAccessPointResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNetAccessPointResponseWithDefaults() *UpdateNetAccessPointResponse { + this := UpdateNetAccessPointResponse{} + return &this +} + +// GetNetAccessPoint returns the NetAccessPoint field value if set, zero value otherwise. +func (o *UpdateNetAccessPointResponse) GetNetAccessPoint() NetAccessPoint { + if o == nil || o.NetAccessPoint == nil { + var ret NetAccessPoint + return ret + } + return *o.NetAccessPoint +} + +// GetNetAccessPointOk returns a tuple with the NetAccessPoint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointResponse) GetNetAccessPointOk() (*NetAccessPoint, bool) { + if o == nil || o.NetAccessPoint == nil { + return nil, false + } + return o.NetAccessPoint, true +} + +// HasNetAccessPoint returns a boolean if a field has been set. +func (o *UpdateNetAccessPointResponse) HasNetAccessPoint() bool { + if o != nil && o.NetAccessPoint != nil { + return true + } + + return false +} + +// SetNetAccessPoint gets a reference to the given NetAccessPoint and assigns it to the NetAccessPoint field. +func (o *UpdateNetAccessPointResponse) SetNetAccessPoint(v NetAccessPoint) { + o.NetAccessPoint = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateNetAccessPointResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetAccessPointResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateNetAccessPointResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateNetAccessPointResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateNetAccessPointResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.NetAccessPoint != nil { + toSerialize["NetAccessPoint"] = o.NetAccessPoint + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNetAccessPointResponse struct { + value *UpdateNetAccessPointResponse + isSet bool +} + +func (v NullableUpdateNetAccessPointResponse) Get() *UpdateNetAccessPointResponse { + return v.value +} + +func (v *NullableUpdateNetAccessPointResponse) Set(val *UpdateNetAccessPointResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNetAccessPointResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNetAccessPointResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNetAccessPointResponse(val *UpdateNetAccessPointResponse) *NullableUpdateNetAccessPointResponse { + return &NullableUpdateNetAccessPointResponse{value: val, isSet: true} +} + +func (v NullableUpdateNetAccessPointResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNetAccessPointResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go new file mode 100644 index 000000000..50e4f0402 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNetRequest struct for UpdateNetRequest +type UpdateNetRequest struct { + // The ID of the DHCP options set (or `default` if you want to associate the default one). + DhcpOptionsSetId string `json:"DhcpOptionsSetId"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of the Net. + NetId string `json:"NetId"` +} + +// NewUpdateNetRequest instantiates a new UpdateNetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNetRequest(dhcpOptionsSetId string, netId string, ) *UpdateNetRequest { + this := UpdateNetRequest{} + this.DhcpOptionsSetId = dhcpOptionsSetId + this.NetId = netId + return &this +} + +// NewUpdateNetRequestWithDefaults instantiates a new UpdateNetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNetRequestWithDefaults() *UpdateNetRequest { + this := UpdateNetRequest{} + return &this +} + +// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value +func (o *UpdateNetRequest) GetDhcpOptionsSetId() string { + if o == nil { + var ret string + return ret + } + + return o.DhcpOptionsSetId +} + +// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value +// and a boolean to check if the value has been set. +func (o *UpdateNetRequest) GetDhcpOptionsSetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DhcpOptionsSetId, true +} + +// SetDhcpOptionsSetId sets field value +func (o *UpdateNetRequest) SetDhcpOptionsSetId(v string) { + o.DhcpOptionsSetId = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateNetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateNetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateNetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetNetId returns the NetId field value +func (o *UpdateNetRequest) GetNetId() string { + if o == nil { + var ret string + return ret + } + + return o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value +// and a boolean to check if the value has been set. +func (o *UpdateNetRequest) GetNetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NetId, true +} + +// SetNetId sets field value +func (o *UpdateNetRequest) SetNetId(v string) { + o.NetId = v +} + +func (o UpdateNetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DhcpOptionsSetId"] = o.DhcpOptionsSetId + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["NetId"] = o.NetId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNetRequest struct { + value *UpdateNetRequest + isSet bool +} + +func (v NullableUpdateNetRequest) Get() *UpdateNetRequest { + return v.value +} + +func (v *NullableUpdateNetRequest) Set(val *UpdateNetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNetRequest(val *UpdateNetRequest) *NullableUpdateNetRequest { + return &NullableUpdateNetRequest{value: val, isSet: true} +} + +func (v NullableUpdateNetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go new file mode 100644 index 000000000..d82077ff3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNetResponse struct for UpdateNetResponse +type UpdateNetResponse struct { + Net *Net `json:"Net,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateNetResponse instantiates a new UpdateNetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNetResponse() *UpdateNetResponse { + this := UpdateNetResponse{} + return &this +} + +// NewUpdateNetResponseWithDefaults instantiates a new UpdateNetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNetResponseWithDefaults() *UpdateNetResponse { + this := UpdateNetResponse{} + return &this +} + +// GetNet returns the Net field value if set, zero value otherwise. +func (o *UpdateNetResponse) GetNet() Net { + if o == nil || o.Net == nil { + var ret Net + return ret + } + return *o.Net +} + +// GetNetOk returns a tuple with the Net field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetResponse) GetNetOk() (*Net, bool) { + if o == nil || o.Net == nil { + return nil, false + } + return o.Net, true +} + +// HasNet returns a boolean if a field has been set. +func (o *UpdateNetResponse) HasNet() bool { + if o != nil && o.Net != nil { + return true + } + + return false +} + +// SetNet gets a reference to the given Net and assigns it to the Net field. +func (o *UpdateNetResponse) SetNet(v Net) { + o.Net = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateNetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateNetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateNetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateNetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Net != nil { + toSerialize["Net"] = o.Net + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNetResponse struct { + value *UpdateNetResponse + isSet bool +} + +func (v NullableUpdateNetResponse) Get() *UpdateNetResponse { + return v.value +} + +func (v *NullableUpdateNetResponse) Set(val *UpdateNetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNetResponse(val *UpdateNetResponse) *NullableUpdateNetResponse { + return &NullableUpdateNetResponse{value: val, isSet: true} +} + +func (v NullableUpdateNetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go new file mode 100644 index 000000000..062c102b6 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go @@ -0,0 +1,257 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNicRequest struct for UpdateNicRequest +type UpdateNicRequest struct { + // A new description for the NIC. + Description *string `json:"Description,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + LinkNic *LinkNicToUpdate `json:"LinkNic,omitempty"` + // The ID of the NIC you want to modify. + NicId string `json:"NicId"` + // One or more IDs of security groups for the NIC.
You must specify at least one group, even if you use the default security group in the Net. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` +} + +// NewUpdateNicRequest instantiates a new UpdateNicRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNicRequest(nicId string, ) *UpdateNicRequest { + this := UpdateNicRequest{} + this.NicId = nicId + return &this +} + +// NewUpdateNicRequestWithDefaults instantiates a new UpdateNicRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNicRequestWithDefaults() *UpdateNicRequest { + this := UpdateNicRequest{} + return &this +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *UpdateNicRequest) GetDescription() string { + if o == nil || o.Description == nil { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicRequest) GetDescriptionOk() (*string, bool) { + if o == nil || o.Description == nil { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *UpdateNicRequest) HasDescription() bool { + if o != nil && o.Description != nil { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *UpdateNicRequest) SetDescription(v string) { + o.Description = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateNicRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateNicRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateNicRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetLinkNic returns the LinkNic field value if set, zero value otherwise. +func (o *UpdateNicRequest) GetLinkNic() LinkNicToUpdate { + if o == nil || o.LinkNic == nil { + var ret LinkNicToUpdate + return ret + } + return *o.LinkNic +} + +// GetLinkNicOk returns a tuple with the LinkNic field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicRequest) GetLinkNicOk() (*LinkNicToUpdate, bool) { + if o == nil || o.LinkNic == nil { + return nil, false + } + return o.LinkNic, true +} + +// HasLinkNic returns a boolean if a field has been set. +func (o *UpdateNicRequest) HasLinkNic() bool { + if o != nil && o.LinkNic != nil { + return true + } + + return false +} + +// SetLinkNic gets a reference to the given LinkNicToUpdate and assigns it to the LinkNic field. +func (o *UpdateNicRequest) SetLinkNic(v LinkNicToUpdate) { + o.LinkNic = &v +} + +// GetNicId returns the NicId field value +func (o *UpdateNicRequest) GetNicId() string { + if o == nil { + var ret string + return ret + } + + return o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value +// and a boolean to check if the value has been set. +func (o *UpdateNicRequest) GetNicIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.NicId, true +} + +// SetNicId sets field value +func (o *UpdateNicRequest) SetNicId(v string) { + o.NicId = v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *UpdateNicRequest) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicRequest) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *UpdateNicRequest) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *UpdateNicRequest) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +func (o UpdateNicRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Description != nil { + toSerialize["Description"] = o.Description + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.LinkNic != nil { + toSerialize["LinkNic"] = o.LinkNic + } + if true { + toSerialize["NicId"] = o.NicId + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNicRequest struct { + value *UpdateNicRequest + isSet bool +} + +func (v NullableUpdateNicRequest) Get() *UpdateNicRequest { + return v.value +} + +func (v *NullableUpdateNicRequest) Set(val *UpdateNicRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNicRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNicRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNicRequest(val *UpdateNicRequest) *NullableUpdateNicRequest { + return &NullableUpdateNicRequest{value: val, isSet: true} +} + +func (v NullableUpdateNicRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNicRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go new file mode 100644 index 000000000..7728f04a7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateNicResponse struct for UpdateNicResponse +type UpdateNicResponse struct { + Nic *Nic `json:"Nic,omitempty"` + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` +} + +// NewUpdateNicResponse instantiates a new UpdateNicResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNicResponse() *UpdateNicResponse { + this := UpdateNicResponse{} + return &this +} + +// NewUpdateNicResponseWithDefaults instantiates a new UpdateNicResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNicResponseWithDefaults() *UpdateNicResponse { + this := UpdateNicResponse{} + return &this +} + +// GetNic returns the Nic field value if set, zero value otherwise. +func (o *UpdateNicResponse) GetNic() Nic { + if o == nil || o.Nic == nil { + var ret Nic + return ret + } + return *o.Nic +} + +// GetNicOk returns a tuple with the Nic field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicResponse) GetNicOk() (*Nic, bool) { + if o == nil || o.Nic == nil { + return nil, false + } + return o.Nic, true +} + +// HasNic returns a boolean if a field has been set. +func (o *UpdateNicResponse) HasNic() bool { + if o != nil && o.Nic != nil { + return true + } + + return false +} + +// SetNic gets a reference to the given Nic and assigns it to the Nic field. +func (o *UpdateNicResponse) SetNic(v Nic) { + o.Nic = &v +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateNicResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNicResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateNicResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateNicResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +func (o UpdateNicResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Nic != nil { + toSerialize["Nic"] = o.Nic + } + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + return json.Marshal(toSerialize) +} + +type NullableUpdateNicResponse struct { + value *UpdateNicResponse + isSet bool +} + +func (v NullableUpdateNicResponse) Get() *UpdateNicResponse { + return v.value +} + +func (v *NullableUpdateNicResponse) Set(val *UpdateNicResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNicResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNicResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNicResponse(val *UpdateNicResponse) *NullableUpdateNicResponse { + return &NullableUpdateNicResponse{value: val, isSet: true} +} + +func (v NullableUpdateNicResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNicResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go new file mode 100644 index 000000000..6319138b7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go @@ -0,0 +1,207 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateRoutePropagationRequest struct for UpdateRoutePropagationRequest +type UpdateRoutePropagationRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // If `true`, a virtual gateway can propagate routes to a specified route table of a Net. If `false`, the propagation is disabled. + Enable bool `json:"Enable"` + // The ID of the route table. + RouteTableId string `json:"RouteTableId"` + // The ID of the virtual gateway. + VirtualGatewayId string `json:"VirtualGatewayId"` +} + +// NewUpdateRoutePropagationRequest instantiates a new UpdateRoutePropagationRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateRoutePropagationRequest(enable bool, routeTableId string, virtualGatewayId string, ) *UpdateRoutePropagationRequest { + this := UpdateRoutePropagationRequest{} + this.Enable = enable + this.RouteTableId = routeTableId + this.VirtualGatewayId = virtualGatewayId + return &this +} + +// NewUpdateRoutePropagationRequestWithDefaults instantiates a new UpdateRoutePropagationRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateRoutePropagationRequestWithDefaults() *UpdateRoutePropagationRequest { + this := UpdateRoutePropagationRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateRoutePropagationRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateRoutePropagationRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateRoutePropagationRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetEnable returns the Enable field value +func (o *UpdateRoutePropagationRequest) GetEnable() bool { + if o == nil { + var ret bool + return ret + } + + return o.Enable +} + +// GetEnableOk returns a tuple with the Enable field value +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationRequest) GetEnableOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.Enable, true +} + +// SetEnable sets field value +func (o *UpdateRoutePropagationRequest) SetEnable(v bool) { + o.Enable = v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *UpdateRoutePropagationRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *UpdateRoutePropagationRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value +func (o *UpdateRoutePropagationRequest) GetVirtualGatewayId() string { + if o == nil { + var ret string + return ret + } + + return o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationRequest) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VirtualGatewayId, true +} + +// SetVirtualGatewayId sets field value +func (o *UpdateRoutePropagationRequest) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = v +} + +func (o UpdateRoutePropagationRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["Enable"] = o.Enable + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + if true { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateRoutePropagationRequest struct { + value *UpdateRoutePropagationRequest + isSet bool +} + +func (v NullableUpdateRoutePropagationRequest) Get() *UpdateRoutePropagationRequest { + return v.value +} + +func (v *NullableUpdateRoutePropagationRequest) Set(val *UpdateRoutePropagationRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateRoutePropagationRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateRoutePropagationRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateRoutePropagationRequest(val *UpdateRoutePropagationRequest) *NullableUpdateRoutePropagationRequest { + return &NullableUpdateRoutePropagationRequest{value: val, isSet: true} +} + +func (v NullableUpdateRoutePropagationRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateRoutePropagationRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go new file mode 100644 index 000000000..1f8d5c7a5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateRoutePropagationResponse struct for UpdateRoutePropagationResponse +type UpdateRoutePropagationResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + RouteTable *RouteTable `json:"RouteTable,omitempty"` +} + +// NewUpdateRoutePropagationResponse instantiates a new UpdateRoutePropagationResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateRoutePropagationResponse() *UpdateRoutePropagationResponse { + this := UpdateRoutePropagationResponse{} + return &this +} + +// NewUpdateRoutePropagationResponseWithDefaults instantiates a new UpdateRoutePropagationResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateRoutePropagationResponseWithDefaults() *UpdateRoutePropagationResponse { + this := UpdateRoutePropagationResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateRoutePropagationResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateRoutePropagationResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateRoutePropagationResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTable returns the RouteTable field value if set, zero value otherwise. +func (o *UpdateRoutePropagationResponse) GetRouteTable() RouteTable { + if o == nil || o.RouteTable == nil { + var ret RouteTable + return ret + } + return *o.RouteTable +} + +// GetRouteTableOk returns a tuple with the RouteTable field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRoutePropagationResponse) GetRouteTableOk() (*RouteTable, bool) { + if o == nil || o.RouteTable == nil { + return nil, false + } + return o.RouteTable, true +} + +// HasRouteTable returns a boolean if a field has been set. +func (o *UpdateRoutePropagationResponse) HasRouteTable() bool { + if o != nil && o.RouteTable != nil { + return true + } + + return false +} + +// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. +func (o *UpdateRoutePropagationResponse) SetRouteTable(v RouteTable) { + o.RouteTable = &v +} + +func (o UpdateRoutePropagationResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTable != nil { + toSerialize["RouteTable"] = o.RouteTable + } + return json.Marshal(toSerialize) +} + +type NullableUpdateRoutePropagationResponse struct { + value *UpdateRoutePropagationResponse + isSet bool +} + +func (v NullableUpdateRoutePropagationResponse) Get() *UpdateRoutePropagationResponse { + return v.value +} + +func (v *NullableUpdateRoutePropagationResponse) Set(val *UpdateRoutePropagationResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateRoutePropagationResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateRoutePropagationResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateRoutePropagationResponse(val *UpdateRoutePropagationResponse) *NullableUpdateRoutePropagationResponse { + return &NullableUpdateRoutePropagationResponse{value: val, isSet: true} +} + +func (v NullableUpdateRoutePropagationResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateRoutePropagationResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go new file mode 100644 index 000000000..cc5a831b2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go @@ -0,0 +1,362 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateRouteRequest struct for UpdateRouteRequest +type UpdateRouteRequest struct { + // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + DestinationIpRange string `json:"DestinationIpRange"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The ID of an Internet service or virtual gateway attached to your Net. + GatewayId *string `json:"GatewayId,omitempty"` + // The ID of a NAT service. + NatServiceId *string `json:"NatServiceId,omitempty"` + // The ID of a Net peering connection. + NetPeeringId *string `json:"NetPeeringId,omitempty"` + // The ID of a network interface card (NIC). + NicId *string `json:"NicId,omitempty"` + // The ID of the route table. + RouteTableId string `json:"RouteTableId"` + // The ID of a NAT VM in your Net. + VmId *string `json:"VmId,omitempty"` +} + +// NewUpdateRouteRequest instantiates a new UpdateRouteRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateRouteRequest(destinationIpRange string, routeTableId string, ) *UpdateRouteRequest { + this := UpdateRouteRequest{} + this.DestinationIpRange = destinationIpRange + this.RouteTableId = routeTableId + return &this +} + +// NewUpdateRouteRequestWithDefaults instantiates a new UpdateRouteRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateRouteRequestWithDefaults() *UpdateRouteRequest { + this := UpdateRouteRequest{} + return &this +} + +// GetDestinationIpRange returns the DestinationIpRange field value +func (o *UpdateRouteRequest) GetDestinationIpRange() string { + if o == nil { + var ret string + return ret + } + + return o.DestinationIpRange +} + +// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetDestinationIpRangeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DestinationIpRange, true +} + +// SetDestinationIpRange sets field value +func (o *UpdateRouteRequest) SetDestinationIpRange(v string) { + o.DestinationIpRange = v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateRouteRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetGatewayId returns the GatewayId field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetGatewayId() string { + if o == nil || o.GatewayId == nil { + var ret string + return ret + } + return *o.GatewayId +} + +// GetGatewayIdOk returns a tuple with the GatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetGatewayIdOk() (*string, bool) { + if o == nil || o.GatewayId == nil { + return nil, false + } + return o.GatewayId, true +} + +// HasGatewayId returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasGatewayId() bool { + if o != nil && o.GatewayId != nil { + return true + } + + return false +} + +// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. +func (o *UpdateRouteRequest) SetGatewayId(v string) { + o.GatewayId = &v +} + +// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetNatServiceId() string { + if o == nil || o.NatServiceId == nil { + var ret string + return ret + } + return *o.NatServiceId +} + +// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetNatServiceIdOk() (*string, bool) { + if o == nil || o.NatServiceId == nil { + return nil, false + } + return o.NatServiceId, true +} + +// HasNatServiceId returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasNatServiceId() bool { + if o != nil && o.NatServiceId != nil { + return true + } + + return false +} + +// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. +func (o *UpdateRouteRequest) SetNatServiceId(v string) { + o.NatServiceId = &v +} + +// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetNetPeeringId() string { + if o == nil || o.NetPeeringId == nil { + var ret string + return ret + } + return *o.NetPeeringId +} + +// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetNetPeeringIdOk() (*string, bool) { + if o == nil || o.NetPeeringId == nil { + return nil, false + } + return o.NetPeeringId, true +} + +// HasNetPeeringId returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasNetPeeringId() bool { + if o != nil && o.NetPeeringId != nil { + return true + } + + return false +} + +// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. +func (o *UpdateRouteRequest) SetNetPeeringId(v string) { + o.NetPeeringId = &v +} + +// GetNicId returns the NicId field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetNicId() string { + if o == nil || o.NicId == nil { + var ret string + return ret + } + return *o.NicId +} + +// GetNicIdOk returns a tuple with the NicId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetNicIdOk() (*string, bool) { + if o == nil || o.NicId == nil { + return nil, false + } + return o.NicId, true +} + +// HasNicId returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasNicId() bool { + if o != nil && o.NicId != nil { + return true + } + + return false +} + +// SetNicId gets a reference to the given string and assigns it to the NicId field. +func (o *UpdateRouteRequest) SetNicId(v string) { + o.NicId = &v +} + +// GetRouteTableId returns the RouteTableId field value +func (o *UpdateRouteRequest) GetRouteTableId() string { + if o == nil { + var ret string + return ret + } + + return o.RouteTableId +} + +// GetRouteTableIdOk returns a tuple with the RouteTableId field value +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetRouteTableIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.RouteTableId, true +} + +// SetRouteTableId sets field value +func (o *UpdateRouteRequest) SetRouteTableId(v string) { + o.RouteTableId = v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *UpdateRouteRequest) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteRequest) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *UpdateRouteRequest) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *UpdateRouteRequest) SetVmId(v string) { + o.VmId = &v +} + +func (o UpdateRouteRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if true { + toSerialize["DestinationIpRange"] = o.DestinationIpRange + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.GatewayId != nil { + toSerialize["GatewayId"] = o.GatewayId + } + if o.NatServiceId != nil { + toSerialize["NatServiceId"] = o.NatServiceId + } + if o.NetPeeringId != nil { + toSerialize["NetPeeringId"] = o.NetPeeringId + } + if o.NicId != nil { + toSerialize["NicId"] = o.NicId + } + if true { + toSerialize["RouteTableId"] = o.RouteTableId + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateRouteRequest struct { + value *UpdateRouteRequest + isSet bool +} + +func (v NullableUpdateRouteRequest) Get() *UpdateRouteRequest { + return v.value +} + +func (v *NullableUpdateRouteRequest) Set(val *UpdateRouteRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateRouteRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateRouteRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateRouteRequest(val *UpdateRouteRequest) *NullableUpdateRouteRequest { + return &NullableUpdateRouteRequest{value: val, isSet: true} +} + +func (v NullableUpdateRouteRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateRouteRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go new file mode 100644 index 000000000..25a3001d3 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateRouteResponse struct for UpdateRouteResponse +type UpdateRouteResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + RouteTable *RouteTable `json:"RouteTable,omitempty"` +} + +// NewUpdateRouteResponse instantiates a new UpdateRouteResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateRouteResponse() *UpdateRouteResponse { + this := UpdateRouteResponse{} + return &this +} + +// NewUpdateRouteResponseWithDefaults instantiates a new UpdateRouteResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateRouteResponseWithDefaults() *UpdateRouteResponse { + this := UpdateRouteResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateRouteResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateRouteResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateRouteResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetRouteTable returns the RouteTable field value if set, zero value otherwise. +func (o *UpdateRouteResponse) GetRouteTable() RouteTable { + if o == nil || o.RouteTable == nil { + var ret RouteTable + return ret + } + return *o.RouteTable +} + +// GetRouteTableOk returns a tuple with the RouteTable field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateRouteResponse) GetRouteTableOk() (*RouteTable, bool) { + if o == nil || o.RouteTable == nil { + return nil, false + } + return o.RouteTable, true +} + +// HasRouteTable returns a boolean if a field has been set. +func (o *UpdateRouteResponse) HasRouteTable() bool { + if o != nil && o.RouteTable != nil { + return true + } + + return false +} + +// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. +func (o *UpdateRouteResponse) SetRouteTable(v RouteTable) { + o.RouteTable = &v +} + +func (o UpdateRouteResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.RouteTable != nil { + toSerialize["RouteTable"] = o.RouteTable + } + return json.Marshal(toSerialize) +} + +type NullableUpdateRouteResponse struct { + value *UpdateRouteResponse + isSet bool +} + +func (v NullableUpdateRouteResponse) Get() *UpdateRouteResponse { + return v.value +} + +func (v *NullableUpdateRouteResponse) Set(val *UpdateRouteResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateRouteResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateRouteResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateRouteResponse(val *UpdateRouteResponse) *NullableUpdateRouteResponse { + return &NullableUpdateRouteResponse{value: val, isSet: true} +} + +func (v NullableUpdateRouteResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateRouteResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go new file mode 100644 index 000000000..1b30943e7 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateServerCertificateRequest struct for UpdateServerCertificateRequest +type UpdateServerCertificateRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // The name of the server certificate you want to modify. + Name *string `json:"Name,omitempty"` + // A new name for the server certificate. + NewName *string `json:"NewName,omitempty"` + // A new path for the server certificate. + NewPath *string `json:"NewPath,omitempty"` +} + +// NewUpdateServerCertificateRequest instantiates a new UpdateServerCertificateRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateServerCertificateRequest() *UpdateServerCertificateRequest { + this := UpdateServerCertificateRequest{} + return &this +} + +// NewUpdateServerCertificateRequestWithDefaults instantiates a new UpdateServerCertificateRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateServerCertificateRequestWithDefaults() *UpdateServerCertificateRequest { + this := UpdateServerCertificateRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateServerCertificateRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateServerCertificateRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateServerCertificateRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *UpdateServerCertificateRequest) GetName() string { + if o == nil || o.Name == nil { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateRequest) GetNameOk() (*string, bool) { + if o == nil || o.Name == nil { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *UpdateServerCertificateRequest) HasName() bool { + if o != nil && o.Name != nil { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *UpdateServerCertificateRequest) SetName(v string) { + o.Name = &v +} + +// GetNewName returns the NewName field value if set, zero value otherwise. +func (o *UpdateServerCertificateRequest) GetNewName() string { + if o == nil || o.NewName == nil { + var ret string + return ret + } + return *o.NewName +} + +// GetNewNameOk returns a tuple with the NewName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateRequest) GetNewNameOk() (*string, bool) { + if o == nil || o.NewName == nil { + return nil, false + } + return o.NewName, true +} + +// HasNewName returns a boolean if a field has been set. +func (o *UpdateServerCertificateRequest) HasNewName() bool { + if o != nil && o.NewName != nil { + return true + } + + return false +} + +// SetNewName gets a reference to the given string and assigns it to the NewName field. +func (o *UpdateServerCertificateRequest) SetNewName(v string) { + o.NewName = &v +} + +// GetNewPath returns the NewPath field value if set, zero value otherwise. +func (o *UpdateServerCertificateRequest) GetNewPath() string { + if o == nil || o.NewPath == nil { + var ret string + return ret + } + return *o.NewPath +} + +// GetNewPathOk returns a tuple with the NewPath field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateRequest) GetNewPathOk() (*string, bool) { + if o == nil || o.NewPath == nil { + return nil, false + } + return o.NewPath, true +} + +// HasNewPath returns a boolean if a field has been set. +func (o *UpdateServerCertificateRequest) HasNewPath() bool { + if o != nil && o.NewPath != nil { + return true + } + + return false +} + +// SetNewPath gets a reference to the given string and assigns it to the NewPath field. +func (o *UpdateServerCertificateRequest) SetNewPath(v string) { + o.NewPath = &v +} + +func (o UpdateServerCertificateRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.Name != nil { + toSerialize["Name"] = o.Name + } + if o.NewName != nil { + toSerialize["NewName"] = o.NewName + } + if o.NewPath != nil { + toSerialize["NewPath"] = o.NewPath + } + return json.Marshal(toSerialize) +} + +type NullableUpdateServerCertificateRequest struct { + value *UpdateServerCertificateRequest + isSet bool +} + +func (v NullableUpdateServerCertificateRequest) Get() *UpdateServerCertificateRequest { + return v.value +} + +func (v *NullableUpdateServerCertificateRequest) Set(val *UpdateServerCertificateRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateServerCertificateRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateServerCertificateRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateServerCertificateRequest(val *UpdateServerCertificateRequest) *NullableUpdateServerCertificateRequest { + return &NullableUpdateServerCertificateRequest{value: val, isSet: true} +} + +func (v NullableUpdateServerCertificateRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateServerCertificateRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go new file mode 100644 index 000000000..2c254da5d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateServerCertificateResponse struct for UpdateServerCertificateResponse +type UpdateServerCertificateResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + ServerCertificate *ServerCertificate `json:"ServerCertificate,omitempty"` +} + +// NewUpdateServerCertificateResponse instantiates a new UpdateServerCertificateResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateServerCertificateResponse() *UpdateServerCertificateResponse { + this := UpdateServerCertificateResponse{} + return &this +} + +// NewUpdateServerCertificateResponseWithDefaults instantiates a new UpdateServerCertificateResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateServerCertificateResponseWithDefaults() *UpdateServerCertificateResponse { + this := UpdateServerCertificateResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateServerCertificateResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateServerCertificateResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateServerCertificateResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetServerCertificate returns the ServerCertificate field value if set, zero value otherwise. +func (o *UpdateServerCertificateResponse) GetServerCertificate() ServerCertificate { + if o == nil || o.ServerCertificate == nil { + var ret ServerCertificate + return ret + } + return *o.ServerCertificate +} + +// GetServerCertificateOk returns a tuple with the ServerCertificate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateServerCertificateResponse) GetServerCertificateOk() (*ServerCertificate, bool) { + if o == nil || o.ServerCertificate == nil { + return nil, false + } + return o.ServerCertificate, true +} + +// HasServerCertificate returns a boolean if a field has been set. +func (o *UpdateServerCertificateResponse) HasServerCertificate() bool { + if o != nil && o.ServerCertificate != nil { + return true + } + + return false +} + +// SetServerCertificate gets a reference to the given ServerCertificate and assigns it to the ServerCertificate field. +func (o *UpdateServerCertificateResponse) SetServerCertificate(v ServerCertificate) { + o.ServerCertificate = &v +} + +func (o UpdateServerCertificateResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.ServerCertificate != nil { + toSerialize["ServerCertificate"] = o.ServerCertificate + } + return json.Marshal(toSerialize) +} + +type NullableUpdateServerCertificateResponse struct { + value *UpdateServerCertificateResponse + isSet bool +} + +func (v NullableUpdateServerCertificateResponse) Get() *UpdateServerCertificateResponse { + return v.value +} + +func (v *NullableUpdateServerCertificateResponse) Set(val *UpdateServerCertificateResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateServerCertificateResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateServerCertificateResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateServerCertificateResponse(val *UpdateServerCertificateResponse) *NullableUpdateServerCertificateResponse { + return &NullableUpdateServerCertificateResponse{value: val, isSet: true} +} + +func (v NullableUpdateServerCertificateResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateServerCertificateResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go new file mode 100644 index 000000000..831321938 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go @@ -0,0 +1,176 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateSnapshotRequest struct for UpdateSnapshotRequest +type UpdateSnapshotRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + PermissionsToCreateVolume PermissionsOnResourceCreation `json:"PermissionsToCreateVolume"` + // The ID of the snapshot. + SnapshotId string `json:"SnapshotId"` +} + +// NewUpdateSnapshotRequest instantiates a new UpdateSnapshotRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateSnapshotRequest(permissionsToCreateVolume PermissionsOnResourceCreation, snapshotId string, ) *UpdateSnapshotRequest { + this := UpdateSnapshotRequest{} + this.PermissionsToCreateVolume = permissionsToCreateVolume + this.SnapshotId = snapshotId + return &this +} + +// NewUpdateSnapshotRequestWithDefaults instantiates a new UpdateSnapshotRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateSnapshotRequestWithDefaults() *UpdateSnapshotRequest { + this := UpdateSnapshotRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateSnapshotRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSnapshotRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateSnapshotRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateSnapshotRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetPermissionsToCreateVolume returns the PermissionsToCreateVolume field value +func (o *UpdateSnapshotRequest) GetPermissionsToCreateVolume() PermissionsOnResourceCreation { + if o == nil { + var ret PermissionsOnResourceCreation + return ret + } + + return o.PermissionsToCreateVolume +} + +// GetPermissionsToCreateVolumeOk returns a tuple with the PermissionsToCreateVolume field value +// and a boolean to check if the value has been set. +func (o *UpdateSnapshotRequest) GetPermissionsToCreateVolumeOk() (*PermissionsOnResourceCreation, bool) { + if o == nil { + return nil, false + } + return &o.PermissionsToCreateVolume, true +} + +// SetPermissionsToCreateVolume sets field value +func (o *UpdateSnapshotRequest) SetPermissionsToCreateVolume(v PermissionsOnResourceCreation) { + o.PermissionsToCreateVolume = v +} + +// GetSnapshotId returns the SnapshotId field value +func (o *UpdateSnapshotRequest) GetSnapshotId() string { + if o == nil { + var ret string + return ret + } + + return o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value +// and a boolean to check if the value has been set. +func (o *UpdateSnapshotRequest) GetSnapshotIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SnapshotId, true +} + +// SetSnapshotId sets field value +func (o *UpdateSnapshotRequest) SetSnapshotId(v string) { + o.SnapshotId = v +} + +func (o UpdateSnapshotRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["PermissionsToCreateVolume"] = o.PermissionsToCreateVolume + } + if true { + toSerialize["SnapshotId"] = o.SnapshotId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateSnapshotRequest struct { + value *UpdateSnapshotRequest + isSet bool +} + +func (v NullableUpdateSnapshotRequest) Get() *UpdateSnapshotRequest { + return v.value +} + +func (v *NullableUpdateSnapshotRequest) Set(val *UpdateSnapshotRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateSnapshotRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateSnapshotRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateSnapshotRequest(val *UpdateSnapshotRequest) *NullableUpdateSnapshotRequest { + return &NullableUpdateSnapshotRequest{value: val, isSet: true} +} + +func (v NullableUpdateSnapshotRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateSnapshotRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go new file mode 100644 index 000000000..46294db26 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateSnapshotResponse struct for UpdateSnapshotResponse +type UpdateSnapshotResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Snapshot *Snapshot `json:"Snapshot,omitempty"` +} + +// NewUpdateSnapshotResponse instantiates a new UpdateSnapshotResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateSnapshotResponse() *UpdateSnapshotResponse { + this := UpdateSnapshotResponse{} + return &this +} + +// NewUpdateSnapshotResponseWithDefaults instantiates a new UpdateSnapshotResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateSnapshotResponseWithDefaults() *UpdateSnapshotResponse { + this := UpdateSnapshotResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateSnapshotResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSnapshotResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateSnapshotResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateSnapshotResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSnapshot returns the Snapshot field value if set, zero value otherwise. +func (o *UpdateSnapshotResponse) GetSnapshot() Snapshot { + if o == nil || o.Snapshot == nil { + var ret Snapshot + return ret + } + return *o.Snapshot +} + +// GetSnapshotOk returns a tuple with the Snapshot field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSnapshotResponse) GetSnapshotOk() (*Snapshot, bool) { + if o == nil || o.Snapshot == nil { + return nil, false + } + return o.Snapshot, true +} + +// HasSnapshot returns a boolean if a field has been set. +func (o *UpdateSnapshotResponse) HasSnapshot() bool { + if o != nil && o.Snapshot != nil { + return true + } + + return false +} + +// SetSnapshot gets a reference to the given Snapshot and assigns it to the Snapshot field. +func (o *UpdateSnapshotResponse) SetSnapshot(v Snapshot) { + o.Snapshot = &v +} + +func (o UpdateSnapshotResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Snapshot != nil { + toSerialize["Snapshot"] = o.Snapshot + } + return json.Marshal(toSerialize) +} + +type NullableUpdateSnapshotResponse struct { + value *UpdateSnapshotResponse + isSet bool +} + +func (v NullableUpdateSnapshotResponse) Get() *UpdateSnapshotResponse { + return v.value +} + +func (v *NullableUpdateSnapshotResponse) Set(val *UpdateSnapshotResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateSnapshotResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateSnapshotResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateSnapshotResponse(val *UpdateSnapshotResponse) *NullableUpdateSnapshotResponse { + return &NullableUpdateSnapshotResponse{value: val, isSet: true} +} + +func (v NullableUpdateSnapshotResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateSnapshotResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go new file mode 100644 index 000000000..568e5b9e0 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go @@ -0,0 +1,177 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateSubnetRequest struct for UpdateSubnetRequest +type UpdateSubnetRequest struct { + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. + MapPublicIpOnLaunch bool `json:"MapPublicIpOnLaunch"` + // The ID of the Subnet. + SubnetId string `json:"SubnetId"` +} + +// NewUpdateSubnetRequest instantiates a new UpdateSubnetRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateSubnetRequest(mapPublicIpOnLaunch bool, subnetId string, ) *UpdateSubnetRequest { + this := UpdateSubnetRequest{} + this.MapPublicIpOnLaunch = mapPublicIpOnLaunch + this.SubnetId = subnetId + return &this +} + +// NewUpdateSubnetRequestWithDefaults instantiates a new UpdateSubnetRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateSubnetRequestWithDefaults() *UpdateSubnetRequest { + this := UpdateSubnetRequest{} + return &this +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateSubnetRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSubnetRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateSubnetRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateSubnetRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetMapPublicIpOnLaunch returns the MapPublicIpOnLaunch field value +func (o *UpdateSubnetRequest) GetMapPublicIpOnLaunch() bool { + if o == nil { + var ret bool + return ret + } + + return o.MapPublicIpOnLaunch +} + +// GetMapPublicIpOnLaunchOk returns a tuple with the MapPublicIpOnLaunch field value +// and a boolean to check if the value has been set. +func (o *UpdateSubnetRequest) GetMapPublicIpOnLaunchOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.MapPublicIpOnLaunch, true +} + +// SetMapPublicIpOnLaunch sets field value +func (o *UpdateSubnetRequest) SetMapPublicIpOnLaunch(v bool) { + o.MapPublicIpOnLaunch = v +} + +// GetSubnetId returns the SubnetId field value +func (o *UpdateSubnetRequest) GetSubnetId() string { + if o == nil { + var ret string + return ret + } + + return o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value +// and a boolean to check if the value has been set. +func (o *UpdateSubnetRequest) GetSubnetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.SubnetId, true +} + +// SetSubnetId sets field value +func (o *UpdateSubnetRequest) SetSubnetId(v string) { + o.SubnetId = v +} + +func (o UpdateSubnetRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if true { + toSerialize["MapPublicIpOnLaunch"] = o.MapPublicIpOnLaunch + } + if true { + toSerialize["SubnetId"] = o.SubnetId + } + return json.Marshal(toSerialize) +} + +type NullableUpdateSubnetRequest struct { + value *UpdateSubnetRequest + isSet bool +} + +func (v NullableUpdateSubnetRequest) Get() *UpdateSubnetRequest { + return v.value +} + +func (v *NullableUpdateSubnetRequest) Set(val *UpdateSubnetRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateSubnetRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateSubnetRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateSubnetRequest(val *UpdateSubnetRequest) *NullableUpdateSubnetRequest { + return &NullableUpdateSubnetRequest{value: val, isSet: true} +} + +func (v NullableUpdateSubnetRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateSubnetRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go new file mode 100644 index 000000000..99ae5e011 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateSubnetResponse struct for UpdateSubnetResponse +type UpdateSubnetResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Subnet *Subnet `json:"Subnet,omitempty"` +} + +// NewUpdateSubnetResponse instantiates a new UpdateSubnetResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateSubnetResponse() *UpdateSubnetResponse { + this := UpdateSubnetResponse{} + return &this +} + +// NewUpdateSubnetResponseWithDefaults instantiates a new UpdateSubnetResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateSubnetResponseWithDefaults() *UpdateSubnetResponse { + this := UpdateSubnetResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateSubnetResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSubnetResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateSubnetResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateSubnetResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetSubnet returns the Subnet field value if set, zero value otherwise. +func (o *UpdateSubnetResponse) GetSubnet() Subnet { + if o == nil || o.Subnet == nil { + var ret Subnet + return ret + } + return *o.Subnet +} + +// GetSubnetOk returns a tuple with the Subnet field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateSubnetResponse) GetSubnetOk() (*Subnet, bool) { + if o == nil || o.Subnet == nil { + return nil, false + } + return o.Subnet, true +} + +// HasSubnet returns a boolean if a field has been set. +func (o *UpdateSubnetResponse) HasSubnet() bool { + if o != nil && o.Subnet != nil { + return true + } + + return false +} + +// SetSubnet gets a reference to the given Subnet and assigns it to the Subnet field. +func (o *UpdateSubnetResponse) SetSubnet(v Subnet) { + o.Subnet = &v +} + +func (o UpdateSubnetResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Subnet != nil { + toSerialize["Subnet"] = o.Subnet + } + return json.Marshal(toSerialize) +} + +type NullableUpdateSubnetResponse struct { + value *UpdateSubnetResponse + isSet bool +} + +func (v NullableUpdateSubnetResponse) Get() *UpdateSubnetResponse { + return v.value +} + +func (v *NullableUpdateSubnetResponse) Set(val *UpdateSubnetResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateSubnetResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateSubnetResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateSubnetResponse(val *UpdateSubnetResponse) *NullableUpdateSubnetResponse { + return &NullableUpdateSubnetResponse{value: val, isSet: true} +} + +func (v NullableUpdateSubnetResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateSubnetResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go new file mode 100644 index 000000000..8bc363b79 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go @@ -0,0 +1,517 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateVmRequest struct for UpdateVmRequest +type UpdateVmRequest struct { + // One or more block device mappings of the VM. + BlockDeviceMappings *[]BlockDeviceMappingVmUpdate `json:"BlockDeviceMappings,omitempty"` + // If `true`, the VM is optimized for BSU I/O. + BsuOptimized *bool `json:"BsuOptimized,omitempty"` + // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. + DeletionProtection *bool `json:"DeletionProtection,omitempty"` + // If `true`, checks whether you have the required permissions to perform the action. + DryRun *bool `json:"DryRun,omitempty"` + // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` + // The name of the keypair.
To complete the replacement, manually replace the old public key with the new public key in the ~/.ssh/authorized_keys file located in the VM. Restart the VM to apply the change. + KeypairName *string `json:"KeypairName,omitempty"` + // The performance of the VM (`standard` \\| `high` \\| `highest`). + Performance *string `json:"Performance,omitempty"` + // One or more IDs of security groups for the VM. + SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` + // The Base64-encoded MIME user data. + UserData *string `json:"UserData,omitempty"` + // The ID of the VM. + VmId string `json:"VmId"` + // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. + VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` + // The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). + VmType *string `json:"VmType,omitempty"` +} + +// NewUpdateVmRequest instantiates a new UpdateVmRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateVmRequest(vmId string, ) *UpdateVmRequest { + this := UpdateVmRequest{} + this.VmId = vmId + return &this +} + +// NewUpdateVmRequestWithDefaults instantiates a new UpdateVmRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateVmRequestWithDefaults() *UpdateVmRequest { + this := UpdateVmRequest{} + return &this +} + +// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetBlockDeviceMappings() []BlockDeviceMappingVmUpdate { + if o == nil || o.BlockDeviceMappings == nil { + var ret []BlockDeviceMappingVmUpdate + return ret + } + return *o.BlockDeviceMappings +} + +// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetBlockDeviceMappingsOk() (*[]BlockDeviceMappingVmUpdate, bool) { + if o == nil || o.BlockDeviceMappings == nil { + return nil, false + } + return o.BlockDeviceMappings, true +} + +// HasBlockDeviceMappings returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasBlockDeviceMappings() bool { + if o != nil && o.BlockDeviceMappings != nil { + return true + } + + return false +} + +// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingVmUpdate and assigns it to the BlockDeviceMappings field. +func (o *UpdateVmRequest) SetBlockDeviceMappings(v []BlockDeviceMappingVmUpdate) { + o.BlockDeviceMappings = &v +} + +// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetBsuOptimized() bool { + if o == nil || o.BsuOptimized == nil { + var ret bool + return ret + } + return *o.BsuOptimized +} + +// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetBsuOptimizedOk() (*bool, bool) { + if o == nil || o.BsuOptimized == nil { + return nil, false + } + return o.BsuOptimized, true +} + +// HasBsuOptimized returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasBsuOptimized() bool { + if o != nil && o.BsuOptimized != nil { + return true + } + + return false +} + +// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. +func (o *UpdateVmRequest) SetBsuOptimized(v bool) { + o.BsuOptimized = &v +} + +// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetDeletionProtection() bool { + if o == nil || o.DeletionProtection == nil { + var ret bool + return ret + } + return *o.DeletionProtection +} + +// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetDeletionProtectionOk() (*bool, bool) { + if o == nil || o.DeletionProtection == nil { + return nil, false + } + return o.DeletionProtection, true +} + +// HasDeletionProtection returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasDeletionProtection() bool { + if o != nil && o.DeletionProtection != nil { + return true + } + + return false +} + +// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. +func (o *UpdateVmRequest) SetDeletionProtection(v bool) { + o.DeletionProtection = &v +} + +// GetDryRun returns the DryRun field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetDryRun() bool { + if o == nil || o.DryRun == nil { + var ret bool + return ret + } + return *o.DryRun +} + +// GetDryRunOk returns a tuple with the DryRun field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetDryRunOk() (*bool, bool) { + if o == nil || o.DryRun == nil { + return nil, false + } + return o.DryRun, true +} + +// HasDryRun returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasDryRun() bool { + if o != nil && o.DryRun != nil { + return true + } + + return false +} + +// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. +func (o *UpdateVmRequest) SetDryRun(v bool) { + o.DryRun = &v +} + +// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetIsSourceDestChecked() bool { + if o == nil || o.IsSourceDestChecked == nil { + var ret bool + return ret + } + return *o.IsSourceDestChecked +} + +// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetIsSourceDestCheckedOk() (*bool, bool) { + if o == nil || o.IsSourceDestChecked == nil { + return nil, false + } + return o.IsSourceDestChecked, true +} + +// HasIsSourceDestChecked returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasIsSourceDestChecked() bool { + if o != nil && o.IsSourceDestChecked != nil { + return true + } + + return false +} + +// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. +func (o *UpdateVmRequest) SetIsSourceDestChecked(v bool) { + o.IsSourceDestChecked = &v +} + +// GetKeypairName returns the KeypairName field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetKeypairName() string { + if o == nil || o.KeypairName == nil { + var ret string + return ret + } + return *o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetKeypairNameOk() (*string, bool) { + if o == nil || o.KeypairName == nil { + return nil, false + } + return o.KeypairName, true +} + +// HasKeypairName returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasKeypairName() bool { + if o != nil && o.KeypairName != nil { + return true + } + + return false +} + +// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. +func (o *UpdateVmRequest) SetKeypairName(v string) { + o.KeypairName = &v +} + +// GetPerformance returns the Performance field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetPerformance() string { + if o == nil || o.Performance == nil { + var ret string + return ret + } + return *o.Performance +} + +// GetPerformanceOk returns a tuple with the Performance field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetPerformanceOk() (*string, bool) { + if o == nil || o.Performance == nil { + return nil, false + } + return o.Performance, true +} + +// HasPerformance returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasPerformance() bool { + if o != nil && o.Performance != nil { + return true + } + + return false +} + +// SetPerformance gets a reference to the given string and assigns it to the Performance field. +func (o *UpdateVmRequest) SetPerformance(v string) { + o.Performance = &v +} + +// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetSecurityGroupIds() []string { + if o == nil || o.SecurityGroupIds == nil { + var ret []string + return ret + } + return *o.SecurityGroupIds +} + +// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetSecurityGroupIdsOk() (*[]string, bool) { + if o == nil || o.SecurityGroupIds == nil { + return nil, false + } + return o.SecurityGroupIds, true +} + +// HasSecurityGroupIds returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasSecurityGroupIds() bool { + if o != nil && o.SecurityGroupIds != nil { + return true + } + + return false +} + +// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. +func (o *UpdateVmRequest) SetSecurityGroupIds(v []string) { + o.SecurityGroupIds = &v +} + +// GetUserData returns the UserData field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetUserData() string { + if o == nil || o.UserData == nil { + var ret string + return ret + } + return *o.UserData +} + +// GetUserDataOk returns a tuple with the UserData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetUserDataOk() (*string, bool) { + if o == nil || o.UserData == nil { + return nil, false + } + return o.UserData, true +} + +// HasUserData returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasUserData() bool { + if o != nil && o.UserData != nil { + return true + } + + return false +} + +// SetUserData gets a reference to the given string and assigns it to the UserData field. +func (o *UpdateVmRequest) SetUserData(v string) { + o.UserData = &v +} + +// GetVmId returns the VmId field value +func (o *UpdateVmRequest) GetVmId() string { + if o == nil { + var ret string + return ret + } + + return o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetVmIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VmId, true +} + +// SetVmId sets field value +func (o *UpdateVmRequest) SetVmId(v string) { + o.VmId = v +} + +// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetVmInitiatedShutdownBehavior() string { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + var ret string + return ret + } + return *o.VmInitiatedShutdownBehavior +} + +// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetVmInitiatedShutdownBehaviorOk() (*string, bool) { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + return nil, false + } + return o.VmInitiatedShutdownBehavior, true +} + +// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasVmInitiatedShutdownBehavior() bool { + if o != nil && o.VmInitiatedShutdownBehavior != nil { + return true + } + + return false +} + +// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. +func (o *UpdateVmRequest) SetVmInitiatedShutdownBehavior(v string) { + o.VmInitiatedShutdownBehavior = &v +} + +// GetVmType returns the VmType field value if set, zero value otherwise. +func (o *UpdateVmRequest) GetVmType() string { + if o == nil || o.VmType == nil { + var ret string + return ret + } + return *o.VmType +} + +// GetVmTypeOk returns a tuple with the VmType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmRequest) GetVmTypeOk() (*string, bool) { + if o == nil || o.VmType == nil { + return nil, false + } + return o.VmType, true +} + +// HasVmType returns a boolean if a field has been set. +func (o *UpdateVmRequest) HasVmType() bool { + if o != nil && o.VmType != nil { + return true + } + + return false +} + +// SetVmType gets a reference to the given string and assigns it to the VmType field. +func (o *UpdateVmRequest) SetVmType(v string) { + o.VmType = &v +} + +func (o UpdateVmRequest) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BlockDeviceMappings != nil { + toSerialize["BlockDeviceMappings"] = o.BlockDeviceMappings + } + if o.BsuOptimized != nil { + toSerialize["BsuOptimized"] = o.BsuOptimized + } + if o.DeletionProtection != nil { + toSerialize["DeletionProtection"] = o.DeletionProtection + } + if o.DryRun != nil { + toSerialize["DryRun"] = o.DryRun + } + if o.IsSourceDestChecked != nil { + toSerialize["IsSourceDestChecked"] = o.IsSourceDestChecked + } + if o.KeypairName != nil { + toSerialize["KeypairName"] = o.KeypairName + } + if o.Performance != nil { + toSerialize["Performance"] = o.Performance + } + if o.SecurityGroupIds != nil { + toSerialize["SecurityGroupIds"] = o.SecurityGroupIds + } + if o.UserData != nil { + toSerialize["UserData"] = o.UserData + } + if true { + toSerialize["VmId"] = o.VmId + } + if o.VmInitiatedShutdownBehavior != nil { + toSerialize["VmInitiatedShutdownBehavior"] = o.VmInitiatedShutdownBehavior + } + if o.VmType != nil { + toSerialize["VmType"] = o.VmType + } + return json.Marshal(toSerialize) +} + +type NullableUpdateVmRequest struct { + value *UpdateVmRequest + isSet bool +} + +func (v NullableUpdateVmRequest) Get() *UpdateVmRequest { + return v.value +} + +func (v *NullableUpdateVmRequest) Set(val *UpdateVmRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateVmRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateVmRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateVmRequest(val *UpdateVmRequest) *NullableUpdateVmRequest { + return &NullableUpdateVmRequest{value: val, isSet: true} +} + +func (v NullableUpdateVmRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateVmRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go new file mode 100644 index 000000000..715485d4d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go @@ -0,0 +1,152 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// UpdateVmResponse struct for UpdateVmResponse +type UpdateVmResponse struct { + ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` + Vm *Vm `json:"Vm,omitempty"` +} + +// NewUpdateVmResponse instantiates a new UpdateVmResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateVmResponse() *UpdateVmResponse { + this := UpdateVmResponse{} + return &this +} + +// NewUpdateVmResponseWithDefaults instantiates a new UpdateVmResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateVmResponseWithDefaults() *UpdateVmResponse { + this := UpdateVmResponse{} + return &this +} + +// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. +func (o *UpdateVmResponse) GetResponseContext() ResponseContext { + if o == nil || o.ResponseContext == nil { + var ret ResponseContext + return ret + } + return *o.ResponseContext +} + +// GetResponseContextOk returns a tuple with the ResponseContext field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmResponse) GetResponseContextOk() (*ResponseContext, bool) { + if o == nil || o.ResponseContext == nil { + return nil, false + } + return o.ResponseContext, true +} + +// HasResponseContext returns a boolean if a field has been set. +func (o *UpdateVmResponse) HasResponseContext() bool { + if o != nil && o.ResponseContext != nil { + return true + } + + return false +} + +// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. +func (o *UpdateVmResponse) SetResponseContext(v ResponseContext) { + o.ResponseContext = &v +} + +// GetVm returns the Vm field value if set, zero value otherwise. +func (o *UpdateVmResponse) GetVm() Vm { + if o == nil || o.Vm == nil { + var ret Vm + return ret + } + return *o.Vm +} + +// GetVmOk returns a tuple with the Vm field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateVmResponse) GetVmOk() (*Vm, bool) { + if o == nil || o.Vm == nil { + return nil, false + } + return o.Vm, true +} + +// HasVm returns a boolean if a field has been set. +func (o *UpdateVmResponse) HasVm() bool { + if o != nil && o.Vm != nil { + return true + } + + return false +} + +// SetVm gets a reference to the given Vm and assigns it to the Vm field. +func (o *UpdateVmResponse) SetVm(v Vm) { + o.Vm = &v +} + +func (o UpdateVmResponse) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ResponseContext != nil { + toSerialize["ResponseContext"] = o.ResponseContext + } + if o.Vm != nil { + toSerialize["Vm"] = o.Vm + } + return json.Marshal(toSerialize) +} + +type NullableUpdateVmResponse struct { + value *UpdateVmResponse + isSet bool +} + +func (v NullableUpdateVmResponse) Get() *UpdateVmResponse { + return v.value +} + +func (v *NullableUpdateVmResponse) Set(val *UpdateVmResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateVmResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateVmResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateVmResponse(val *UpdateVmResponse) *NullableUpdateVmResponse { + return &NullableUpdateVmResponse{value: val, isSet: true} +} + +func (v NullableUpdateVmResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateVmResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go new file mode 100644 index 000000000..40b2cd4e5 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go @@ -0,0 +1,265 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// VirtualGateway Information about the virtual gateway. +type VirtualGateway struct { + // The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). + ConnectionType *string `json:"ConnectionType,omitempty"` + // The Net to which the virtual gateway is attached. + NetToVirtualGatewayLinks *[]NetToVirtualGatewayLink `json:"NetToVirtualGatewayLinks,omitempty"` + // The state of the virtual gateway (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` + // One or more tags associated with the virtual gateway. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the virtual gateway. + VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` +} + +// NewVirtualGateway instantiates a new VirtualGateway object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVirtualGateway() *VirtualGateway { + this := VirtualGateway{} + return &this +} + +// NewVirtualGatewayWithDefaults instantiates a new VirtualGateway object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVirtualGatewayWithDefaults() *VirtualGateway { + this := VirtualGateway{} + return &this +} + +// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. +func (o *VirtualGateway) GetConnectionType() string { + if o == nil || o.ConnectionType == nil { + var ret string + return ret + } + return *o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VirtualGateway) GetConnectionTypeOk() (*string, bool) { + if o == nil || o.ConnectionType == nil { + return nil, false + } + return o.ConnectionType, true +} + +// HasConnectionType returns a boolean if a field has been set. +func (o *VirtualGateway) HasConnectionType() bool { + if o != nil && o.ConnectionType != nil { + return true + } + + return false +} + +// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. +func (o *VirtualGateway) SetConnectionType(v string) { + o.ConnectionType = &v +} + +// GetNetToVirtualGatewayLinks returns the NetToVirtualGatewayLinks field value if set, zero value otherwise. +func (o *VirtualGateway) GetNetToVirtualGatewayLinks() []NetToVirtualGatewayLink { + if o == nil || o.NetToVirtualGatewayLinks == nil { + var ret []NetToVirtualGatewayLink + return ret + } + return *o.NetToVirtualGatewayLinks +} + +// GetNetToVirtualGatewayLinksOk returns a tuple with the NetToVirtualGatewayLinks field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VirtualGateway) GetNetToVirtualGatewayLinksOk() (*[]NetToVirtualGatewayLink, bool) { + if o == nil || o.NetToVirtualGatewayLinks == nil { + return nil, false + } + return o.NetToVirtualGatewayLinks, true +} + +// HasNetToVirtualGatewayLinks returns a boolean if a field has been set. +func (o *VirtualGateway) HasNetToVirtualGatewayLinks() bool { + if o != nil && o.NetToVirtualGatewayLinks != nil { + return true + } + + return false +} + +// SetNetToVirtualGatewayLinks gets a reference to the given []NetToVirtualGatewayLink and assigns it to the NetToVirtualGatewayLinks field. +func (o *VirtualGateway) SetNetToVirtualGatewayLinks(v []NetToVirtualGatewayLink) { + o.NetToVirtualGatewayLinks = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *VirtualGateway) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VirtualGateway) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *VirtualGateway) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *VirtualGateway) SetState(v string) { + o.State = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *VirtualGateway) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VirtualGateway) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *VirtualGateway) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *VirtualGateway) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. +func (o *VirtualGateway) GetVirtualGatewayId() string { + if o == nil || o.VirtualGatewayId == nil { + var ret string + return ret + } + return *o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VirtualGateway) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil || o.VirtualGatewayId == nil { + return nil, false + } + return o.VirtualGatewayId, true +} + +// HasVirtualGatewayId returns a boolean if a field has been set. +func (o *VirtualGateway) HasVirtualGatewayId() bool { + if o != nil && o.VirtualGatewayId != nil { + return true + } + + return false +} + +// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. +func (o *VirtualGateway) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = &v +} + +func (o VirtualGateway) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ConnectionType != nil { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.NetToVirtualGatewayLinks != nil { + toSerialize["NetToVirtualGatewayLinks"] = o.NetToVirtualGatewayLinks + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VirtualGatewayId != nil { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + return json.Marshal(toSerialize) +} + +type NullableVirtualGateway struct { + value *VirtualGateway + isSet bool +} + +func (v NullableVirtualGateway) Get() *VirtualGateway { + return v.value +} + +func (v *NullableVirtualGateway) Set(val *VirtualGateway) { + v.value = val + v.isSet = true +} + +func (v NullableVirtualGateway) IsSet() bool { + return v.isSet +} + +func (v *NullableVirtualGateway) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVirtualGateway(val *VirtualGateway) *NullableVirtualGateway { + return &NullableVirtualGateway{value: val, isSet: true} +} + +func (v NullableVirtualGateway) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVirtualGateway) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go new file mode 100644 index 000000000..da82c8698 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go @@ -0,0 +1,1263 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Vm Information about the VM. +type Vm struct { + // The architecture of the VM (`i386` \\| `x86_64`). + Architecture *string `json:"Architecture,omitempty"` + // The block device mapping of the VM. + BlockDeviceMappings *[]BlockDeviceMappingCreated `json:"BlockDeviceMappings,omitempty"` + // If `true`, the VM is optimized for BSU I/O. + BsuOptimized *bool `json:"BsuOptimized,omitempty"` + // The idempotency token provided when launching the VM. + ClientToken *string `json:"ClientToken,omitempty"` + // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. + DeletionProtection *bool `json:"DeletionProtection,omitempty"` + // The hypervisor type of the VMs (`ovm` \\| `xen`). + Hypervisor *string `json:"Hypervisor,omitempty"` + // The ID of the OMI used to create the VM. + ImageId *string `json:"ImageId,omitempty"` + // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` + // The name of the keypair used when launching the VM. + KeypairName *string `json:"KeypairName,omitempty"` + // The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). + LaunchNumber *int32 `json:"LaunchNumber,omitempty"` + // The ID of the Net in which the VM is running. + NetId *string `json:"NetId,omitempty"` + // The network interface cards (NICs) the VMs are attached to. + Nics *[]NicLight `json:"Nics,omitempty"` + // Indicates the operating system (OS) of the VM. + OsFamily *string `json:"OsFamily,omitempty"` + // The performance of the VM (`standard` \\| `high` \\| `highest`). + Performance *string `json:"Performance,omitempty"` + Placement *Placement `json:"Placement,omitempty"` + // The name of the private DNS. + PrivateDnsName *string `json:"PrivateDnsName,omitempty"` + // The primary private IP address of the VM. + PrivateIp *string `json:"PrivateIp,omitempty"` + // The product code associated with the OMI used to create the VM (`0001` Linux/Unix \\| `0002` Windows \\| `0004` Linux/Oracle \\| `0005` Windows 10). + ProductCodes *[]string `json:"ProductCodes,omitempty"` + // The name of the public DNS. + PublicDnsName *string `json:"PublicDnsName,omitempty"` + // The public IP address of the VM. + PublicIp *string `json:"PublicIp,omitempty"` + // The reservation ID of the VM. + ReservationId *string `json:"ReservationId,omitempty"` + // The name of the root device for the VM (for example, /dev/vda1). + RootDeviceName *string `json:"RootDeviceName,omitempty"` + // The type of root device used by the VM (always `bsu`). + RootDeviceType *string `json:"RootDeviceType,omitempty"` + // One or more security groups associated with the VM. + SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` + // The state of the VM (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). + State *string `json:"State,omitempty"` + // The reason explaining the current state of the VM. + StateReason *string `json:"StateReason,omitempty"` + // The ID of the Subnet for the VM. + SubnetId *string `json:"SubnetId,omitempty"` + // One or more tags associated with the VM. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The Base64-encoded MIME user data. + UserData *string `json:"UserData,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` + // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. + VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` + // The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). + VmType *string `json:"VmType,omitempty"` +} + +// NewVm instantiates a new Vm object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVm() *Vm { + this := Vm{} + return &this +} + +// NewVmWithDefaults instantiates a new Vm object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVmWithDefaults() *Vm { + this := Vm{} + return &this +} + +// GetArchitecture returns the Architecture field value if set, zero value otherwise. +func (o *Vm) GetArchitecture() string { + if o == nil || o.Architecture == nil { + var ret string + return ret + } + return *o.Architecture +} + +// GetArchitectureOk returns a tuple with the Architecture field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetArchitectureOk() (*string, bool) { + if o == nil || o.Architecture == nil { + return nil, false + } + return o.Architecture, true +} + +// HasArchitecture returns a boolean if a field has been set. +func (o *Vm) HasArchitecture() bool { + if o != nil && o.Architecture != nil { + return true + } + + return false +} + +// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. +func (o *Vm) SetArchitecture(v string) { + o.Architecture = &v +} + +// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. +func (o *Vm) GetBlockDeviceMappings() []BlockDeviceMappingCreated { + if o == nil || o.BlockDeviceMappings == nil { + var ret []BlockDeviceMappingCreated + return ret + } + return *o.BlockDeviceMappings +} + +// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetBlockDeviceMappingsOk() (*[]BlockDeviceMappingCreated, bool) { + if o == nil || o.BlockDeviceMappings == nil { + return nil, false + } + return o.BlockDeviceMappings, true +} + +// HasBlockDeviceMappings returns a boolean if a field has been set. +func (o *Vm) HasBlockDeviceMappings() bool { + if o != nil && o.BlockDeviceMappings != nil { + return true + } + + return false +} + +// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingCreated and assigns it to the BlockDeviceMappings field. +func (o *Vm) SetBlockDeviceMappings(v []BlockDeviceMappingCreated) { + o.BlockDeviceMappings = &v +} + +// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. +func (o *Vm) GetBsuOptimized() bool { + if o == nil || o.BsuOptimized == nil { + var ret bool + return ret + } + return *o.BsuOptimized +} + +// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetBsuOptimizedOk() (*bool, bool) { + if o == nil || o.BsuOptimized == nil { + return nil, false + } + return o.BsuOptimized, true +} + +// HasBsuOptimized returns a boolean if a field has been set. +func (o *Vm) HasBsuOptimized() bool { + if o != nil && o.BsuOptimized != nil { + return true + } + + return false +} + +// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. +func (o *Vm) SetBsuOptimized(v bool) { + o.BsuOptimized = &v +} + +// GetClientToken returns the ClientToken field value if set, zero value otherwise. +func (o *Vm) GetClientToken() string { + if o == nil || o.ClientToken == nil { + var ret string + return ret + } + return *o.ClientToken +} + +// GetClientTokenOk returns a tuple with the ClientToken field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetClientTokenOk() (*string, bool) { + if o == nil || o.ClientToken == nil { + return nil, false + } + return o.ClientToken, true +} + +// HasClientToken returns a boolean if a field has been set. +func (o *Vm) HasClientToken() bool { + if o != nil && o.ClientToken != nil { + return true + } + + return false +} + +// SetClientToken gets a reference to the given string and assigns it to the ClientToken field. +func (o *Vm) SetClientToken(v string) { + o.ClientToken = &v +} + +// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. +func (o *Vm) GetDeletionProtection() bool { + if o == nil || o.DeletionProtection == nil { + var ret bool + return ret + } + return *o.DeletionProtection +} + +// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetDeletionProtectionOk() (*bool, bool) { + if o == nil || o.DeletionProtection == nil { + return nil, false + } + return o.DeletionProtection, true +} + +// HasDeletionProtection returns a boolean if a field has been set. +func (o *Vm) HasDeletionProtection() bool { + if o != nil && o.DeletionProtection != nil { + return true + } + + return false +} + +// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. +func (o *Vm) SetDeletionProtection(v bool) { + o.DeletionProtection = &v +} + +// GetHypervisor returns the Hypervisor field value if set, zero value otherwise. +func (o *Vm) GetHypervisor() string { + if o == nil || o.Hypervisor == nil { + var ret string + return ret + } + return *o.Hypervisor +} + +// GetHypervisorOk returns a tuple with the Hypervisor field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetHypervisorOk() (*string, bool) { + if o == nil || o.Hypervisor == nil { + return nil, false + } + return o.Hypervisor, true +} + +// HasHypervisor returns a boolean if a field has been set. +func (o *Vm) HasHypervisor() bool { + if o != nil && o.Hypervisor != nil { + return true + } + + return false +} + +// SetHypervisor gets a reference to the given string and assigns it to the Hypervisor field. +func (o *Vm) SetHypervisor(v string) { + o.Hypervisor = &v +} + +// GetImageId returns the ImageId field value if set, zero value otherwise. +func (o *Vm) GetImageId() string { + if o == nil || o.ImageId == nil { + var ret string + return ret + } + return *o.ImageId +} + +// GetImageIdOk returns a tuple with the ImageId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetImageIdOk() (*string, bool) { + if o == nil || o.ImageId == nil { + return nil, false + } + return o.ImageId, true +} + +// HasImageId returns a boolean if a field has been set. +func (o *Vm) HasImageId() bool { + if o != nil && o.ImageId != nil { + return true + } + + return false +} + +// SetImageId gets a reference to the given string and assigns it to the ImageId field. +func (o *Vm) SetImageId(v string) { + o.ImageId = &v +} + +// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. +func (o *Vm) GetIsSourceDestChecked() bool { + if o == nil || o.IsSourceDestChecked == nil { + var ret bool + return ret + } + return *o.IsSourceDestChecked +} + +// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetIsSourceDestCheckedOk() (*bool, bool) { + if o == nil || o.IsSourceDestChecked == nil { + return nil, false + } + return o.IsSourceDestChecked, true +} + +// HasIsSourceDestChecked returns a boolean if a field has been set. +func (o *Vm) HasIsSourceDestChecked() bool { + if o != nil && o.IsSourceDestChecked != nil { + return true + } + + return false +} + +// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. +func (o *Vm) SetIsSourceDestChecked(v bool) { + o.IsSourceDestChecked = &v +} + +// GetKeypairName returns the KeypairName field value if set, zero value otherwise. +func (o *Vm) GetKeypairName() string { + if o == nil || o.KeypairName == nil { + var ret string + return ret + } + return *o.KeypairName +} + +// GetKeypairNameOk returns a tuple with the KeypairName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetKeypairNameOk() (*string, bool) { + if o == nil || o.KeypairName == nil { + return nil, false + } + return o.KeypairName, true +} + +// HasKeypairName returns a boolean if a field has been set. +func (o *Vm) HasKeypairName() bool { + if o != nil && o.KeypairName != nil { + return true + } + + return false +} + +// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. +func (o *Vm) SetKeypairName(v string) { + o.KeypairName = &v +} + +// GetLaunchNumber returns the LaunchNumber field value if set, zero value otherwise. +func (o *Vm) GetLaunchNumber() int32 { + if o == nil || o.LaunchNumber == nil { + var ret int32 + return ret + } + return *o.LaunchNumber +} + +// GetLaunchNumberOk returns a tuple with the LaunchNumber field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetLaunchNumberOk() (*int32, bool) { + if o == nil || o.LaunchNumber == nil { + return nil, false + } + return o.LaunchNumber, true +} + +// HasLaunchNumber returns a boolean if a field has been set. +func (o *Vm) HasLaunchNumber() bool { + if o != nil && o.LaunchNumber != nil { + return true + } + + return false +} + +// SetLaunchNumber gets a reference to the given int32 and assigns it to the LaunchNumber field. +func (o *Vm) SetLaunchNumber(v int32) { + o.LaunchNumber = &v +} + +// GetNetId returns the NetId field value if set, zero value otherwise. +func (o *Vm) GetNetId() string { + if o == nil || o.NetId == nil { + var ret string + return ret + } + return *o.NetId +} + +// GetNetIdOk returns a tuple with the NetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetNetIdOk() (*string, bool) { + if o == nil || o.NetId == nil { + return nil, false + } + return o.NetId, true +} + +// HasNetId returns a boolean if a field has been set. +func (o *Vm) HasNetId() bool { + if o != nil && o.NetId != nil { + return true + } + + return false +} + +// SetNetId gets a reference to the given string and assigns it to the NetId field. +func (o *Vm) SetNetId(v string) { + o.NetId = &v +} + +// GetNics returns the Nics field value if set, zero value otherwise. +func (o *Vm) GetNics() []NicLight { + if o == nil || o.Nics == nil { + var ret []NicLight + return ret + } + return *o.Nics +} + +// GetNicsOk returns a tuple with the Nics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetNicsOk() (*[]NicLight, bool) { + if o == nil || o.Nics == nil { + return nil, false + } + return o.Nics, true +} + +// HasNics returns a boolean if a field has been set. +func (o *Vm) HasNics() bool { + if o != nil && o.Nics != nil { + return true + } + + return false +} + +// SetNics gets a reference to the given []NicLight and assigns it to the Nics field. +func (o *Vm) SetNics(v []NicLight) { + o.Nics = &v +} + +// GetOsFamily returns the OsFamily field value if set, zero value otherwise. +func (o *Vm) GetOsFamily() string { + if o == nil || o.OsFamily == nil { + var ret string + return ret + } + return *o.OsFamily +} + +// GetOsFamilyOk returns a tuple with the OsFamily field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetOsFamilyOk() (*string, bool) { + if o == nil || o.OsFamily == nil { + return nil, false + } + return o.OsFamily, true +} + +// HasOsFamily returns a boolean if a field has been set. +func (o *Vm) HasOsFamily() bool { + if o != nil && o.OsFamily != nil { + return true + } + + return false +} + +// SetOsFamily gets a reference to the given string and assigns it to the OsFamily field. +func (o *Vm) SetOsFamily(v string) { + o.OsFamily = &v +} + +// GetPerformance returns the Performance field value if set, zero value otherwise. +func (o *Vm) GetPerformance() string { + if o == nil || o.Performance == nil { + var ret string + return ret + } + return *o.Performance +} + +// GetPerformanceOk returns a tuple with the Performance field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPerformanceOk() (*string, bool) { + if o == nil || o.Performance == nil { + return nil, false + } + return o.Performance, true +} + +// HasPerformance returns a boolean if a field has been set. +func (o *Vm) HasPerformance() bool { + if o != nil && o.Performance != nil { + return true + } + + return false +} + +// SetPerformance gets a reference to the given string and assigns it to the Performance field. +func (o *Vm) SetPerformance(v string) { + o.Performance = &v +} + +// GetPlacement returns the Placement field value if set, zero value otherwise. +func (o *Vm) GetPlacement() Placement { + if o == nil || o.Placement == nil { + var ret Placement + return ret + } + return *o.Placement +} + +// GetPlacementOk returns a tuple with the Placement field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPlacementOk() (*Placement, bool) { + if o == nil || o.Placement == nil { + return nil, false + } + return o.Placement, true +} + +// HasPlacement returns a boolean if a field has been set. +func (o *Vm) HasPlacement() bool { + if o != nil && o.Placement != nil { + return true + } + + return false +} + +// SetPlacement gets a reference to the given Placement and assigns it to the Placement field. +func (o *Vm) SetPlacement(v Placement) { + o.Placement = &v +} + +// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. +func (o *Vm) GetPrivateDnsName() string { + if o == nil || o.PrivateDnsName == nil { + var ret string + return ret + } + return *o.PrivateDnsName +} + +// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPrivateDnsNameOk() (*string, bool) { + if o == nil || o.PrivateDnsName == nil { + return nil, false + } + return o.PrivateDnsName, true +} + +// HasPrivateDnsName returns a boolean if a field has been set. +func (o *Vm) HasPrivateDnsName() bool { + if o != nil && o.PrivateDnsName != nil { + return true + } + + return false +} + +// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. +func (o *Vm) SetPrivateDnsName(v string) { + o.PrivateDnsName = &v +} + +// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. +func (o *Vm) GetPrivateIp() string { + if o == nil || o.PrivateIp == nil { + var ret string + return ret + } + return *o.PrivateIp +} + +// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPrivateIpOk() (*string, bool) { + if o == nil || o.PrivateIp == nil { + return nil, false + } + return o.PrivateIp, true +} + +// HasPrivateIp returns a boolean if a field has been set. +func (o *Vm) HasPrivateIp() bool { + if o != nil && o.PrivateIp != nil { + return true + } + + return false +} + +// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. +func (o *Vm) SetPrivateIp(v string) { + o.PrivateIp = &v +} + +// GetProductCodes returns the ProductCodes field value if set, zero value otherwise. +func (o *Vm) GetProductCodes() []string { + if o == nil || o.ProductCodes == nil { + var ret []string + return ret + } + return *o.ProductCodes +} + +// GetProductCodesOk returns a tuple with the ProductCodes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetProductCodesOk() (*[]string, bool) { + if o == nil || o.ProductCodes == nil { + return nil, false + } + return o.ProductCodes, true +} + +// HasProductCodes returns a boolean if a field has been set. +func (o *Vm) HasProductCodes() bool { + if o != nil && o.ProductCodes != nil { + return true + } + + return false +} + +// SetProductCodes gets a reference to the given []string and assigns it to the ProductCodes field. +func (o *Vm) SetProductCodes(v []string) { + o.ProductCodes = &v +} + +// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. +func (o *Vm) GetPublicDnsName() string { + if o == nil || o.PublicDnsName == nil { + var ret string + return ret + } + return *o.PublicDnsName +} + +// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPublicDnsNameOk() (*string, bool) { + if o == nil || o.PublicDnsName == nil { + return nil, false + } + return o.PublicDnsName, true +} + +// HasPublicDnsName returns a boolean if a field has been set. +func (o *Vm) HasPublicDnsName() bool { + if o != nil && o.PublicDnsName != nil { + return true + } + + return false +} + +// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. +func (o *Vm) SetPublicDnsName(v string) { + o.PublicDnsName = &v +} + +// GetPublicIp returns the PublicIp field value if set, zero value otherwise. +func (o *Vm) GetPublicIp() string { + if o == nil || o.PublicIp == nil { + var ret string + return ret + } + return *o.PublicIp +} + +// GetPublicIpOk returns a tuple with the PublicIp field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetPublicIpOk() (*string, bool) { + if o == nil || o.PublicIp == nil { + return nil, false + } + return o.PublicIp, true +} + +// HasPublicIp returns a boolean if a field has been set. +func (o *Vm) HasPublicIp() bool { + if o != nil && o.PublicIp != nil { + return true + } + + return false +} + +// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. +func (o *Vm) SetPublicIp(v string) { + o.PublicIp = &v +} + +// GetReservationId returns the ReservationId field value if set, zero value otherwise. +func (o *Vm) GetReservationId() string { + if o == nil || o.ReservationId == nil { + var ret string + return ret + } + return *o.ReservationId +} + +// GetReservationIdOk returns a tuple with the ReservationId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetReservationIdOk() (*string, bool) { + if o == nil || o.ReservationId == nil { + return nil, false + } + return o.ReservationId, true +} + +// HasReservationId returns a boolean if a field has been set. +func (o *Vm) HasReservationId() bool { + if o != nil && o.ReservationId != nil { + return true + } + + return false +} + +// SetReservationId gets a reference to the given string and assigns it to the ReservationId field. +func (o *Vm) SetReservationId(v string) { + o.ReservationId = &v +} + +// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. +func (o *Vm) GetRootDeviceName() string { + if o == nil || o.RootDeviceName == nil { + var ret string + return ret + } + return *o.RootDeviceName +} + +// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetRootDeviceNameOk() (*string, bool) { + if o == nil || o.RootDeviceName == nil { + return nil, false + } + return o.RootDeviceName, true +} + +// HasRootDeviceName returns a boolean if a field has been set. +func (o *Vm) HasRootDeviceName() bool { + if o != nil && o.RootDeviceName != nil { + return true + } + + return false +} + +// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. +func (o *Vm) SetRootDeviceName(v string) { + o.RootDeviceName = &v +} + +// GetRootDeviceType returns the RootDeviceType field value if set, zero value otherwise. +func (o *Vm) GetRootDeviceType() string { + if o == nil || o.RootDeviceType == nil { + var ret string + return ret + } + return *o.RootDeviceType +} + +// GetRootDeviceTypeOk returns a tuple with the RootDeviceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetRootDeviceTypeOk() (*string, bool) { + if o == nil || o.RootDeviceType == nil { + return nil, false + } + return o.RootDeviceType, true +} + +// HasRootDeviceType returns a boolean if a field has been set. +func (o *Vm) HasRootDeviceType() bool { + if o != nil && o.RootDeviceType != nil { + return true + } + + return false +} + +// SetRootDeviceType gets a reference to the given string and assigns it to the RootDeviceType field. +func (o *Vm) SetRootDeviceType(v string) { + o.RootDeviceType = &v +} + +// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. +func (o *Vm) GetSecurityGroups() []SecurityGroupLight { + if o == nil || o.SecurityGroups == nil { + var ret []SecurityGroupLight + return ret + } + return *o.SecurityGroups +} + +// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetSecurityGroupsOk() (*[]SecurityGroupLight, bool) { + if o == nil || o.SecurityGroups == nil { + return nil, false + } + return o.SecurityGroups, true +} + +// HasSecurityGroups returns a boolean if a field has been set. +func (o *Vm) HasSecurityGroups() bool { + if o != nil && o.SecurityGroups != nil { + return true + } + + return false +} + +// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. +func (o *Vm) SetSecurityGroups(v []SecurityGroupLight) { + o.SecurityGroups = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Vm) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Vm) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Vm) SetState(v string) { + o.State = &v +} + +// GetStateReason returns the StateReason field value if set, zero value otherwise. +func (o *Vm) GetStateReason() string { + if o == nil || o.StateReason == nil { + var ret string + return ret + } + return *o.StateReason +} + +// GetStateReasonOk returns a tuple with the StateReason field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetStateReasonOk() (*string, bool) { + if o == nil || o.StateReason == nil { + return nil, false + } + return o.StateReason, true +} + +// HasStateReason returns a boolean if a field has been set. +func (o *Vm) HasStateReason() bool { + if o != nil && o.StateReason != nil { + return true + } + + return false +} + +// SetStateReason gets a reference to the given string and assigns it to the StateReason field. +func (o *Vm) SetStateReason(v string) { + o.StateReason = &v +} + +// GetSubnetId returns the SubnetId field value if set, zero value otherwise. +func (o *Vm) GetSubnetId() string { + if o == nil || o.SubnetId == nil { + var ret string + return ret + } + return *o.SubnetId +} + +// GetSubnetIdOk returns a tuple with the SubnetId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetSubnetIdOk() (*string, bool) { + if o == nil || o.SubnetId == nil { + return nil, false + } + return o.SubnetId, true +} + +// HasSubnetId returns a boolean if a field has been set. +func (o *Vm) HasSubnetId() bool { + if o != nil && o.SubnetId != nil { + return true + } + + return false +} + +// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. +func (o *Vm) SetSubnetId(v string) { + o.SubnetId = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Vm) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Vm) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Vm) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetUserData returns the UserData field value if set, zero value otherwise. +func (o *Vm) GetUserData() string { + if o == nil || o.UserData == nil { + var ret string + return ret + } + return *o.UserData +} + +// GetUserDataOk returns a tuple with the UserData field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetUserDataOk() (*string, bool) { + if o == nil || o.UserData == nil { + return nil, false + } + return o.UserData, true +} + +// HasUserData returns a boolean if a field has been set. +func (o *Vm) HasUserData() bool { + if o != nil && o.UserData != nil { + return true + } + + return false +} + +// SetUserData gets a reference to the given string and assigns it to the UserData field. +func (o *Vm) SetUserData(v string) { + o.UserData = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *Vm) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *Vm) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *Vm) SetVmId(v string) { + o.VmId = &v +} + +// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. +func (o *Vm) GetVmInitiatedShutdownBehavior() string { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + var ret string + return ret + } + return *o.VmInitiatedShutdownBehavior +} + +// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetVmInitiatedShutdownBehaviorOk() (*string, bool) { + if o == nil || o.VmInitiatedShutdownBehavior == nil { + return nil, false + } + return o.VmInitiatedShutdownBehavior, true +} + +// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. +func (o *Vm) HasVmInitiatedShutdownBehavior() bool { + if o != nil && o.VmInitiatedShutdownBehavior != nil { + return true + } + + return false +} + +// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. +func (o *Vm) SetVmInitiatedShutdownBehavior(v string) { + o.VmInitiatedShutdownBehavior = &v +} + +// GetVmType returns the VmType field value if set, zero value otherwise. +func (o *Vm) GetVmType() string { + if o == nil || o.VmType == nil { + var ret string + return ret + } + return *o.VmType +} + +// GetVmTypeOk returns a tuple with the VmType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Vm) GetVmTypeOk() (*string, bool) { + if o == nil || o.VmType == nil { + return nil, false + } + return o.VmType, true +} + +// HasVmType returns a boolean if a field has been set. +func (o *Vm) HasVmType() bool { + if o != nil && o.VmType != nil { + return true + } + + return false +} + +// SetVmType gets a reference to the given string and assigns it to the VmType field. +func (o *Vm) SetVmType(v string) { + o.VmType = &v +} + +func (o Vm) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Architecture != nil { + toSerialize["Architecture"] = o.Architecture + } + if o.BlockDeviceMappings != nil { + toSerialize["BlockDeviceMappings"] = o.BlockDeviceMappings + } + if o.BsuOptimized != nil { + toSerialize["BsuOptimized"] = o.BsuOptimized + } + if o.ClientToken != nil { + toSerialize["ClientToken"] = o.ClientToken + } + if o.DeletionProtection != nil { + toSerialize["DeletionProtection"] = o.DeletionProtection + } + if o.Hypervisor != nil { + toSerialize["Hypervisor"] = o.Hypervisor + } + if o.ImageId != nil { + toSerialize["ImageId"] = o.ImageId + } + if o.IsSourceDestChecked != nil { + toSerialize["IsSourceDestChecked"] = o.IsSourceDestChecked + } + if o.KeypairName != nil { + toSerialize["KeypairName"] = o.KeypairName + } + if o.LaunchNumber != nil { + toSerialize["LaunchNumber"] = o.LaunchNumber + } + if o.NetId != nil { + toSerialize["NetId"] = o.NetId + } + if o.Nics != nil { + toSerialize["Nics"] = o.Nics + } + if o.OsFamily != nil { + toSerialize["OsFamily"] = o.OsFamily + } + if o.Performance != nil { + toSerialize["Performance"] = o.Performance + } + if o.Placement != nil { + toSerialize["Placement"] = o.Placement + } + if o.PrivateDnsName != nil { + toSerialize["PrivateDnsName"] = o.PrivateDnsName + } + if o.PrivateIp != nil { + toSerialize["PrivateIp"] = o.PrivateIp + } + if o.ProductCodes != nil { + toSerialize["ProductCodes"] = o.ProductCodes + } + if o.PublicDnsName != nil { + toSerialize["PublicDnsName"] = o.PublicDnsName + } + if o.PublicIp != nil { + toSerialize["PublicIp"] = o.PublicIp + } + if o.ReservationId != nil { + toSerialize["ReservationId"] = o.ReservationId + } + if o.RootDeviceName != nil { + toSerialize["RootDeviceName"] = o.RootDeviceName + } + if o.RootDeviceType != nil { + toSerialize["RootDeviceType"] = o.RootDeviceType + } + if o.SecurityGroups != nil { + toSerialize["SecurityGroups"] = o.SecurityGroups + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.StateReason != nil { + toSerialize["StateReason"] = o.StateReason + } + if o.SubnetId != nil { + toSerialize["SubnetId"] = o.SubnetId + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.UserData != nil { + toSerialize["UserData"] = o.UserData + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + if o.VmInitiatedShutdownBehavior != nil { + toSerialize["VmInitiatedShutdownBehavior"] = o.VmInitiatedShutdownBehavior + } + if o.VmType != nil { + toSerialize["VmType"] = o.VmType + } + return json.Marshal(toSerialize) +} + +type NullableVm struct { + value *Vm + isSet bool +} + +func (v NullableVm) Get() *Vm { + return v.value +} + +func (v *NullableVm) Set(val *Vm) { + v.value = val + v.isSet = true +} + +func (v NullableVm) IsSet() bool { + return v.isSet +} + +func (v *NullableVm) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVm(val *Vm) *NullableVm { + return &NullableVm{value: val, isSet: true} +} + +func (v NullableVm) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVm) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go new file mode 100644 index 000000000..c4626eacd --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go @@ -0,0 +1,191 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// VmState Information about the state of the VM. +type VmState struct { + // The current state of the VM (`InService` \\| `OutOfService` \\| `Unknown`). + CurrentState *string `json:"CurrentState,omitempty"` + // The previous state of the VM (`InService` \\| `OutOfService` \\| `Unknown`). + PreviousState *string `json:"PreviousState,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` +} + +// NewVmState instantiates a new VmState object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVmState() *VmState { + this := VmState{} + return &this +} + +// NewVmStateWithDefaults instantiates a new VmState object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVmStateWithDefaults() *VmState { + this := VmState{} + return &this +} + +// GetCurrentState returns the CurrentState field value if set, zero value otherwise. +func (o *VmState) GetCurrentState() string { + if o == nil || o.CurrentState == nil { + var ret string + return ret + } + return *o.CurrentState +} + +// GetCurrentStateOk returns a tuple with the CurrentState field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmState) GetCurrentStateOk() (*string, bool) { + if o == nil || o.CurrentState == nil { + return nil, false + } + return o.CurrentState, true +} + +// HasCurrentState returns a boolean if a field has been set. +func (o *VmState) HasCurrentState() bool { + if o != nil && o.CurrentState != nil { + return true + } + + return false +} + +// SetCurrentState gets a reference to the given string and assigns it to the CurrentState field. +func (o *VmState) SetCurrentState(v string) { + o.CurrentState = &v +} + +// GetPreviousState returns the PreviousState field value if set, zero value otherwise. +func (o *VmState) GetPreviousState() string { + if o == nil || o.PreviousState == nil { + var ret string + return ret + } + return *o.PreviousState +} + +// GetPreviousStateOk returns a tuple with the PreviousState field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmState) GetPreviousStateOk() (*string, bool) { + if o == nil || o.PreviousState == nil { + return nil, false + } + return o.PreviousState, true +} + +// HasPreviousState returns a boolean if a field has been set. +func (o *VmState) HasPreviousState() bool { + if o != nil && o.PreviousState != nil { + return true + } + + return false +} + +// SetPreviousState gets a reference to the given string and assigns it to the PreviousState field. +func (o *VmState) SetPreviousState(v string) { + o.PreviousState = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *VmState) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmState) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *VmState) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *VmState) SetVmId(v string) { + o.VmId = &v +} + +func (o VmState) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.CurrentState != nil { + toSerialize["CurrentState"] = o.CurrentState + } + if o.PreviousState != nil { + toSerialize["PreviousState"] = o.PreviousState + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + return json.Marshal(toSerialize) +} + +type NullableVmState struct { + value *VmState + isSet bool +} + +func (v NullableVmState) Get() *VmState { + return v.value +} + +func (v *NullableVmState) Set(val *VmState) { + v.value = val + v.isSet = true +} + +func (v NullableVmState) IsSet() bool { + return v.isSet +} + +func (v *NullableVmState) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVmState(val *VmState) *NullableVmState { + return &NullableVmState{value: val, isSet: true} +} + +func (v NullableVmState) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVmState) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go new file mode 100644 index 000000000..f14a8ba11 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go @@ -0,0 +1,228 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// VmStates Information about the states of the VMs. +type VmStates struct { + // One or more scheduled events associated with the VM. + MaintenanceEvents *[]MaintenanceEvent `json:"MaintenanceEvents,omitempty"` + // The name of the Subregion of the VM. + SubregionName *string `json:"SubregionName,omitempty"` + // The ID of the VM. + VmId *string `json:"VmId,omitempty"` + // The state of the VM (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). + VmState *string `json:"VmState,omitempty"` +} + +// NewVmStates instantiates a new VmStates object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVmStates() *VmStates { + this := VmStates{} + return &this +} + +// NewVmStatesWithDefaults instantiates a new VmStates object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVmStatesWithDefaults() *VmStates { + this := VmStates{} + return &this +} + +// GetMaintenanceEvents returns the MaintenanceEvents field value if set, zero value otherwise. +func (o *VmStates) GetMaintenanceEvents() []MaintenanceEvent { + if o == nil || o.MaintenanceEvents == nil { + var ret []MaintenanceEvent + return ret + } + return *o.MaintenanceEvents +} + +// GetMaintenanceEventsOk returns a tuple with the MaintenanceEvents field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmStates) GetMaintenanceEventsOk() (*[]MaintenanceEvent, bool) { + if o == nil || o.MaintenanceEvents == nil { + return nil, false + } + return o.MaintenanceEvents, true +} + +// HasMaintenanceEvents returns a boolean if a field has been set. +func (o *VmStates) HasMaintenanceEvents() bool { + if o != nil && o.MaintenanceEvents != nil { + return true + } + + return false +} + +// SetMaintenanceEvents gets a reference to the given []MaintenanceEvent and assigns it to the MaintenanceEvents field. +func (o *VmStates) SetMaintenanceEvents(v []MaintenanceEvent) { + o.MaintenanceEvents = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *VmStates) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmStates) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *VmStates) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *VmStates) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetVmId returns the VmId field value if set, zero value otherwise. +func (o *VmStates) GetVmId() string { + if o == nil || o.VmId == nil { + var ret string + return ret + } + return *o.VmId +} + +// GetVmIdOk returns a tuple with the VmId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmStates) GetVmIdOk() (*string, bool) { + if o == nil || o.VmId == nil { + return nil, false + } + return o.VmId, true +} + +// HasVmId returns a boolean if a field has been set. +func (o *VmStates) HasVmId() bool { + if o != nil && o.VmId != nil { + return true + } + + return false +} + +// SetVmId gets a reference to the given string and assigns it to the VmId field. +func (o *VmStates) SetVmId(v string) { + o.VmId = &v +} + +// GetVmState returns the VmState field value if set, zero value otherwise. +func (o *VmStates) GetVmState() string { + if o == nil || o.VmState == nil { + var ret string + return ret + } + return *o.VmState +} + +// GetVmStateOk returns a tuple with the VmState field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmStates) GetVmStateOk() (*string, bool) { + if o == nil || o.VmState == nil { + return nil, false + } + return o.VmState, true +} + +// HasVmState returns a boolean if a field has been set. +func (o *VmStates) HasVmState() bool { + if o != nil && o.VmState != nil { + return true + } + + return false +} + +// SetVmState gets a reference to the given string and assigns it to the VmState field. +func (o *VmStates) SetVmState(v string) { + o.VmState = &v +} + +func (o VmStates) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.MaintenanceEvents != nil { + toSerialize["MaintenanceEvents"] = o.MaintenanceEvents + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.VmId != nil { + toSerialize["VmId"] = o.VmId + } + if o.VmState != nil { + toSerialize["VmState"] = o.VmState + } + return json.Marshal(toSerialize) +} + +type NullableVmStates struct { + value *VmStates + isSet bool +} + +func (v NullableVmStates) Get() *VmStates { + return v.value +} + +func (v *NullableVmStates) Set(val *VmStates) { + v.value = val + v.isSet = true +} + +func (v NullableVmStates) IsSet() bool { + return v.isSet +} + +func (v *NullableVmStates) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVmStates(val *VmStates) *NullableVmStates { + return &NullableVmStates{value: val, isSet: true} +} + +func (v NullableVmStates) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVmStates) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go new file mode 100644 index 000000000..2e71a7304 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go @@ -0,0 +1,339 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// VmType Information about the VM type. +type VmType struct { + // Indicates whether the VM is optimized for BSU I/O. + BsuOptimized *bool `json:"BsuOptimized,omitempty"` + // The maximum number of private IP addresses per network interface card (NIC). + MaxPrivateIps *int32 `json:"MaxPrivateIps,omitempty"` + // The amount of memory, in gibibytes. + MemorySize *float32 `json:"MemorySize,omitempty"` + // The number of vCores. + VcoreCount *int32 `json:"VcoreCount,omitempty"` + // The name of the VM type. + VmTypeName *string `json:"VmTypeName,omitempty"` + // The maximum number of ephemeral storage disks. + VolumeCount *int32 `json:"VolumeCount,omitempty"` + // The size of one ephemeral storage disk, in gibibytes (GiB). + VolumeSize *int32 `json:"VolumeSize,omitempty"` +} + +// NewVmType instantiates a new VmType object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVmType() *VmType { + this := VmType{} + return &this +} + +// NewVmTypeWithDefaults instantiates a new VmType object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVmTypeWithDefaults() *VmType { + this := VmType{} + return &this +} + +// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. +func (o *VmType) GetBsuOptimized() bool { + if o == nil || o.BsuOptimized == nil { + var ret bool + return ret + } + return *o.BsuOptimized +} + +// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetBsuOptimizedOk() (*bool, bool) { + if o == nil || o.BsuOptimized == nil { + return nil, false + } + return o.BsuOptimized, true +} + +// HasBsuOptimized returns a boolean if a field has been set. +func (o *VmType) HasBsuOptimized() bool { + if o != nil && o.BsuOptimized != nil { + return true + } + + return false +} + +// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. +func (o *VmType) SetBsuOptimized(v bool) { + o.BsuOptimized = &v +} + +// GetMaxPrivateIps returns the MaxPrivateIps field value if set, zero value otherwise. +func (o *VmType) GetMaxPrivateIps() int32 { + if o == nil || o.MaxPrivateIps == nil { + var ret int32 + return ret + } + return *o.MaxPrivateIps +} + +// GetMaxPrivateIpsOk returns a tuple with the MaxPrivateIps field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetMaxPrivateIpsOk() (*int32, bool) { + if o == nil || o.MaxPrivateIps == nil { + return nil, false + } + return o.MaxPrivateIps, true +} + +// HasMaxPrivateIps returns a boolean if a field has been set. +func (o *VmType) HasMaxPrivateIps() bool { + if o != nil && o.MaxPrivateIps != nil { + return true + } + + return false +} + +// SetMaxPrivateIps gets a reference to the given int32 and assigns it to the MaxPrivateIps field. +func (o *VmType) SetMaxPrivateIps(v int32) { + o.MaxPrivateIps = &v +} + +// GetMemorySize returns the MemorySize field value if set, zero value otherwise. +func (o *VmType) GetMemorySize() float32 { + if o == nil || o.MemorySize == nil { + var ret float32 + return ret + } + return *o.MemorySize +} + +// GetMemorySizeOk returns a tuple with the MemorySize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetMemorySizeOk() (*float32, bool) { + if o == nil || o.MemorySize == nil { + return nil, false + } + return o.MemorySize, true +} + +// HasMemorySize returns a boolean if a field has been set. +func (o *VmType) HasMemorySize() bool { + if o != nil && o.MemorySize != nil { + return true + } + + return false +} + +// SetMemorySize gets a reference to the given float32 and assigns it to the MemorySize field. +func (o *VmType) SetMemorySize(v float32) { + o.MemorySize = &v +} + +// GetVcoreCount returns the VcoreCount field value if set, zero value otherwise. +func (o *VmType) GetVcoreCount() int32 { + if o == nil || o.VcoreCount == nil { + var ret int32 + return ret + } + return *o.VcoreCount +} + +// GetVcoreCountOk returns a tuple with the VcoreCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetVcoreCountOk() (*int32, bool) { + if o == nil || o.VcoreCount == nil { + return nil, false + } + return o.VcoreCount, true +} + +// HasVcoreCount returns a boolean if a field has been set. +func (o *VmType) HasVcoreCount() bool { + if o != nil && o.VcoreCount != nil { + return true + } + + return false +} + +// SetVcoreCount gets a reference to the given int32 and assigns it to the VcoreCount field. +func (o *VmType) SetVcoreCount(v int32) { + o.VcoreCount = &v +} + +// GetVmTypeName returns the VmTypeName field value if set, zero value otherwise. +func (o *VmType) GetVmTypeName() string { + if o == nil || o.VmTypeName == nil { + var ret string + return ret + } + return *o.VmTypeName +} + +// GetVmTypeNameOk returns a tuple with the VmTypeName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetVmTypeNameOk() (*string, bool) { + if o == nil || o.VmTypeName == nil { + return nil, false + } + return o.VmTypeName, true +} + +// HasVmTypeName returns a boolean if a field has been set. +func (o *VmType) HasVmTypeName() bool { + if o != nil && o.VmTypeName != nil { + return true + } + + return false +} + +// SetVmTypeName gets a reference to the given string and assigns it to the VmTypeName field. +func (o *VmType) SetVmTypeName(v string) { + o.VmTypeName = &v +} + +// GetVolumeCount returns the VolumeCount field value if set, zero value otherwise. +func (o *VmType) GetVolumeCount() int32 { + if o == nil || o.VolumeCount == nil { + var ret int32 + return ret + } + return *o.VolumeCount +} + +// GetVolumeCountOk returns a tuple with the VolumeCount field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetVolumeCountOk() (*int32, bool) { + if o == nil || o.VolumeCount == nil { + return nil, false + } + return o.VolumeCount, true +} + +// HasVolumeCount returns a boolean if a field has been set. +func (o *VmType) HasVolumeCount() bool { + if o != nil && o.VolumeCount != nil { + return true + } + + return false +} + +// SetVolumeCount gets a reference to the given int32 and assigns it to the VolumeCount field. +func (o *VmType) SetVolumeCount(v int32) { + o.VolumeCount = &v +} + +// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. +func (o *VmType) GetVolumeSize() int32 { + if o == nil || o.VolumeSize == nil { + var ret int32 + return ret + } + return *o.VolumeSize +} + +// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VmType) GetVolumeSizeOk() (*int32, bool) { + if o == nil || o.VolumeSize == nil { + return nil, false + } + return o.VolumeSize, true +} + +// HasVolumeSize returns a boolean if a field has been set. +func (o *VmType) HasVolumeSize() bool { + if o != nil && o.VolumeSize != nil { + return true + } + + return false +} + +// SetVolumeSize gets a reference to the given int32 and assigns it to the VolumeSize field. +func (o *VmType) SetVolumeSize(v int32) { + o.VolumeSize = &v +} + +func (o VmType) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.BsuOptimized != nil { + toSerialize["BsuOptimized"] = o.BsuOptimized + } + if o.MaxPrivateIps != nil { + toSerialize["MaxPrivateIps"] = o.MaxPrivateIps + } + if o.MemorySize != nil { + toSerialize["MemorySize"] = o.MemorySize + } + if o.VcoreCount != nil { + toSerialize["VcoreCount"] = o.VcoreCount + } + if o.VmTypeName != nil { + toSerialize["VmTypeName"] = o.VmTypeName + } + if o.VolumeCount != nil { + toSerialize["VolumeCount"] = o.VolumeCount + } + if o.VolumeSize != nil { + toSerialize["VolumeSize"] = o.VolumeSize + } + return json.Marshal(toSerialize) +} + +type NullableVmType struct { + value *VmType + isSet bool +} + +func (v NullableVmType) Get() *VmType { + return v.value +} + +func (v *NullableVmType) Set(val *VmType) { + v.value = val + v.isSet = true +} + +func (v NullableVmType) IsSet() bool { + return v.isSet +} + +func (v *NullableVmType) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVmType(val *VmType) *NullableVmType { + return &NullableVmType{value: val, isSet: true} +} + +func (v NullableVmType) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVmType) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go new file mode 100644 index 000000000..ef88c0581 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go @@ -0,0 +1,413 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// Volume Information about the volume. +type Volume struct { + // The number of I/O operations per second (IOPS):
- For `io1` volumes, the number of provisioned IOPS
- For `gp2` volumes, the baseline performance of the volume + Iops *int32 `json:"Iops,omitempty"` + // Information about your volume attachment. + LinkedVolumes *[]LinkedVolume `json:"LinkedVolumes,omitempty"` + // The size of the volume, in gibibytes (GiB). + Size *int32 `json:"Size,omitempty"` + // The snapshot from which the volume was created. + SnapshotId *string `json:"SnapshotId,omitempty"` + // The state of the volume (`creating` \\| `available` \\| `in-use` \\| `deleting` \\| `error`). + State *string `json:"State,omitempty"` + // The Subregion in which the volume was created. + SubregionName *string `json:"SubregionName,omitempty"` + // One or more tags associated with the volume. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the volume. + VolumeId *string `json:"VolumeId,omitempty"` + // The type of the volume (`standard` \\| `gp2` \\| `io1`). + VolumeType *string `json:"VolumeType,omitempty"` +} + +// NewVolume instantiates a new Volume object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVolume() *Volume { + this := Volume{} + return &this +} + +// NewVolumeWithDefaults instantiates a new Volume object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVolumeWithDefaults() *Volume { + this := Volume{} + return &this +} + +// GetIops returns the Iops field value if set, zero value otherwise. +func (o *Volume) GetIops() int32 { + if o == nil || o.Iops == nil { + var ret int32 + return ret + } + return *o.Iops +} + +// GetIopsOk returns a tuple with the Iops field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetIopsOk() (*int32, bool) { + if o == nil || o.Iops == nil { + return nil, false + } + return o.Iops, true +} + +// HasIops returns a boolean if a field has been set. +func (o *Volume) HasIops() bool { + if o != nil && o.Iops != nil { + return true + } + + return false +} + +// SetIops gets a reference to the given int32 and assigns it to the Iops field. +func (o *Volume) SetIops(v int32) { + o.Iops = &v +} + +// GetLinkedVolumes returns the LinkedVolumes field value if set, zero value otherwise. +func (o *Volume) GetLinkedVolumes() []LinkedVolume { + if o == nil || o.LinkedVolumes == nil { + var ret []LinkedVolume + return ret + } + return *o.LinkedVolumes +} + +// GetLinkedVolumesOk returns a tuple with the LinkedVolumes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetLinkedVolumesOk() (*[]LinkedVolume, bool) { + if o == nil || o.LinkedVolumes == nil { + return nil, false + } + return o.LinkedVolumes, true +} + +// HasLinkedVolumes returns a boolean if a field has been set. +func (o *Volume) HasLinkedVolumes() bool { + if o != nil && o.LinkedVolumes != nil { + return true + } + + return false +} + +// SetLinkedVolumes gets a reference to the given []LinkedVolume and assigns it to the LinkedVolumes field. +func (o *Volume) SetLinkedVolumes(v []LinkedVolume) { + o.LinkedVolumes = &v +} + +// GetSize returns the Size field value if set, zero value otherwise. +func (o *Volume) GetSize() int32 { + if o == nil || o.Size == nil { + var ret int32 + return ret + } + return *o.Size +} + +// GetSizeOk returns a tuple with the Size field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetSizeOk() (*int32, bool) { + if o == nil || o.Size == nil { + return nil, false + } + return o.Size, true +} + +// HasSize returns a boolean if a field has been set. +func (o *Volume) HasSize() bool { + if o != nil && o.Size != nil { + return true + } + + return false +} + +// SetSize gets a reference to the given int32 and assigns it to the Size field. +func (o *Volume) SetSize(v int32) { + o.Size = &v +} + +// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. +func (o *Volume) GetSnapshotId() string { + if o == nil || o.SnapshotId == nil { + var ret string + return ret + } + return *o.SnapshotId +} + +// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetSnapshotIdOk() (*string, bool) { + if o == nil || o.SnapshotId == nil { + return nil, false + } + return o.SnapshotId, true +} + +// HasSnapshotId returns a boolean if a field has been set. +func (o *Volume) HasSnapshotId() bool { + if o != nil && o.SnapshotId != nil { + return true + } + + return false +} + +// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. +func (o *Volume) SetSnapshotId(v string) { + o.SnapshotId = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *Volume) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *Volume) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *Volume) SetState(v string) { + o.State = &v +} + +// GetSubregionName returns the SubregionName field value if set, zero value otherwise. +func (o *Volume) GetSubregionName() string { + if o == nil || o.SubregionName == nil { + var ret string + return ret + } + return *o.SubregionName +} + +// GetSubregionNameOk returns a tuple with the SubregionName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetSubregionNameOk() (*string, bool) { + if o == nil || o.SubregionName == nil { + return nil, false + } + return o.SubregionName, true +} + +// HasSubregionName returns a boolean if a field has been set. +func (o *Volume) HasSubregionName() bool { + if o != nil && o.SubregionName != nil { + return true + } + + return false +} + +// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. +func (o *Volume) SetSubregionName(v string) { + o.SubregionName = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *Volume) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *Volume) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *Volume) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetVolumeId returns the VolumeId field value if set, zero value otherwise. +func (o *Volume) GetVolumeId() string { + if o == nil || o.VolumeId == nil { + var ret string + return ret + } + return *o.VolumeId +} + +// GetVolumeIdOk returns a tuple with the VolumeId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetVolumeIdOk() (*string, bool) { + if o == nil || o.VolumeId == nil { + return nil, false + } + return o.VolumeId, true +} + +// HasVolumeId returns a boolean if a field has been set. +func (o *Volume) HasVolumeId() bool { + if o != nil && o.VolumeId != nil { + return true + } + + return false +} + +// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. +func (o *Volume) SetVolumeId(v string) { + o.VolumeId = &v +} + +// GetVolumeType returns the VolumeType field value if set, zero value otherwise. +func (o *Volume) GetVolumeType() string { + if o == nil || o.VolumeType == nil { + var ret string + return ret + } + return *o.VolumeType +} + +// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Volume) GetVolumeTypeOk() (*string, bool) { + if o == nil || o.VolumeType == nil { + return nil, false + } + return o.VolumeType, true +} + +// HasVolumeType returns a boolean if a field has been set. +func (o *Volume) HasVolumeType() bool { + if o != nil && o.VolumeType != nil { + return true + } + + return false +} + +// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. +func (o *Volume) SetVolumeType(v string) { + o.VolumeType = &v +} + +func (o Volume) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.Iops != nil { + toSerialize["Iops"] = o.Iops + } + if o.LinkedVolumes != nil { + toSerialize["LinkedVolumes"] = o.LinkedVolumes + } + if o.Size != nil { + toSerialize["Size"] = o.Size + } + if o.SnapshotId != nil { + toSerialize["SnapshotId"] = o.SnapshotId + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.SubregionName != nil { + toSerialize["SubregionName"] = o.SubregionName + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VolumeId != nil { + toSerialize["VolumeId"] = o.VolumeId + } + if o.VolumeType != nil { + toSerialize["VolumeType"] = o.VolumeType + } + return json.Marshal(toSerialize) +} + +type NullableVolume struct { + value *Volume + isSet bool +} + +func (v NullableVolume) Get() *Volume { + return v.value +} + +func (v *NullableVolume) Set(val *Volume) { + v.value = val + v.isSet = true +} + +func (v NullableVolume) IsSet() bool { + return v.isSet +} + +func (v *NullableVolume) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVolume(val *Volume) *NullableVolume { + return &NullableVolume{value: val, isSet: true} +} + +func (v NullableVolume) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVolume) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go new file mode 100644 index 000000000..dcb4f97ba --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go @@ -0,0 +1,413 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// VpnConnection Information about a VPN connection. +type VpnConnection struct { + // The configuration to apply to the client gateway to establish the VPN connection, in XML format. + ClientGatewayConfiguration *string `json:"ClientGatewayConfiguration,omitempty"` + // The ID of the client gateway used on the client end of the connection. + ClientGatewayId *string `json:"ClientGatewayId,omitempty"` + // The type of VPN connection (always `ipsec.1`). + ConnectionType *string `json:"ConnectionType,omitempty"` + // Information about one or more static routes associated with the VPN connection, if any. + Routes *[]RouteLight `json:"Routes,omitempty"` + // The state of the VPN connection (`pending` \\| `available` \\| `deleting` \\| `deleted`). + State *string `json:"State,omitempty"` + // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). + StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` + // One or more tags associated with the VPN connection. + Tags *[]ResourceTag `json:"Tags,omitempty"` + // The ID of the virtual gateway used on the 3DS OUTSCALE end of the connection. + VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` + // The ID of the VPN connection. + VpnConnectionId *string `json:"VpnConnectionId,omitempty"` +} + +// NewVpnConnection instantiates a new VpnConnection object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewVpnConnection() *VpnConnection { + this := VpnConnection{} + return &this +} + +// NewVpnConnectionWithDefaults instantiates a new VpnConnection object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewVpnConnectionWithDefaults() *VpnConnection { + this := VpnConnection{} + return &this +} + +// GetClientGatewayConfiguration returns the ClientGatewayConfiguration field value if set, zero value otherwise. +func (o *VpnConnection) GetClientGatewayConfiguration() string { + if o == nil || o.ClientGatewayConfiguration == nil { + var ret string + return ret + } + return *o.ClientGatewayConfiguration +} + +// GetClientGatewayConfigurationOk returns a tuple with the ClientGatewayConfiguration field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetClientGatewayConfigurationOk() (*string, bool) { + if o == nil || o.ClientGatewayConfiguration == nil { + return nil, false + } + return o.ClientGatewayConfiguration, true +} + +// HasClientGatewayConfiguration returns a boolean if a field has been set. +func (o *VpnConnection) HasClientGatewayConfiguration() bool { + if o != nil && o.ClientGatewayConfiguration != nil { + return true + } + + return false +} + +// SetClientGatewayConfiguration gets a reference to the given string and assigns it to the ClientGatewayConfiguration field. +func (o *VpnConnection) SetClientGatewayConfiguration(v string) { + o.ClientGatewayConfiguration = &v +} + +// GetClientGatewayId returns the ClientGatewayId field value if set, zero value otherwise. +func (o *VpnConnection) GetClientGatewayId() string { + if o == nil || o.ClientGatewayId == nil { + var ret string + return ret + } + return *o.ClientGatewayId +} + +// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetClientGatewayIdOk() (*string, bool) { + if o == nil || o.ClientGatewayId == nil { + return nil, false + } + return o.ClientGatewayId, true +} + +// HasClientGatewayId returns a boolean if a field has been set. +func (o *VpnConnection) HasClientGatewayId() bool { + if o != nil && o.ClientGatewayId != nil { + return true + } + + return false +} + +// SetClientGatewayId gets a reference to the given string and assigns it to the ClientGatewayId field. +func (o *VpnConnection) SetClientGatewayId(v string) { + o.ClientGatewayId = &v +} + +// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. +func (o *VpnConnection) GetConnectionType() string { + if o == nil || o.ConnectionType == nil { + var ret string + return ret + } + return *o.ConnectionType +} + +// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetConnectionTypeOk() (*string, bool) { + if o == nil || o.ConnectionType == nil { + return nil, false + } + return o.ConnectionType, true +} + +// HasConnectionType returns a boolean if a field has been set. +func (o *VpnConnection) HasConnectionType() bool { + if o != nil && o.ConnectionType != nil { + return true + } + + return false +} + +// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. +func (o *VpnConnection) SetConnectionType(v string) { + o.ConnectionType = &v +} + +// GetRoutes returns the Routes field value if set, zero value otherwise. +func (o *VpnConnection) GetRoutes() []RouteLight { + if o == nil || o.Routes == nil { + var ret []RouteLight + return ret + } + return *o.Routes +} + +// GetRoutesOk returns a tuple with the Routes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetRoutesOk() (*[]RouteLight, bool) { + if o == nil || o.Routes == nil { + return nil, false + } + return o.Routes, true +} + +// HasRoutes returns a boolean if a field has been set. +func (o *VpnConnection) HasRoutes() bool { + if o != nil && o.Routes != nil { + return true + } + + return false +} + +// SetRoutes gets a reference to the given []RouteLight and assigns it to the Routes field. +func (o *VpnConnection) SetRoutes(v []RouteLight) { + o.Routes = &v +} + +// GetState returns the State field value if set, zero value otherwise. +func (o *VpnConnection) GetState() string { + if o == nil || o.State == nil { + var ret string + return ret + } + return *o.State +} + +// GetStateOk returns a tuple with the State field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetStateOk() (*string, bool) { + if o == nil || o.State == nil { + return nil, false + } + return o.State, true +} + +// HasState returns a boolean if a field has been set. +func (o *VpnConnection) HasState() bool { + if o != nil && o.State != nil { + return true + } + + return false +} + +// SetState gets a reference to the given string and assigns it to the State field. +func (o *VpnConnection) SetState(v string) { + o.State = &v +} + +// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. +func (o *VpnConnection) GetStaticRoutesOnly() bool { + if o == nil || o.StaticRoutesOnly == nil { + var ret bool + return ret + } + return *o.StaticRoutesOnly +} + +// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetStaticRoutesOnlyOk() (*bool, bool) { + if o == nil || o.StaticRoutesOnly == nil { + return nil, false + } + return o.StaticRoutesOnly, true +} + +// HasStaticRoutesOnly returns a boolean if a field has been set. +func (o *VpnConnection) HasStaticRoutesOnly() bool { + if o != nil && o.StaticRoutesOnly != nil { + return true + } + + return false +} + +// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. +func (o *VpnConnection) SetStaticRoutesOnly(v bool) { + o.StaticRoutesOnly = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *VpnConnection) GetTags() []ResourceTag { + if o == nil || o.Tags == nil { + var ret []ResourceTag + return ret + } + return *o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetTagsOk() (*[]ResourceTag, bool) { + if o == nil || o.Tags == nil { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *VpnConnection) HasTags() bool { + if o != nil && o.Tags != nil { + return true + } + + return false +} + +// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. +func (o *VpnConnection) SetTags(v []ResourceTag) { + o.Tags = &v +} + +// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. +func (o *VpnConnection) GetVirtualGatewayId() string { + if o == nil || o.VirtualGatewayId == nil { + var ret string + return ret + } + return *o.VirtualGatewayId +} + +// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetVirtualGatewayIdOk() (*string, bool) { + if o == nil || o.VirtualGatewayId == nil { + return nil, false + } + return o.VirtualGatewayId, true +} + +// HasVirtualGatewayId returns a boolean if a field has been set. +func (o *VpnConnection) HasVirtualGatewayId() bool { + if o != nil && o.VirtualGatewayId != nil { + return true + } + + return false +} + +// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. +func (o *VpnConnection) SetVirtualGatewayId(v string) { + o.VirtualGatewayId = &v +} + +// GetVpnConnectionId returns the VpnConnectionId field value if set, zero value otherwise. +func (o *VpnConnection) GetVpnConnectionId() string { + if o == nil || o.VpnConnectionId == nil { + var ret string + return ret + } + return *o.VpnConnectionId +} + +// GetVpnConnectionIdOk returns a tuple with the VpnConnectionId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *VpnConnection) GetVpnConnectionIdOk() (*string, bool) { + if o == nil || o.VpnConnectionId == nil { + return nil, false + } + return o.VpnConnectionId, true +} + +// HasVpnConnectionId returns a boolean if a field has been set. +func (o *VpnConnection) HasVpnConnectionId() bool { + if o != nil && o.VpnConnectionId != nil { + return true + } + + return false +} + +// SetVpnConnectionId gets a reference to the given string and assigns it to the VpnConnectionId field. +func (o *VpnConnection) SetVpnConnectionId(v string) { + o.VpnConnectionId = &v +} + +func (o VpnConnection) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.ClientGatewayConfiguration != nil { + toSerialize["ClientGatewayConfiguration"] = o.ClientGatewayConfiguration + } + if o.ClientGatewayId != nil { + toSerialize["ClientGatewayId"] = o.ClientGatewayId + } + if o.ConnectionType != nil { + toSerialize["ConnectionType"] = o.ConnectionType + } + if o.Routes != nil { + toSerialize["Routes"] = o.Routes + } + if o.State != nil { + toSerialize["State"] = o.State + } + if o.StaticRoutesOnly != nil { + toSerialize["StaticRoutesOnly"] = o.StaticRoutesOnly + } + if o.Tags != nil { + toSerialize["Tags"] = o.Tags + } + if o.VirtualGatewayId != nil { + toSerialize["VirtualGatewayId"] = o.VirtualGatewayId + } + if o.VpnConnectionId != nil { + toSerialize["VpnConnectionId"] = o.VpnConnectionId + } + return json.Marshal(toSerialize) +} + +type NullableVpnConnection struct { + value *VpnConnection + isSet bool +} + +func (v NullableVpnConnection) Get() *VpnConnection { + return v.value +} + +func (v *NullableVpnConnection) Set(val *VpnConnection) { + v.value = val + v.isSet = true +} + +func (v NullableVpnConnection) IsSet() bool { + return v.isSet +} + +func (v *NullableVpnConnection) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableVpnConnection(val *VpnConnection) *NullableVpnConnection { + return &NullableVpnConnection{value: val, isSet: true} +} + +func (v NullableVpnConnection) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableVpnConnection) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_with.go b/vendor/github.com/outscale/osc-sdk-go/osc/model_with.go new file mode 100644 index 000000000..54da2d2a2 --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/model_with.go @@ -0,0 +1,672 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" +) + +// With The information to be displayed in the API logs to retrieve. +type With struct { + // If set to `true`, the account ID is displayed in the logs. + AccountId *bool `json:"AccountId,omitempty"` + // If set to `true`, the duration of the call is displayed each log. + CallDuration *bool `json:"CallDuration,omitempty"` + // If set to `true`, the API key used for the query is displayed each log. + QueryAccessKey *bool `json:"QueryAccessKey,omitempty"` + // If set to `true`, the name of the API service used by the call is displayed in each log (`oapi` \\| `fcu` \\| `lbu` \\| `directlink` \\| `eim` \\| `icu`). + QueryApiName *bool `json:"QueryApiName,omitempty"` + // If set to `true`, the version of the API service used by the call is displayed in each log. + QueryApiVersion *bool `json:"QueryApiVersion,omitempty"` + // If set to `true`, the name of the call is displayed in each log. + QueryCallName *bool `json:"QueryCallName,omitempty"` + // If set to `true`, the date of the call is displayed in each log. + QueryDate *bool `json:"QueryDate,omitempty"` + // If set to `true`, the query header RAW is displayed in each log. + QueryHeaderRaw *bool `json:"QueryHeaderRaw,omitempty"` + // If set to `true`, the query header size is displayed in each log. + QueryHeaderSize *bool `json:"QueryHeaderSize,omitempty"` + // If set to `true`, the IP address used to make to query is displayed in each log. + QueryIpAddress *bool `json:"QueryIpAddress,omitempty"` + // If set to `true`, the query payload raw is displayed in each log. + QueryPayloadRaw *bool `json:"QueryPayloadRaw,omitempty"` + // If set to `true`, the query payload size is displayed in each log. + QueryPayloadSize *bool `json:"QueryPayloadSize,omitempty"` + // If set to `true`, the user agent used to make the HTTP request is displayed in each log. + QueryUserAgent *bool `json:"QueryUserAgent,omitempty"` + // By default ot if set to `true`, the ID of the call is displayed in each log. + RequestId *bool `json:"RequestId,omitempty"` + // If set to `true`, the size of the response (in bytes) is displayed in each log. + ResponseSize *bool `json:"ResponseSize,omitempty"` + // If set to `true`, the HTTP code provided by the response is displayed in each log. + ResponseStatusCode *bool `json:"ResponseStatusCode,omitempty"` +} + +// NewWith instantiates a new With object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewWith() *With { + this := With{} + return &this +} + +// NewWithWithDefaults instantiates a new With object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewWithWithDefaults() *With { + this := With{} + return &this +} + +// GetAccountId returns the AccountId field value if set, zero value otherwise. +func (o *With) GetAccountId() bool { + if o == nil || o.AccountId == nil { + var ret bool + return ret + } + return *o.AccountId +} + +// GetAccountIdOk returns a tuple with the AccountId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetAccountIdOk() (*bool, bool) { + if o == nil || o.AccountId == nil { + return nil, false + } + return o.AccountId, true +} + +// HasAccountId returns a boolean if a field has been set. +func (o *With) HasAccountId() bool { + if o != nil && o.AccountId != nil { + return true + } + + return false +} + +// SetAccountId gets a reference to the given bool and assigns it to the AccountId field. +func (o *With) SetAccountId(v bool) { + o.AccountId = &v +} + +// GetCallDuration returns the CallDuration field value if set, zero value otherwise. +func (o *With) GetCallDuration() bool { + if o == nil || o.CallDuration == nil { + var ret bool + return ret + } + return *o.CallDuration +} + +// GetCallDurationOk returns a tuple with the CallDuration field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetCallDurationOk() (*bool, bool) { + if o == nil || o.CallDuration == nil { + return nil, false + } + return o.CallDuration, true +} + +// HasCallDuration returns a boolean if a field has been set. +func (o *With) HasCallDuration() bool { + if o != nil && o.CallDuration != nil { + return true + } + + return false +} + +// SetCallDuration gets a reference to the given bool and assigns it to the CallDuration field. +func (o *With) SetCallDuration(v bool) { + o.CallDuration = &v +} + +// GetQueryAccessKey returns the QueryAccessKey field value if set, zero value otherwise. +func (o *With) GetQueryAccessKey() bool { + if o == nil || o.QueryAccessKey == nil { + var ret bool + return ret + } + return *o.QueryAccessKey +} + +// GetQueryAccessKeyOk returns a tuple with the QueryAccessKey field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryAccessKeyOk() (*bool, bool) { + if o == nil || o.QueryAccessKey == nil { + return nil, false + } + return o.QueryAccessKey, true +} + +// HasQueryAccessKey returns a boolean if a field has been set. +func (o *With) HasQueryAccessKey() bool { + if o != nil && o.QueryAccessKey != nil { + return true + } + + return false +} + +// SetQueryAccessKey gets a reference to the given bool and assigns it to the QueryAccessKey field. +func (o *With) SetQueryAccessKey(v bool) { + o.QueryAccessKey = &v +} + +// GetQueryApiName returns the QueryApiName field value if set, zero value otherwise. +func (o *With) GetQueryApiName() bool { + if o == nil || o.QueryApiName == nil { + var ret bool + return ret + } + return *o.QueryApiName +} + +// GetQueryApiNameOk returns a tuple with the QueryApiName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryApiNameOk() (*bool, bool) { + if o == nil || o.QueryApiName == nil { + return nil, false + } + return o.QueryApiName, true +} + +// HasQueryApiName returns a boolean if a field has been set. +func (o *With) HasQueryApiName() bool { + if o != nil && o.QueryApiName != nil { + return true + } + + return false +} + +// SetQueryApiName gets a reference to the given bool and assigns it to the QueryApiName field. +func (o *With) SetQueryApiName(v bool) { + o.QueryApiName = &v +} + +// GetQueryApiVersion returns the QueryApiVersion field value if set, zero value otherwise. +func (o *With) GetQueryApiVersion() bool { + if o == nil || o.QueryApiVersion == nil { + var ret bool + return ret + } + return *o.QueryApiVersion +} + +// GetQueryApiVersionOk returns a tuple with the QueryApiVersion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryApiVersionOk() (*bool, bool) { + if o == nil || o.QueryApiVersion == nil { + return nil, false + } + return o.QueryApiVersion, true +} + +// HasQueryApiVersion returns a boolean if a field has been set. +func (o *With) HasQueryApiVersion() bool { + if o != nil && o.QueryApiVersion != nil { + return true + } + + return false +} + +// SetQueryApiVersion gets a reference to the given bool and assigns it to the QueryApiVersion field. +func (o *With) SetQueryApiVersion(v bool) { + o.QueryApiVersion = &v +} + +// GetQueryCallName returns the QueryCallName field value if set, zero value otherwise. +func (o *With) GetQueryCallName() bool { + if o == nil || o.QueryCallName == nil { + var ret bool + return ret + } + return *o.QueryCallName +} + +// GetQueryCallNameOk returns a tuple with the QueryCallName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryCallNameOk() (*bool, bool) { + if o == nil || o.QueryCallName == nil { + return nil, false + } + return o.QueryCallName, true +} + +// HasQueryCallName returns a boolean if a field has been set. +func (o *With) HasQueryCallName() bool { + if o != nil && o.QueryCallName != nil { + return true + } + + return false +} + +// SetQueryCallName gets a reference to the given bool and assigns it to the QueryCallName field. +func (o *With) SetQueryCallName(v bool) { + o.QueryCallName = &v +} + +// GetQueryDate returns the QueryDate field value if set, zero value otherwise. +func (o *With) GetQueryDate() bool { + if o == nil || o.QueryDate == nil { + var ret bool + return ret + } + return *o.QueryDate +} + +// GetQueryDateOk returns a tuple with the QueryDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryDateOk() (*bool, bool) { + if o == nil || o.QueryDate == nil { + return nil, false + } + return o.QueryDate, true +} + +// HasQueryDate returns a boolean if a field has been set. +func (o *With) HasQueryDate() bool { + if o != nil && o.QueryDate != nil { + return true + } + + return false +} + +// SetQueryDate gets a reference to the given bool and assigns it to the QueryDate field. +func (o *With) SetQueryDate(v bool) { + o.QueryDate = &v +} + +// GetQueryHeaderRaw returns the QueryHeaderRaw field value if set, zero value otherwise. +func (o *With) GetQueryHeaderRaw() bool { + if o == nil || o.QueryHeaderRaw == nil { + var ret bool + return ret + } + return *o.QueryHeaderRaw +} + +// GetQueryHeaderRawOk returns a tuple with the QueryHeaderRaw field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryHeaderRawOk() (*bool, bool) { + if o == nil || o.QueryHeaderRaw == nil { + return nil, false + } + return o.QueryHeaderRaw, true +} + +// HasQueryHeaderRaw returns a boolean if a field has been set. +func (o *With) HasQueryHeaderRaw() bool { + if o != nil && o.QueryHeaderRaw != nil { + return true + } + + return false +} + +// SetQueryHeaderRaw gets a reference to the given bool and assigns it to the QueryHeaderRaw field. +func (o *With) SetQueryHeaderRaw(v bool) { + o.QueryHeaderRaw = &v +} + +// GetQueryHeaderSize returns the QueryHeaderSize field value if set, zero value otherwise. +func (o *With) GetQueryHeaderSize() bool { + if o == nil || o.QueryHeaderSize == nil { + var ret bool + return ret + } + return *o.QueryHeaderSize +} + +// GetQueryHeaderSizeOk returns a tuple with the QueryHeaderSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryHeaderSizeOk() (*bool, bool) { + if o == nil || o.QueryHeaderSize == nil { + return nil, false + } + return o.QueryHeaderSize, true +} + +// HasQueryHeaderSize returns a boolean if a field has been set. +func (o *With) HasQueryHeaderSize() bool { + if o != nil && o.QueryHeaderSize != nil { + return true + } + + return false +} + +// SetQueryHeaderSize gets a reference to the given bool and assigns it to the QueryHeaderSize field. +func (o *With) SetQueryHeaderSize(v bool) { + o.QueryHeaderSize = &v +} + +// GetQueryIpAddress returns the QueryIpAddress field value if set, zero value otherwise. +func (o *With) GetQueryIpAddress() bool { + if o == nil || o.QueryIpAddress == nil { + var ret bool + return ret + } + return *o.QueryIpAddress +} + +// GetQueryIpAddressOk returns a tuple with the QueryIpAddress field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryIpAddressOk() (*bool, bool) { + if o == nil || o.QueryIpAddress == nil { + return nil, false + } + return o.QueryIpAddress, true +} + +// HasQueryIpAddress returns a boolean if a field has been set. +func (o *With) HasQueryIpAddress() bool { + if o != nil && o.QueryIpAddress != nil { + return true + } + + return false +} + +// SetQueryIpAddress gets a reference to the given bool and assigns it to the QueryIpAddress field. +func (o *With) SetQueryIpAddress(v bool) { + o.QueryIpAddress = &v +} + +// GetQueryPayloadRaw returns the QueryPayloadRaw field value if set, zero value otherwise. +func (o *With) GetQueryPayloadRaw() bool { + if o == nil || o.QueryPayloadRaw == nil { + var ret bool + return ret + } + return *o.QueryPayloadRaw +} + +// GetQueryPayloadRawOk returns a tuple with the QueryPayloadRaw field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryPayloadRawOk() (*bool, bool) { + if o == nil || o.QueryPayloadRaw == nil { + return nil, false + } + return o.QueryPayloadRaw, true +} + +// HasQueryPayloadRaw returns a boolean if a field has been set. +func (o *With) HasQueryPayloadRaw() bool { + if o != nil && o.QueryPayloadRaw != nil { + return true + } + + return false +} + +// SetQueryPayloadRaw gets a reference to the given bool and assigns it to the QueryPayloadRaw field. +func (o *With) SetQueryPayloadRaw(v bool) { + o.QueryPayloadRaw = &v +} + +// GetQueryPayloadSize returns the QueryPayloadSize field value if set, zero value otherwise. +func (o *With) GetQueryPayloadSize() bool { + if o == nil || o.QueryPayloadSize == nil { + var ret bool + return ret + } + return *o.QueryPayloadSize +} + +// GetQueryPayloadSizeOk returns a tuple with the QueryPayloadSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryPayloadSizeOk() (*bool, bool) { + if o == nil || o.QueryPayloadSize == nil { + return nil, false + } + return o.QueryPayloadSize, true +} + +// HasQueryPayloadSize returns a boolean if a field has been set. +func (o *With) HasQueryPayloadSize() bool { + if o != nil && o.QueryPayloadSize != nil { + return true + } + + return false +} + +// SetQueryPayloadSize gets a reference to the given bool and assigns it to the QueryPayloadSize field. +func (o *With) SetQueryPayloadSize(v bool) { + o.QueryPayloadSize = &v +} + +// GetQueryUserAgent returns the QueryUserAgent field value if set, zero value otherwise. +func (o *With) GetQueryUserAgent() bool { + if o == nil || o.QueryUserAgent == nil { + var ret bool + return ret + } + return *o.QueryUserAgent +} + +// GetQueryUserAgentOk returns a tuple with the QueryUserAgent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetQueryUserAgentOk() (*bool, bool) { + if o == nil || o.QueryUserAgent == nil { + return nil, false + } + return o.QueryUserAgent, true +} + +// HasQueryUserAgent returns a boolean if a field has been set. +func (o *With) HasQueryUserAgent() bool { + if o != nil && o.QueryUserAgent != nil { + return true + } + + return false +} + +// SetQueryUserAgent gets a reference to the given bool and assigns it to the QueryUserAgent field. +func (o *With) SetQueryUserAgent(v bool) { + o.QueryUserAgent = &v +} + +// GetRequestId returns the RequestId field value if set, zero value otherwise. +func (o *With) GetRequestId() bool { + if o == nil || o.RequestId == nil { + var ret bool + return ret + } + return *o.RequestId +} + +// GetRequestIdOk returns a tuple with the RequestId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetRequestIdOk() (*bool, bool) { + if o == nil || o.RequestId == nil { + return nil, false + } + return o.RequestId, true +} + +// HasRequestId returns a boolean if a field has been set. +func (o *With) HasRequestId() bool { + if o != nil && o.RequestId != nil { + return true + } + + return false +} + +// SetRequestId gets a reference to the given bool and assigns it to the RequestId field. +func (o *With) SetRequestId(v bool) { + o.RequestId = &v +} + +// GetResponseSize returns the ResponseSize field value if set, zero value otherwise. +func (o *With) GetResponseSize() bool { + if o == nil || o.ResponseSize == nil { + var ret bool + return ret + } + return *o.ResponseSize +} + +// GetResponseSizeOk returns a tuple with the ResponseSize field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetResponseSizeOk() (*bool, bool) { + if o == nil || o.ResponseSize == nil { + return nil, false + } + return o.ResponseSize, true +} + +// HasResponseSize returns a boolean if a field has been set. +func (o *With) HasResponseSize() bool { + if o != nil && o.ResponseSize != nil { + return true + } + + return false +} + +// SetResponseSize gets a reference to the given bool and assigns it to the ResponseSize field. +func (o *With) SetResponseSize(v bool) { + o.ResponseSize = &v +} + +// GetResponseStatusCode returns the ResponseStatusCode field value if set, zero value otherwise. +func (o *With) GetResponseStatusCode() bool { + if o == nil || o.ResponseStatusCode == nil { + var ret bool + return ret + } + return *o.ResponseStatusCode +} + +// GetResponseStatusCodeOk returns a tuple with the ResponseStatusCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *With) GetResponseStatusCodeOk() (*bool, bool) { + if o == nil || o.ResponseStatusCode == nil { + return nil, false + } + return o.ResponseStatusCode, true +} + +// HasResponseStatusCode returns a boolean if a field has been set. +func (o *With) HasResponseStatusCode() bool { + if o != nil && o.ResponseStatusCode != nil { + return true + } + + return false +} + +// SetResponseStatusCode gets a reference to the given bool and assigns it to the ResponseStatusCode field. +func (o *With) SetResponseStatusCode(v bool) { + o.ResponseStatusCode = &v +} + +func (o With) MarshalJSON() ([]byte, error) { + toSerialize := map[string]interface{}{} + if o.AccountId != nil { + toSerialize["AccountId"] = o.AccountId + } + if o.CallDuration != nil { + toSerialize["CallDuration"] = o.CallDuration + } + if o.QueryAccessKey != nil { + toSerialize["QueryAccessKey"] = o.QueryAccessKey + } + if o.QueryApiName != nil { + toSerialize["QueryApiName"] = o.QueryApiName + } + if o.QueryApiVersion != nil { + toSerialize["QueryApiVersion"] = o.QueryApiVersion + } + if o.QueryCallName != nil { + toSerialize["QueryCallName"] = o.QueryCallName + } + if o.QueryDate != nil { + toSerialize["QueryDate"] = o.QueryDate + } + if o.QueryHeaderRaw != nil { + toSerialize["QueryHeaderRaw"] = o.QueryHeaderRaw + } + if o.QueryHeaderSize != nil { + toSerialize["QueryHeaderSize"] = o.QueryHeaderSize + } + if o.QueryIpAddress != nil { + toSerialize["QueryIpAddress"] = o.QueryIpAddress + } + if o.QueryPayloadRaw != nil { + toSerialize["QueryPayloadRaw"] = o.QueryPayloadRaw + } + if o.QueryPayloadSize != nil { + toSerialize["QueryPayloadSize"] = o.QueryPayloadSize + } + if o.QueryUserAgent != nil { + toSerialize["QueryUserAgent"] = o.QueryUserAgent + } + if o.RequestId != nil { + toSerialize["RequestId"] = o.RequestId + } + if o.ResponseSize != nil { + toSerialize["ResponseSize"] = o.ResponseSize + } + if o.ResponseStatusCode != nil { + toSerialize["ResponseStatusCode"] = o.ResponseStatusCode + } + return json.Marshal(toSerialize) +} + +type NullableWith struct { + value *With + isSet bool +} + +func (v NullableWith) Get() *With { + return v.value +} + +func (v *NullableWith) Set(val *With) { + v.value = val + v.isSet = true +} + +func (v NullableWith) IsSet() bool { + return v.isSet +} + +func (v *NullableWith) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableWith(val *With) *NullableWith { + return &NullableWith{value: val, isSet: true} +} + +func (v NullableWith) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableWith) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/response.go b/vendor/github.com/outscale/osc-sdk-go/osc/response.go new file mode 100644 index 000000000..a1d2c8f8d --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/response.go @@ -0,0 +1,48 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "net/http" +) + +// APIResponse stores the API response returned by the server. +type APIResponse struct { + *http.Response `json:"-"` + Message string `json:"message,omitempty"` + // Operation is the name of the OpenAPI operation. + Operation string `json:"operation,omitempty"` + // RequestURL is the request URL. This value is always available, even if the + // embedded *http.Response is nil. + RequestURL string `json:"url,omitempty"` + // Method is the HTTP method used for the request. This value is always + // available, even if the embedded *http.Response is nil. + Method string `json:"method,omitempty"` + // Payload holds the contents of the response body (which may be nil or empty). + // This is provided here as the raw response.Body() reader will have already + // been drained. + Payload []byte `json:"-"` +} + +// NewAPIResponse returns a new APIResonse object. +func NewAPIResponse(r *http.Response) *APIResponse { + + response := &APIResponse{Response: r} + return response +} + +// NewAPIResponseWithError returns a new APIResponse object with the provided error message. +func NewAPIResponseWithError(errorMessage string) *APIResponse { + + response := &APIResponse{Message: errorMessage} + return response +} diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/utils.go b/vendor/github.com/outscale/osc-sdk-go/osc/utils.go new file mode 100644 index 000000000..9e633e47a --- /dev/null +++ b/vendor/github.com/outscale/osc-sdk-go/osc/utils.go @@ -0,0 +1,336 @@ +/* + * 3DS OUTSCALE API + * + * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. + * + * API version: 1.4 + * Contact: support@outscale.com + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package osc + +import ( + "encoding/json" + "time" +) + +// PtrBool is a helper routine that returns a pointer to given boolean value. +func PtrBool(v bool) *bool { return &v } + +// PtrInt is a helper routine that returns a pointer to given integer value. +func PtrInt(v int) *int { return &v } + +// PtrInt32 is a helper routine that returns a pointer to given integer value. +func PtrInt32(v int32) *int32 { return &v } + +// PtrInt64 is a helper routine that returns a pointer to given integer value. +func PtrInt64(v int64) *int64 { return &v } + +// PtrFloat32 is a helper routine that returns a pointer to given float value. +func PtrFloat32(v float32) *float32 { return &v } + +// PtrFloat64 is a helper routine that returns a pointer to given float value. +func PtrFloat64(v float64) *float64 { return &v } + +// PtrString is a helper routine that returns a pointer to given string value. +func PtrString(v string) *string { return &v } + +// PtrTime is helper routine that returns a pointer to given Time value. +func PtrTime(v time.Time) *time.Time { return &v } + +type NullableBool struct { + value *bool + isSet bool +} + +func (v NullableBool) Get() *bool { + return v.value +} + +func (v *NullableBool) Set(val *bool) { + v.value = val + v.isSet = true +} + +func (v NullableBool) IsSet() bool { + return v.isSet +} + +func (v *NullableBool) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBool(val *bool) *NullableBool { + return &NullableBool{value: val, isSet: true} +} + +func (v NullableBool) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBool) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableInt struct { + value *int + isSet bool +} + +func (v NullableInt) Get() *int { + return v.value +} + +func (v *NullableInt) Set(val *int) { + v.value = val + v.isSet = true +} + +func (v NullableInt) IsSet() bool { + return v.isSet +} + +func (v *NullableInt) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt(val *int) *NullableInt { + return &NullableInt{value: val, isSet: true} +} + +func (v NullableInt) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableInt32 struct { + value *int32 + isSet bool +} + +func (v NullableInt32) Get() *int32 { + return v.value +} + +func (v *NullableInt32) Set(val *int32) { + v.value = val + v.isSet = true +} + +func (v NullableInt32) IsSet() bool { + return v.isSet +} + +func (v *NullableInt32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt32(val *int32) *NullableInt32 { + return &NullableInt32{value: val, isSet: true} +} + +func (v NullableInt32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableInt64 struct { + value *int64 + isSet bool +} + +func (v NullableInt64) Get() *int64 { + return v.value +} + +func (v *NullableInt64) Set(val *int64) { + v.value = val + v.isSet = true +} + +func (v NullableInt64) IsSet() bool { + return v.isSet +} + +func (v *NullableInt64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt64(val *int64) *NullableInt64 { + return &NullableInt64{value: val, isSet: true} +} + +func (v NullableInt64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableFloat32 struct { + value *float32 + isSet bool +} + +func (v NullableFloat32) Get() *float32 { + return v.value +} + +func (v *NullableFloat32) Set(val *float32) { + v.value = val + v.isSet = true +} + +func (v NullableFloat32) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat32(val *float32) *NullableFloat32 { + return &NullableFloat32{value: val, isSet: true} +} + +func (v NullableFloat32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableFloat64 struct { + value *float64 + isSet bool +} + +func (v NullableFloat64) Get() *float64 { + return v.value +} + +func (v *NullableFloat64) Set(val *float64) { + v.value = val + v.isSet = true +} + +func (v NullableFloat64) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat64(val *float64) *NullableFloat64 { + return &NullableFloat64{value: val, isSet: true} +} + +func (v NullableFloat64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableString struct { + value *string + isSet bool +} + +func (v NullableString) Get() *string { + return v.value +} + +func (v *NullableString) Set(val *string) { + v.value = val + v.isSet = true +} + +func (v NullableString) IsSet() bool { + return v.isSet +} + +func (v *NullableString) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableString(val *string) *NullableString { + return &NullableString{value: val, isSet: true} +} + +func (v NullableString) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableString) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + +type NullableTime struct { + value *time.Time + isSet bool +} + +func (v NullableTime) Get() *time.Time { + return v.value +} + +func (v *NullableTime) Set(val *time.Time) { + v.value = val + v.isSet = true +} + +func (v NullableTime) IsSet() bool { + return v.isSet +} + +func (v *NullableTime) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTime(val *time.Time) *NullableTime { + return &NullableTime{value: val, isSet: true} +} + +func (v NullableTime) MarshalJSON() ([]byte, error) { + return v.value.MarshalJSON() +} + +func (v *NullableTime) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/vendor/modules.txt b/vendor/modules.txt index 7728ff1f2..7c776e93d 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -16,7 +16,7 @@ github.com/apparentlymart/go-cidr/cidr github.com/apparentlymart/go-textseg/textseg # github.com/armon/go-radix v1.0.0 github.com/armon/go-radix -# github.com/aws/aws-sdk-go v1.31.10 +# github.com/aws/aws-sdk-go v1.34.14 github.com/aws/aws-sdk-go/aws github.com/aws/aws-sdk-go/aws/arn github.com/aws/aws-sdk-go/aws/awserr @@ -222,6 +222,8 @@ github.com/mitchellh/reflectwalk github.com/oklog/run # github.com/openlyinc/pointy v1.1.2 github.com/openlyinc/pointy +# github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c +github.com/outscale/osc-sdk-go/osc # github.com/posener/complete v1.2.1 github.com/posener/complete github.com/posener/complete/cmd From 83f4273c8082f3f51b01de93fbc4ab0bd24c8834 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Mon, 19 Oct 2020 10:55:33 -0600 Subject: [PATCH 008/218] migrated client from marin to official sdk outscale --- outscale/config.go | 20 ++--- outscale/data_source_outscale_access_key.go | 9 +-- outscale/data_source_outscale_access_keys.go | 11 +-- .../data_source_outscale_client_gateway.go | 7 +- .../data_source_outscale_client_gateways.go | 7 +- outscale/data_source_outscale_dhcp_option.go | 7 +- outscale/data_source_outscale_dhcp_options.go | 7 +- outscale/data_source_outscale_image.go | 5 +- outscale/data_source_outscale_images.go | 6 +- .../data_source_outscale_internet_service.go | 5 +- .../data_source_outscale_internet_services.go | 5 +- outscale/data_source_outscale_keypair.go | 5 +- outscale/data_source_outscale_keypairs.go | 5 +- outscale/data_source_outscale_nat_service.go | 5 +- outscale/data_source_outscale_nat_services.go | 5 +- outscale/data_source_outscale_net.go | 5 +- .../data_source_outscale_net_attributes.go | 5 +- outscale/data_source_outscale_net_peering.go | 5 +- outscale/data_source_outscale_net_peerings.go | 5 +- outscale/data_source_outscale_nets.go | 5 +- outscale/data_source_outscale_nic.go | 5 +- outscale/data_source_outscale_nic_test.go | 7 +- outscale/data_source_outscale_nics.go | 5 +- outscale/data_source_outscale_public_ip.go | 5 +- outscale/data_source_outscale_public_ips.go | 5 +- outscale/data_source_outscale_route_table.go | 5 +- outscale/data_source_outscale_route_tables.go | 5 +- .../data_source_outscale_security_group.go | 5 +- .../data_source_outscale_security_groups.go | 5 +- outscale/data_source_outscale_snapshot.go | 9 +-- outscale/data_source_outscale_snapshots.go | 5 +- outscale/data_source_outscale_subnet.go | 9 +-- outscale/data_source_outscale_subnets.go | 5 +- outscale/data_source_outscale_tag.go | 5 +- outscale/data_source_outscale_tags.go | 5 +- .../data_source_outscale_virtual_gateway.go | 5 +- .../data_source_outscale_virtual_gateways.go | 5 +- outscale/data_source_outscale_vm.go | 7 +- outscale/data_source_outscale_vm_state.go | 5 +- outscale/data_source_outscale_vms.go | 7 +- outscale/data_source_outscale_vms_state.go | 5 +- outscale/data_source_outscale_volume.go | 7 +- outscale/data_source_outscale_volumes.go | 5 +- .../data_source_outscale_vpn_connection.go | 11 +-- .../data_source_outscale_vpn_connections.go | 7 +- outscale/instance_set_set.go | 2 +- outscale/oapi_tags.go | 15 ++-- outscale/resource_outscale_access_key.go | 18 ++--- outscale/resource_outscale_access_key_test.go | 11 +-- outscale/resource_outscale_client_gateway.go | 18 ++--- .../resource_outscale_client_gateway_test.go | 11 +-- outscale/resource_outscale_dhcp_option.go | 50 +++++------- .../resource_outscale_dhcp_option_test.go | 19 ++--- outscale/resource_outscale_image.go | 42 ++++------ ...source_outscale_image_launch_permission.go | 15 ++-- ...e_outscale_image_launch_permission_test.go | 5 +- outscale/resource_outscale_image_test.go | 19 ++--- .../resource_outscale_internet_service.go | 19 ++--- ...resource_outscale_internet_service_link.go | 46 ++++------- ...rce_outscale_internet_service_link_test.go | 19 ++--- ...resource_outscale_internet_service_test.go | 19 ++--- outscale/resource_outscale_keypair.go | 12 +-- outscale/resource_outscale_keypair_test.go | 11 ++- outscale/resource_outscale_nat_service.go | 43 ++++------ .../resource_outscale_nat_service_test.go | 19 ++--- outscale/resource_outscale_net.go | 9 +-- outscale/resource_outscale_net_attributes.go | 20 +---- outscale/resource_outscale_net_peering.go | 17 ++-- ...source_outscale_net_peering_acceptation.go | 5 +- .../resource_outscale_net_peering_test.go | 15 ++-- outscale/resource_outscale_net_test.go | 7 +- outscale/resource_outscale_nic.go | 33 ++++---- outscale/resource_outscale_nic_link.go | 17 ++-- outscale/resource_outscale_nic_link_test.go | 5 +- outscale/resource_outscale_nic_private_ip.go | 11 ++- .../resource_outscale_nic_private_ip_test.go | 2 +- outscale/resource_outscale_nic_test.go | 5 +- outscale/resource_outscale_public_ip.go | 21 +++-- outscale/resource_outscale_public_ip_link.go | 9 +-- .../resource_outscale_public_ip_link_test.go | 11 ++- outscale/resource_outscale_public_ip_test.go | 7 +- outscale/resource_outscale_route.go | 25 +++--- outscale/resource_outscale_route_table.go | 15 ++-- .../resource_outscale_route_table_link.go | 18 ++--- ...resource_outscale_route_table_link_test.go | 7 +- .../resource_outscale_route_table_test.go | 7 +- outscale/resource_outscale_route_test.go | 2 +- outscale/resource_outscale_security_group.go | 13 ++-- .../resource_outscale_security_group_rule.go | 25 +++--- ...ource_outscale_security_group_rule_test.go | 9 +-- .../resource_outscale_security_group_test.go | 2 +- outscale/resource_outscale_snapshot.go | 13 ++-- .../resource_outscale_snapshot_attributes.go | 9 +-- outscale/resource_outscale_snapshot_test.go | 5 +- outscale/resource_outscale_subnet.go | 21 +++-- outscale/resource_outscale_subnet_test.go | 27 +++---- outscale/resource_outscale_tags.go | 9 +-- outscale/resource_outscale_tags_test.go | 7 +- outscale/resource_outscale_virtual_gateway.go | 29 ++++--- .../resource_outscale_virtual_gateway_link.go | 22 +++--- ...urce_outscale_virtual_gateway_link_test.go | 10 +-- ...scale_virtual_gateway_route_propagation.go | 15 ++-- ..._virtual_gateway_route_propagation_test.go | 11 ++- .../resource_outscale_virtual_gateway_test.go | 15 ++-- outscale/resource_outscale_vm.go | 78 +++++++------------ outscale/resource_outscale_vm_test.go | 15 ++-- outscale/resource_outscale_volume.go | 17 ++-- outscale/resource_outscale_volume_test.go | 5 +- outscale/resource_outscale_volumes_link.go | 13 ++-- .../resource_outscale_volumes_link_test.go | 2 +- outscale/resource_outscale_vpn_connection.go | 16 +--- .../resource_outscale_vpn_connection_route.go | 19 ++--- ...urce_outscale_vpn_connection_route_test.go | 11 +-- .../resource_outscale_vpn_connection_test.go | 11 +-- outscale/transport.go | 50 ++++++++++++ utils/utils.go | 2 +- 116 files changed, 589 insertions(+), 856 deletions(-) create mode 100644 outscale/transport.go diff --git a/outscale/config.go b/outscale/config.go index 9ea73e25a..a857cddef 100644 --- a/outscale/config.go +++ b/outscale/config.go @@ -2,12 +2,11 @@ package outscale import ( "crypto/tls" - "fmt" "net/http" "github.com/hashicorp/terraform-plugin-sdk/helper/logging" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) // Config ... @@ -35,20 +34,11 @@ func (c *Config) Client() (*OutscaleClient, error) { skipClient.Transport = logging.NewTransport("Outscale", skipClient.Transport) - skipClient.Transport = oscgo.NewTransport(c.AccessKeyID, c.SecretKeyID, c.Region, skipClient.Transport) + skipClient.Transport = NewTransport(c.AccessKeyID, c.SecretKeyID, c.Region, skipClient.Transport) - basePath := fmt.Sprintf("https://api.%s.outscale.com/oapi/latest", c.Region) - - if endpoint, ok := c.Endpoints["api"]; ok { - basePath = endpoint.(string) - } - - oscConfig := &oscgo.Configuration{ - BasePath: basePath, - DefaultHeader: make(map[string]string), - UserAgent: "terraform-provider-outscale-dev", - HTTPClient: skipClient, - } + oscConfig := oscgo.NewConfiguration() + oscConfig.Debug = true + oscConfig.HTTPClient = skipClient oscClient := oscgo.NewAPIClient(oscConfig) diff --git a/outscale/data_source_outscale_access_key.go b/outscale/data_source_outscale_access_key.go index 474d2d75c..29f8e62cf 100644 --- a/outscale/data_source_outscale_access_key.go +++ b/outscale/data_source_outscale_access_key.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -70,11 +69,7 @@ func dataSourceOutscaleAccessKeyRead(d *schema.ResourceData, meta interface{}) e var resp oscgo.ReadAccessKeysResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.AccessKeyApi.ReadAccessKeys(context.Background(), &oscgo.ReadAccessKeysOpts{ - ReadAccessKeysRequest: optional.NewInterface(oscgo.ReadAccessKeysRequest{ - Filters: filterReq, - }), - }) + resp, _, err = conn.AccessKeyApi.ReadAccessKeys(context.Background()).ReadAccessKeysRequest(oscgo.ReadAccessKeysRequest{Filters: filterReq}).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_access_keys.go b/outscale/data_source_outscale_access_keys.go index 25020f5d6..2f661c6cd 100644 --- a/outscale/data_source_outscale_access_keys.go +++ b/outscale/data_source_outscale_access_keys.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -89,11 +88,9 @@ func dataSourceOutscaleAccessKeysRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadAccessKeysResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.AccessKeyApi.ReadAccessKeys(context.Background(), &oscgo.ReadAccessKeysOpts{ - ReadAccessKeysRequest: optional.NewInterface(oscgo.ReadAccessKeysRequest{ - Filters: filterReq, - }), - }) + resp, _, err = conn.AccessKeyApi.ReadAccessKeys(context.Background()).ReadAccessKeysRequest(oscgo.ReadAccessKeysRequest{ + Filters: filterReq, + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_client_gateway.go b/outscale/data_source_outscale_client_gateway.go index 42c15e207..b383ec1bf 100644 --- a/outscale/data_source_outscale_client_gateway.go +++ b/outscale/data_source_outscale_client_gateway.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -73,9 +72,7 @@ func dataSourceOutscaleClientGatewayRead(d *schema.ResourceData, meta interface{ var resp oscgo.ReadClientGatewaysResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ClientGatewayApi.ReadClientGateways(context.Background(), &oscgo.ReadClientGatewaysOpts{ - ReadClientGatewaysRequest: optional.NewInterface(params), - }) + resp, _, err = conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_client_gateways.go b/outscale/data_source_outscale_client_gateways.go index 35fd81215..7951ea8be 100644 --- a/outscale/data_source_outscale_client_gateways.go +++ b/outscale/data_source_outscale_client_gateways.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -87,9 +86,7 @@ func dataSourceOutscaleClientGatewaysRead(d *schema.ResourceData, meta interface var resp oscgo.ReadClientGatewaysResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ClientGatewayApi.ReadClientGateways(context.Background(), &oscgo.ReadClientGatewaysOpts{ - ReadClientGatewaysRequest: optional.NewInterface(params), - }) + resp, _, err = conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_dhcp_option.go b/outscale/data_source_outscale_dhcp_option.go index 87d843cbf..2d23ea6c8 100644 --- a/outscale/data_source_outscale_dhcp_option.go +++ b/outscale/data_source_outscale_dhcp_option.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -82,9 +81,7 @@ func dataSourceOutscaleDHCPOptionRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadDhcpOptionsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background(), &oscgo.ReadDhcpOptionsOpts{ - ReadDhcpOptionsRequest: optional.NewInterface(params), - }) + resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background()).ReadDhcpOptionsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_dhcp_options.go b/outscale/data_source_outscale_dhcp_options.go index cdd246885..1d638162b 100644 --- a/outscale/data_source_outscale_dhcp_options.go +++ b/outscale/data_source_outscale_dhcp_options.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -91,9 +90,7 @@ func dataSourceOutscaleDHCPOptionsRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadDhcpOptionsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background(), &oscgo.ReadDhcpOptionsOpts{ - ReadDhcpOptionsRequest: optional.NewInterface(params), - }) + resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background()).ReadDhcpOptionsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_image.go b/outscale/data_source_outscale_image.go index ccb7fe94c..c0c8c3a41 100644 --- a/outscale/data_source_outscale_image.go +++ b/outscale/data_source_outscale_image.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" @@ -186,7 +185,7 @@ func dataSourceOutscaleOAPIImageRead(d *schema.ResourceData, meta interface{}) e var resp oscgo.ReadImagesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ImageApi.ReadImages(context.Background(), &oscgo.ReadImagesOpts{ReadImagesRequest: optional.NewInterface(req)}) + resp, _, err = conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_images.go b/outscale/data_source_outscale_images.go index 0895cfb73..069555da3 100644 --- a/outscale/data_source_outscale_images.go +++ b/outscale/data_source_outscale_images.go @@ -7,9 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -198,7 +196,7 @@ func dataSourceOutscaleOAPIImagesRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadImagesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ImageApi.ReadImages(context.Background(), &oscgo.ReadImagesOpts{ReadImagesRequest: optional.NewInterface(req)}) + resp, _, err = conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_internet_service.go b/outscale/data_source_outscale_internet_service.go index 72720dcea..edf98c583 100644 --- a/outscale/data_source_outscale_internet_service.go +++ b/outscale/data_source_outscale_internet_service.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -68,7 +67,7 @@ func datasourceOutscaleOAPIInternetServiceRead(d *schema.ResourceData, meta inte var resp oscgo.ReadInternetServicesResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { - r, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), &oscgo.ReadInternetServicesOpts{ReadInternetServicesRequest: optional.NewInterface(params)}) + r, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_internet_services.go b/outscale/data_source_outscale_internet_services.go index bf3938dc6..a6b3ee9c0 100644 --- a/outscale/data_source_outscale_internet_services.go +++ b/outscale/data_source_outscale_internet_services.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -85,7 +84,7 @@ func datasourceOutscaleOAPIInternetServicesRead(d *schema.ResourceData, meta int var resp oscgo.ReadInternetServicesResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.InternetServiceApi.ReadInternetServices(context.Background(), &oscgo.ReadInternetServicesOpts{ReadInternetServicesRequest: optional.NewInterface(params)}) + resp, _, err = conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_keypair.go b/outscale/data_source_outscale_keypair.go index c80838c44..2c29a8b92 100644 --- a/outscale/data_source_outscale_keypair.go +++ b/outscale/data_source_outscale_keypair.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -36,7 +35,7 @@ func datasourceOutscaleOApiKeyPairRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadKeypairsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background(), &oscgo.ReadKeypairsOpts{ReadKeypairsRequest: optional.NewInterface(req)}) + resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background()).ReadKeypairsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_keypairs.go b/outscale/data_source_outscale_keypairs.go index f43738111..eacec0064 100644 --- a/outscale/data_source_outscale_keypairs.go +++ b/outscale/data_source_outscale_keypairs.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -41,7 +40,7 @@ func datasourceOutscaleOAPiKeyPairsRead(d *schema.ResourceData, meta interface{} var resp oscgo.ReadKeypairsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background(), &oscgo.ReadKeypairsOpts{ReadKeypairsRequest: optional.NewInterface(req)}) + resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background()).ReadKeypairsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_nat_service.go b/outscale/data_source_outscale_nat_service.go index 6828ff72a..2257bb1e8 100644 --- a/outscale/data_source_outscale_nat_service.go +++ b/outscale/data_source_outscale_nat_service.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -87,7 +86,7 @@ func dataSourceOutscaleOAPINatServiceRead(d *schema.ResourceData, meta interface err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.NatServiceApi.ReadNatServices(context.Background(), &oscgo.ReadNatServicesOpts{ReadNatServicesRequest: optional.NewInterface(params)}) + resp, _, err = conn.NatServiceApi.ReadNatServices(context.Background()).ReadNatServicesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_nat_services.go b/outscale/data_source_outscale_nat_services.go index 37228d4c2..8b806ff74 100644 --- a/outscale/data_source_outscale_nat_services.go +++ b/outscale/data_source_outscale_nat_services.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -103,7 +102,7 @@ func dataSourceOutscaleOAPINatServicesRead(d *schema.ResourceData, meta interfac err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.NatServiceApi.ReadNatServices(context.Background(), &oscgo.ReadNatServicesOpts{ReadNatServicesRequest: optional.NewInterface(params)}) + resp, _, err = conn.NatServiceApi.ReadNatServices(context.Background()).ReadNatServicesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_net.go b/outscale/data_source_outscale_net.go index f705f4e04..361d9a5af 100644 --- a/outscale/data_source_outscale_net.go +++ b/outscale/data_source_outscale_net.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -71,7 +70,7 @@ func dataSourceOutscaleOAPIVpcRead(d *schema.ResourceData, meta interface{}) err var err error var resp oscgo.ReadNetsResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), &oscgo.ReadNetsOpts{ReadNetsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_net_attributes.go b/outscale/data_source_outscale_net_attributes.go index cf168f0c8..b741e2678 100644 --- a/outscale/data_source_outscale_net_attributes.go +++ b/outscale/data_source_outscale_net_attributes.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -64,7 +63,7 @@ func dataSourceOutscaleOAPIVpcAttrRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadNetsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), &oscgo.ReadNetsOpts{ReadNetsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_net_peering.go b/outscale/data_source_outscale_net_peering.go index 19c03a96c..fa1dc47b5 100644 --- a/outscale/data_source_outscale_net_peering.go +++ b/outscale/data_source_outscale_net_peering.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "log" "reflect" "strings" @@ -68,7 +67,7 @@ func dataSourceOutscaleOAPILinPeeringConnectionRead(d *schema.ResourceData, meta var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_net_peerings.go b/outscale/data_source_outscale_net_peerings.go index b675a3be7..5f5a07148 100644 --- a/outscale/data_source_outscale_net_peerings.go +++ b/outscale/data_source_outscale_net_peerings.go @@ -6,8 +6,7 @@ import ( "log" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -74,7 +73,7 @@ func dataSourceOutscaleOAPILinPeeringsConnectionRead(d *schema.ResourceData, met var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(params)}) + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(params).Execute() return resource.RetryableError(err) }) diff --git a/outscale/data_source_outscale_nets.go b/outscale/data_source_outscale_nets.go index 770e89e02..9b41fd3f4 100644 --- a/outscale/data_source_outscale_nets.go +++ b/outscale/data_source_outscale_nets.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -96,7 +95,7 @@ func dataSourceOutscaleOAPIVpcsRead(d *schema.ResourceData, meta interface{}) er var err error var resp oscgo.ReadNetsResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), &oscgo.ReadNetsOpts{ReadNetsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_nic.go b/outscale/data_source_outscale_nic.go index d42f43e24..868ffcc15 100644 --- a/outscale/data_source_outscale_nic.go +++ b/outscale/data_source_outscale_nic.go @@ -8,8 +8,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -239,7 +238,7 @@ func dataSourceOutscaleOAPINicRead(d *schema.ResourceData, meta interface{}) err var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(dnri)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(dnri).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_nic_test.go b/outscale/data_source_outscale_nic_test.go index f7fc78b30..a7c8ef867 100644 --- a/outscale/data_source_outscale_nic_test.go +++ b/outscale/data_source_outscale_nic_test.go @@ -6,8 +6,7 @@ import ( "os" "strings" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "testing" "time" @@ -76,7 +75,7 @@ func testAccCheckOutscaleOAPIENIDestroy(s *terraform.State) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -111,7 +110,7 @@ func testAccCheckOutscaleOAPINICDestroy(s *terraform.State) error { var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(dnir)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(dnir).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_nics.go b/outscale/data_source_outscale_nics.go index a6127e358..dd02f73b0 100644 --- a/outscale/data_source_outscale_nics.go +++ b/outscale/data_source_outscale_nics.go @@ -5,8 +5,7 @@ import ( "fmt" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -239,7 +238,7 @@ func dataSourceOutscaleOAPINicsRead(d *schema.ResourceData, meta interface{}) er var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(params)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(params).Execute() return resource.RetryableError(err) }) diff --git a/outscale/data_source_outscale_public_ip.go b/outscale/data_source_outscale_public_ip.go index 1e36dd571..349b0f0e1 100644 --- a/outscale/data_source_outscale_public_ip.go +++ b/outscale/data_source_outscale_public_ip.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -84,7 +83,7 @@ func dataSourceOutscaleOAPIPublicIPRead(d *schema.ResourceData, meta interface{} var response oscgo.ReadPublicIpsResponse err := resource.Retry(60*time.Second, func() *resource.RetryError { var err error - response, _, err = conn.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + response, _, err = conn.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_public_ips.go b/outscale/data_source_outscale_public_ips.go index 33839e765..de6013211 100644 --- a/outscale/data_source_outscale_public_ips.go +++ b/outscale/data_source_outscale_public_ips.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -82,7 +81,7 @@ func dataSourceOutscalePublicIPSRead(d *schema.ResourceData, meta interface{}) e var resp oscgo.ReadPublicIpsResponse err := resource.Retry(60*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + resp, _, err = conn.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() return resource.RetryableError(err) }) diff --git a/outscale/data_source_outscale_route_table.go b/outscale/data_source_outscale_route_table.go index cc75f8e3b..3f1963017 100644 --- a/outscale/data_source_outscale_route_table.go +++ b/outscale/data_source_outscale_route_table.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -153,7 +152,7 @@ func dataSourceOutscaleOAPIRouteTableRead(d *schema.ResourceData, meta interface var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil && strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) } diff --git a/outscale/data_source_outscale_route_tables.go b/outscale/data_source_outscale_route_tables.go index 4fb51c5a9..ee6f95287 100644 --- a/outscale/data_source_outscale_route_tables.go +++ b/outscale/data_source_outscale_route_tables.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -171,7 +170,7 @@ func dataSourceOutscaleOAPIRouteTablesRead(d *schema.ResourceData, meta interfac var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_security_group.go b/outscale/data_source_outscale_security_group.go index a36793de9..4e2592ee6 100644 --- a/outscale/data_source_outscale_security_group.go +++ b/outscale/data_source_outscale_security_group.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -183,7 +182,7 @@ func dataSourceOutscaleOAPISecurityGroupRead(d *schema.ResourceData, meta interf var err error var resp oscgo.ReadSecurityGroupsResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background(), &oscgo.ReadSecurityGroupsOpts{ReadSecurityGroupsRequest: optional.NewInterface(req)}) + resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background()).ReadSecurityGroupsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { diff --git a/outscale/data_source_outscale_security_groups.go b/outscale/data_source_outscale_security_groups.go index 16d52dfa0..e3a7acd95 100644 --- a/outscale/data_source_outscale_security_groups.go +++ b/outscale/data_source_outscale_security_groups.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -212,7 +211,7 @@ func dataSourceOutscaleOAPISecurityGroupsRead(d *schema.ResourceData, meta inter var err error var resp oscgo.ReadSecurityGroupsResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background(), &oscgo.ReadSecurityGroupsOpts{ReadSecurityGroupsRequest: optional.NewInterface(req)}) + resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background()).ReadSecurityGroupsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { diff --git a/outscale/data_source_outscale_snapshot.go b/outscale/data_source_outscale_snapshot.go index fe70485c9..23adef347 100644 --- a/outscale/data_source_outscale_snapshot.go +++ b/outscale/data_source_outscale_snapshot.go @@ -8,8 +8,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" @@ -122,7 +121,7 @@ func dataSourceOutscaleOAPISnapshotRead(d *schema.ResourceData, meta interface{} var resp oscgo.ReadSnapshotsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(params)}) + resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { @@ -221,7 +220,7 @@ func buildOutscaleOapiSnapshootDataSourceFilters(set *schema.Set, filter *oscgo. filter.SetPermissionsToCreateVolumeGlobalPermission(boolean) case "progresses": - filter.SetProgresses(utils.StringSliceToInt64Slice(values)) + filter.SetProgresses(utils.StringSliceToInt32Slice(values)) case "snapshot_ids": filter.SetSnapshotIds(values) @@ -242,7 +241,7 @@ func buildOutscaleOapiSnapshootDataSourceFilters(set *schema.Set, filter *oscgo. filter.SetVolumeIds(values) case "volume_sizes": - filter.SetVolumeSizes(utils.StringSliceToInt64Slice(values)) + filter.SetVolumeSizes(utils.StringSliceToInt32Slice(values)) default: log.Printf("[Debug] Unknown Filter Name: %s.", name) diff --git a/outscale/data_source_outscale_snapshots.go b/outscale/data_source_outscale_snapshots.go index 04e97927d..2aab45061 100644 --- a/outscale/data_source_outscale_snapshots.go +++ b/outscale/data_source_outscale_snapshots.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -137,7 +136,7 @@ func dataSourceOutscaleOAPISnapshotsRead(d *schema.ResourceData, meta interface{ var resp oscgo.ReadSnapshotsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(params)}) + resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { diff --git a/outscale/data_source_outscale_subnet.go b/outscale/data_source_outscale_subnet.go index 65490e10f..3726f043a 100644 --- a/outscale/data_source_outscale_subnet.go +++ b/outscale/data_source_outscale_subnet.go @@ -9,8 +9,7 @@ import ( "github.com/spf13/cast" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -78,7 +77,7 @@ func dataSourceOutscaleOAPISubnetRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadSubnetsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { - r, _, err := conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ReadSubnetsRequest: optional.NewInterface(req)}) + r, _, err := conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -143,10 +142,10 @@ func buildOutscaleOAPISubnetDataSourceFilters(set *schema.Set) *oscgo.FiltersSub for _, v := range set.List() { m := v.(map[string]interface{}) var filterValues []string - var availableIPsCounts []int64 + var availableIPsCounts []int32 for _, e := range m["values"].([]interface{}) { filterValues = append(filterValues, e.(string)) - availableIPsCounts = append(availableIPsCounts, cast.ToInt64(e)) + availableIPsCounts = append(availableIPsCounts, cast.ToInt32(e)) } switch name := m["name"].(string); name { diff --git a/outscale/data_source_outscale_subnets.go b/outscale/data_source_outscale_subnets.go index f8454adcd..0788c8a8a 100644 --- a/outscale/data_source_outscale_subnets.go +++ b/outscale/data_source_outscale_subnets.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -95,7 +94,7 @@ func dataSourceOutscaleOAPISubnetsRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadSubnetsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ReadSubnetsRequest: optional.NewInterface(req)}) + resp, _, err = conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_tag.go b/outscale/data_source_outscale_tag.go index 3b48f03cc..11554fb21 100644 --- a/outscale/data_source_outscale_tag.go +++ b/outscale/data_source_outscale_tag.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -55,7 +54,7 @@ func dataSourceOutscaleOAPITagRead(d *schema.ResourceData, meta interface{}) err var err error err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.TagApi.ReadTags(context.Background(), &oscgo.ReadTagsOpts{ReadTagsRequest: optional.NewInterface(params)}) + resp, _, err = conn.TagApi.ReadTags(context.Background()).ReadTagsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_tags.go b/outscale/data_source_outscale_tags.go index e59eadce5..89cd61d9b 100644 --- a/outscale/data_source_outscale_tags.go +++ b/outscale/data_source_outscale_tags.go @@ -5,8 +5,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -60,7 +59,7 @@ func dataSourceOutscaleOAPITagsRead(d *schema.ResourceData, meta interface{}) er var err error err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.TagApi.ReadTags(context.Background(), &oscgo.ReadTagsOpts{ReadTagsRequest: optional.NewInterface(params)}) + resp, _, err = conn.TagApi.ReadTags(context.Background()).ReadTagsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_virtual_gateway.go b/outscale/data_source_outscale_virtual_gateway.go index d73b1ea54..4040688ef 100644 --- a/outscale/data_source_outscale_virtual_gateway.go +++ b/outscale/data_source_outscale_virtual_gateway.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "log" "strings" "time" @@ -84,7 +83,7 @@ func dataSourceOutscaleOAPIVirtualGatewayRead(d *schema.ResourceData, meta inter var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(params)}) + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_virtual_gateways.go b/outscale/data_source_outscale_virtual_gateways.go index 21336c7b2..14a1f39f2 100644 --- a/outscale/data_source_outscale_virtual_gateways.go +++ b/outscale/data_source_outscale_virtual_gateways.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "strings" "time" @@ -89,7 +88,7 @@ func dataSourceOutscaleOAPIVirtualGatewaysRead(d *schema.ResourceData, meta inte var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(params)}) + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_vm.go b/outscale/data_source_outscale_vm.go index 4400899d8..763c652c8 100644 --- a/outscale/data_source_outscale_vm.go +++ b/outscale/data_source_outscale_vm.go @@ -8,11 +8,10 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/aws/aws-sdk-go/aws" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func dataSourceOutscaleOAPIVM() *schema.Resource { @@ -44,9 +43,7 @@ func dataSourceOutscaleOAPIVMRead(d *schema.ResourceData, meta interface{}) erro var resp oscgo.ReadVmsResponse err := resource.Retry(30*time.Second, func() *resource.RetryError { - r, _, err := client.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ - ReadVmsRequest: optional.NewInterface(params), - }) + r, _, err := client.VmApi.ReadVms(context.Background()).ReadVmsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_vm_state.go b/outscale/data_source_outscale_vm_state.go index 079312a0f..4d0f863fa 100644 --- a/outscale/data_source_outscale_vm_state.go +++ b/outscale/data_source_outscale_vm_state.go @@ -8,8 +8,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -106,7 +105,7 @@ func dataSourceOutscaleOAPIVMStateRead(d *schema.ResourceData, meta interface{}) var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VmApi.ReadVmsState(context.Background(), &oscgo.ReadVmsStateOpts{ReadVmsStateRequest: optional.NewInterface(params)}) + resp, _, err = conn.VmApi.ReadVmsState(context.Background()).ReadVmsStateRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_vms.go b/outscale/data_source_outscale_vms.go index cb92834a6..9996b9a43 100644 --- a/outscale/data_source_outscale_vms.go +++ b/outscale/data_source_outscale_vms.go @@ -8,10 +8,9 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func datasourceOutscaleOApiVMS() *schema.Resource { @@ -84,9 +83,7 @@ func dataSourceOutscaleOApiVMSRead(d *schema.ResourceData, meta interface{}) err var resp oscgo.ReadVmsResponse err := resource.Retry(30*time.Second, func() *resource.RetryError { - r, _, err := client.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ - ReadVmsRequest: optional.NewInterface(params), - }) + r, _, err := client.VmApi.ReadVms(context.Background()).ReadVmsRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/data_source_outscale_vms_state.go b/outscale/data_source_outscale_vms_state.go index 9be5f4846..7196599a6 100644 --- a/outscale/data_source_outscale_vms_state.go +++ b/outscale/data_source_outscale_vms_state.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -69,7 +68,7 @@ func dataSourceOutscaleOAPIVMSStateRead(d *schema.ResourceData, meta interface{} var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VmApi.ReadVmsState(context.Background(), &oscgo.ReadVmsStateOpts{ReadVmsStateRequest: optional.NewInterface(params)}) + resp, _, err = conn.VmApi.ReadVmsState(context.Background()).ReadVmsStateRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_volume.go b/outscale/data_source_outscale_volume.go index ade94355a..7c8ccbc65 100644 --- a/outscale/data_source_outscale_volume.go +++ b/outscale/data_source_outscale_volume.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/davecgh/go-spew/spew" @@ -111,7 +110,7 @@ func datasourceOAPIVolumeRead(d *schema.ResourceData, meta interface{}) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(params)}) + resp, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -237,7 +236,7 @@ func buildOutscaleOSCAPIDataSourceVolumesFilters(set *schema.Set) oscgo.FiltersV case "volume_ids": filters.SetVolumeIds(filterValues) case "volume_sizes": - filters.SetVolumeSizes(utils.StringSliceToInt64Slice(filterValues)) + filters.SetVolumeSizes(utils.StringSliceToInt32Slice(filterValues)) case "volume_types": filters.SetVolumeTypes(filterValues) case "link_volume_vm_ids": diff --git a/outscale/data_source_outscale_volumes.go b/outscale/data_source_outscale_volumes.go index ecbc65d3f..39c0f0791 100644 --- a/outscale/data_source_outscale_volumes.go +++ b/outscale/data_source_outscale_volumes.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/davecgh/go-spew/spew" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -124,7 +123,7 @@ func datasourceOAPIVolumesRead(d *schema.ResourceData, meta interface{}) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(params)}) + resp, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(params).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_vpn_connection.go b/outscale/data_source_outscale_vpn_connection.go index ffe5df39b..17256f184 100644 --- a/outscale/data_source_outscale_vpn_connection.go +++ b/outscale/data_source_outscale_vpn_connection.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -102,9 +101,7 @@ func dataSourceOutscaleVPNConnectionRead(d *schema.ResourceData, meta interface{ var resp oscgo.ReadVpnConnectionsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(params), - }) + resp, _, err = conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -172,9 +169,9 @@ func buildOutscaleDataSourceVPNConnectionFilters(set *schema.Set) *oscgo.Filters filterValues = append(filterValues, e.(string)) } - var filteBgpAsnsValues []int64 + var filteBgpAsnsValues []int32 for _, e := range m["values"].([]interface{}) { - filteBgpAsnsValues = append(filteBgpAsnsValues, cast.ToInt64(e)) + filteBgpAsnsValues = append(filteBgpAsnsValues, cast.ToInt32(e)) } switch name := m["name"].(string); name { diff --git a/outscale/data_source_outscale_vpn_connections.go b/outscale/data_source_outscale_vpn_connections.go index 8faa80a13..afeef3123 100644 --- a/outscale/data_source_outscale_vpn_connections.go +++ b/outscale/data_source_outscale_vpn_connections.go @@ -7,10 +7,9 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func dataSourceOutscaleVPNConnections() *schema.Resource { @@ -115,9 +114,7 @@ func dataSourceOutscaleVPNConnectionsRead(d *schema.ResourceData, meta interface var resp oscgo.ReadVpnConnectionsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(params), - }) + resp, _, err = conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/instance_set_set.go b/outscale/instance_set_set.go index 83d66ce11..94757a1ea 100644 --- a/outscale/instance_set_set.go +++ b/outscale/instance_set_set.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/hashcode" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func getOAPISecurityGroups(groups []oscgo.SecurityGroupLight) (SecurityGroup []map[string]interface{}, SecurityGroupIds []string) { diff --git a/outscale/oapi_tags.go b/outscale/oapi_tags.go index 30c25fbd7..da01e0d8d 100644 --- a/outscale/oapi_tags.go +++ b/outscale/oapi_tags.go @@ -8,10 +8,9 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func setOSCAPITags(conn *oscgo.APIClient, d *schema.ResourceData) error { @@ -25,10 +24,10 @@ func setOSCAPITags(conn *oscgo.APIClient, d *schema.ResourceData) error { // Set tag if len(remove) > 0 { err := resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err := conn.TagApi.DeleteTags(context.Background(), &oscgo.DeleteTagsOpts{DeleteTagsRequest: optional.NewInterface(oscgo.DeleteTagsRequest{ + _, _, err := conn.TagApi.DeleteTags(context.Background()).DeleteTagsRequest(oscgo.DeleteTagsRequest{ ResourceIds: []string{d.Id()}, Tags: remove, - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), ".NotFound") { return resource.RetryableError(err) // retry @@ -43,10 +42,10 @@ func setOSCAPITags(conn *oscgo.APIClient, d *schema.ResourceData) error { } if len(create) > 0 { err := resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err := conn.TagApi.CreateTags(context.Background(), &oscgo.CreateTagsOpts{CreateTagsRequest: optional.NewInterface(oscgo.CreateTagsRequest{ + _, _, err := conn.TagApi.CreateTags(context.Background()).CreateTagsRequest(oscgo.CreateTagsRequest{ ResourceIds: []string{d.Id()}, Tags: create, - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), ".NotFound") { return resource.RetryableError(err) // retry @@ -201,9 +200,7 @@ func assignTags(tag *schema.Set, resourceID string, conn *oscgo.APIClient) error request.Tags = tagsFromSliceMap(tag) request.ResourceIds = []string{resourceID} err := resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err := conn.TagApi.CreateTags(context.Background(), &oscgo.CreateTagsOpts{ - CreateTagsRequest: optional.NewInterface(request), - }) + _, _, err := conn.TagApi.CreateTags(context.Background()).CreateTagsRequest(request).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "NotFound") { diff --git a/outscale/resource_outscale_access_key.go b/outscale/resource_outscale_access_key.go index 2a04c6e9f..c41ba86dd 100644 --- a/outscale/resource_outscale_access_key.go +++ b/outscale/resource_outscale_access_key.go @@ -6,12 +6,10 @@ import ( "strings" "time" - "github.com/antihax/optional" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" "github.com/hashicorp/terraform-plugin-sdk/helper/validation" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleAccessKey() *schema.Resource { @@ -61,7 +59,7 @@ func resourceOutscaleAccessKeyCreate(d *schema.ResourceData, meta interface{}) e var res oscgo.CreateAccessKeyResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - res, _, err = conn.AccessKeyApi.CreateAccessKey(context.Background()) + res, _, err = conn.AccessKeyApi.CreateAccessKey(context.Background()).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -92,9 +90,7 @@ func resourceOutscaleAccessKeyRead(d *schema.ResourceData, meta interface{}) err AccessKeyId: d.Id(), } - resp, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background(), &oscgo.ReadSecretAccessKeyOpts{ - ReadSecretAccessKeyRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background()).ReadSecretAccessKeyRequest(filter).Execute() if err != nil { return err } @@ -148,9 +144,7 @@ func resourceOutscaleAccessKeyDelete(d *schema.ResourceData, meta interface{}) e var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.AccessKeyApi.DeleteAccessKey(context.Background(), &oscgo.DeleteAccessKeyOpts{ - DeleteAccessKeyRequest: optional.NewInterface(req), - }) + _, _, err = conn.AccessKeyApi.DeleteAccessKey(context.Background()).DeleteAccessKeyRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -172,9 +166,7 @@ func updateAccessKey(conn *oscgo.APIClient, id, state string) error { State: state, } - _, _, err := conn.AccessKeyApi.UpdateAccessKey(context.Background(), &oscgo.UpdateAccessKeyOpts{ - UpdateAccessKeyRequest: optional.NewInterface(req), - }) + _, _, err := conn.AccessKeyApi.UpdateAccessKey(context.Background()).UpdateAccessKeyRequest(req).Execute() if err != nil { return err } diff --git a/outscale/resource_outscale_access_key_test.go b/outscale/resource_outscale_access_key_test.go index b16508753..90f6ac2e2 100644 --- a/outscale/resource_outscale_access_key_test.go +++ b/outscale/resource_outscale_access_key_test.go @@ -5,10 +5,9 @@ import ( "fmt" "testing" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func TestAccOutscaleAccessKey_basic(t *testing.T) { @@ -139,9 +138,7 @@ func testAccCheckOutscaleAccessKeyExists(resourceName string) resource.TestCheck AccessKeyId: rs.Primary.ID, } - _, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background(), &oscgo.ReadSecretAccessKeyOpts{ - ReadSecretAccessKeyRequest: optional.NewInterface(filter), - }) + _, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background()).ReadSecretAccessKeyRequest(filter).Execute() if err != nil { return fmt.Errorf("Outscale Access Key not found (%s)", rs.Primary.ID) } @@ -161,9 +158,7 @@ func testAccCheckOutscaleAccessKeyDestroy(s *terraform.State) error { AccessKeyId: rs.Primary.ID, } - _, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background(), &oscgo.ReadSecretAccessKeyOpts{ - ReadSecretAccessKeyRequest: optional.NewInterface(filter), - }) + _, _, err := conn.AccessKeyApi.ReadSecretAccessKey(context.Background()).ReadSecretAccessKeyRequest(filter).Execute() if err != nil { return fmt.Errorf("Outscale Access Key still exists (%s)", rs.Primary.ID) } diff --git a/outscale/resource_outscale_client_gateway.go b/outscale/resource_outscale_client_gateway.go index a15c648ab..db8d650f7 100644 --- a/outscale/resource_outscale_client_gateway.go +++ b/outscale/resource_outscale_client_gateway.go @@ -6,13 +6,12 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleClientGateway() *schema.Resource { @@ -62,15 +61,12 @@ func resourceOutscaleClientGatewayCreate(d *schema.ResourceData, meta interface{ conn := meta.(*OutscaleClient).OSCAPI req := oscgo.CreateClientGatewayRequest{ - BgpAsn: cast.ToInt64(d.Get("bgp_asn")), + BgpAsn: cast.ToInt32(d.Get("bgp_asn")), ConnectionType: d.Get("connection_type").(string), PublicIp: d.Get("public_ip").(string), } - client, _, err := conn.ClientGatewayApi.CreateClientGateway(context.Background(), - &oscgo.CreateClientGatewayOpts{ - CreateClientGatewayRequest: optional.NewInterface(req), - }) + client, _, err := conn.ClientGatewayApi.CreateClientGateway(context.Background()).CreateClientGatewayRequest(req).Execute() if err != nil { return err } @@ -157,9 +153,7 @@ func resourceOutscaleClientGatewayDelete(d *schema.ResourceData, meta interface{ ClientGatewayId: gatewayID, } - _, _, err := conn.ClientGatewayApi.DeleteClientGateway(context.Background(), &oscgo.DeleteClientGatewayOpts{ - DeleteClientGatewayRequest: optional.NewInterface(req), - }) + _, _, err := conn.ClientGatewayApi.DeleteClientGateway(context.Background()).DeleteClientGatewayRequest(req).Execute() if err != nil { return err } @@ -190,9 +184,7 @@ func clientGatewayRefreshFunc(conn *oscgo.APIClient, gatewayID *string) resource }, } - resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background(), &oscgo.ReadClientGatewaysOpts{ - ReadClientGatewaysRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(filter).Execute() if err != nil { switch { case strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:"): diff --git a/outscale/resource_outscale_client_gateway_test.go b/outscale/resource_outscale_client_gateway_test.go index 55527f204..0517dfc7f 100644 --- a/outscale/resource_outscale_client_gateway_test.go +++ b/outscale/resource_outscale_client_gateway_test.go @@ -5,11 +5,10 @@ import ( "fmt" "testing" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" ) @@ -102,9 +101,7 @@ func testAccCheckClientGatewayExists(resourceName string) resource.TestCheckFunc }, } - resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background(), &oscgo.ReadClientGatewaysOpts{ - ReadClientGatewaysRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(filter).Execute() if err != nil || len(resp.GetClientGateways()) < 1 { return fmt.Errorf("Outscale Client Gateway not found (%s)", rs.Primary.ID) } @@ -126,9 +123,7 @@ func testAccCheckClientGatewayDestroy(s *terraform.State) error { }, } - resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background(), &oscgo.ReadClientGatewaysOpts{ - ReadClientGatewaysRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(filter).Execute() if err != nil || len(resp.GetClientGateways()) > 0 && resp.GetClientGateways()[0].GetState() != "deleted" { return fmt.Errorf("Outscale Client Gateway still exists (%s): %s", rs.Primary.ID, err) diff --git a/outscale/resource_outscale_dhcp_option.go b/outscale/resource_outscale_dhcp_option.go index aff36643e..74e77ed49 100644 --- a/outscale/resource_outscale_dhcp_option.go +++ b/outscale/resource_outscale_dhcp_option.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -116,8 +115,8 @@ func resourceOutscaleDHCPOptionRead(d *schema.ResourceData, meta interface{}) er return err } - dhcps, ok := resp.GetDhcpOptionsSetsOk() - if !ok { + dhcps := resp.GetDhcpOptionsSets() + if len(dhcps) == 0 { d.SetId("") return nil } @@ -192,9 +191,7 @@ func createDhcpOption(conn *oscgo.APIClient, dhcp oscgo.CreateDhcpOptionsRequest var resp oscgo.CreateDhcpOptionsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.DhcpOptionApi.CreateDhcpOptions(context.Background(), &oscgo.CreateDhcpOptionsOpts{ - CreateDhcpOptionsRequest: optional.NewInterface(dhcp), - }) + resp, _, err = conn.DhcpOptionApi.CreateDhcpOptions(context.Background()).CreateDhcpOptionsRequest(dhcp).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -218,9 +215,7 @@ func readDhcpOption(conn *oscgo.APIClient, dhcpID string) (*oscgo.DhcpOptionsSet var resp oscgo.ReadDhcpOptionsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background(), &oscgo.ReadDhcpOptionsOpts{ - ReadDhcpOptionsRequest: optional.NewInterface(filterRequest), - }) + resp, _, err = conn.DhcpOptionApi.ReadDhcpOptions(context.Background()).ReadDhcpOptionsRequest(filterRequest).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -233,8 +228,8 @@ func readDhcpOption(conn *oscgo.APIClient, dhcpID string) (*oscgo.DhcpOptionsSet return nil, &resp, err } - dhcps, ok := resp.GetDhcpOptionsSetsOk() - if !ok || len(dhcps) == 0 { + dhcps := resp.GetDhcpOptionsSets() + if len(dhcps) == 0 { return nil, &resp, fmt.Errorf("the Outscale DHCP Option is not found %s", dhcpID) } @@ -243,11 +238,9 @@ func readDhcpOption(conn *oscgo.APIClient, dhcpID string) (*oscgo.DhcpOptionsSet func deleteDhcpOptions(conn *oscgo.APIClient, dhcpID string) error { err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.DhcpOptionApi.DeleteDhcpOptions(context.Background(), &oscgo.DeleteDhcpOptionsOpts{ - DeleteDhcpOptionsRequest: optional.NewInterface(oscgo.DeleteDhcpOptionsRequest{ - DhcpOptionsSetId: dhcpID, - }), - }) + _, _, err := conn.DhcpOptionApi.DeleteDhcpOptions(context.Background()).DeleteDhcpOptionsRequest(oscgo.DeleteDhcpOptionsRequest{ + DhcpOptionsSetId: dhcpID, + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -264,14 +257,11 @@ func getAttachedDHCPs(conn *oscgo.APIClient, dhcpID string) ([]oscgo.Net, error) var resp oscgo.ReadNetsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), - &oscgo.ReadNetsOpts{ - ReadNetsRequest: optional.NewInterface(oscgo.ReadNetsRequest{ - Filters: &oscgo.FiltersNet{ - DhcpOptionsSetIds: &[]string{dhcpID}, - }, - }), - }) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(oscgo.ReadNetsRequest{ + Filters: &oscgo.FiltersNet{ + DhcpOptionsSetIds: &[]string{dhcpID}, + }, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -291,12 +281,10 @@ func getAttachedDHCPs(conn *oscgo.APIClient, dhcpID string) ([]oscgo.Net, error) func detachDHCPs(conn *oscgo.APIClient, nets []oscgo.Net) error { // Detaching the dhcp of the nets for _, net := range nets { - _, _, err := conn.NetApi.UpdateNet(context.Background(), &oscgo.UpdateNetOpts{ - UpdateNetRequest: optional.NewInterface(oscgo.UpdateNetRequest{ - DhcpOptionsSetId: "default", - NetId: net.GetNetId(), - }), - }) + _, _, err := conn.NetApi.UpdateNet(context.Background()).UpdateNetRequest(oscgo.UpdateNetRequest{ + DhcpOptionsSetId: "default", + NetId: net.GetNetId(), + }).Execute() if err != nil { return fmt.Errorf("Error updating net(%s) in DHCP Option resource: %s", net.GetNetId(), err) } diff --git a/outscale/resource_outscale_dhcp_option_test.go b/outscale/resource_outscale_dhcp_option_test.go index c4286d536..09c5b4e18 100644 --- a/outscale/resource_outscale_dhcp_option_test.go +++ b/outscale/resource_outscale_dhcp_option_test.go @@ -6,13 +6,12 @@ import ( "strings" "testing" - "github.com/antihax/optional" "github.com/openlyinc/pointy" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" "github.com/hashicorp/terraform/helper/acctest" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func TestAccOutscaleOAPIDhcpOptional_basic(t *testing.T) { @@ -204,11 +203,9 @@ func testAccCheckOutscaleDHCPOptionExists(n string) resource.TestCheckFunc { return fmt.Errorf("No DHCP Option id is set") } - resp, _, err := conn.DhcpOptionApi.ReadDhcpOptions(context.Background(), &oscgo.ReadDhcpOptionsOpts{ - ReadDhcpOptionsRequest: optional.NewInterface(oscgo.ReadDhcpOptionsRequest{ - Filters: &oscgo.FiltersDhcpOptions{DhcpOptionsSetIds: &[]string{rs.Primary.ID}}, - }), - }) + resp, _, err := conn.DhcpOptionApi.ReadDhcpOptions(context.Background()).ReadDhcpOptionsRequest(oscgo.ReadDhcpOptionsRequest{ + Filters: &oscgo.FiltersDhcpOptions{DhcpOptionsSetIds: &[]string{rs.Primary.ID}}, + }).Execute() if err != nil || len(resp.GetDhcpOptionsSets()) < 1 { return fmt.Errorf("DHCP Option is not found (%s)", rs.Primary.ID) } @@ -224,11 +221,9 @@ func testAccCheckOAPIDHCPOptionDestroy(s *terraform.State) error { continue } - resp, _, err := conn.DhcpOptionApi.ReadDhcpOptions(context.Background(), &oscgo.ReadDhcpOptionsOpts{ - ReadDhcpOptionsRequest: optional.NewInterface(oscgo.ReadDhcpOptionsRequest{ - Filters: &oscgo.FiltersDhcpOptions{DhcpOptionsSetIds: &[]string{rs.Primary.ID}}, - }), - }) + resp, _, err := conn.DhcpOptionApi.ReadDhcpOptions(context.Background()).ReadDhcpOptionsRequest(oscgo.ReadDhcpOptionsRequest{ + Filters: &oscgo.FiltersDhcpOptions{DhcpOptionsSetIds: &[]string{rs.Primary.ID}}, + }).Execute() if strings.Contains(fmt.Sprint(err), "InvalidDhcpID.NotFound") { continue } diff --git a/outscale/resource_outscale_image.go b/outscale/resource_outscale_image.go index db2b326f7..196864820 100644 --- a/outscale/resource_outscale_image.go +++ b/outscale/resource_outscale_image.go @@ -6,9 +6,7 @@ import ( "log" "time" - "github.com/antihax/optional" - - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/openlyinc/pointy" "github.com/spf13/cast" @@ -221,9 +219,7 @@ func resourceOAPIImageCreate(d *schema.ResourceData, meta interface{}) error { imageRequest.SetRootDeviceName(v) } - resp, _, err := conn.ImageApi.CreateImage(context.Background(), &oscgo.CreateImageOpts{ - CreateImageRequest: optional.NewInterface(imageRequest), - }) + resp, _, err := conn.ImageApi.CreateImage(context.Background()).CreateImageRequest(imageRequest).Execute() if err != nil { return err } @@ -236,16 +232,12 @@ func resourceOAPIImageCreate(d *schema.ResourceData, meta interface{}) error { log.Printf("[DEBUG] Waiting for OMI %s to become available...", *image.ImageId) - filterReq := &oscgo.ReadImagesOpts{ - ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ - Filters: &oscgo.FiltersImage{ImageIds: &[]string{*image.ImageId}}, - }), - } + req := oscgo.ReadImagesRequest{Filters: &oscgo.FiltersImage{ImageIds: &[]string{*image.ImageId}}} stateConf := &resource.StateChangeConf{ Pending: []string{"pending"}, Target: []string{"available"}, - Refresh: ImageOAPIStateRefreshFunc(conn, filterReq, "failed"), + Refresh: ImageOAPIStateRefreshFunc(conn, req, "failed"), Timeout: 10 * time.Minute, MinTimeout: 30 * time.Second, Delay: 1 * time.Minute, @@ -272,13 +264,11 @@ func resourceOAPIImageRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI id := d.Id() - req := &oscgo.ReadImagesOpts{ - ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ - Filters: &oscgo.FiltersImage{ImageIds: &[]string{id}}, - }), + req := oscgo.ReadImagesRequest{ + Filters: &oscgo.FiltersImage{ImageIds: &[]string{id}}, } - resp, _, err := conn.ImageApi.ReadImages(context.Background(), req) + resp, _, err := conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(req).Execute() if err != nil { return fmt.Errorf("Error reading for OMI (%s): %v", id, err) } @@ -376,11 +366,9 @@ func resourceOAPIImageUpdate(d *schema.ResourceData, meta interface{}) error { func resourceOAPIImageDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - _, _, err := conn.ImageApi.DeleteImage(context.Background(), &oscgo.DeleteImageOpts{ - DeleteImageRequest: optional.NewInterface(oscgo.DeleteImageRequest{ - ImageId: d.Id(), - }), - }) + _, _, err := conn.ImageApi.DeleteImage(context.Background()).DeleteImageRequest(oscgo.DeleteImageRequest{ + ImageId: d.Id(), + }).Execute() if err != nil { return fmt.Errorf("Error deleting the image") @@ -397,10 +385,8 @@ func resourceOAPIImageDelete(d *schema.ResourceData, meta interface{}) error { func resourceOutscaleOAPIImageWaitForDestroy(id string, conn *oscgo.APIClient) error { log.Printf("[INFO] Waiting for OMI %s to be deleted...", id) - filterReq := &oscgo.ReadImagesOpts{ - ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ - Filters: &oscgo.FiltersImage{ImageIds: &[]string{id}}, - }), + filterReq := oscgo.ReadImagesRequest{ + Filters: &oscgo.FiltersImage{ImageIds: &[]string{id}}, } stateConf := &resource.StateChangeConf{ @@ -420,9 +406,9 @@ func resourceOutscaleOAPIImageWaitForDestroy(id string, conn *oscgo.APIClient) e } // ImageOAPIStateRefreshFunc ... -func ImageOAPIStateRefreshFunc(client *oscgo.APIClient, req *oscgo.ReadImagesOpts, failState string) resource.StateRefreshFunc { +func ImageOAPIStateRefreshFunc(client *oscgo.APIClient, req oscgo.ReadImagesRequest, failState string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := client.ImageApi.ReadImages(context.Background(), req) + resp, _, err := client.ImageApi.ReadImages(context.Background()).ReadImagesRequest(req).Execute() if err != nil { return nil, "failed", err } diff --git a/outscale/resource_outscale_image_launch_permission.go b/outscale/resource_outscale_image_launch_permission.go index fced87b51..26cb15ff0 100644 --- a/outscale/resource_outscale_image_launch_permission.go +++ b/outscale/resource_outscale_image_launch_permission.go @@ -8,8 +8,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" @@ -156,7 +155,7 @@ func resourceOutscaleOAPIImageLaunchPermissionCreate(d *schema.ResourceData, met err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - _, _, err = conn.ImageApi.UpdateImage(context.Background(), &oscgo.UpdateImageOpts{UpdateImageRequest: optional.NewInterface(request)}) + _, _, err = conn.ImageApi.UpdateImage(context.Background()).UpdateImageRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -185,11 +184,11 @@ func resourceOutscaleOAPIImageLaunchPermissionRead(d *schema.ResourceData, meta var resp oscgo.ReadImagesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ImageApi.ReadImages(context.Background(), &oscgo.ReadImagesOpts{ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ + resp, _, err = conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(oscgo.ReadImagesRequest{ Filters: &oscgo.FiltersImage{ ImageIds: &[]string{d.Id()}, }, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -247,7 +246,7 @@ func resourceOutscaleOAPIImageLaunchPermissionDelete(d *schema.ResourceData, met err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - _, _, err = conn.ImageApi.UpdateImage(context.Background(), &oscgo.UpdateImageOpts{UpdateImageRequest: optional.NewInterface(request)}) + _, _, err = conn.ImageApi.UpdateImage(context.Background()).UpdateImageRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -274,11 +273,11 @@ func hasOAPILaunchPermission(conn *oscgo.APIClient, imageID string) (bool, error var resp oscgo.ReadImagesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ImageApi.ReadImages(context.Background(), &oscgo.ReadImagesOpts{ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ + resp, _, err = conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(oscgo.ReadImagesRequest{ Filters: &oscgo.FiltersImage{ ImageIds: &[]string{imageID}, }, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_image_launch_permission_test.go b/outscale/resource_outscale_image_launch_permission_test.go index fb8c106a4..971aca212 100644 --- a/outscale/resource_outscale_image_launch_permission_test.go +++ b/outscale/resource_outscale_image_launch_permission_test.go @@ -9,8 +9,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws" r "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -152,7 +151,7 @@ func testAccOutscaleOAPIImageDisappears(imageID *string) r.TestCheckFunc { err := r.Retry(5*time.Minute, func() *r.RetryError { var err error - _, _, err = conn.ImageApi.DeleteImage(context.Background(), &oscgo.DeleteImageOpts{DeleteImageRequest: optional.NewInterface(req)}) + _, _, err = conn.ImageApi.DeleteImage(context.Background()).DeleteImageRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return r.RetryableError(err) diff --git a/outscale/resource_outscale_image_test.go b/outscale/resource_outscale_image_test.go index c81ddf391..6b1f24f01 100644 --- a/outscale/resource_outscale_image_test.go +++ b/outscale/resource_outscale_image_test.go @@ -6,8 +6,7 @@ import ( "os" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -52,13 +51,11 @@ func testAccCheckOAPIImageDestroy(s *terraform.State) error { continue } - filterReq := &oscgo.ReadImagesOpts{ - ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ - Filters: &oscgo.FiltersImage{ImageIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadImagesRequest{ + Filters: &oscgo.FiltersImage{ImageIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.ImageApi.ReadImages(context.Background(), filterReq) + resp, _, err := conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(filterReq).Execute() if err != nil || len(resp.GetImages()) > 0 { return fmt.Errorf("Image still exists (%s)", rs.Primary.ID) } @@ -79,13 +76,11 @@ func testAccCheckOAPIImageExists(n string, ami *oscgo.Image) resource.TestCheckF conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI - filterReq := &oscgo.ReadImagesOpts{ - ReadImagesRequest: optional.NewInterface(oscgo.ReadImagesRequest{ - Filters: &oscgo.FiltersImage{ImageIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadImagesRequest{ + Filters: &oscgo.FiltersImage{ImageIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.ImageApi.ReadImages(context.Background(), filterReq) + resp, _, err := conn.ImageApi.ReadImages(context.Background()).ReadImagesRequest(filterReq).Execute() if err != nil || len(resp.GetImages()) < 1 { return fmt.Errorf("Image not found (%s)", rs.Primary.ID) } diff --git a/outscale/resource_outscale_internet_service.go b/outscale/resource_outscale_internet_service.go index 4b4df45fa..c284cd0b1 100644 --- a/outscale/resource_outscale_internet_service.go +++ b/outscale/resource_outscale_internet_service.go @@ -7,12 +7,11 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleOAPIInternetService() *schema.Resource { @@ -50,9 +49,7 @@ func resourceOutscaleOAPIInternetService() *schema.Resource { func resourceOutscaleOAPIInternetServiceCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - resp, _, err := conn.InternetServiceApi.CreateInternetService(context.Background(), &oscgo.CreateInternetServiceOpts{ - CreateInternetServiceRequest: optional.NewInterface(oscgo.CreateInternetServiceRequest{}), - }) + resp, _, err := conn.InternetServiceApi.CreateInternetService(context.Background()).CreateInternetServiceRequest(oscgo.CreateInternetServiceRequest{}).Execute() if err != nil { return fmt.Errorf("[DEBUG] Error creating Internet Service: %s", utils.GetErrorResponse(err)) } @@ -83,7 +80,7 @@ func resourceOutscaleOAPIInternetServiceRead(d *schema.ResourceData, meta interf var resp oscgo.ReadInternetServicesResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { - r, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), &oscgo.ReadInternetServicesOpts{ReadInternetServicesRequest: optional.NewInterface(req)}) + r, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -140,10 +137,8 @@ func resourceOutscaleOAPIInternetServiceDelete(d *schema.ResourceData, meta inte conn := meta.(*OutscaleClient).OSCAPI internetServiceID := d.Id() - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, } stateConf := &resource.StateChangeConf{ @@ -164,9 +159,7 @@ func resourceOutscaleOAPIInternetServiceDelete(d *schema.ResourceData, meta inte InternetServiceId: internetServiceID, } - _, _, err = conn.InternetServiceApi.DeleteInternetService(context.Background(), &oscgo.DeleteInternetServiceOpts{ - DeleteInternetServiceRequest: optional.NewInterface(req), - }) + _, _, err = conn.InternetServiceApi.DeleteInternetService(context.Background()).DeleteInternetServiceRequest(req).Execute() if err != nil { return fmt.Errorf("[DEBUG] Error deleting Internet Service id (%s)", err) } diff --git a/outscale/resource_outscale_internet_service_link.go b/outscale/resource_outscale_internet_service_link.go index 311e142a4..245e14b1f 100644 --- a/outscale/resource_outscale_internet_service_link.go +++ b/outscale/resource_outscale_internet_service_link.go @@ -6,9 +6,7 @@ import ( "fmt" "time" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/antihax/optional" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -69,14 +67,12 @@ func resourceOutscaleOAPIInternetServiceLinkCreate(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI internetServiceID := d.Get("internet_service_id").(string) - req := &oscgo.LinkInternetServiceOpts{ - LinkInternetServiceRequest: optional.NewInterface(oscgo.LinkInternetServiceRequest{ - InternetServiceId: internetServiceID, - NetId: d.Get("net_id").(string), - }), + req := oscgo.LinkInternetServiceRequest{ + InternetServiceId: internetServiceID, + NetId: d.Get("net_id").(string), } - resp, _, err := conn.InternetServiceApi.LinkInternetService(context.Background(), req) + resp, _, err := conn.InternetServiceApi.LinkInternetService(context.Background()).LinkInternetServiceRequest(req).Execute() if err != nil { return fmt.Errorf("Error Link Internet Service: %s", err.Error()) } @@ -85,10 +81,8 @@ func resourceOutscaleOAPIInternetServiceLinkCreate(d *schema.ResourceData, meta return fmt.Errorf("Error there is not Link Internet Service (%s)", err) } - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, } stateConf := &resource.StateChangeConf{ @@ -116,10 +110,8 @@ func resourceOutscaleOAPIInternetServiceLinkRead(d *schema.ResourceData, meta in conn := meta.(*OutscaleClient).OSCAPI internetServiceID := d.Id() - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, } stateConf := &resource.StateChangeConf{ @@ -167,10 +159,8 @@ func resourceOutscaleOAPIInternetServiceLinkDelete(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI internetServiceID := d.Id() - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{internetServiceID}}, } stateConf := &resource.StateChangeConf{ @@ -190,14 +180,12 @@ func resourceOutscaleOAPIInternetServiceLinkDelete(d *schema.ResourceData, meta resp := value.(oscgo.ReadInternetServicesResponse) internetService := resp.GetInternetServices()[0] - req := &oscgo.UnlinkInternetServiceOpts{ - UnlinkInternetServiceRequest: optional.NewInterface(oscgo.UnlinkInternetServiceRequest{ - InternetServiceId: internetService.GetInternetServiceId(), - NetId: internetService.GetNetId(), - }), + req := oscgo.UnlinkInternetServiceRequest{ + InternetServiceId: internetService.GetInternetServiceId(), + NetId: internetService.GetNetId(), } - _, _, err = conn.InternetServiceApi.UnlinkInternetService(context.Background(), req) + _, _, err = conn.InternetServiceApi.UnlinkInternetService(context.Background()).UnlinkInternetServiceRequest(req).Execute() if err != nil { return fmt.Errorf("error unlink Internet Service (%s): %s", d.Id(), err) } @@ -207,9 +195,9 @@ func resourceOutscaleOAPIInternetServiceLinkDelete(d *schema.ResourceData, meta // LISOAPIStateRefreshFunction returns a resource.StateRefreshFunc that is used to watch // a Link Internet Service. -func LISOAPIStateRefreshFunction(client *oscgo.APIClient, req *oscgo.ReadInternetServicesOpts, failState string) resource.StateRefreshFunc { +func LISOAPIStateRefreshFunction(client *oscgo.APIClient, req oscgo.ReadInternetServicesRequest, failState string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := client.InternetServiceApi.ReadInternetServices(context.Background(), req) + resp, _, err := client.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(req).Execute() if err != nil { return nil, "failed", err } diff --git a/outscale/resource_outscale_internet_service_link_test.go b/outscale/resource_outscale_internet_service_link_test.go index ea6338672..ebbee9e4c 100644 --- a/outscale/resource_outscale_internet_service_link_test.go +++ b/outscale/resource_outscale_internet_service_link_test.go @@ -5,8 +5,7 @@ import ( "fmt" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -79,13 +78,11 @@ func testAccCheckOutscaleOSCAPIInternetServiceLinkExists(n string) resource.Test return fmt.Errorf("No internet gateway id is set") } - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), filterReq) + resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(filterReq).Execute() if err != nil || len(resp.GetInternetServices()) < 1 { return fmt.Errorf("Internet Service Link not found (%s)", rs.Primary.ID) } @@ -101,13 +98,11 @@ func testAccCheckOutscaleOSCAPIInternetServiceLinkDestroyed(s *terraform.State) continue } - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), filterReq) + resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(filterReq).Execute() if err != nil || len(resp.GetInternetServices()) > 0 { return fmt.Errorf("Internet Service Link still exists (%s)", rs.Primary.ID) } diff --git a/outscale/resource_outscale_internet_service_test.go b/outscale/resource_outscale_internet_service_test.go index ca844dd19..e8783e19a 100644 --- a/outscale/resource_outscale_internet_service_test.go +++ b/outscale/resource_outscale_internet_service_test.go @@ -5,8 +5,7 @@ import ( "fmt" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -47,13 +46,11 @@ func testAccCheckOutscaleInternetServiceExists(n string) resource.TestCheckFunc return fmt.Errorf("No internet gateway id is set") } - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), filterReq) + resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(filterReq).Execute() if err != nil || len(resp.GetInternetServices()) < 1 { return fmt.Errorf("Internet Service Link not found (%s)", rs.Primary.ID) } @@ -69,13 +66,11 @@ func testAccCheckOutscaleInternetServiceDestroyed(s *terraform.State) error { continue } - filterReq := &oscgo.ReadInternetServicesOpts{ - ReadInternetServicesRequest: optional.NewInterface(oscgo.ReadInternetServicesRequest{ - Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadInternetServicesRequest{ + Filters: &oscgo.FiltersInternetService{InternetServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background(), filterReq) + resp, _, err := conn.InternetServiceApi.ReadInternetServices(context.Background()).ReadInternetServicesRequest(filterReq).Execute() if err != nil || len(resp.GetInternetServices()) > 0 { return fmt.Errorf("Internet Service Link still exists (%s)", rs.Primary.ID) } diff --git a/outscale/resource_outscale_keypair.go b/outscale/resource_outscale_keypair.go index a076606be..fd42a580d 100644 --- a/outscale/resource_outscale_keypair.go +++ b/outscale/resource_outscale_keypair.go @@ -3,11 +3,11 @@ package outscale import ( "context" "fmt" + "log" "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -57,7 +57,7 @@ func resourceOAPIKeyPairCreate(d *schema.ResourceData, meta interface{}) error { var resp oscgo.CreateKeypairResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.KeypairApi.CreateKeypair(context.Background(), &oscgo.CreateKeypairOpts{CreateKeypairRequest: optional.NewInterface(req)}) + resp, _, err = conn.KeypairApi.CreateKeypair(context.Background()).CreateKeypairRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -69,7 +69,7 @@ func resourceOAPIKeyPairCreate(d *schema.ResourceData, meta interface{}) error { }) var errString string - + log.Printf("[DEBUG] resp keypair: %+v", resp) if err != nil { errString = err.Error() return fmt.Errorf("Error creating OAPIKeyPair: %s", errString) @@ -99,7 +99,7 @@ func resourceOAPIKeyPairRead(d *schema.ResourceData, meta interface{}) error { var resp oscgo.ReadKeypairsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background(), &oscgo.ReadKeypairsOpts{ReadKeypairsRequest: optional.NewInterface(req)}) + resp, _, err = conn.KeypairApi.ReadKeypairs(context.Background()).ReadKeypairsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -150,7 +150,7 @@ func resourceOAPIKeyPairDelete(d *schema.ResourceData, meta interface{}) error { } var err error - _, _, err = conn.KeypairApi.DeleteKeypair(context.Background(), &oscgo.DeleteKeypairOpts{DeleteKeypairRequest: optional.NewInterface(request)}) + _, _, err = conn.KeypairApi.DeleteKeypair(context.Background()).DeleteKeypairRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_keypair_test.go b/outscale/resource_outscale_keypair_test.go index a36454766..9c4057161 100644 --- a/outscale/resource_outscale_keypair_test.go +++ b/outscale/resource_outscale_keypair_test.go @@ -7,8 +7,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" @@ -98,9 +97,9 @@ func testAccCheckOutscaleOAPIKeyPairDestroy(s *terraform.State) error { var resp oscgo.ReadKeypairsResponse err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.OSCAPI.KeypairApi.ReadKeypairs(context.Background(), &oscgo.ReadKeypairsOpts{ReadKeypairsRequest: optional.NewInterface(oscgo.ReadKeypairsRequest{ + resp, _, err = conn.OSCAPI.KeypairApi.ReadKeypairs(context.Background()).ReadKeypairsRequest(oscgo.ReadKeypairsRequest{ Filters: &oscgo.FiltersKeypair{KeypairNames: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -156,9 +155,9 @@ func testAccCheckOutscaleOAPIKeyPairExists(n string, res *oscgo.Keypair) resourc err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.OSCAPI.KeypairApi.ReadKeypairs(context.Background(), &oscgo.ReadKeypairsOpts{ReadKeypairsRequest: optional.NewInterface(oscgo.ReadKeypairsRequest{ + resp, _, err = conn.OSCAPI.KeypairApi.ReadKeypairs(context.Background()).ReadKeypairsRequest(oscgo.ReadKeypairsRequest{ Filters: &oscgo.FiltersKeypair{KeypairNames: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_nat_service.go b/outscale/resource_outscale_nat_service.go index 5b23cd9cb..5d307a36f 100644 --- a/outscale/resource_outscale_nat_service.go +++ b/outscale/resource_outscale_nat_service.go @@ -7,8 +7,7 @@ import ( "log" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -73,14 +72,12 @@ func resourceOutscaleOAPINatService() *schema.Resource { func resourceOAPINatServiceCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - req := &oscgo.CreateNatServiceOpts{ - CreateNatServiceRequest: optional.NewInterface(oscgo.CreateNatServiceRequest{ - PublicIpId: d.Get("public_ip_id").(string), - SubnetId: d.Get("subnet_id").(string), - }), + req := oscgo.CreateNatServiceRequest{ + PublicIpId: d.Get("public_ip_id").(string), + SubnetId: d.Get("subnet_id").(string), } - resp, _, err := conn.NatServiceApi.CreateNatService(context.Background(), req) + resp, _, err := conn.NatServiceApi.CreateNatService(context.Background()).CreateNatServiceRequest(req).Execute() if err != nil { return fmt.Errorf("Error creating Nat Service: %s", err.Error()) } @@ -97,10 +94,8 @@ func resourceOAPINatServiceCreate(d *schema.ResourceData, meta interface{}) erro // Wait for the NAT Service to become available log.Printf("\n\n[DEBUG] Waiting for NAT Service (%s) to become available", natService.GetNatServiceId()) - filterReq := &oscgo.ReadNatServicesOpts{ - ReadNatServicesRequest: optional.NewInterface(oscgo.ReadNatServicesRequest{ - Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{natService.GetNatServiceId()}}, - }), + filterReq := oscgo.ReadNatServicesRequest{ + Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{natService.GetNatServiceId()}}, } stateConf := &resource.StateChangeConf{ @@ -132,10 +127,8 @@ func resourceOAPINatServiceCreate(d *schema.ResourceData, meta interface{}) erro func resourceOAPINatServiceRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - filterReq := &oscgo.ReadNatServicesOpts{ - ReadNatServicesRequest: optional.NewInterface(oscgo.ReadNatServicesRequest{ - Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{d.Id()}}, - }), + filterReq := oscgo.ReadNatServicesRequest{ + Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{d.Id()}}, } stateConf := &resource.StateChangeConf{ @@ -201,19 +194,15 @@ func resourceOAPINatServiceDelete(d *schema.ResourceData, meta interface{}) erro log.Printf("[INFO] Deleting NAT Service: %s\n", d.Id()) - _, _, err := conn.NatServiceApi.DeleteNatService(context.Background(), &oscgo.DeleteNatServiceOpts{ - DeleteNatServiceRequest: optional.NewInterface(oscgo.DeleteNatServiceRequest{ - NatServiceId: d.Id(), - }), - }) + _, _, err := conn.NatServiceApi.DeleteNatService(context.Background()).DeleteNatServiceRequest(oscgo.DeleteNatServiceRequest{ + NatServiceId: d.Id(), + }).Execute() if err != nil { return fmt.Errorf("Error deleting Nat Service: %s", err) } - filterReq := &oscgo.ReadNatServicesOpts{ - ReadNatServicesRequest: optional.NewInterface(oscgo.ReadNatServicesRequest{ - Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{d.Id()}}, - }), + filterReq := oscgo.ReadNatServicesRequest{ + Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{d.Id()}}, } stateConf := &resource.StateChangeConf{ @@ -235,9 +224,9 @@ func resourceOAPINatServiceDelete(d *schema.ResourceData, meta interface{}) erro // NGOAPIStateRefreshFunc returns a resource.StateRefreshFunc that is used to watch // a NAT Service. -func NGOAPIStateRefreshFunc(client *oscgo.APIClient, req *oscgo.ReadNatServicesOpts, failState string) resource.StateRefreshFunc { +func NGOAPIStateRefreshFunc(client *oscgo.APIClient, req oscgo.ReadNatServicesRequest, failState string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := client.NatServiceApi.ReadNatServices(context.Background(), req) + resp, _, err := client.NatServiceApi.ReadNatServices(context.Background()).ReadNatServicesRequest(req).Execute() if err != nil { return nil, "failed", err } diff --git a/outscale/resource_outscale_nat_service_test.go b/outscale/resource_outscale_nat_service_test.go index a513fa94c..519eb797b 100644 --- a/outscale/resource_outscale_nat_service_test.go +++ b/outscale/resource_outscale_nat_service_test.go @@ -5,8 +5,7 @@ import ( "fmt" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -56,13 +55,11 @@ func testAccCheckOAPINatGatewayDestroy(s *terraform.State) error { continue } - filterReq := &oscgo.ReadNatServicesOpts{ - ReadNatServicesRequest: optional.NewInterface(oscgo.ReadNatServicesRequest{ - Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadNatServicesRequest{ + Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.NatServiceApi.ReadNatServices(context.Background(), filterReq) + resp, _, err := conn.NatServiceApi.ReadNatServices(context.Background()).ReadNatServicesRequest(filterReq).Execute() if err != nil || len(resp.GetNatServices()) > 0 { return fmt.Errorf("Nat Services still exists (%s)", rs.Primary.ID) } @@ -83,13 +80,11 @@ func testAccCheckOAPINatGatewayExists(n string, ns *oscgo.NatService) resource.T conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI - filterReq := &oscgo.ReadNatServicesOpts{ - ReadNatServicesRequest: optional.NewInterface(oscgo.ReadNatServicesRequest{ - Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{rs.Primary.ID}}, - }), + filterReq := oscgo.ReadNatServicesRequest{ + Filters: &oscgo.FiltersNatService{NatServiceIds: &[]string{rs.Primary.ID}}, } - resp, _, err := conn.NatServiceApi.ReadNatServices(context.Background(), filterReq) + resp, _, err := conn.NatServiceApi.ReadNatServices(context.Background()).ReadNatServicesRequest(filterReq).Execute() if err != nil || len(resp.GetNatServices()) < 1 { return fmt.Errorf("Nat Services not found (%s)", rs.Primary.ID) } diff --git a/outscale/resource_outscale_net.go b/outscale/resource_outscale_net.go index 5b7f70460..58dfeb442 100644 --- a/outscale/resource_outscale_net.go +++ b/outscale/resource_outscale_net.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -47,7 +46,7 @@ func resourceOutscaleOAPINetCreate(d *schema.ResourceData, meta interface{}) err var resp oscgo.CreateNetResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.CreateNet(context.Background(), &oscgo.CreateNetOpts{CreateNetRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetApi.CreateNet(context.Background()).CreateNetRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -91,7 +90,7 @@ func resourceOutscaleOAPINetRead(d *schema.ResourceData, meta interface{}) error var resp oscgo.ReadNetsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), &oscgo.ReadNetsOpts{ReadNetsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -159,7 +158,7 @@ func resourceOutscaleOAPINetDelete(d *schema.ResourceData, meta interface{}) err Pending: []string{"pending"}, Target: []string{"deleted", "failed"}, Refresh: func() (interface{}, string, error) { - _, _, err := conn.NetApi.DeleteNet(context.Background(), &oscgo.DeleteNetOpts{DeleteNetRequest: optional.NewInterface(req)}) + _, _, err := conn.NetApi.DeleteNet(context.Background()).DeleteNetRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return nil, "pending", nil diff --git a/outscale/resource_outscale_net_attributes.go b/outscale/resource_outscale_net_attributes.go index 24e39b17b..4de610bc8 100644 --- a/outscale/resource_outscale_net_attributes.go +++ b/outscale/resource_outscale_net_attributes.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -71,11 +70,7 @@ func resourceOutscaleOAPILinAttrCreate(d *schema.ResourceData, meta interface{}) var err error var resp oscgo.UpdateNetResponse err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.UpdateNet(context.Background(), - &oscgo.UpdateNetOpts{ - UpdateNetRequest: optional.NewInterface(req), - }, - ) + resp, _, err = conn.NetApi.UpdateNet(context.Background()).UpdateNetRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -107,10 +102,7 @@ func resourceOutscaleOAPILinAttrUpdate(d *schema.ResourceData, meta interface{}) } if err := resource.Retry(120*time.Second, func() *resource.RetryError { - _, _, err := conn.NetApi.UpdateNet(context.Background(), - &oscgo.UpdateNetOpts{ - UpdateNetRequest: optional.NewInterface(req), - }) + _, _, err := conn.NetApi.UpdateNet(context.Background()).UpdateNetRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -139,11 +131,7 @@ func resourceOutscaleOAPILinAttrRead(d *schema.ResourceData, meta interface{}) e var resp oscgo.ReadNetsResponse var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - resp, _, err = conn.NetApi.ReadNets(context.Background(), - &oscgo.ReadNetsOpts{ - ReadNetsRequest: optional.NewInterface(req), - }, - ) + resp, _, err = conn.NetApi.ReadNets(context.Background()).ReadNetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_net_peering.go b/outscale/resource_outscale_net_peering.go index 58f87ddca..99a8eaa20 100644 --- a/outscale/resource_outscale_net_peering.go +++ b/outscale/resource_outscale_net_peering.go @@ -9,8 +9,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -91,7 +90,7 @@ func resourceOutscaleOAPILinPeeringCreate(d *schema.ResourceData, meta interface var resp oscgo.CreateNetPeeringResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.CreateNetPeering(context.Background(), &oscgo.CreateNetPeeringOpts{CreateNetPeeringRequest: optional.NewInterface(createOpts)}) + resp, _, err = conn.NetPeeringApi.CreateNetPeering(context.Background()).CreateNetPeeringRequest(createOpts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -144,9 +143,9 @@ func resourceOutscaleOAPILinPeeringRead(d *schema.ResourceData, meta interface{} var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(oscgo.ReadNetPeeringsRequest{ + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(oscgo.ReadNetPeeringsRequest{ Filters: &oscgo.FiltersNetPeering{NetPeeringIds: &[]string{d.Id()}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -259,9 +258,9 @@ func resourceOutscaleOAPILinPeeringDelete(d *schema.ResourceData, meta interface var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NetPeeringApi.DeleteNetPeering(context.Background(), &oscgo.DeleteNetPeeringOpts{DeleteNetPeeringRequest: optional.NewInterface(oscgo.DeleteNetPeeringRequest{ + _, _, err = conn.NetPeeringApi.DeleteNetPeering(context.Background()).DeleteNetPeeringRequest(oscgo.DeleteNetPeeringRequest{ NetPeeringId: d.Id(), - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -289,9 +288,9 @@ func resourceOutscaleOAPILinPeeringConnectionStateRefreshFunc(conn *oscgo.APICli var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(oscgo.ReadNetPeeringsRequest{ + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(oscgo.ReadNetPeeringsRequest{ Filters: &oscgo.FiltersNetPeering{NetPeeringIds: &[]string{id}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_net_peering_acceptation.go b/outscale/resource_outscale_net_peering_acceptation.go index ef2199f13..aa9bfc545 100644 --- a/outscale/resource_outscale_net_peering_acceptation.go +++ b/outscale/resource_outscale_net_peering_acceptation.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -78,7 +77,7 @@ func resourceOutscaleOAPILinPeeringAccepterCreate(d *schema.ResourceData, meta i var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NetPeeringApi.AcceptNetPeering(context.Background(), &oscgo.AcceptNetPeeringOpts{AcceptNetPeeringRequest: optional.NewInterface(req)}) + _, _, err = conn.NetPeeringApi.AcceptNetPeering(context.Background()).AcceptNetPeeringRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_net_peering_test.go b/outscale/resource_outscale_net_peering_test.go index 244168801..8c65072b6 100644 --- a/outscale/resource_outscale_net_peering_test.go +++ b/outscale/resource_outscale_net_peering_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -75,9 +74,9 @@ func TestAccOutscaleOAPILinPeeringConnection_plan(t *testing.T) { testDestroy := func(*terraform.State) error { conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI log.Printf("[DEBUG] Test deleting the Net Peering.") - _, _, err := conn.NetPeeringApi.DeleteNetPeering(context.Background(), &oscgo.DeleteNetPeeringOpts{DeleteNetPeeringRequest: optional.NewInterface(oscgo.DeleteNetPeeringRequest{ + _, _, err := conn.NetPeeringApi.DeleteNetPeering(context.Background()).DeleteNetPeeringRequest(oscgo.DeleteNetPeeringRequest{ NetPeeringId: connection.GetNetPeeringId(), - })}) + }).Execute() if err != nil { return err } @@ -114,9 +113,9 @@ func testAccCheckOutscaleOAPILinPeeringConnectionDestroy(s *terraform.State) err var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(oscgo.ReadNetPeeringsRequest{ + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(oscgo.ReadNetPeeringsRequest{ Filters: &oscgo.FiltersNetPeering{NetPeeringIds: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -176,9 +175,9 @@ func testAccCheckOutscaleOAPILinPeeringConnectionExists(n string, connection *os var resp oscgo.ReadNetPeeringsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background(), &oscgo.ReadNetPeeringsOpts{ReadNetPeeringsRequest: optional.NewInterface(oscgo.ReadNetPeeringsRequest{ + resp, _, err = conn.NetPeeringApi.ReadNetPeerings(context.Background()).ReadNetPeeringsRequest(oscgo.ReadNetPeeringsRequest{ Filters: &oscgo.FiltersNetPeering{NetPeeringIds: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_net_test.go b/outscale/resource_outscale_net_test.go index 80158a149..e2f6b1e65 100644 --- a/outscale/resource_outscale_net_test.go +++ b/outscale/resource_outscale_net_test.go @@ -7,8 +7,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -71,9 +70,9 @@ func testAccCheckOutscaleOAPILinExists(n string, res *oscgo.Net) resource.TestCh err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.OSCAPI.NetApi.ReadNets(context.Background(), &oscgo.ReadNetsOpts{ReadNetsRequest: optional.NewInterface(oscgo.ReadNetsRequest{ + resp, _, err = conn.OSCAPI.NetApi.ReadNets(context.Background()).ReadNetsRequest(oscgo.ReadNetsRequest{ Filters: &oscgo.FiltersNet{NetIds: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_nic.go b/outscale/resource_outscale_nic.go index 9f043dfd0..e9ca7f8de 100644 --- a/outscale/resource_outscale_nic.go +++ b/outscale/resource_outscale_nic.go @@ -10,8 +10,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -266,7 +265,7 @@ func resourceOutscaleOAPINicCreate(d *schema.ResourceData, meta interface{}) err var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.CreateNic(context.Background(), &oscgo.CreateNicOpts{CreateNicRequest: optional.NewInterface(request)}) + resp, _, err = conn.NicApi.CreateNic(context.Background()).CreateNicRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -316,7 +315,7 @@ func resourceOutscaleOAPINicRead(d *schema.ResourceData, meta interface{}) error var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(dnir)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(dnir).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -474,7 +473,7 @@ func resourceOutscaleOAPINicDelete(d *schema.ResourceData, meta interface{}) err } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.DeleteNic(context.Background(), &oscgo.DeleteNicOpts{DeleteNicRequest: optional.NewInterface(deleteEniOpts)}) + _, _, err = conn.NicApi.DeleteNic(context.Background()).DeleteNicRequest(deleteEniOpts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -519,11 +518,7 @@ func resourceOutscaleOAPINicDetach(meta interface{}, nicID string) error { } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UnlinkNic(context.Background(), - &oscgo.UnlinkNicOpts{ - UnlinkNicRequest: optional.NewInterface(req), - }, - ) + _, _, err = conn.NicApi.UnlinkNic(context.Background()).UnlinkNicRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -561,13 +556,13 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err na := na.([]interface{})[0].(map[string]interface{}) di := na["device_number"].(int) ar := oscgo.LinkNicRequest{ - DeviceNumber: int64(di), + DeviceNumber: int32(di), VmId: na["instance"].(string), NicId: d.Id(), } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.LinkNic(context.Background(), &oscgo.LinkNicOpts{LinkNicRequest: optional.NewInterface(ar)}) + _, _, err = conn.NicApi.LinkNic(context.Background()).LinkNicRequest(ar).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -597,7 +592,7 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err } err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background(), &oscgo.UnlinkPrivateIpsOpts{UnlinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background()).UnlinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -621,7 +616,7 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.LinkPrivateIps(context.Background(), &oscgo.LinkPrivateIpsOpts{LinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.LinkPrivateIps(context.Background()).LinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -659,13 +654,13 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err dif := int32(diff) input := oscgo.LinkPrivateIpsRequest{ NicId: d.Id(), - SecondaryPrivateIpCount: pointy.Int64(int64(dif)), + SecondaryPrivateIpCount: pointy.Int32(dif), } // _, err := conn.VM.AssignPrivateIpAddresses(input) err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - _, _, err = conn.NicApi.LinkPrivateIps(context.Background(), &oscgo.LinkPrivateIpsOpts{LinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.LinkPrivateIps(context.Background()).LinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -686,7 +681,7 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err } err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background(), &oscgo.UnlinkPrivateIpsOpts{UnlinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background()).UnlinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -713,7 +708,7 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UpdateNic(context.Background(), &oscgo.UpdateNicOpts{UpdateNicRequest: optional.NewInterface(request)}) + _, _, err = conn.NicApi.UpdateNic(context.Background()).UpdateNicRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -738,7 +733,7 @@ func resourceOutscaleOAPINicUpdate(d *schema.ResourceData, meta interface{}) err var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UpdateNic(context.Background(), &oscgo.UpdateNicOpts{UpdateNicRequest: optional.NewInterface(request)}) + _, _, err = conn.NicApi.UpdateNic(context.Background()).UpdateNicRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_nic_link.go b/outscale/resource_outscale_nic_link.go index 8eb9a9bae..91a4783e8 100644 --- a/outscale/resource_outscale_nic_link.go +++ b/outscale/resource_outscale_nic_link.go @@ -9,8 +9,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -74,7 +73,7 @@ func resourceOutscaleOAPINetworkInterfaceAttachmentCreate(d *schema.ResourceData nicID := d.Get("nic_id").(string) opts := oscgo.LinkNicRequest{ - DeviceNumber: int64(di), + DeviceNumber: int32(di), VmId: vmID, NicId: nicID, } @@ -84,7 +83,7 @@ func resourceOutscaleOAPINetworkInterfaceAttachmentCreate(d *schema.ResourceData var resp oscgo.LinkNicResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.LinkNic(context.Background(), &oscgo.LinkNicOpts{LinkNicRequest: optional.NewInterface(opts)}) + resp, _, err = conn.NicApi.LinkNic(context.Background()).LinkNicRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -155,11 +154,7 @@ func resourceOutscaleOAPINetworkInterfaceAttachmentDelete(d *schema.ResourceData var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UnlinkNic(context.Background(), - &oscgo.UnlinkNicOpts{ - UnlinkNicRequest: optional.NewInterface(req), - }, - ) + _, _, err = conn.NicApi.UnlinkNic(context.Background()).UnlinkNicRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -244,9 +239,7 @@ func nicLinkRefreshFunc(conn *oscgo.APIClient, nicID string) resource.StateRefre var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), - &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(req)}, - ) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_nic_link_test.go b/outscale/resource_outscale_nic_link_test.go index 8850eda68..2b96e7b8a 100644 --- a/outscale/resource_outscale_nic_link_test.go +++ b/outscale/resource_outscale_nic_link_test.go @@ -11,8 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -101,7 +100,7 @@ func testAccCheckOutscaleNicLinkDestroy(s *terraform.State) error { var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(dnir)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(dnir).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_nic_private_ip.go b/outscale/resource_outscale_nic_private_ip.go index 027ccc10b..890dc6e87 100644 --- a/outscale/resource_outscale_nic_private_ip.go +++ b/outscale/resource_outscale_nic_private_ip.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -69,7 +68,7 @@ func resourceOutscaleOAPINetworkInterfacePrivateIPCreate(d *schema.ResourceData, } if v, ok := d.GetOk("secondary_private_ip_count"); ok { - input.SetSecondaryPrivateIpCount(int64(v.(int) - 1)) + input.SetSecondaryPrivateIpCount(int32(v.(int) - 1)) } if v, ok := d.GetOk("private_ips"); ok { @@ -78,7 +77,7 @@ func resourceOutscaleOAPINetworkInterfacePrivateIPCreate(d *schema.ResourceData, var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.LinkPrivateIps(context.Background(), &oscgo.LinkPrivateIpsOpts{LinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.LinkPrivateIps(context.Background()).LinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -109,7 +108,7 @@ func resourceOutscaleOAPINetworkInterfacePrivateIPRead(d *schema.ResourceData, m var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(req)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -191,7 +190,7 @@ func resourceOutscaleOAPINetworkInterfacePrivateIPDelete(d *schema.ResourceData, var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background(), &oscgo.UnlinkPrivateIpsOpts{UnlinkPrivateIpsRequest: optional.NewInterface(input)}) + _, _, err = conn.NicApi.UnlinkPrivateIps(context.Background()).UnlinkPrivateIpsRequest(input).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_nic_private_ip_test.go b/outscale/resource_outscale_nic_private_ip_test.go index d8e713e9a..329baa84d 100644 --- a/outscale/resource_outscale_nic_private_ip_test.go +++ b/outscale/resource_outscale_nic_private_ip_test.go @@ -5,7 +5,7 @@ import ( "os" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/resource_outscale_nic_test.go b/outscale/resource_outscale_nic_test.go index 052f42647..dbef70e20 100644 --- a/outscale/resource_outscale_nic_test.go +++ b/outscale/resource_outscale_nic_test.go @@ -9,8 +9,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -65,7 +64,7 @@ func testAccCheckOutscaleOAPIENIExists(n string, res *oscgo.Nic) resource.TestCh var resp oscgo.ReadNicsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.NicApi.ReadNics(context.Background(), &oscgo.ReadNicsOpts{ReadNicsRequest: optional.NewInterface(dnir)}) + resp, _, err = conn.NicApi.ReadNics(context.Background()).ReadNicsRequest(dnir).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_public_ip.go b/outscale/resource_outscale_public_ip.go index 8961f4a69..32803653e 100644 --- a/outscale/resource_outscale_public_ip.go +++ b/outscale/resource_outscale_public_ip.go @@ -7,11 +7,10 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" ) @@ -40,7 +39,7 @@ func resourceOutscaleOAPIPublicIPCreate(d *schema.ResourceData, meta interface{} allocOpts := oscgo.CreatePublicIpRequest{} log.Printf("[DEBUG] EIP create configuration: %#v", allocOpts) - resp, _, err := conn.PublicIpApi.CreatePublicIp(context.Background(), &oscgo.CreatePublicIpOpts{CreatePublicIpRequest: optional.NewInterface(allocOpts)}) + resp, _, err := conn.PublicIpApi.CreatePublicIp(context.Background()).CreatePublicIpRequest(allocOpts).Execute() if err != nil { return fmt.Errorf("error creating EIP: %s", utils.GetErrorResponse(err)) } @@ -72,7 +71,7 @@ func resourceOutscaleOAPIPublicIPRead(d *schema.ResourceData, meta interface{}) Filters: &oscgo.FiltersPublicIp{PublicIpIds: &[]string{id}}, } - response, _, err := conn.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + response, _, err := conn.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() if err != nil { if e := fmt.Sprint(err); strings.Contains(e, "InvalidAllocationID.NotFound") || strings.Contains(e, "InvalidAddress.NotFound") { @@ -150,7 +149,7 @@ func resourceOutscaleOAPIPublicIPUpdate(d *schema.ResourceData, meta interface{} err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - _, _, err = conn.PublicIpApi.LinkPublicIp(context.Background(), &oscgo.LinkPublicIpOpts{LinkPublicIpRequest: optional.NewInterface(assocOpts)}) + _, _, err = conn.PublicIpApi.LinkPublicIp(context.Background()).LinkPublicIpRequest(assocOpts).Execute() if err != nil { if e := fmt.Sprint(err); strings.Contains(e, "InvalidAllocationID.NotFound") || strings.Contains(e, "InvalidAddress.NotFound") { @@ -206,14 +205,14 @@ func resourceOutscaleOAPIPublicIPDelete(d *schema.ResourceData, meta interface{} switch resourceOutscaleOAPIPublicIPDomain(d) { case "vpc": lppiId := d.Get("link_public_ip_id").(string) - _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background(), &oscgo.UnlinkPublicIpOpts{UnlinkPublicIpRequest: optional.NewInterface(oscgo.UnlinkPublicIpRequest{ + _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background()).UnlinkPublicIpRequest(oscgo.UnlinkPublicIpRequest{ LinkPublicIpId: &lppiId, - })}) + }).Execute() case "standard": pIP := d.Get("public_ip").(string) - _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background(), &oscgo.UnlinkPublicIpOpts{UnlinkPublicIpRequest: optional.NewInterface(oscgo.UnlinkPublicIpRequest{ + _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background()).UnlinkPublicIpRequest(oscgo.UnlinkPublicIpRequest{ PublicIp: &pIP, - })}) + }).Execute() } if err != nil { @@ -229,9 +228,9 @@ func resourceOutscaleOAPIPublicIPDelete(d *schema.ResourceData, meta interface{} idIP := d.Id() log.Printf("[DEBUG] EIP release (destroy) address: %v", d.Id()) - _, _, err = conn.PublicIpApi.DeletePublicIp(context.Background(), &oscgo.DeletePublicIpOpts{DeletePublicIpRequest: optional.NewInterface(oscgo.DeletePublicIpRequest{ + _, _, err = conn.PublicIpApi.DeletePublicIp(context.Background()).DeletePublicIpRequest(oscgo.DeletePublicIpRequest{ PublicIpId: &idIP, - })}) + }).Execute() if e := fmt.Sprint(err); strings.Contains(e, "InvalidAllocationID.NotFound") || strings.Contains(e, "InvalidAddress.NotFound") { return nil diff --git a/outscale/resource_outscale_public_ip_link.go b/outscale/resource_outscale_public_ip_link.go index e7eae8b22..a62076c18 100644 --- a/outscale/resource_outscale_public_ip_link.go +++ b/outscale/resource_outscale_public_ip_link.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -64,7 +63,7 @@ func resourceOutscaleOAPIPublicIPLinkCreate(d *schema.ResourceData, meta interfa err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.PublicIpApi.LinkPublicIp(context.Background(), &oscgo.LinkPublicIpOpts{LinkPublicIpRequest: optional.NewInterface(request)}) + resp, _, err = conn.PublicIpApi.LinkPublicIp(context.Background()).LinkPublicIpRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -114,7 +113,7 @@ func resourceOutscaleOAPIPublicIPLinkRead(d *schema.ResourceData, meta interface err = resource.Retry(60*time.Second, func() *resource.RetryError { - response, _, err = conn.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(request)}) + response, _, err = conn.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -156,7 +155,7 @@ func resourceOutscaleOAPIPublicIPLinkDelete(d *schema.ResourceData, meta interfa err = resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background(), &oscgo.UnlinkPublicIpOpts{UnlinkPublicIpRequest: optional.NewInterface(opts)}) + _, _, err = conn.PublicIpApi.UnlinkPublicIp(context.Background()).UnlinkPublicIpRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_public_ip_link_test.go b/outscale/resource_outscale_public_ip_link_test.go index 5721d4bc8..a4dda903b 100644 --- a/outscale/resource_outscale_public_ip_link_test.go +++ b/outscale/resource_outscale_public_ip_link_test.go @@ -9,8 +9,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -59,7 +58,7 @@ func testAccCheckOutscaleOAPIPublicIPLinkExists(name string, res *oscgo.PublicIp LinkPublicIpIds: &[]string{res.GetLinkPublicIpId()}, }, } - response, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(request)}) + response, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(request).Execute() if err != nil { log.Printf("[DEBUG] ERROR testAccCheckOutscaleOAPIPublicIPLinkExists (%s)", err) @@ -99,7 +98,7 @@ func testAccCheckOutscaleOAPIPublicIPLinkDestroy(s *terraform.State) error { LinkPublicIpIds: &[]string{id}, }, } - response, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(request)}) + response, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(request).Execute() log.Printf("[DEBUG] ERROR testAccCheckOutscaleOAPIPublicIPLinkDestroy (%s)", err) @@ -134,7 +133,7 @@ func testAccCheckOutscaleOAPIPublicIPLExists(n string, res *oscgo.PublicIp) reso LinkPublicIpIds: &[]string{rs.Primary.ID}, }, } - resp, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + resp, _, err := conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() if err != nil { return err @@ -156,7 +155,7 @@ func testAccCheckOutscaleOAPIPublicIPLExists(n string, res *oscgo.PublicIp) reso var response oscgo.ReadPublicIpsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() if err != nil { if e := fmt.Sprint(err); strings.Contains(e, "InvalidAllocationID.NotFound") || strings.Contains(e, "InvalidAddress.NotFound") { diff --git a/outscale/resource_outscale_public_ip_test.go b/outscale/resource_outscale_public_ip_test.go index a5f7f6a68..261bfac4d 100644 --- a/outscale/resource_outscale_public_ip_test.go +++ b/outscale/resource_outscale_public_ip_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -146,7 +145,7 @@ func testAccCheckOutscaleOAPIPublicIPDestroy(s *terraform.State) error { var response oscgo.ReadPublicIpsResponse err := resource.Retry(60*time.Second, func() *resource.RetryError { var err error - response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() return resource.RetryableError(err) }) @@ -220,7 +219,7 @@ func testAccCheckOutscaleOAPIPublicIPExists(n string, res *oscgo.PublicIp) resou var response oscgo.ReadPublicIpsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { var err error - response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background(), &oscgo.ReadPublicIpsOpts{ReadPublicIpsRequest: optional.NewInterface(req)}) + response, _, err = conn.OSCAPI.PublicIpApi.ReadPublicIps(context.Background()).ReadPublicIpsRequest(req).Execute() if err != nil { if e := fmt.Sprint(err); strings.Contains(e, "InvalidAllocationID.NotFound") || strings.Contains(e, "InvalidPublicIps.NotFound") { diff --git a/outscale/resource_outscale_route.go b/outscale/resource_outscale_route.go index 6598d3892..fd6bd9bc9 100644 --- a/outscale/resource_outscale_route.go +++ b/outscale/resource_outscale_route.go @@ -9,9 +9,8 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" "github.com/openlyinc/pointy" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -129,7 +128,7 @@ func resourceOutscaleOAPIRouteCreate(d *schema.ResourceData, meta interface{}) e var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - _, _, err = conn.RouteApi.CreateRoute(context.Background(), &oscgo.CreateRouteOpts{CreateRouteRequest: optional.NewInterface(createOpts)}) + _, _, err = conn.RouteApi.CreateRoute(context.Background()).CreateRouteRequest(createOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") { @@ -240,7 +239,7 @@ func resourceOutscaleOAPIRouteUpdate(d *schema.ResourceData, meta interface{}) e conn := meta.(*OutscaleClient).OSCAPI numTargets, target := getTarget(d) - replaceOpts := &oscgo.UpdateRouteRequest{} + replaceOpts := oscgo.UpdateRouteRequest{} switch target { case "vm_id": @@ -255,31 +254,31 @@ func resourceOutscaleOAPIRouteUpdate(d *schema.ResourceData, meta interface{}) e switch target { case "gateway_id": - replaceOpts = &oscgo.UpdateRouteRequest{ + replaceOpts = oscgo.UpdateRouteRequest{ RouteTableId: d.Get("route_table_id").(string), DestinationIpRange: d.Get("destination_ip_range").(string), GatewayId: pointy.String(d.Get("gateway_id").(string)), } case "nat_service_id": - replaceOpts = &oscgo.UpdateRouteRequest{ + replaceOpts = oscgo.UpdateRouteRequest{ RouteTableId: d.Get("route_table_id").(string), DestinationIpRange: d.Get("destination_ip_range").(string), GatewayId: pointy.String(d.Get("nat_service_id").(string)), } case "vm_id": - replaceOpts = &oscgo.UpdateRouteRequest{ + replaceOpts = oscgo.UpdateRouteRequest{ RouteTableId: d.Get("route_table_id").(string), DestinationIpRange: d.Get("destination_ip_range").(string), VmId: pointy.String(d.Get("vm_id").(string)), } case "nic_id": - replaceOpts = &oscgo.UpdateRouteRequest{ + replaceOpts = oscgo.UpdateRouteRequest{ RouteTableId: d.Get("route_table_id").(string), DestinationIpRange: d.Get("destination_ip_range").(string), NicId: pointy.String(d.Get("nic_id").(string)), } case "net_peering_id": - replaceOpts = &oscgo.UpdateRouteRequest{ + replaceOpts = oscgo.UpdateRouteRequest{ RouteTableId: d.Get("route_table_id").(string), DestinationIpRange: d.Get("destination_ip_range").(string), NetPeeringId: pointy.String(d.Get("net_peering_id").(string)), @@ -291,7 +290,7 @@ func resourceOutscaleOAPIRouteUpdate(d *schema.ResourceData, meta interface{}) e var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - _, _, err = conn.RouteApi.UpdateRoute(context.Background(), &oscgo.UpdateRouteOpts{UpdateRouteRequest: optional.NewInterface(*replaceOpts)}) + _, _, err = conn.RouteApi.UpdateRoute(context.Background()).UpdateRouteRequest(replaceOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") { @@ -323,7 +322,7 @@ func resourceOutscaleOAPIRouteDelete(d *schema.ResourceData, meta interface{}) e err := resource.Retry(5*time.Minute, func() *resource.RetryError { log.Printf("[DEBUG] Trying to delete route with opts %+v", deleteOpts) - resp, _, err := conn.RouteApi.DeleteRoute(context.Background(), &oscgo.DeleteRouteOpts{DeleteRouteRequest: optional.NewInterface(deleteOpts)}) + resp, _, err := conn.RouteApi.DeleteRoute(context.Background()).DeleteRouteRequest(deleteOpts).Execute() log.Printf("[DEBUG] Route delete result: %+v", resp) if err == nil { @@ -357,7 +356,7 @@ func resourceOutscaleOAPIRouteExists(d *schema.ResourceData, meta interface{}) ( var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(findOpts)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(findOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") || strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { @@ -410,7 +409,7 @@ func findResourceOAPIRoute(conn *oscgo.APIClient, rtbid string, cidr string) (*o var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(findOpts)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(findOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") || strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { diff --git a/outscale/resource_outscale_route_table.go b/outscale/resource_outscale_route_table.go index cc17a3362..4ae80eafc 100644 --- a/outscale/resource_outscale_route_table.go +++ b/outscale/resource_outscale_route_table.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -147,7 +146,7 @@ func resourceOutscaleOAPIRouteTableCreate(d *schema.ResourceData, meta interface var resp oscgo.CreateRouteTableResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.CreateRouteTable(context.Background(), &oscgo.CreateRouteTableOpts{CreateRouteTableRequest: optional.NewInterface(createOpts)}) + resp, _, err = conn.RouteTableApi.CreateRouteTable(context.Background()).CreateRouteTableRequest(createOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -269,9 +268,9 @@ func resourceOutscaleOAPIRouteTableDelete(d *schema.ResourceData, meta interface var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.RouteTableApi.UnlinkRouteTable(context.Background(), &oscgo.UnlinkRouteTableOpts{UnlinkRouteTableRequest: optional.NewInterface(oscgo.UnlinkRouteTableRequest{ + _, _, err := conn.RouteTableApi.UnlinkRouteTable(context.Background()).UnlinkRouteTableRequest(oscgo.UnlinkRouteTableRequest{ LinkRouteTableId: a.GetLinkRouteTableId(), - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -293,9 +292,9 @@ func resourceOutscaleOAPIRouteTableDelete(d *schema.ResourceData, meta interface log.Printf("[INFO] Deleting Route Table: %s", d.Id()) err = resource.Retry(15*time.Minute, func() *resource.RetryError { - _, _, err = conn.RouteTableApi.DeleteRouteTable(context.Background(), &oscgo.DeleteRouteTableOpts{DeleteRouteTableRequest: optional.NewInterface(oscgo.DeleteRouteTableRequest{ + _, _, err = conn.RouteTableApi.DeleteRouteTable(context.Background()).DeleteRouteTableRequest(oscgo.DeleteRouteTableRequest{ RouteTableId: d.Id(), - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -336,7 +335,7 @@ func readOAPIRouteTable(conn *oscgo.APIClient, routeTableID string, linkIds ...s routeTableRequest.Filters = &oscgo.FiltersRouteTable{RouteTableIds: &[]string{routeTableID}} err = resource.Retry(15*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(routeTableRequest)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(routeTableRequest).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_route_table_link.go b/outscale/resource_outscale_route_table_link.go index 596ed3c9d..58b35a77b 100644 --- a/outscale/resource_outscale_route_table_link.go +++ b/outscale/resource_outscale_route_table_link.go @@ -8,8 +8,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -67,7 +66,7 @@ func resourceOutscaleOAPILinkRouteTableCreate(d *schema.ResourceData, meta inter var resp oscgo.LinkRouteTableResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.LinkRouteTable(context.Background(), &oscgo.LinkRouteTableOpts{LinkRouteTableRequest: optional.NewInterface(linkRouteTableOpts)}) + resp, _, err = conn.RouteTableApi.LinkRouteTable(context.Background()).LinkRouteTableRequest(linkRouteTableOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidRouteTableID.NotFound") { return resource.RetryableError(err) @@ -122,9 +121,9 @@ func resourceOutscaleOAPILinkRouteTableDelete(d *schema.ResourceData, meta inter var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.RouteTableApi.UnlinkRouteTable(context.Background(), &oscgo.UnlinkRouteTableOpts{UnlinkRouteTableRequest: optional.NewInterface(oscgo.UnlinkRouteTableRequest{ + _, _, err = conn.RouteTableApi.UnlinkRouteTable(context.Background()).UnlinkRouteTableRequest(oscgo.UnlinkRouteTableRequest{ LinkRouteTableId: d.Id(), - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -177,12 +176,9 @@ func readOutscaleLinkRouteTable(meta *OutscaleClient, routeTableID, linkRouteTab var err error err = resource.Retry(15*time.Minute, func() *resource.RetryError { - rt, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), - &oscgo.ReadRouteTablesOpts{ - ReadRouteTablesRequest: optional.NewInterface(oscgo.ReadRouteTablesRequest{ - Filters: &oscgo.FiltersRouteTable{RouteTableIds: &[]string{routeTableID}}, - }), - }) + rt, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(oscgo.ReadRouteTablesRequest{ + Filters: &oscgo.FiltersRouteTable{RouteTableIds: &[]string{routeTableID}}, + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_route_table_link_test.go b/outscale/resource_outscale_route_table_link_test.go index 19554a0b1..5be848fbb 100644 --- a/outscale/resource_outscale_route_table_link_test.go +++ b/outscale/resource_outscale_route_table_link_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -86,7 +85,7 @@ func testAccCheckOAPILinkRouteTableDestroy(s *terraform.State) error { var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") || strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { log.Printf("[DEBUG] Trying to create route again: %q", err) @@ -135,7 +134,7 @@ func testAccCheckOAPILinkRouteTableExists(n string, v *oscgo.RouteTable) resourc var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") { log.Printf("[DEBUG] Trying to create route again: %q", err) diff --git a/outscale/resource_outscale_route_table_test.go b/outscale/resource_outscale_route_table_test.go index 6a23c64b6..324a3867e 100644 --- a/outscale/resource_outscale_route_table_test.go +++ b/outscale/resource_outscale_route_table_test.go @@ -9,8 +9,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -213,7 +212,7 @@ func testAccCheckOAPIRouteTableDestroy(s *terraform.State) error { } err = resource.Retry(15*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") || strings.Contains(fmt.Sprint(err), "InvalidParameterException") { log.Printf("[DEBUG] Trying to create route again: %q", err) @@ -263,7 +262,7 @@ func testAccCheckOAPIRouteTableExists(n string, v *oscgo.RouteTable, t *[]oscgo. }, } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(params)}) + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(params).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidParameterException") || strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { log.Printf("[DEBUG] Trying to create route again: %q", err) diff --git a/outscale/resource_outscale_route_test.go b/outscale/resource_outscale_route_test.go index 5036c03ff..910f10c6e 100644 --- a/outscale/resource_outscale_route_test.go +++ b/outscale/resource_outscale_route_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_security_group.go b/outscale/resource_outscale_security_group.go index 0e755d4ae..173792971 100644 --- a/outscale/resource_outscale_security_group.go +++ b/outscale/resource_outscale_security_group.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -136,7 +135,7 @@ func resourceOutscaleOAPISecurityGroupCreate(d *schema.ResourceData, meta interf var resp oscgo.CreateSecurityGroupResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SecurityGroupApi.CreateSecurityGroup(context.Background(), &oscgo.CreateSecurityGroupOpts{CreateSecurityGroupRequest: optional.NewInterface(securityGroupOpts)}) + resp, _, err = conn.SecurityGroupApi.CreateSecurityGroup(context.Background()).CreateSecurityGroupRequest(securityGroupOpts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { @@ -237,9 +236,9 @@ func resourceOutscaleOAPISecurityGroupDelete(d *schema.ResourceData, meta interf log.Printf("[DEBUG] Security Group destroy: %v", d.Id()) securityGroupID := d.Id() return resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.SecurityGroupApi.DeleteSecurityGroup(context.Background(), &oscgo.DeleteSecurityGroupOpts{DeleteSecurityGroupRequest: optional.NewInterface(oscgo.DeleteSecurityGroupRequest{ + _, _, err := conn.SecurityGroupApi.DeleteSecurityGroup(context.Background()).DeleteSecurityGroupRequest(oscgo.DeleteSecurityGroupRequest{ SecurityGroupId: &securityGroupID, - })}) + }).Execute() if err != nil { var errString string @@ -291,9 +290,7 @@ func readSecurityGroups(client *oscgo.APIClient, securityGroupID string) (*oscgo var err error var resp oscgo.ReadSecurityGroupsResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = client.SecurityGroupApi.ReadSecurityGroups(context.Background(), &oscgo.ReadSecurityGroupsOpts{ - ReadSecurityGroupsRequest: optional.NewInterface(filters), - }) + resp, _, err = client.SecurityGroupApi.ReadSecurityGroups(context.Background()).ReadSecurityGroupsRequest(filters).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_security_group_rule.go b/outscale/resource_outscale_security_group_rule.go index 39b8e2b1f..18dbd2a00 100644 --- a/outscale/resource_outscale_security_group_rule.go +++ b/outscale/resource_outscale_security_group_rule.go @@ -6,9 +6,8 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" "github.com/openlyinc/pointy" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/terraform-providers/terraform-provider-outscale/utils" @@ -95,10 +94,10 @@ func resourceOutscaleOAPIOutboundRuleCreate(d *schema.ResourceData, meta interfa } if v, ok := d.GetOkExists("from_port_range"); ok { - req.FromPortRange = pointy.Int64(cast.ToInt64(v)) + req.FromPortRange = pointy.Int32(cast.ToInt32(v)) } if v, ok := d.GetOkExists("to_port_range"); ok { - req.ToPortRange = pointy.Int64(cast.ToInt64(v)) + req.ToPortRange = pointy.Int32(cast.ToInt32(v)) } if v, ok := d.GetOk("ip_protocol"); ok { req.IpProtocol = pointy.String(v.(string)) @@ -116,10 +115,7 @@ func resourceOutscaleOAPIOutboundRuleCreate(d *schema.ResourceData, meta interfa var err error var resp oscgo.CreateSecurityGroupRuleResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SecurityGroupRuleApi.CreateSecurityGroupRule(context.Background(), - &oscgo.CreateSecurityGroupRuleOpts{ - CreateSecurityGroupRuleRequest: optional.NewInterface(req), - }) + resp, _, err = conn.SecurityGroupRuleApi.CreateSecurityGroupRule(context.Background()).CreateSecurityGroupRuleRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -175,10 +171,10 @@ func resourceOutscaleOAPIOutboundRuleDelete(d *schema.ResourceData, meta interfa } if v, ok := d.GetOkExists("from_port_range"); ok { - req.FromPortRange = pointy.Int64(cast.ToInt64(v)) + req.FromPortRange = pointy.Int32(cast.ToInt32(v)) } if v, ok := d.GetOkExists("to_port_range"); ok { - req.ToPortRange = pointy.Int64(cast.ToInt64(v)) + req.ToPortRange = pointy.Int32(cast.ToInt32(v)) } if v, ok := d.GetOk("ip_protocol"); ok { req.IpProtocol = pointy.String(v.(string)) @@ -188,10 +184,7 @@ func resourceOutscaleOAPIOutboundRuleDelete(d *schema.ResourceData, meta interfa } err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.SecurityGroupRuleApi.DeleteSecurityGroupRule(context.Background(), - &oscgo.DeleteSecurityGroupRuleOpts{ - DeleteSecurityGroupRuleRequest: optional.NewInterface(req), - }) + _, _, err := conn.SecurityGroupRuleApi.DeleteSecurityGroupRule(context.Background()).DeleteSecurityGroupRuleRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -226,13 +219,13 @@ func expandRules(d *schema.ResourceData) *[]oscgo.SecurityGroupRule { rules[i].ServiceIds = expandStringValueListPointer(r["service_ids"].([]interface{})) } if v, ok := r["from_port_range"]; ok { - rules[i].FromPortRange = pointy.Int64(cast.ToInt64(v)) + rules[i].FromPortRange = pointy.Int32(cast.ToInt32(v)) } if v, ok := r["ip_protocol"]; ok && v != "" { rules[i].IpProtocol = pointy.String(cast.ToString(v)) } if v, ok := r["to_port_range"]; ok { - rules[i].ToPortRange = pointy.Int64(cast.ToInt64(v)) + rules[i].ToPortRange = pointy.Int32(cast.ToInt32(v)) } } return &rules diff --git a/outscale/resource_outscale_security_group_rule_test.go b/outscale/resource_outscale_security_group_rule_test.go index 990406f5e..14221cc53 100644 --- a/outscale/resource_outscale_security_group_rule_test.go +++ b/outscale/resource_outscale_security_group_rule_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -80,8 +79,8 @@ func testAccCheckOutscaleOAPIRuleAttributes(n string, group *oscgo.SecurityGroup } if p == nil { - fromPortRange := int64(443) - toPortRange := int64(443) + fromPortRange := int32(443) + toPortRange := int32(443) ipProtocol := "tcp" p = &oscgo.SecurityGroupRule{ FromPortRange: &fromPortRange, @@ -187,7 +186,7 @@ func testAccCheckOutscaleOAPIRuleExists(n string, group *oscgo.SecurityGroup) re var resp oscgo.ReadSecurityGroupsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background(), &oscgo.ReadSecurityGroupsOpts{ReadSecurityGroupsRequest: optional.NewInterface(req)}) + resp, _, err = conn.SecurityGroupApi.ReadSecurityGroups(context.Background()).ReadSecurityGroupsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { diff --git a/outscale/resource_outscale_security_group_test.go b/outscale/resource_outscale_security_group_test.go index 322b7e834..255364137 100644 --- a/outscale/resource_outscale_security_group_test.go +++ b/outscale/resource_outscale_security_group_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_snapshot.go b/outscale/resource_outscale_snapshot.go index 0dfe0dce9..c7fca5866 100644 --- a/outscale/resource_outscale_snapshot.go +++ b/outscale/resource_outscale_snapshot.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -152,7 +151,7 @@ func resourceOutscaleOAPISnapshotCreate(d *schema.ResourceData, meta interface{} var resp oscgo.CreateSnapshotResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.CreateSnapshot(context.Background(), &oscgo.CreateSnapshotOpts{CreateSnapshotRequest: optional.NewInterface(request)}) + resp, _, err = conn.SnapshotApi.CreateSnapshot(context.Background()).CreateSnapshotRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -203,7 +202,7 @@ func resourceOutscaleOAPISnapshotRead(d *schema.ResourceData, meta interface{}) var resp oscgo.ReadSnapshotsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(req)}) + resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { return resource.RetryableError(err) @@ -281,7 +280,7 @@ func resourceOutscaleOAPISnapshotDelete(d *schema.ResourceData, meta interface{} request := oscgo.DeleteSnapshotRequest{SnapshotId: d.Id()} err := resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.SnapshotApi.DeleteSnapshot(context.Background(), &oscgo.DeleteSnapshotOpts{DeleteSnapshotRequest: optional.NewInterface(request)}) + _, _, err := conn.SnapshotApi.DeleteSnapshot(context.Background()).DeleteSnapshotRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { @@ -320,9 +319,9 @@ func SnapshotOAPIStateRefreshFunc(client *oscgo.APIClient, id string) resource.S var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = client.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(oscgo.ReadSnapshotsRequest{ + resp, _, err = client.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(oscgo.ReadSnapshotsRequest{ Filters: &oscgo.FiltersSnapshot{SnapshotIds: &[]string{id}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_snapshot_attributes.go b/outscale/resource_outscale_snapshot_attributes.go index 5f005943d..c3d241aea 100644 --- a/outscale/resource_outscale_snapshot_attributes.go +++ b/outscale/resource_outscale_snapshot_attributes.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -139,7 +138,7 @@ func resourcedOutscaleOAPISnapshotAttributesCreate(d *schema.ResourceData, meta var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - _, _, err = conn.SnapshotApi.UpdateSnapshot(context.Background(), &oscgo.UpdateSnapshotOpts{UpdateSnapshotRequest: optional.NewInterface(req)}) + _, _, err = conn.SnapshotApi.UpdateSnapshot(context.Background()).UpdateSnapshotRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { log.Printf("[DEBUG] Error: %q", err) @@ -167,11 +166,11 @@ func resourcedOutscaleOAPISnapshotAttributesRead(d *schema.ResourceData, meta in var resp oscgo.ReadSnapshotsResponse var err error err = resource.Retry(2*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(oscgo.ReadSnapshotsRequest{ + resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(oscgo.ReadSnapshotsRequest{ Filters: &oscgo.FiltersSnapshot{ SnapshotIds: &[]string{d.Id()}, }, - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { log.Printf("[DEBUG] Error: %q", err) diff --git a/outscale/resource_outscale_snapshot_test.go b/outscale/resource_outscale_snapshot_test.go index 18b03aebb..f004b8b26 100644 --- a/outscale/resource_outscale_snapshot_test.go +++ b/outscale/resource_outscale_snapshot_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -136,7 +135,7 @@ func testAccCheckOAPISnapshotExists(n string, v *oscgo.Snapshot) resource.TestCh var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background(), &oscgo.ReadSnapshotsOpts{ReadSnapshotsRequest: optional.NewInterface(request)}) + resp, _, err = conn.SnapshotApi.ReadSnapshots(context.Background()).ReadSnapshotsRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_subnet.go b/outscale/resource_outscale_subnet.go index a44f7d5eb..0177eb82e 100644 --- a/outscale/resource_outscale_subnet.go +++ b/outscale/resource_outscale_subnet.go @@ -7,10 +7,9 @@ import ( "strings" "time" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleOAPISubNet() *schema.Resource { @@ -43,7 +42,7 @@ func resourceOutscaleOAPISubNetCreate(d *schema.ResourceData, meta interface{}) var resp oscgo.CreateSubnetResponse var err error err = resource.Retry(40*time.Second, func() *resource.RetryError { - r, _, err := conn.SubnetApi.CreateSubnet(context.Background(), &oscgo.CreateSubnetOpts{CreateSubnetRequest: optional.NewInterface(req)}) + r, _, err := conn.SubnetApi.CreateSubnet(context.Background()).CreateSubnetRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { fmt.Printf("[INFO] Request limit exceeded") @@ -96,7 +95,7 @@ func resourceOutscaleOAPISubNetRead(d *schema.ResourceData, meta interface{}) er } var resp oscgo.ReadSubnetsResponse err := resource.Retry(120*time.Second, func() *resource.RetryError { - r, _, err := conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ReadSubnetsRequest: optional.NewInterface(req)}) + r, _, err := conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -137,7 +136,7 @@ func resourceOutscaleOAPISubNetDelete(d *schema.ResourceData, meta interface{}) } var err error err = resource.Retry(120*time.Second, func() *resource.RetryError { - _, _, err = conn.SubnetApi.DeleteSubnet(context.Background(), &oscgo.DeleteSubnetOpts{DeleteSubnetRequest: optional.NewInterface(req)}) + _, _, err = conn.SubnetApi.DeleteSubnet(context.Background()).DeleteSubnetRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -198,13 +197,11 @@ func readOutscaleOAPISubNet(d *schema.ResourceData, subnet *oscgo.Subnet) error } func SubnetStateOApiRefreshFunc(conn *oscgo.APIClient, subnetID string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ - ReadSubnetsRequest: optional.NewInterface(oscgo.ReadSubnetsRequest{ - Filters: &oscgo.FiltersSubnet{ - SubnetIds: &[]string{subnetID}, - }, - }), - }) + resp, _, err := conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(oscgo.ReadSubnetsRequest{ + Filters: &oscgo.FiltersSubnet{ + SubnetIds: &[]string{subnetID}, + }, + }).Execute() if err != nil { log.Printf("[ERROR] error on SubnetStateRefresh: %s", err) return nil, "error", err diff --git a/outscale/resource_outscale_subnet_test.go b/outscale/resource_outscale_subnet_test.go index b36bd6760..41e3ab5cb 100644 --- a/outscale/resource_outscale_subnet_test.go +++ b/outscale/resource_outscale_subnet_test.go @@ -8,10 +8,9 @@ import ( "testing" "time" - "github.com/antihax/optional" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func TestAccOutscaleOAPISubNet_basic(t *testing.T) { @@ -48,13 +47,11 @@ func testAccCheckOutscaleOAPISubNetExists(n string, res *oscgo.Subnet) resource. err := resource.Retry(30*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ - ReadSubnetsRequest: optional.NewInterface(oscgo.ReadSubnetsRequest{ - Filters: &oscgo.FiltersSubnet{ - SubnetIds: &[]string{rs.Primary.ID}, - }, - }), - }) + resp, _, err = conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(oscgo.ReadSubnetsRequest{ + Filters: &oscgo.FiltersSubnet{ + SubnetIds: &[]string{rs.Primary.ID}, + }, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -91,13 +88,11 @@ func testAccCheckOutscaleOAPISubNetDestroyed(s *terraform.State) error { conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI err := resource.Retry(30*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.SubnetApi.ReadSubnets(context.Background(), &oscgo.ReadSubnetsOpts{ - ReadSubnetsRequest: optional.NewInterface(oscgo.ReadSubnetsRequest{ - Filters: &oscgo.FiltersSubnet{ - SubnetIds: &[]string{rs.Primary.ID}, - }, - }), - }) + resp, _, err = conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(oscgo.ReadSubnetsRequest{ + Filters: &oscgo.FiltersSubnet{ + SubnetIds: &[]string{rs.Primary.ID}, + }, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_tags.go b/outscale/resource_outscale_tags.go index 97caabed2..bdbe48231 100644 --- a/outscale/resource_outscale_tags.go +++ b/outscale/resource_outscale_tags.go @@ -6,8 +6,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -58,7 +57,7 @@ func resourceOutscaleOAPITagsCreate(d *schema.ResourceData, meta interface{}) er } err := resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err := conn.TagApi.CreateTags(context.Background(), &oscgo.CreateTagsOpts{CreateTagsRequest: optional.NewInterface(request)}) + _, _, err := conn.TagApi.CreateTags(context.Background()).CreateTagsRequest(request).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), ".NotFound") { return resource.RetryableError(err) @@ -117,7 +116,7 @@ func resourceOutscaleOAPITagsRead(d *schema.ResourceData, meta interface{}) erro var err error err = resource.Retry(60*time.Second, func() *resource.RetryError { - resp, _, err = conn.TagApi.ReadTags(context.Background(), &oscgo.ReadTagsOpts{ReadTagsRequest: optional.NewInterface(params)}) + resp, _, err = conn.TagApi.ReadTags(context.Background()).ReadTagsRequest(params).Execute() return resource.RetryableError(err) }) @@ -168,7 +167,7 @@ func resourceOutscaleOAPITagsDelete(d *schema.ResourceData, meta interface{}) er } err := resource.Retry(60*time.Second, func() *resource.RetryError { - _, _, err := conn.TagApi.DeleteTags(context.Background(), &oscgo.DeleteTagsOpts{DeleteTagsRequest: optional.NewInterface(request)}) + _, _, err := conn.TagApi.DeleteTags(context.Background()).DeleteTagsRequest(request).Execute() if err != nil { ec2err, ok := err.(awserr.Error) if ok && strings.Contains(ec2err.Code(), ".NotFound") { diff --git a/outscale/resource_outscale_tags_test.go b/outscale/resource_outscale_tags_test.go index ec47800b3..708f65df6 100644 --- a/outscale/resource_outscale_tags_test.go +++ b/outscale/resource_outscale_tags_test.go @@ -8,10 +8,9 @@ import ( "testing" "time" - "github.com/antihax/optional" "github.com/go-test/deep" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -85,11 +84,11 @@ func oapiTestAccCheckOutscaleVMExistsWithProviders(n string, i *oscgo.Vm, provid var err error for { - resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ + resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ Filters: &oscgo.FiltersVm{ VmIds: &[]string{rs.Primary.ID}, }, - })}) + }).Execute() if err != nil { time.Sleep(10 * time.Second) } else { diff --git a/outscale/resource_outscale_virtual_gateway.go b/outscale/resource_outscale_virtual_gateway.go index b19fecbe3..598c61fff 100644 --- a/outscale/resource_outscale_virtual_gateway.go +++ b/outscale/resource_outscale_virtual_gateway.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "log" "strings" "time" @@ -80,7 +79,7 @@ func resourceOutscaleOAPIVirtualGatewayCreate(d *schema.ResourceData, meta inter var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.CreateVirtualGateway(context.Background(), &oscgo.CreateVirtualGatewayOpts{CreateVirtualGatewayRequest: optional.NewInterface(createOpts)}) + resp, _, err = conn.VirtualGatewayApi.CreateVirtualGateway(context.Background()).CreateVirtualGatewayRequest(createOpts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -128,9 +127,9 @@ func resourceOutscaleOAPIVirtualGatewayRead(d *schema.ResourceData, meta interfa var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{d.Id()}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -201,9 +200,9 @@ func resourceOutscaleOAPIVirtualGatewayDelete(d *schema.ResourceData, meta inter conn := meta.(*OutscaleClient).OSCAPI return resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := conn.VirtualGatewayApi.DeleteVirtualGateway(context.Background(), &oscgo.DeleteVirtualGatewayOpts{DeleteVirtualGatewayRequest: optional.NewInterface(oscgo.DeleteVirtualGatewayRequest{ + _, _, err := conn.VirtualGatewayApi.DeleteVirtualGateway(context.Background()).DeleteVirtualGatewayRequest(oscgo.DeleteVirtualGatewayRequest{ VirtualGatewayId: d.Id(), - })}) + }).Execute() if err == nil { return nil } @@ -232,9 +231,9 @@ func vpnGatewayAttachStateRefreshFunc(conn *oscgo.APIClient, id string, expected var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{id}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -278,13 +277,11 @@ func oapiVpnGatewayGetLink(vgw oscgo.VirtualGateway) *oscgo.NetToVirtualGatewayL func virtualGatewayStateRefreshFunc(conn *oscgo.APIClient, instanceID, failState string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ - ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ - Filters: &oscgo.FiltersVirtualGateway{ - VirtualGatewayIds: &[]string{instanceID}, - }, - }), - }) + resp, _, err := conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ + Filters: &oscgo.FiltersVirtualGateway{ + VirtualGatewayIds: &[]string{instanceID}, + }, + }).Execute() if err != nil { log.Printf("[ERROR] error on InstanceStateRefresh: %s", err) diff --git a/outscale/resource_outscale_virtual_gateway_link.go b/outscale/resource_outscale_virtual_gateway_link.go index c410da184..f5f4eda83 100644 --- a/outscale/resource_outscale_virtual_gateway_link.go +++ b/outscale/resource_outscale_virtual_gateway_link.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -80,7 +79,7 @@ func resourceOutscaleOAPIVirtualGatewayLinkCreate(d *schema.ResourceData, meta i var err error err = resource.Retry(30*time.Second, func() *resource.RetryError { - _, _, err = conn.VirtualGatewayApi.LinkVirtualGateway(context.Background(), &oscgo.LinkVirtualGatewayOpts{LinkVirtualGatewayRequest: optional.NewInterface(createOpts)}) + _, _, err = conn.VirtualGatewayApi.LinkVirtualGateway(context.Background()).LinkVirtualGatewayRequest(createOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidVirtualGatewayID.NotFound") { return resource.RetryableError( @@ -126,9 +125,9 @@ func resourceOutscaleOAPIVirtualGatewayLinkRead(d *schema.ResourceData, meta int var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{vgwID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -215,10 +214,10 @@ func resourceOutscaleOAPIVirtualGatewayLinkDelete(d *schema.ResourceData, meta i var err error err = resource.Retry(30*time.Second, func() *resource.RetryError { - _, _, err = conn.VirtualGatewayApi.UnlinkVirtualGateway(context.Background(), &oscgo.UnlinkVirtualGatewayOpts{UnlinkVirtualGatewayRequest: optional.NewInterface(oscgo.UnlinkVirtualGatewayRequest{ + _, _, err = conn.VirtualGatewayApi.UnlinkVirtualGateway(context.Background()).UnlinkVirtualGatewayRequest(oscgo.UnlinkVirtualGatewayRequest{ VirtualGatewayId: d.Id(), NetId: netID.(string), - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidVpnGatewayID.NotFound") { return resource.RetryableError( @@ -269,11 +268,10 @@ func vpnGatewayLinkStateRefresh(conn *oscgo.APIClient, vpcID, vgwID string) reso var err error var resp oscgo.ReadVirtualGatewaysResponse err = resource.Retry(30*time.Second, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface( - oscgo.ReadVirtualGatewaysRequest{Filters: &oscgo.FiltersVirtualGateway{ - VirtualGatewayIds: &[]string{vgwID}, - LinkNetIds: &[]string{vpcID}, - }})}) + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{Filters: &oscgo.FiltersVirtualGateway{ + VirtualGatewayIds: &[]string{vgwID}, + LinkNetIds: &[]string{vpcID}, + }}).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "InvalidVpnGatewayID.NotFound") { return resource.RetryableError( diff --git a/outscale/resource_outscale_virtual_gateway_link_test.go b/outscale/resource_outscale_virtual_gateway_link_test.go index cd71b43d6..947a0845a 100644 --- a/outscale/resource_outscale_virtual_gateway_link_test.go +++ b/outscale/resource_outscale_virtual_gateway_link_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -173,10 +172,9 @@ func testAccCheckOAPIVpnGatewayAttachmentDestroy(s *terraform.State) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface( - oscgo.ReadVirtualGatewaysRequest{ - Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{vgwID}}, - })}) + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ + Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{vgwID}}, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_virtual_gateway_route_propagation.go b/outscale/resource_outscale_virtual_gateway_route_propagation.go index e47f1becf..1d00f3c24 100644 --- a/outscale/resource_outscale_virtual_gateway_route_propagation.go +++ b/outscale/resource_outscale_virtual_gateway_route_propagation.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "log" "strings" "time" @@ -56,11 +55,11 @@ func resourceOutscaleOAPIVpnGatewayRoutePropagationEnable(d *schema.ResourceData var resp oscgo.UpdateRoutePropagationResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.UpdateRoutePropagation(context.Background(), &oscgo.UpdateRoutePropagationOpts{UpdateRoutePropagationRequest: optional.NewInterface(oscgo.UpdateRoutePropagationRequest{ + resp, _, err = conn.VirtualGatewayApi.UpdateRoutePropagation(context.Background()).UpdateRoutePropagationRequest(oscgo.UpdateRoutePropagationRequest{ VirtualGatewayId: gwID, RouteTableId: rtID, Enable: enable, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -92,11 +91,11 @@ func resourceOutscaleOAPIVpnGatewayRoutePropagationDisable(d *schema.ResourceDat var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.VirtualGatewayApi.UpdateRoutePropagation(context.Background(), &oscgo.UpdateRoutePropagationOpts{UpdateRoutePropagationRequest: optional.NewInterface(oscgo.UpdateRoutePropagationRequest{ + _, _, err = conn.VirtualGatewayApi.UpdateRoutePropagation(context.Background()).UpdateRoutePropagationRequest(oscgo.UpdateRoutePropagationRequest{ VirtualGatewayId: gwID, RouteTableId: rtID, Enable: enable, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -123,9 +122,9 @@ func resourceOutscaleOAPIVpnGatewayRoutePropagationRead(d *schema.ResourceData, var resp oscgo.ReadRouteTablesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background(), &oscgo.ReadRouteTablesOpts{ReadRouteTablesRequest: optional.NewInterface(oscgo.ReadRouteTablesRequest{ + resp, _, err = conn.RouteTableApi.ReadRouteTables(context.Background()).ReadRouteTablesRequest(oscgo.ReadRouteTablesRequest{ Filters: &oscgo.FiltersRouteTable{RouteTableIds: &[]string{rtID}}, - })}) + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_virtual_gateway_route_propagation_test.go b/outscale/resource_outscale_virtual_gateway_route_propagation_test.go index 957ee201c..59e143a81 100644 --- a/outscale/resource_outscale_virtual_gateway_route_propagation_test.go +++ b/outscale/resource_outscale_virtual_gateway_route_propagation_test.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "strings" "testing" "time" @@ -50,9 +49,9 @@ func testAccCheckOAPIVirtualRoutePropagationDestroy(s *terraform.State) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = oscapi.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = oscapi.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{rs.Primary.Attributes["gateway_id"]}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -68,9 +67,9 @@ func testAccCheckOAPIVirtualRoutePropagationDestroy(s *terraform.State) error { if len(resp.GetVirtualGateways()) > 0 { err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err := oscapi.VirtualGatewayApi.DeleteVirtualGateway(context.Background(), &oscgo.DeleteVirtualGatewayOpts{DeleteVirtualGatewayRequest: optional.NewInterface(&oscgo.DeleteVirtualGatewayRequest{ + _, _, err := oscapi.VirtualGatewayApi.DeleteVirtualGateway(context.Background()).DeleteVirtualGatewayRequest(oscgo.DeleteVirtualGatewayRequest{ VirtualGatewayId: resp.GetVirtualGateways()[0].GetVirtualGatewayId(), - })}) + }).Execute() if err == nil { return nil } diff --git a/outscale/resource_outscale_virtual_gateway_test.go b/outscale/resource_outscale_virtual_gateway_test.go index a2535bef1..b74404940 100644 --- a/outscale/resource_outscale_virtual_gateway_test.go +++ b/outscale/resource_outscale_virtual_gateway_test.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "strings" "testing" "time" @@ -127,7 +126,7 @@ func testAccOutscaleOAPIVirtualGatewayDisappears(gateway *oscgo.VirtualGateway) } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.VirtualGatewayApi.DeleteVirtualGateway(context.Background(), &oscgo.DeleteVirtualGatewayOpts{DeleteVirtualGatewayRequest: optional.NewInterface(opts)}) + _, _, err = conn.VirtualGatewayApi.DeleteVirtualGateway(context.Background()).DeleteVirtualGatewayRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -150,7 +149,7 @@ func testAccOutscaleOAPIVirtualGatewayDisappears(gateway *oscgo.VirtualGateway) var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(opts)}) + resp, _, err = conn.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -192,9 +191,9 @@ func testAccCheckOAPIVirtualGatewayDestroy(s *terraform.State) error { var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = OSCAPI.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = OSCAPI.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -252,9 +251,9 @@ func testAccCheckOAPIVirtualGatewayExists(n string, ig *oscgo.VirtualGateway) re var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = OSCAPI.VirtualGatewayApi.ReadVirtualGateways(context.Background(), &oscgo.ReadVirtualGatewaysOpts{ReadVirtualGatewaysRequest: optional.NewInterface(oscgo.ReadVirtualGatewaysRequest{ + resp, _, err = OSCAPI.VirtualGatewayApi.ReadVirtualGateways(context.Background()).ReadVirtualGatewaysRequest(oscgo.ReadVirtualGatewaysRequest{ Filters: &oscgo.FiltersVirtualGateway{VirtualGatewayIds: &[]string{rs.Primary.ID}}, - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_vm.go b/outscale/resource_outscale_vm.go index dd7f2eb57..a910add11 100644 --- a/outscale/resource_outscale_vm.go +++ b/outscale/resource_outscale_vm.go @@ -14,8 +14,7 @@ import ( "github.com/spf13/cast" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" ) @@ -507,9 +506,7 @@ func resourceOAPIVMCreate(d *schema.ResourceData, meta interface{}) error { var resp oscgo.CreateVmsResponse err = resource.Retry(30*time.Second, func() *resource.RetryError { var err error - resp, _, err = conn.VmApi.CreateVms(context.Background(), &oscgo.CreateVmsOpts{ - CreateVmsRequest: optional.NewInterface(vmOpts), - }) + resp, _, err = conn.VmApi.CreateVms(context.Background()).CreateVmsRequest(vmOpts).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -532,6 +529,7 @@ func resourceOAPIVMCreate(d *schema.ResourceData, meta interface{}) error { d.SetId(vm.GetVmId()) + log.Println("[DEBUG] imprimo log subnet") if tags, ok := d.GetOk("tags"); ok { err := assignTags(tags.(*schema.Set), vm.GetVmId(), conn) if err != nil { @@ -589,13 +587,11 @@ func resourceOAPIVMRead(d *schema.ResourceData, meta interface{}) error { var resp oscgo.ReadVmsResponse err := resource.Retry(30*time.Second, func() *resource.RetryError { - r, _, err := conn.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ - ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ - Filters: &oscgo.FiltersVm{ - VmIds: &[]string{d.Id()}, - }, - }), - }) + r, _, err := conn.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ + Filters: &oscgo.FiltersVm{ + VmIds: &[]string{d.Id()}, + }, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -639,11 +635,7 @@ func resourceOAPIVMRead(d *schema.ResourceData, meta interface{}) error { } func getOAPIVMAdminPassword(VMID string, conn *oscgo.APIClient) (string, error) { - resp, _, err := conn.VmApi.ReadAdminPassword(context.Background(), - &oscgo.ReadAdminPasswordOpts{ - ReadAdminPasswordRequest: optional.NewInterface(oscgo.ReadAdminPasswordRequest{VmId: VMID}), - }, - ) + resp, _, err := conn.VmApi.ReadAdminPassword(context.Background()).ReadAdminPasswordRequest(oscgo.ReadAdminPasswordRequest{VmId: VMID}).Execute() if err != nil { return "", fmt.Errorf("error reading the VM's password %s", err) @@ -824,11 +816,9 @@ func resourceOAPIVMDelete(d *schema.ResourceData, meta interface{}) error { var err error err = resource.Retry(30*time.Second, func() *resource.RetryError { - _, _, err = conn.VmApi.DeleteVms(context.Background(), &oscgo.DeleteVmsOpts{ - DeleteVmsRequest: optional.NewInterface(oscgo.DeleteVmsRequest{ - VmIds: []string{id}, - }), - }) + _, _, err = conn.VmApi.DeleteVms(context.Background()).DeleteVmsRequest(oscgo.DeleteVmsRequest{ + VmIds: []string{id}, + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { @@ -868,8 +858,8 @@ func buildCreateVmsRequest(d *schema.ResourceData, meta interface{}) (oscgo.Crea request := oscgo.CreateVmsRequest{ DeletionProtection: oscgo.PtrBool(d.Get("deletion_protection").(bool)), BsuOptimized: oscgo.PtrBool(d.Get("bsu_optimized").(bool)), - MaxVmsCount: oscgo.PtrInt64(1), - MinVmsCount: oscgo.PtrInt64(1), + MaxVmsCount: oscgo.PtrInt32(1), + MinVmsCount: oscgo.PtrInt32(1), ImageId: d.Get("image_id").(string), Placement: expandPlacement(d), } @@ -964,7 +954,7 @@ func expandBlockDeviceBSU(bsu map[string]interface{}) oscgo.BsuToCreate { bsuToCreate.SetSnapshotId(cast.ToString(snapshotID)) } if volumeSize, ok := bsu["volume_size"]; ok && volumeSize != "" { - bsuToCreate.SetVolumeSize(cast.ToInt64(volumeSize)) + bsuToCreate.SetVolumeSize(cast.ToInt32(volumeSize)) } if volumeType, ok := bsu["volume_type"]; ok && volumeType != "" { @@ -972,7 +962,7 @@ func expandBlockDeviceBSU(bsu map[string]interface{}) oscgo.BsuToCreate { bsuToCreate.SetVolumeType(vType) if iops, ok := bsu["iops"]; ok && vType == "io1" { - bsuToCreate.SetIops(cast.ToInt64(iops)) + bsuToCreate.SetIops(cast.ToInt32(iops)) } } @@ -988,7 +978,7 @@ func buildNetworkOApiInterfaceOpts(d *schema.ResourceData) []oscgo.NicForVmCreat nic := v.(map[string]interface{}) ni := oscgo.NicForVmCreation{ - DeviceNumber: oscgo.PtrInt64(int64(nic["device_number"].(int))), + DeviceNumber: oscgo.PtrInt32(int32(nic["device_number"].(int))), } if v := nic["nic_id"].(string); v != "" { @@ -996,7 +986,7 @@ func buildNetworkOApiInterfaceOpts(d *schema.ResourceData) []oscgo.NicForVmCreat } if v := nic["secondary_private_ip_count"].(int); v > 0 { - ni.SetSecondaryPrivateIpCount(int64(v)) + ni.SetSecondaryPrivateIpCount(int32(v)) } if delete, deleteOK := d.GetOk(fmt.Sprintf("nics.%d.delete_on_vm_deletion", i)); deleteOK { @@ -1053,13 +1043,11 @@ func expandPlacement(d *schema.ResourceData) *oscgo.Placement { func vmStateRefreshFunc(conn *oscgo.APIClient, instanceID, failState string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := conn.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ - ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ - Filters: &oscgo.FiltersVm{ - VmIds: &[]string{instanceID}, - }, - }), - }) + resp, _, err := conn.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ + Filters: &oscgo.FiltersVm{ + VmIds: &[]string{instanceID}, + }, + }).Execute() if err != nil { log.Printf("[ERROR] error on InstanceStateRefresh: %s", err) @@ -1083,11 +1071,9 @@ func vmStateRefreshFunc(conn *oscgo.APIClient, instanceID, failState string) res } func stopVM(vmID string, conn *oscgo.APIClient) error { - _, _, err := conn.VmApi.StopVms(context.Background(), &oscgo.StopVmsOpts{ - StopVmsRequest: optional.NewInterface(oscgo.StopVmsRequest{ - VmIds: []string{vmID}, - }), - }) + _, _, err := conn.VmApi.StopVms(context.Background()).StopVmsRequest(oscgo.StopVmsRequest{ + VmIds: []string{vmID}, + }).Execute() if err != nil { return fmt.Errorf("error stopping vms %s", err) @@ -1111,11 +1097,9 @@ func stopVM(vmID string, conn *oscgo.APIClient) error { } func startVM(vmID string, conn *oscgo.APIClient) error { - _, _, err := conn.VmApi.StartVms(context.Background(), &oscgo.StartVmsOpts{ - StartVmsRequest: optional.NewInterface(oscgo.StartVmsRequest{ - VmIds: []string{vmID}, - }), - }) + _, _, err := conn.VmApi.StartVms(context.Background()).StartVmsRequest(oscgo.StartVmsRequest{ + VmIds: []string{vmID}, + }).Execute() if err != nil { return fmt.Errorf("error starting vm %s", err) @@ -1138,9 +1122,7 @@ func startVM(vmID string, conn *oscgo.APIClient) error { } func updateVmAttr(conn *oscgo.APIClient, instanceAttrOpts oscgo.UpdateVmRequest) error { - if _, _, err := conn.VmApi.UpdateVm(context.Background(), &oscgo.UpdateVmOpts{ - UpdateVmRequest: optional.NewInterface(instanceAttrOpts), - }); err != nil { + if _, _, err := conn.VmApi.UpdateVm(context.Background()).UpdateVmRequest(instanceAttrOpts).Execute(); err != nil { return err } return nil diff --git a/outscale/resource_outscale_vm_test.go b/outscale/resource_outscale_vm_test.go index b5eac0621..cd2f8e51e 100644 --- a/outscale/resource_outscale_vm_test.go +++ b/outscale/resource_outscale_vm_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -457,9 +456,9 @@ func testAccCheckOAPIVMExistsWithProviders(n string, i *oscgo.Vm, providers *[]* var resp oscgo.ReadVmsResponse var err error for { - resp, _, err = client.OSCAPI.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ + resp, _, err = client.OSCAPI.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ Filters: getVMsFilterByVMID(rs.Primary.ID), - })}) + }).Execute() if err != nil { time.Sleep(10 * time.Second) } else { @@ -516,9 +515,9 @@ func testAccCheckOutscaleOAPIVMDestroyWithProvider(s *terraform.State, provider var err error for { // Try to find the resource - resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ + resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ Filters: getVMsFilterByVMID(rs.Primary.ID), - })}) + }).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded") { time.Sleep(10 * time.Second) @@ -574,9 +573,9 @@ func testAccCheckOutscaleOAPIVMExistsWithProviders(n string, i *oscgo.Vm, provid var err error for { - resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background(), &oscgo.ReadVmsOpts{ReadVmsRequest: optional.NewInterface(oscgo.ReadVmsRequest{ + resp, _, err = conn.OSCAPI.VmApi.ReadVms(context.Background()).ReadVmsRequest(oscgo.ReadVmsRequest{ Filters: getVMsFilterByVMID(rs.Primary.ID), - })}) + }).Execute() if err != nil { if oapiErr, ok := err.(awserr.Error); ok && oapiErr.Code() == "InvalidVmsID.NotFound" { continue diff --git a/outscale/resource_outscale_volume.go b/outscale/resource_outscale_volume.go index 86fd8b986..0f6c710c2 100644 --- a/outscale/resource_outscale_volume.go +++ b/outscale/resource_outscale_volume.go @@ -7,8 +7,7 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/aws/aws-sdk-go/aws/awserr" @@ -109,7 +108,7 @@ func resourceOAPIVolumeCreate(d *schema.ResourceData, meta interface{}) error { SubregionName: d.Get("subregion_name").(string), } if value, ok := d.GetOk("size"); ok { - request.SetSize(int64(value.(int))) + request.SetSize(int32(value.(int))) } if value, ok := d.GetOk("snapshot_id"); ok { request.SetSnapshotId(value.(string)) @@ -125,14 +124,14 @@ func resourceOAPIVolumeCreate(d *schema.ResourceData, meta interface{}) error { if t != "io1" && iops > 0 { log.Printf("[WARN] IOPs is only valid for storate type io1 for EBS Volumes") } else if t == "io1" { - request.SetIops(int64(iops)) + request.SetIops(int32(iops)) } var resp oscgo.CreateVolumeResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.VolumeApi.CreateVolume(context.Background(), &oscgo.CreateVolumeOpts{CreateVolumeRequest: optional.NewInterface(request)}) + resp, _, err = conn.VolumeApi.CreateVolume(context.Background()).CreateVolumeRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -185,7 +184,7 @@ func resourceOAPIVolumeRead(d *schema.ResourceData, meta interface{}) error { var resp oscgo.ReadVolumesResponse err := resource.Retry(5*time.Minute, func() *resource.RetryError { - r, _, err := conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(request)}) + r, _, err := conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -245,7 +244,7 @@ func resourceOAPIVolumeDelete(d *schema.ResourceData, meta interface{}) error { request := oscgo.DeleteVolumeRequest{ VolumeId: d.Id(), } - _, _, err := conn.VolumeApi.DeleteVolume(context.Background(), &oscgo.DeleteVolumeOpts{DeleteVolumeRequest: optional.NewInterface(request)}) + _, _, err := conn.VolumeApi.DeleteVolume(context.Background()).DeleteVolumeRequest(request).Execute() if err == nil { return nil } @@ -262,11 +261,11 @@ func resourceOAPIVolumeDelete(d *schema.ResourceData, meta interface{}) error { func volumeOAPIStateRefreshFunc(conn *oscgo.APIClient, volumeID string) resource.StateRefreshFunc { return func() (interface{}, string, error) { - resp, _, err := conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(oscgo.ReadVolumesRequest{ + resp, _, err := conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(oscgo.ReadVolumesRequest{ Filters: &oscgo.FiltersVolume{ VolumeIds: &[]string{volumeID}, }, - })}) + }).Execute() if err != nil { if ec2err, ok := err.(awserr.Error); ok { diff --git a/outscale/resource_outscale_volume_test.go b/outscale/resource_outscale_volume_test.go index 8ed94893a..d6649c3ad 100644 --- a/outscale/resource_outscale_volume_test.go +++ b/outscale/resource_outscale_volume_test.go @@ -8,8 +8,7 @@ import ( "testing" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" @@ -111,7 +110,7 @@ func testAccCheckOAPIVolumeExists(n string, v *oscgo.Volume) resource.TestCheckF var response oscgo.ReadVolumesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - response, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(request)}) + response, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_volumes_link.go b/outscale/resource_outscale_volumes_link.go index 499fd24c0..a8353d7dd 100644 --- a/outscale/resource_outscale_volumes_link.go +++ b/outscale/resource_outscale_volumes_link.go @@ -7,9 +7,8 @@ import ( "strings" "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" "github.com/openlyinc/pointy" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/aws/aws-sdk-go/aws/awserr" @@ -93,7 +92,7 @@ func resourceOAPIVolumeLinkCreate(d *schema.ResourceData, meta interface{}) erro var vols oscgo.ReadVolumesResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - vols, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(request)}) + vols, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { @@ -136,7 +135,7 @@ func resourceOAPIVolumeLinkCreate(d *schema.ResourceData, meta interface{}) erro err := resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - _, _, err = conn.VolumeApi.LinkVolume(context.Background(), &oscgo.LinkVolumeOpts{LinkVolumeRequest: optional.NewInterface(opts)}) + _, _, err = conn.VolumeApi.LinkVolume(context.Background()).LinkVolumeRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -204,7 +203,7 @@ func volumeOAPIAttachmentStateRefreshFunc(conn *oscgo.APIClient, volumeID, insta err = resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - resp, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(request)}) + resp, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -248,7 +247,7 @@ func resourceOAPIVolumeLinkRead(d *schema.ResourceData, meta interface{}) error err = resource.Retry(5*time.Minute, func() *resource.RetryError { var err error - vols, _, err = conn.VolumeApi.ReadVolumes(context.Background(), &oscgo.ReadVolumesOpts{ReadVolumesRequest: optional.NewInterface(request)}) + vols, _, err = conn.VolumeApi.ReadVolumes(context.Background()).ReadVolumesRequest(request).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { return resource.RetryableError(err) @@ -325,7 +324,7 @@ func resourceOAPIVolumeLinkDelete(d *schema.ResourceData, meta interface{}) erro var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.VolumeApi.UnlinkVolume(context.Background(), &oscgo.UnlinkVolumeOpts{UnlinkVolumeRequest: optional.NewInterface(opts)}) + _, _, err = conn.VolumeApi.UnlinkVolume(context.Background()).UnlinkVolumeRequest(opts).Execute() if err != nil { if strings.Contains(err.Error(), "RequestLimitExceeded:") { diff --git a/outscale/resource_outscale_volumes_link_test.go b/outscale/resource_outscale_volumes_link_test.go index 4c404967b..0d38f1e0e 100644 --- a/outscale/resource_outscale_volumes_link_test.go +++ b/outscale/resource_outscale_volumes_link_test.go @@ -5,7 +5,7 @@ import ( "os" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_vpn_connection.go b/outscale/resource_outscale_vpn_connection.go index ddeabdbc4..ed530e227 100644 --- a/outscale/resource_outscale_vpn_connection.go +++ b/outscale/resource_outscale_vpn_connection.go @@ -10,8 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" "github.com/spf13/cast" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleVPNConnection() *schema.Resource { @@ -105,10 +104,7 @@ func resourceOutscaleVPNConnectionCreate(d *schema.ResourceData, meta interface{ req.SetStaticRoutesOnly(cast.ToBool(staticRoutesOnly)) } - vpn, _, err := conn.VpnConnectionApi.CreateVpnConnection(context.Background(), - &oscgo.CreateVpnConnectionOpts{ - CreateVpnConnectionRequest: optional.NewInterface(req), - }) + vpn, _, err := conn.VpnConnectionApi.CreateVpnConnection(context.Background()).CreateVpnConnectionRequest(req).Execute() if err != nil { return fmt.Errorf("Error creating Outscale VPN Conecction: %s", err) } @@ -205,9 +201,7 @@ func resourceOutscaleVPNConnectionDelete(d *schema.ResourceData, meta interface{ VpnConnectionId: vpnConnectionID, } - _, _, err := conn.VpnConnectionApi.DeleteVpnConnection(context.Background(), &oscgo.DeleteVpnConnectionOpts{ - DeleteVpnConnectionRequest: optional.NewInterface(req), - }) + _, _, err := conn.VpnConnectionApi.DeleteVpnConnection(context.Background()).DeleteVpnConnectionRequest(req).Execute() if err != nil { return err } @@ -238,9 +232,7 @@ func vpnConnectionRefreshFunc(conn *oscgo.APIClient, vpnConnectionID *string) re }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() if err != nil { switch { case strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:"): diff --git a/outscale/resource_outscale_vpn_connection_route.go b/outscale/resource_outscale_vpn_connection_route.go index c72e75a95..ddec8d46b 100644 --- a/outscale/resource_outscale_vpn_connection_route.go +++ b/outscale/resource_outscale_vpn_connection_route.go @@ -8,12 +8,10 @@ import ( "strings" "time" - "github.com/antihax/optional" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func resourceOutscaleVPNConnectionRoute() *schema.Resource { @@ -55,10 +53,7 @@ func resourceOutscaleVPNConnectionRouteCreate(d *schema.ResourceData, meta inter VpnConnectionId: vpnConnectionID, } - _, _, err := conn.VpnConnectionApi.CreateVpnConnectionRoute(context.Background(), - &oscgo.CreateVpnConnectionRouteOpts{ - CreateVpnConnectionRouteRequest: optional.NewInterface(req), - }) + _, _, err := conn.VpnConnectionApi.CreateVpnConnectionRoute(context.Background()).CreateVpnConnectionRouteRequest(req).Execute() if err != nil { return fmt.Errorf("Error creating Outscale VPN Conecction Route: %s", err) } @@ -106,9 +101,7 @@ func resourceOutscaleVPNConnectionRouteDelete(d *schema.ResourceData, meta inter VpnConnectionId: vpnConnectionID, } - _, _, err := conn.VpnConnectionApi.DeleteVpnConnectionRoute(context.Background(), &oscgo.DeleteVpnConnectionRouteOpts{ - DeleteVpnConnectionRouteRequest: optional.NewInterface(req), - }) + _, _, err := conn.VpnConnectionApi.DeleteVpnConnectionRoute(context.Background()).DeleteVpnConnectionRouteRequest(req).Execute() if err != nil { return err } @@ -140,9 +133,7 @@ func vpnConnectionRouteRefreshFunc(conn *oscgo.APIClient, destinationIPRange, vp }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() if err != nil { switch { case strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:"): @@ -161,7 +152,7 @@ func vpnConnectionRouteRefreshFunc(conn *oscgo.APIClient, destinationIPRange, vp routes, ok := vpnConnection.GetRoutesOk() if ok { - for _, route := range routes { + for _, route := range *routes { if route.GetDestinationIpRange() == *destinationIPRange { return resp, route.GetState(), nil } diff --git a/outscale/resource_outscale_vpn_connection_route_test.go b/outscale/resource_outscale_vpn_connection_route_test.go index 5eb3363cc..8d95e7265 100644 --- a/outscale/resource_outscale_vpn_connection_route_test.go +++ b/outscale/resource_outscale_vpn_connection_route_test.go @@ -6,8 +6,7 @@ import ( "os" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -93,9 +92,7 @@ func testAccOutscaleVPNConnectionRouteExists(resourceName string) resource.TestC }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() vpnConnection := resp.GetVpnConnections()[0] @@ -129,9 +126,7 @@ func testAccOutscaleVPNConnectionRouteDestroy(s *terraform.State) error { }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() vpnConnection := resp.GetVpnConnections()[0] diff --git a/outscale/resource_outscale_vpn_connection_test.go b/outscale/resource_outscale_vpn_connection_test.go index 15d49e11d..263a149c6 100644 --- a/outscale/resource_outscale_vpn_connection_test.go +++ b/outscale/resource_outscale_vpn_connection_test.go @@ -5,8 +5,7 @@ import ( "fmt" "testing" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -173,9 +172,7 @@ func testAccOutscaleVPNConnectionExists(resourceName string) resource.TestCheckF }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() if err != nil || len(resp.GetVpnConnections()) < 1 { return fmt.Errorf("Outscale VPN Connection not found (%s)", rs.Primary.ID) } @@ -196,9 +193,7 @@ func testAccOutscaleVPNConnectionDestroy(s *terraform.State) error { }, } - resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background(), &oscgo.ReadVpnConnectionsOpts{ - ReadVpnConnectionsRequest: optional.NewInterface(filter), - }) + resp, _, err := conn.VpnConnectionApi.ReadVpnConnections(context.Background()).ReadVpnConnectionsRequest(filter).Execute() if err != nil || len(resp.GetVpnConnections()) > 0 && resp.GetVpnConnections()[0].GetState() != "deleted" { return fmt.Errorf("Outscale VPN Connection still exists (%s): %s", rs.Primary.ID, err) diff --git a/outscale/transport.go b/outscale/transport.go new file mode 100644 index 000000000..661f96463 --- /dev/null +++ b/outscale/transport.go @@ -0,0 +1,50 @@ +package outscale + +import ( + "io/ioutil" + "net/http" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws/credentials" + v4 "github.com/aws/aws-sdk-go/aws/signer/v4" +) + +type transport struct { + transport http.RoundTripper + signer *v4.Signer + region string +} + +func (t *transport) sign(req *http.Request, body []byte) error { + reader := strings.NewReader(string(body)) + timestamp := time.Now() + _, err := t.signer.Sign(req, reader, "oapi", t.region, timestamp) + return err +} + +func (t *transport) RoundTrip(req *http.Request) (*http.Response, error) { + body, err := ioutil.ReadAll(req.Body) + if err != nil { + return nil, err + } + + if err := t.sign(req, body); err != nil { + return nil, err + } + + resp, err := t.transport.RoundTrip(req) + if err != nil { + return resp, err + } + + return resp, nil +} + +func NewTransport(accessKey, accessSecret, region string, t http.RoundTripper) *transport { + s := &v4.Signer{ + Credentials: credentials.NewStaticCredentials(accessKey, + accessSecret, ""), + } + return &transport{t, s, region} +} diff --git a/utils/utils.go b/utils/utils.go index b3e5e1bf1..abc07cc6e 100644 --- a/utils/utils.go +++ b/utils/utils.go @@ -5,7 +5,7 @@ import ( "fmt" "strconv" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/spf13/cast" "github.com/aws/aws-sdk-go/aws" From 5ed3ebca11e3fb23f101c1ab2ea8046cb9709c8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Mon, 19 Oct 2020 12:25:17 -0600 Subject: [PATCH 009/218] added basepath in config --- outscale/config.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/outscale/config.go b/outscale/config.go index a857cddef..914ead2f7 100644 --- a/outscale/config.go +++ b/outscale/config.go @@ -2,6 +2,7 @@ package outscale import ( "crypto/tls" + "fmt" "net/http" "github.com/hashicorp/terraform-plugin-sdk/helper/logging" @@ -36,9 +37,16 @@ func (c *Config) Client() (*OutscaleClient, error) { skipClient.Transport = NewTransport(c.AccessKeyID, c.SecretKeyID, c.Region, skipClient.Transport) + basePath := fmt.Sprintf("api.%s.outscale.com", c.Region) + if endpoint, ok := c.Endpoints["api"]; ok { + basePath = endpoint.(string) + } + oscConfig := oscgo.NewConfiguration() oscConfig.Debug = true oscConfig.HTTPClient = skipClient + oscConfig.Host = basePath + oscConfig.UserAgent = "terraform-provider-outscale-dev" oscClient := oscgo.NewAPIClient(oscConfig) From 9f89f4c5109898a85b8e756298ca98d0ee0f5c30 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Tue, 20 Oct 2020 15:17:43 -0600 Subject: [PATCH 010/218] fixes parameter set --- outscale/data_source_outscale_vpn_connection.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/data_source_outscale_vpn_connection.go b/outscale/data_source_outscale_vpn_connection.go index 17256f184..fcd4787f6 100644 --- a/outscale/data_source_outscale_vpn_connection.go +++ b/outscale/data_source_outscale_vpn_connection.go @@ -136,7 +136,7 @@ func dataSourceOutscaleVPNConnectionRead(d *schema.ResourceData, meta interface{ if err := d.Set("static_routes_only", vpnConnection.GetStaticRoutesOnly()); err != nil { return err } - if err := d.Set("client_gateway_configuration", vpnConnection.GetClientGatewayId()); err != nil { + if err := d.Set("client_gateway_configuration", vpnConnection.GetClientGatewayConfiguration()); err != nil { return err } if err := d.Set("vpn_connection_id", vpnConnection.GetVpnConnectionId()); err != nil { From 828571184a401dc99d750da46929d396e232465b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Wed, 21 Oct 2020 10:56:03 -0600 Subject: [PATCH 011/218] chore: deleted sdk marin vendor --- go.mod | 3 +- go.sum | 4 - vendor/github.com/antihax/optional/LICENSE | 8 - vendor/github.com/antihax/optional/bool.go | 36 - vendor/github.com/antihax/optional/byte.go | 36 - .../github.com/antihax/optional/complex128.go | 36 - .../github.com/antihax/optional/complex64.go | 36 - vendor/github.com/antihax/optional/float32.go | 36 - vendor/github.com/antihax/optional/float64.go | 36 - vendor/github.com/antihax/optional/go.mod | 3 - vendor/github.com/antihax/optional/int.go | 36 - vendor/github.com/antihax/optional/int16.go | 36 - vendor/github.com/antihax/optional/int32.go | 36 - vendor/github.com/antihax/optional/int64.go | 36 - vendor/github.com/antihax/optional/int8.go | 36 - .../github.com/antihax/optional/interface.go | 37 - vendor/github.com/antihax/optional/rune.go | 36 - vendor/github.com/antihax/optional/string.go | 36 - vendor/github.com/antihax/optional/time.go | 38 - vendor/github.com/antihax/optional/uint.go | 36 - vendor/github.com/antihax/optional/uint16.go | 36 - vendor/github.com/antihax/optional/uint32.go | 36 - vendor/github.com/antihax/optional/uint64.go | 36 - vendor/github.com/antihax/optional/uint8.go | 36 - vendor/github.com/antihax/optional/uintptr.go | 36 - .../marinsalinas/osc-sdk-go/.gitignore | 24 - .../osc-sdk-go/.openapi-generator-ignore | 23 - .../marinsalinas/osc-sdk-go/.travis.yml | 8 - .../marinsalinas/osc-sdk-go/README.md | 681 - .../marinsalinas/osc-sdk-go/api_access_key.go | 585 - .../marinsalinas/osc-sdk-go/api_account.go | 711 - .../marinsalinas/osc-sdk-go/api_api_log.go | 141 - .../osc-sdk-go/api_client_gateway.go | 369 - .../marinsalinas/osc-sdk-go/api_default.go | 141 - .../osc-sdk-go/api_dhcp_option.go | 369 - .../osc-sdk-go/api_direct_link.go | 369 - .../osc-sdk-go/api_direct_link_interface.go | 369 - .../osc-sdk-go/api_flexible_gpu.go | 811 - .../marinsalinas/osc-sdk-go/api_image.go | 832 -- .../osc-sdk-go/api_internet_service.go | 748 - .../marinsalinas/osc-sdk-go/api_keypair.go | 470 - .../marinsalinas/osc-sdk-go/api_listener.go | 711 - .../osc-sdk-go/api_load_balancer.go | 1167 -- .../osc-sdk-go/api_load_balancer_policy.go | 255 - .../marinsalinas/osc-sdk-go/api_location.go | 127 - .../osc-sdk-go/api_nat_service.go | 460 - .../marinsalinas/osc-sdk-go/api_net.go | 614 - .../osc-sdk-go/api_net_access_point.go | 583 - .../osc-sdk-go/api_net_peering.go | 778 - .../marinsalinas/osc-sdk-go/api_nic.go | 1180 -- .../osc-sdk-go/api_product_type.go | 127 - .../marinsalinas/osc-sdk-go/api_public_ip.go | 848 -- .../marinsalinas/osc-sdk-go/api_quota.go | 141 - .../marinsalinas/osc-sdk-go/api_region.go | 141 - .../marinsalinas/osc-sdk-go/api_route.go | 460 - .../osc-sdk-go/api_route_table.go | 748 - .../osc-sdk-go/api_security_group.go | 460 - .../osc-sdk-go/api_security_group_rule.go | 316 - .../osc-sdk-go/api_server_certificate.go | 483 - .../marinsalinas/osc-sdk-go/api_snapshot.go | 832 -- .../marinsalinas/osc-sdk-go/api_subnet.go | 614 - .../marinsalinas/osc-sdk-go/api_subregion.go | 141 - .../marinsalinas/osc-sdk-go/api_tag.go | 460 - .../marinsalinas/osc-sdk-go/api_task.go | 141 - .../osc-sdk-go/api_virtual_gateway.go | 711 - .../marinsalinas/osc-sdk-go/api_vm.go | 1568 -- .../marinsalinas/osc-sdk-go/api_volume.go | 748 - .../osc-sdk-go/api_vpn_connection.go | 597 - .../marinsalinas/osc-sdk-go/client.go | 619 - .../marinsalinas/osc-sdk-go/configuration.go | 76 - .../marinsalinas/osc-sdk-go/gen-config.json | 4 - .../marinsalinas/osc-sdk-go/git_push.sh | 58 - .../github.com/marinsalinas/osc-sdk-go/go.mod | 9 - .../github.com/marinsalinas/osc-sdk-go/go.sum | 31 - .../model_accept_net_peering_request.go | 95 - .../model_accept_net_peering_response.go | 111 - .../osc-sdk-go/model_accepter_net.go | 148 - .../osc-sdk-go/model_access_key.go | 183 - .../osc-sdk-go/model_access_key_secret_key.go | 218 - .../osc-sdk-go/model_access_log.go | 183 - .../marinsalinas/osc-sdk-go/model_account.go | 533 - .../model_application_sticky_cookie_policy.go | 113 - .../osc-sdk-go/model_backend_vm_health.go | 183 - .../model_block_device_mapping_created.go | 112 - .../model_block_device_mapping_image.go | 147 - .../model_block_device_mapping_vm_creation.go | 182 - .../model_block_device_mapping_vm_update.go | 182 - .../osc-sdk-go/model_bsu_created.go | 183 - .../osc-sdk-go/model_bsu_to_create.go | 218 - .../osc-sdk-go/model_bsu_to_update_vm.go | 113 - .../model_check_authentication_request.go | 148 - .../model_check_authentication_response.go | 77 - .../osc-sdk-go/model_client_gateway.go | 253 - .../osc-sdk-go/model_consumption_entry.go | 323 - .../model_create_access_key_response.go | 111 - .../model_create_account_request.go | 389 - .../model_create_account_response.go | 111 - .../model_create_client_gateway_request.go | 129 - .../model_create_client_gateway_response.go | 111 - .../model_create_dhcp_options_request.go | 183 - .../model_create_dhcp_options_response.go | 111 - ...el_create_direct_link_interface_request.go | 111 - ...l_create_direct_link_interface_response.go | 111 - .../model_create_direct_link_request.go | 129 - .../model_create_direct_link_response.go | 111 - .../model_create_flexible_gpu_request.go | 182 - .../model_create_flexible_gpu_response.go | 111 - .../model_create_image_export_task_request.go | 111 - ...model_create_image_export_task_response.go | 111 - .../osc-sdk-go/model_create_image_request.go | 428 - .../osc-sdk-go/model_create_image_response.go | 111 - .../model_create_internet_service_request.go | 78 - .../model_create_internet_service_response.go | 111 - .../model_create_keypair_request.go | 130 - .../model_create_keypair_response.go | 111 - .../model_create_listener_rule_request.go | 127 - .../model_create_listener_rule_response.go | 111 - ..._create_load_balancer_listeners_request.go | 112 - ...create_load_balancer_listeners_response.go | 111 - ...del_create_load_balancer_policy_request.go | 164 - ...el_create_load_balancer_policy_response.go | 111 - .../model_create_load_balancer_request.go | 287 - .../model_create_load_balancer_response.go | 111 - ...model_create_load_balancer_tags_request.go | 112 - ...odel_create_load_balancer_tags_response.go | 77 - .../model_create_nat_service_request.go | 112 - .../model_create_nat_service_response.go | 111 - .../model_create_net_access_point_request.go | 147 - .../model_create_net_access_point_response.go | 111 - .../model_create_net_peering_request.go | 112 - .../model_create_net_peering_response.go | 111 - .../osc-sdk-go/model_create_net_request.go | 130 - .../osc-sdk-go/model_create_net_response.go | 111 - .../osc-sdk-go/model_create_nic_request.go | 200 - .../osc-sdk-go/model_create_nic_response.go | 111 - .../model_create_public_ip_request.go | 78 - .../model_create_public_ip_response.go | 111 - .../osc-sdk-go/model_create_route_request.go | 287 - .../osc-sdk-go/model_create_route_response.go | 111 - .../model_create_route_table_request.go | 95 - .../model_create_route_table_response.go | 111 - .../model_create_security_group_request.go | 147 - .../model_create_security_group_response.go | 111 - ...odel_create_security_group_rule_request.go | 357 - ...del_create_security_group_rule_response.go | 111 - ...model_create_server_certificate_request.go | 199 - ...odel_create_server_certificate_response.go | 111 - ...del_create_snapshot_export_task_request.go | 111 - ...el_create_snapshot_export_task_response.go | 111 - .../model_create_snapshot_request.go | 288 - .../model_create_snapshot_response.go | 111 - .../osc-sdk-go/model_create_subnet_request.go | 147 - .../model_create_subnet_response.go | 111 - .../osc-sdk-go/model_create_tags_request.go | 112 - .../osc-sdk-go/model_create_tags_response.go | 77 - .../model_create_virtual_gateway_request.go | 95 - .../model_create_virtual_gateway_response.go | 111 - .../osc-sdk-go/model_create_vms_request.go | 724 - .../osc-sdk-go/model_create_vms_response.go | 112 - .../osc-sdk-go/model_create_volume_request.go | 235 - .../model_create_volume_response.go | 111 - .../model_create_vpn_connection_request.go | 164 - .../model_create_vpn_connection_response.go | 111 - ...del_create_vpn_connection_route_request.go | 112 - ...el_create_vpn_connection_route_response.go | 77 - .../model_delete_access_key_request.go | 95 - .../model_delete_access_key_response.go | 77 - .../model_delete_client_gateway_request.go | 95 - .../model_delete_client_gateway_response.go | 77 - .../model_delete_dhcp_options_request.go | 95 - .../model_delete_dhcp_options_response.go | 77 - ...el_delete_direct_link_interface_request.go | 95 - ...l_delete_direct_link_interface_response.go | 77 - .../model_delete_direct_link_request.go | 95 - .../model_delete_direct_link_response.go | 77 - .../model_delete_export_task_request.go | 95 - .../model_delete_export_task_response.go | 77 - .../model_delete_flexible_gpu_request.go | 95 - .../model_delete_flexible_gpu_response.go | 77 - .../osc-sdk-go/model_delete_image_request.go | 95 - .../osc-sdk-go/model_delete_image_response.go | 77 - .../model_delete_internet_service_request.go | 95 - .../model_delete_internet_service_response.go | 77 - .../model_delete_keypair_request.go | 95 - .../model_delete_keypair_response.go | 77 - .../model_delete_listener_rule_request.go | 95 - .../model_delete_listener_rule_response.go | 77 - ..._delete_load_balancer_listeners_request.go | 112 - ...delete_load_balancer_listeners_response.go | 111 - ...del_delete_load_balancer_policy_request.go | 112 - ...el_delete_load_balancer_policy_response.go | 111 - .../model_delete_load_balancer_request.go | 95 - .../model_delete_load_balancer_response.go | 77 - ...model_delete_load_balancer_tags_request.go | 112 - ...odel_delete_load_balancer_tags_response.go | 77 - .../model_delete_nat_service_request.go | 95 - .../model_delete_nat_service_response.go | 77 - .../model_delete_net_access_point_request.go | 95 - .../model_delete_net_access_point_response.go | 77 - .../model_delete_net_peering_request.go | 95 - .../model_delete_net_peering_response.go | 77 - .../osc-sdk-go/model_delete_net_request.go | 95 - .../osc-sdk-go/model_delete_net_response.go | 77 - .../osc-sdk-go/model_delete_nic_request.go | 95 - .../osc-sdk-go/model_delete_nic_response.go | 77 - .../model_delete_public_ip_request.go | 148 - .../model_delete_public_ip_response.go | 77 - .../osc-sdk-go/model_delete_route_request.go | 112 - .../osc-sdk-go/model_delete_route_response.go | 111 - .../model_delete_route_table_request.go | 95 - .../model_delete_route_table_response.go | 77 - .../model_delete_security_group_request.go | 148 - .../model_delete_security_group_response.go | 77 - ...odel_delete_security_group_rule_request.go | 357 - ...del_delete_security_group_rule_response.go | 111 - ...model_delete_server_certificate_request.go | 95 - ...odel_delete_server_certificate_response.go | 77 - .../model_delete_snapshot_request.go | 95 - .../model_delete_snapshot_response.go | 77 - .../osc-sdk-go/model_delete_subnet_request.go | 95 - .../model_delete_subnet_response.go | 77 - .../osc-sdk-go/model_delete_tags_request.go | 112 - .../osc-sdk-go/model_delete_tags_response.go | 77 - .../model_delete_virtual_gateway_request.go | 95 - .../model_delete_virtual_gateway_response.go | 77 - .../osc-sdk-go/model_delete_vms_request.go | 95 - .../osc-sdk-go/model_delete_vms_response.go | 112 - .../osc-sdk-go/model_delete_volume_request.go | 95 - .../model_delete_volume_response.go | 77 - .../model_delete_vpn_connection_request.go | 95 - .../model_delete_vpn_connection_response.go | 77 - ...del_delete_vpn_connection_route_request.go | 112 - ...el_delete_vpn_connection_route_response.go | 77 - ...deregister_vms_in_load_balancer_request.go | 112 - ...eregister_vms_in_load_balancer_response.go | 77 - .../osc-sdk-go/model_dhcp_options_set.go | 288 - .../osc-sdk-go/model_direct_link.go | 288 - .../osc-sdk-go/model_direct_link_interface.go | 216 - .../model_direct_link_interfaces.go | 498 - .../osc-sdk-go/model_error_response.go | 112 - .../marinsalinas/osc-sdk-go/model_errors.go | 148 - .../osc-sdk-go/model_filters_access_keys.go | 113 - .../osc-sdk-go/model_filters_api_log.go | 358 - .../model_filters_client_gateway.go | 323 - .../osc-sdk-go/model_filters_dhcp_options.go | 323 - .../osc-sdk-go/model_filters_direct_link.go | 78 - .../model_filters_direct_link_interface.go | 113 - .../osc-sdk-go/model_filters_export_task.go | 183 - .../osc-sdk-go/model_filters_flexible_gpu.go | 253 - .../osc-sdk-go/model_filters_image.go | 778 - .../model_filters_internet_service.go | 183 - .../osc-sdk-go/model_filters_keypair.go | 113 - .../osc-sdk-go/model_filters_listener_rule.go | 78 - .../osc-sdk-go/model_filters_load_balancer.go | 78 - .../osc-sdk-go/model_filters_nat_service.go | 288 - .../osc-sdk-go/model_filters_net.go | 288 - .../model_filters_net_access_point.go | 288 - .../osc-sdk-go/model_filters_net_peering.go | 463 - .../osc-sdk-go/model_filters_nic.go | 218 - .../osc-sdk-go/model_filters_product_type.go | 78 - .../osc-sdk-go/model_filters_public_ip.go | 428 - .../osc-sdk-go/model_filters_quota.go | 183 - .../osc-sdk-go/model_filters_route_table.go | 533 - .../model_filters_security_group.go | 253 - .../model_filters_server_certificate.go | 78 - .../osc-sdk-go/model_filters_service.go | 113 - .../osc-sdk-go/model_filters_snapshot.go | 498 - .../osc-sdk-go/model_filters_subnet.go | 253 - .../osc-sdk-go/model_filters_subregion.go | 78 - .../osc-sdk-go/model_filters_tag.go | 183 - .../model_filters_virtual_gateway.go | 323 - .../osc-sdk-go/model_filters_vm.go | 183 - .../osc-sdk-go/model_filters_vm_type.go | 253 - .../osc-sdk-go/model_filters_vms_state.go | 148 - .../osc-sdk-go/model_filters_volume.go | 568 - .../model_filters_vpn_connection.go | 323 - .../osc-sdk-go/model_flexible_gpu.go | 288 - .../osc-sdk-go/model_flexible_gpu_catalog.go | 218 - .../osc-sdk-go/model_health_check.go | 162 - .../marinsalinas/osc-sdk-go/model_image.go | 636 - .../osc-sdk-go/model_image_export_task.go | 287 - .../osc-sdk-go/model_internet_service.go | 183 - .../marinsalinas/osc-sdk-go/model_keypair.go | 113 - .../osc-sdk-go/model_keypair_created.go | 148 - .../model_link_flexible_gpu_request.go | 112 - .../model_link_flexible_gpu_response.go | 77 - .../model_link_internet_service_request.go | 112 - .../model_link_internet_service_response.go | 77 - .../marinsalinas/osc-sdk-go/model_link_nic.go | 253 - .../osc-sdk-go/model_link_nic_light.go | 183 - .../osc-sdk-go/model_link_nic_request.go | 129 - .../osc-sdk-go/model_link_nic_response.go | 112 - .../osc-sdk-go/model_link_nic_to_update.go | 113 - .../model_link_private_ips_request.go | 200 - .../model_link_private_ips_response.go | 77 - .../osc-sdk-go/model_link_public_ip.go | 218 - .../model_link_public_ip_light_for_vm.go | 148 - .../model_link_public_ip_request.go | 288 - .../model_link_public_ip_response.go | 112 - .../osc-sdk-go/model_link_route_table.go | 183 - .../model_link_route_table_request.go | 112 - .../model_link_route_table_response.go | 112 - .../model_link_virtual_gateway_request.go | 112 - .../model_link_virtual_gateway_response.go | 111 - .../osc-sdk-go/model_link_volume_request.go | 129 - .../osc-sdk-go/model_link_volume_response.go | 77 - .../osc-sdk-go/model_linked_volume.go | 218 - .../marinsalinas/osc-sdk-go/model_listener.go | 253 - .../osc-sdk-go/model_listener_for_creation.go | 164 - .../osc-sdk-go/model_listener_rule.go | 323 - .../model_listener_rule_for_creation.go | 235 - .../osc-sdk-go/model_load_balancer.go | 565 - .../osc-sdk-go/model_load_balancer_light.go | 77 - ...odel_load_balancer_sticky_cookie_policy.go | 78 - .../osc-sdk-go/model_load_balancer_tag.go | 148 - .../marinsalinas/osc-sdk-go/model_location.go | 113 - .../marinsalinas/osc-sdk-go/model_log.go | 603 - .../osc-sdk-go/model_maintenance_event.go | 183 - .../osc-sdk-go/model_nat_service.go | 253 - .../marinsalinas/osc-sdk-go/model_net.go | 253 - .../osc-sdk-go/model_net_access_point.go | 253 - .../osc-sdk-go/model_net_peering.go | 215 - .../osc-sdk-go/model_net_peering_state.go | 113 - .../model_net_to_virtual_gateway_link.go | 113 - .../marinsalinas/osc-sdk-go/model_nic.go | 566 - .../osc-sdk-go/model_nic_for_vm_creation.go | 323 - .../osc-sdk-go/model_nic_light.go | 496 - .../osc-sdk-go/model_osu_api_key.go | 113 - .../osc-sdk-go/model_osu_export.go | 181 - .../model_permissions_on_resource.go | 113 - .../model_permissions_on_resource_creation.go | 111 - .../osc-sdk-go/model_placement.go | 113 - .../osc-sdk-go/model_private_ip.go | 182 - .../osc-sdk-go/model_private_ip_light.go | 113 - .../model_private_ip_light_for_vm.go | 182 - .../osc-sdk-go/model_product_type.go | 148 - .../osc-sdk-go/model_public_ip.go | 323 - .../osc-sdk-go/model_public_ip_light.go | 113 - .../marinsalinas/osc-sdk-go/model_quota.go | 288 - .../osc-sdk-go/model_quota_types.go | 113 - .../model_read_access_keys_request.go | 77 - .../model_read_access_keys_response.go | 112 - .../osc-sdk-go/model_read_accounts_request.go | 78 - .../model_read_accounts_response.go | 112 - .../model_read_admin_password_request.go | 95 - .../model_read_admin_password_response.go | 147 - .../osc-sdk-go/model_read_api_logs_request.go | 216 - .../model_read_api_logs_response.go | 147 - .../model_read_client_gateways_request.go | 112 - .../model_read_client_gateways_response.go | 112 - .../model_read_console_output_request.go | 95 - .../model_read_console_output_response.go | 147 - .../model_read_consumption_account_request.go | 112 - ...model_read_consumption_account_response.go | 112 - .../model_read_dhcp_options_request.go | 112 - .../model_read_dhcp_options_response.go | 112 - ...del_read_direct_link_interfaces_request.go | 112 - ...el_read_direct_link_interfaces_response.go | 112 - .../model_read_direct_links_request.go | 112 - .../model_read_direct_links_response.go | 112 - ...model_read_flexible_gpu_catalog_request.go | 78 - ...odel_read_flexible_gpu_catalog_response.go | 112 - .../model_read_flexible_gpus_request.go | 112 - .../model_read_flexible_gpus_response.go | 112 - .../model_read_image_export_tasks_request.go | 112 - .../model_read_image_export_tasks_response.go | 112 - .../osc-sdk-go/model_read_images_request.go | 112 - .../osc-sdk-go/model_read_images_response.go | 112 - .../model_read_internet_services_request.go | 112 - .../model_read_internet_services_response.go | 112 - .../osc-sdk-go/model_read_keypairs_request.go | 112 - .../model_read_keypairs_response.go | 112 - .../model_read_listener_rules_request.go | 112 - .../model_read_listener_rules_response.go | 112 - .../model_read_load_balancer_tags_request.go | 95 - .../model_read_load_balancer_tags_response.go | 112 - .../model_read_load_balancers_request.go | 112 - .../model_read_load_balancers_response.go | 112 - .../model_read_locations_request.go | 78 - .../model_read_locations_response.go | 112 - .../model_read_nat_services_request.go | 112 - .../model_read_nat_services_response.go | 112 - ..._read_net_access_point_services_request.go | 112 - ...read_net_access_point_services_response.go | 112 - .../model_read_net_access_points_request.go | 112 - .../model_read_net_access_points_response.go | 112 - .../model_read_net_peerings_request.go | 112 - .../model_read_net_peerings_response.go | 112 - .../osc-sdk-go/model_read_nets_request.go | 112 - .../osc-sdk-go/model_read_nets_response.go | 112 - .../osc-sdk-go/model_read_nics_request.go | 112 - .../osc-sdk-go/model_read_nics_response.go | 112 - .../model_read_product_types_request.go | 112 - .../model_read_product_types_response.go | 112 - .../model_read_public_ip_ranges_request.go | 78 - .../model_read_public_ip_ranges_response.go | 112 - .../model_read_public_ips_request.go | 112 - .../model_read_public_ips_response.go | 112 - .../osc-sdk-go/model_read_quotas_request.go | 112 - .../osc-sdk-go/model_read_quotas_response.go | 112 - .../osc-sdk-go/model_read_regions_request.go | 78 - .../osc-sdk-go/model_read_regions_response.go | 112 - .../model_read_route_tables_request.go | 112 - .../model_read_route_tables_response.go | 112 - .../model_read_secret_access_key_request.go | 60 - .../model_read_secret_access_key_response.go | 111 - .../model_read_security_groups_request.go | 112 - .../model_read_security_groups_response.go | 112 - .../model_read_server_certificates_request.go | 112 - ...model_read_server_certificates_response.go | 112 - ...odel_read_snapshot_export_tasks_request.go | 112 - ...del_read_snapshot_export_tasks_response.go | 112 - .../model_read_snapshots_request.go | 112 - .../model_read_snapshots_response.go | 112 - .../osc-sdk-go/model_read_subnets_request.go | 112 - .../osc-sdk-go/model_read_subnets_response.go | 112 - .../model_read_subregions_request.go | 112 - .../model_read_subregions_response.go | 112 - .../osc-sdk-go/model_read_tags_request.go | 112 - .../osc-sdk-go/model_read_tags_response.go | 112 - .../model_read_virtual_gateways_request.go | 112 - .../model_read_virtual_gateways_response.go | 112 - .../osc-sdk-go/model_read_vm_types_request.go | 112 - .../model_read_vm_types_response.go | 112 - .../model_read_vms_health_request.go | 130 - .../model_read_vms_health_response.go | 112 - .../osc-sdk-go/model_read_vms_request.go | 112 - .../osc-sdk-go/model_read_vms_response.go | 112 - .../model_read_vms_state_request.go | 147 - .../model_read_vms_state_response.go | 112 - .../osc-sdk-go/model_read_volumes_request.go | 112 - .../osc-sdk-go/model_read_volumes_response.go | 112 - .../model_read_vpn_connections_request.go | 112 - .../model_read_vpn_connections_response.go | 112 - .../osc-sdk-go/model_reboot_vms_request.go | 95 - .../osc-sdk-go/model_reboot_vms_response.go | 77 - .../marinsalinas/osc-sdk-go/model_region.go | 113 - ...l_register_vms_in_load_balancer_request.go | 112 - ..._register_vms_in_load_balancer_response.go | 77 - .../model_reject_net_peering_request.go | 95 - .../model_reject_net_peering_response.go | 77 - .../model_reset_account_password_request.go | 112 - .../model_reset_account_password_response.go | 77 - .../model_resource_load_balancer_tag.go | 78 - .../osc-sdk-go/model_resource_tag.go | 77 - .../osc-sdk-go/model_response_context.go | 78 - .../marinsalinas/osc-sdk-go/model_route.go | 428 - .../osc-sdk-go/model_route_light.go | 148 - ...model_route_propagating_virtual_gateway.go | 78 - .../osc-sdk-go/model_route_table.go | 253 - .../osc-sdk-go/model_security_group.go | 323 - .../osc-sdk-go/model_security_group_light.go | 113 - .../osc-sdk-go/model_security_group_rule.go | 253 - .../model_security_groups_member.go | 148 - ...model_send_reset_password_email_request.go | 95 - ...odel_send_reset_password_email_response.go | 77 - .../osc-sdk-go/model_server_certificate.go | 218 - .../marinsalinas/osc-sdk-go/model_service.go | 148 - .../marinsalinas/osc-sdk-go/model_snapshot.go | 392 - .../osc-sdk-go/model_snapshot_export_task.go | 287 - .../osc-sdk-go/model_source_net.go | 148 - .../osc-sdk-go/model_source_security_group.go | 113 - .../osc-sdk-go/model_start_vms_request.go | 95 - .../osc-sdk-go/model_start_vms_response.go | 112 - .../osc-sdk-go/model_state_comment.go | 113 - .../osc-sdk-go/model_stop_vms_request.go | 130 - .../osc-sdk-go/model_stop_vms_response.go | 112 - .../marinsalinas/osc-sdk-go/model_subnet.go | 323 - .../osc-sdk-go/model_subregion.go | 148 - .../marinsalinas/osc-sdk-go/model_tag.go | 183 - .../model_unlink_flexible_gpu_request.go | 95 - .../model_unlink_flexible_gpu_response.go | 77 - .../model_unlink_internet_service_request.go | 112 - .../model_unlink_internet_service_response.go | 77 - .../osc-sdk-go/model_unlink_nic_request.go | 95 - .../osc-sdk-go/model_unlink_nic_response.go | 77 - .../model_unlink_private_ips_request.go | 112 - .../model_unlink_private_ips_response.go | 77 - .../model_unlink_public_ip_request.go | 148 - .../model_unlink_public_ip_response.go | 77 - .../model_unlink_route_table_request.go | 95 - .../model_unlink_route_table_response.go | 77 - .../model_unlink_virtual_gateway_request.go | 112 - .../model_unlink_virtual_gateway_response.go | 77 - .../osc-sdk-go/model_unlink_volume_request.go | 130 - .../model_unlink_volume_response.go | 77 - .../model_update_access_key_request.go | 77 - .../model_update_access_key_response.go | 111 - .../model_update_account_request.go | 498 - .../model_update_account_response.go | 111 - .../model_update_flexible_gpu_request.go | 130 - .../model_update_flexible_gpu_response.go | 111 - .../osc-sdk-go/model_update_image_request.go | 111 - .../osc-sdk-go/model_update_image_response.go | 111 - .../model_update_listener_rule_request.go | 165 - .../model_update_listener_rule_response.go | 111 - .../model_update_load_balancer_request.go | 268 - .../model_update_load_balancer_response.go | 111 - .../model_update_net_access_point_request.go | 165 - .../model_update_net_access_point_response.go | 111 - .../osc-sdk-go/model_update_net_request.go | 112 - .../osc-sdk-go/model_update_net_response.go | 111 - .../osc-sdk-go/model_update_nic_request.go | 199 - .../osc-sdk-go/model_update_nic_response.go | 111 - .../model_update_route_propagation_request.go | 129 - ...model_update_route_propagation_response.go | 111 - .../osc-sdk-go/model_update_route_request.go | 287 - .../osc-sdk-go/model_update_route_response.go | 111 - ...model_update_server_certificate_request.go | 183 - ...odel_update_server_certificate_response.go | 111 - .../model_update_snapshot_request.go | 111 - .../model_update_snapshot_response.go | 111 - .../osc-sdk-go/model_update_subnet_request.go | 112 - .../model_update_subnet_response.go | 111 - .../osc-sdk-go/model_update_vm_request.go | 445 - .../osc-sdk-go/model_update_vm_response.go | 111 - .../osc-sdk-go/model_virtual_gateway.go | 218 - .../marinsalinas/osc-sdk-go/model_vm.go | 1162 -- .../marinsalinas/osc-sdk-go/model_vm_state.go | 148 - .../osc-sdk-go/model_vm_states.go | 183 - .../marinsalinas/osc-sdk-go/model_vm_type.go | 288 - .../marinsalinas/osc-sdk-go/model_volume.go | 358 - .../osc-sdk-go/model_vpn_connection.go | 358 - .../marinsalinas/osc-sdk-go/model_with.go | 603 - .../marinsalinas/osc-sdk-go/outscale.yaml | 12339 ---------------- .../marinsalinas/osc-sdk-go/response.go | 47 - .../marinsalinas/osc-sdk-go/transport.go | 57 - .../marinsalinas/osc-sdk-go/utils.go | 244 - vendor/modules.txt | 4 - 529 files changed, 1 insertion(+), 105870 deletions(-) delete mode 100644 vendor/github.com/antihax/optional/LICENSE delete mode 100644 vendor/github.com/antihax/optional/bool.go delete mode 100644 vendor/github.com/antihax/optional/byte.go delete mode 100644 vendor/github.com/antihax/optional/complex128.go delete mode 100644 vendor/github.com/antihax/optional/complex64.go delete mode 100644 vendor/github.com/antihax/optional/float32.go delete mode 100644 vendor/github.com/antihax/optional/float64.go delete mode 100644 vendor/github.com/antihax/optional/go.mod delete mode 100644 vendor/github.com/antihax/optional/int.go delete mode 100644 vendor/github.com/antihax/optional/int16.go delete mode 100644 vendor/github.com/antihax/optional/int32.go delete mode 100644 vendor/github.com/antihax/optional/int64.go delete mode 100644 vendor/github.com/antihax/optional/int8.go delete mode 100644 vendor/github.com/antihax/optional/interface.go delete mode 100644 vendor/github.com/antihax/optional/rune.go delete mode 100644 vendor/github.com/antihax/optional/string.go delete mode 100644 vendor/github.com/antihax/optional/time.go delete mode 100644 vendor/github.com/antihax/optional/uint.go delete mode 100644 vendor/github.com/antihax/optional/uint16.go delete mode 100644 vendor/github.com/antihax/optional/uint32.go delete mode 100644 vendor/github.com/antihax/optional/uint64.go delete mode 100644 vendor/github.com/antihax/optional/uint8.go delete mode 100644 vendor/github.com/antihax/optional/uintptr.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/.gitignore delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/.openapi-generator-ignore delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/.travis.yml delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/README.md delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_access_key.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_account.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_api_log.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_client_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_default.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_dhcp_option.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link_interface.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_flexible_gpu.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_image.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_internet_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_keypair.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_listener.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer_policy.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_location.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_nat_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_net.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_net_access_point.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_net_peering.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_nic.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_product_type.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_public_ip.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_quota.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_region.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_route.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_route_table.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_security_group.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_security_group_rule.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_server_certificate.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_snapshot.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_subnet.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_subregion.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_task.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_virtual_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_volume.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/api_vpn_connection.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/client.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/configuration.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/gen-config.json delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/git_push.sh delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/go.mod delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/go.sum delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_accepter_net.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_access_key.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_access_key_secret_key.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_access_log.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_account.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_application_sticky_cookie_policy.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_backend_vm_health.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_created.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_image.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_creation.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_update.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_created.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_create.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_update_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_client_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_consumption_entry.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_access_key_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_dhcp_options_set.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interface.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interfaces.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_error_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_errors.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_access_keys.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_api_log.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_client_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_dhcp_options.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link_interface.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_export_task.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_flexible_gpu.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_image.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_internet_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_keypair.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_listener_rule.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_load_balancer.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nat_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_access_point.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_peering.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nic.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_product_type.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_public_ip.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_quota.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_route_table.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_security_group.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_server_certificate.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_snapshot.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subnet.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subregion.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_virtual_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm_type.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vms_state.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_volume.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vpn_connection.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu_catalog.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_health_check.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_image.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_image_export_task.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_internet_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_keypair.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_keypair_created.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_to_update.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_light_for_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_linked_volume.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_listener.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_listener_for_creation.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule_for_creation.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_sticky_cookie_policy.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_location.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_log.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_maintenance_event.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_nat_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_net.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_net_access_point.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering_state.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_net_to_virtual_gateway_link.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_nic.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_nic_for_vm_creation.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_nic_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_osu_api_key.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_osu_export.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource_creation.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_placement.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light_for_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_product_type.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_quota.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_quota_types.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_region.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_resource_load_balancer_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_resource_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_response_context.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_route.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_route_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_route_propagating_virtual_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_route_table.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_security_group.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_light.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_rule.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_security_groups_member.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_server_certificate.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_service.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot_export_task.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_source_net.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_source_security_group.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_state_comment.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_subnet.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_subregion.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_tag.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_request.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_virtual_gateway.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_vm.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_vm_state.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_vm_states.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_vm_type.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_volume.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_vpn_connection.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/model_with.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/outscale.yaml delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/response.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/transport.go delete mode 100644 vendor/github.com/marinsalinas/osc-sdk-go/utils.go diff --git a/go.mod b/go.mod index a4fdf47d8..c9af480a7 100644 --- a/go.mod +++ b/go.mod @@ -3,14 +3,13 @@ module github.com/terraform-providers/terraform-provider-outscale go 1.12 require ( - github.com/antihax/optional v1.0.0 + github.com/antihax/optional v1.0.0 // indirect github.com/aws/aws-sdk-go v1.34.14 github.com/davecgh/go-spew v1.1.1 github.com/go-test/deep v1.0.6 github.com/hashicorp/errwrap v1.0.0 github.com/hashicorp/terraform v0.12.26 github.com/hashicorp/terraform-plugin-sdk v1.13.1 - github.com/marinsalinas/osc-sdk-go v0.0.0-20200616160510-b775d5bdde1a github.com/openlyinc/pointy v1.1.2 github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c github.com/spf13/cast v1.3.1 diff --git a/go.sum b/go.sum index f485a8b0f..33c749623 100644 --- a/go.sum +++ b/go.sum @@ -246,10 +246,6 @@ github.com/likexian/simplejson-go v0.0.0-20190409170913-40473a74d76d/go.mod h1:T github.com/likexian/simplejson-go v0.0.0-20190419151922-c1f9f0b4f084/go.mod h1:U4O1vIJvIKwbMZKUJ62lppfdvkCdVd2nfMimHK81eec= github.com/likexian/simplejson-go v0.0.0-20190502021454-d8787b4bfa0b/go.mod h1:3BWwtmKP9cXWwYCr5bkoVDEfLywacOv0s06OBEDpyt8= github.com/lusis/go-artifactory v0.0.0-20160115162124-7e4ce345df82/go.mod h1:y54tfGmO3NKssKveTEFFzH8C/akrSOy/iW9qEAUDV84= -github.com/marinsalinas/osc-sdk-go v0.0.0-20200604013811-2a0709d28c42 h1:W0ARpVKKMd62mwJN4zgTIJvPbAZqmEpgMDE69mwH9Qw= -github.com/marinsalinas/osc-sdk-go v0.0.0-20200604013811-2a0709d28c42/go.mod h1:sAOwtwOnen34VH6PiCGG+QnzH0a2bqEga1Y9DEjqGVM= -github.com/marinsalinas/osc-sdk-go v0.0.0-20200616160510-b775d5bdde1a h1:PaiGgG1EeFIYPlymtzPZMltH5uNGY6EZJouudO218Gk= -github.com/marinsalinas/osc-sdk-go v0.0.0-20200616160510-b775d5bdde1a/go.mod h1:sAOwtwOnen34VH6PiCGG+QnzH0a2bqEga1Y9DEjqGVM= github.com/masterzen/simplexml v0.0.0-20160608183007-4572e39b1ab9/go.mod h1:kCEbxUJlNDEBNbdQMkPSp6yaKcRXVI6f4ddk8Riv4bc= github.com/masterzen/winrm v0.0.0-20190223112901-5e5c9a7fe54b/go.mod h1:wr1VqkwW0AB5JS0QLy5GpVMS9E3VtRoSYXUYyVk46KY= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= diff --git a/vendor/github.com/antihax/optional/LICENSE b/vendor/github.com/antihax/optional/LICENSE deleted file mode 100644 index 19587fe47..000000000 --- a/vendor/github.com/antihax/optional/LICENSE +++ /dev/null @@ -1,8 +0,0 @@ -The MIT License (MIT) -Copyright (c) 2016 Adam Hintz - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/vendor/github.com/antihax/optional/bool.go b/vendor/github.com/antihax/optional/bool.go deleted file mode 100644 index 4f35ff561..000000000 --- a/vendor/github.com/antihax/optional/bool.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Bool struct { - isSet bool - value bool -} - -func NewBool(value bool) Bool { - return Bool{ - true, - value, - } -} - -// EmptyBool returns a new Bool that does not have a value set. -func EmptyBool() Bool { - return Bool{ - false, - false, - } -} - -func (b Bool) IsSet() bool { - return b.isSet -} - -func (b Bool) Value() bool { - return b.value -} - -func (b Bool) Default(defaultValue bool) bool { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/byte.go b/vendor/github.com/antihax/optional/byte.go deleted file mode 100644 index d22bbe8ff..000000000 --- a/vendor/github.com/antihax/optional/byte.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Byte struct { - isSet bool - value byte -} - -func NewByte(value byte) Byte { - return Byte{ - true, - value, - } -} - -// EmptyByte returns a new Byte that does not have a value set. -func EmptyByte() Byte { - return Byte{ - false, - 0, - } -} - -func (b Byte) IsSet() bool { - return b.isSet -} - -func (b Byte) Value() byte { - return b.value -} - -func (b Byte) Default(defaultValue byte) byte { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/complex128.go b/vendor/github.com/antihax/optional/complex128.go deleted file mode 100644 index 290b3f37b..000000000 --- a/vendor/github.com/antihax/optional/complex128.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Complex128 struct { - isSet bool - value complex128 -} - -func NewComplex128(value complex128) Complex128 { - return Complex128{ - true, - value, - } -} - -// EmptyComplex128 returns a new Complex128 that does not have a value set. -func EmptyComplex128() Complex128 { - return Complex128{ - false, - 0, - } -} - -func (i Complex128) IsSet() bool { - return i.isSet -} - -func (i Complex128) Value() complex128 { - return i.value -} - -func (i Complex128) Default(defaultValue complex128) complex128 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/complex64.go b/vendor/github.com/antihax/optional/complex64.go deleted file mode 100644 index 7d372d8c1..000000000 --- a/vendor/github.com/antihax/optional/complex64.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Complex64 struct { - isSet bool - value complex64 -} - -func NewComplex64(value complex64) Complex64 { - return Complex64{ - true, - value, - } -} - -// EmptyComplex64 returns a new Complex64 that does not have a value set. -func EmptyComplex64() Complex64 { - return Complex64{ - false, - 0, - } -} - -func (i Complex64) IsSet() bool { - return i.isSet -} - -func (i Complex64) Value() complex64 { - return i.value -} - -func (i Complex64) Default(defaultValue complex64) complex64 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/float32.go b/vendor/github.com/antihax/optional/float32.go deleted file mode 100644 index 519cc5d69..000000000 --- a/vendor/github.com/antihax/optional/float32.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Float32 struct { - isSet bool - value float32 -} - -func NewFloat32(value float32) Float32 { - return Float32{ - true, - value, - } -} - -// EmptyFloat32 returns a new Float32 that does not have a value set. -func EmptyFloat32() Float32 { - return Float32{ - false, - 0, - } -} - -func (i Float32) IsSet() bool { - return i.isSet -} - -func (i Float32) Value() float32 { - return i.value -} - -func (i Float32) Default(defaultValue float32) float32 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/float64.go b/vendor/github.com/antihax/optional/float64.go deleted file mode 100644 index 835f7058e..000000000 --- a/vendor/github.com/antihax/optional/float64.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Float64 struct { - isSet bool - value float64 -} - -func NewFloat64(value float64) Float64 { - return Float64{ - true, - value, - } -} - -// EmptyFloat64 returns a new Float64 that does not have a value set. -func EmptyFloat64() Float64 { - return Float64{ - false, - 0, - } -} - -func (i Float64) IsSet() bool { - return i.isSet -} - -func (i Float64) Value() float64 { - return i.value -} - -func (i Float64) Default(defaultValue float64) float64 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/go.mod b/vendor/github.com/antihax/optional/go.mod deleted file mode 100644 index 27b7e9021..000000000 --- a/vendor/github.com/antihax/optional/go.mod +++ /dev/null @@ -1,3 +0,0 @@ -module github.com/antihax/optional - -go 1.13 diff --git a/vendor/github.com/antihax/optional/int.go b/vendor/github.com/antihax/optional/int.go deleted file mode 100644 index 6c3e65b92..000000000 --- a/vendor/github.com/antihax/optional/int.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Int struct { - isSet bool - value int -} - -func NewInt(value int) Int { - return Int{ - true, - value, - } -} - -// EmptyInt returns a new Int that does not have a value set. -func EmptyInt() Int { - return Int{ - false, - 0, - } -} - -func (i Int) IsSet() bool { - return i.isSet -} - -func (i Int) Value() int { - return i.value -} - -func (i Int) Default(defaultValue int) int { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/int16.go b/vendor/github.com/antihax/optional/int16.go deleted file mode 100644 index 49465b8c7..000000000 --- a/vendor/github.com/antihax/optional/int16.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Int16 struct { - isSet bool - value int16 -} - -func NewInt16(value int16) Int16 { - return Int16{ - true, - value, - } -} - -// EmptyInt16 returns a new Int16 that does not have a value set. -func EmptyInt16() Int16 { - return Int16{ - false, - 0, - } -} - -func (i Int16) IsSet() bool { - return i.isSet -} - -func (i Int16) Value() int16 { - return i.value -} - -func (i Int16) Default(defaultValue int16) int16 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/int32.go b/vendor/github.com/antihax/optional/int32.go deleted file mode 100644 index f3a33c78d..000000000 --- a/vendor/github.com/antihax/optional/int32.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Int32 struct { - isSet bool - value int32 -} - -func NewInt32(value int32) Int32 { - return Int32{ - true, - value, - } -} - -// EmptyInt32 returns a new Int32 that does not have a value set. -func EmptyInt32() Int32 { - return Int32{ - false, - 0, - } -} - -func (i Int32) IsSet() bool { - return i.isSet -} - -func (i Int32) Value() int32 { - return i.value -} - -func (i Int32) Default(defaultValue int32) int32 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/int64.go b/vendor/github.com/antihax/optional/int64.go deleted file mode 100644 index d047470b7..000000000 --- a/vendor/github.com/antihax/optional/int64.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Int64 struct { - isSet bool - value int64 -} - -func NewInt64(value int64) Int64 { - return Int64{ - true, - value, - } -} - -// EmptyInt64 returns a new Int64 that does not have a value set. -func EmptyInt64() Int64 { - return Int64{ - false, - 0, - } -} - -func (i Int64) IsSet() bool { - return i.isSet -} - -func (i Int64) Value() int64 { - return i.value -} - -func (i Int64) Default(defaultValue int64) int64 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/int8.go b/vendor/github.com/antihax/optional/int8.go deleted file mode 100644 index 2bd11bda7..000000000 --- a/vendor/github.com/antihax/optional/int8.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Int8 struct { - isSet bool - value int8 -} - -func NewInt8(value int8) Int8 { - return Int8{ - true, - value, - } -} - -// EmptyInt8 returns a new Int8 that does not have a value set. -func EmptyInt8() Int8 { - return Int8{ - false, - 0, - } -} - -func (i Int8) IsSet() bool { - return i.isSet -} - -func (i Int8) Value() int8 { - return i.value -} - -func (i Int8) Default(defaultValue int8) int8 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/interface.go b/vendor/github.com/antihax/optional/interface.go deleted file mode 100644 index a6f2416dd..000000000 --- a/vendor/github.com/antihax/optional/interface.go +++ /dev/null @@ -1,37 +0,0 @@ -package optional - -// Optional represents a generic optional type, stored as an interface{}. -type Interface struct { - isSet bool - value interface{} -} - -func NewInterface(value interface{}) Interface { - return Interface{ - true, - value, - } -} - -// EmptyInterface returns a new Interface that does not have a value set. -func EmptyInterface() Interface { - return Interface{ - false, - nil, - } -} - -func (b Interface) IsSet() bool { - return b.isSet -} - -func (b Interface) Value() interface{} { - return b.value -} - -func (b Interface) Default(defaultValue interface{}) interface{} { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/rune.go b/vendor/github.com/antihax/optional/rune.go deleted file mode 100644 index cbac81929..000000000 --- a/vendor/github.com/antihax/optional/rune.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Rune struct { - isSet bool - value rune -} - -func NewRune(value rune) Rune { - return Rune{ - true, - value, - } -} - -// EmptyRune returns a new Rune that does not have a value set. -func EmptyRune() Rune { - return Rune{ - false, - 0, - } -} - -func (b Rune) IsSet() bool { - return b.isSet -} - -func (b Rune) Value() rune { - return b.value -} - -func (b Rune) Default(defaultValue rune) rune { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/string.go b/vendor/github.com/antihax/optional/string.go deleted file mode 100644 index a2e5a2b44..000000000 --- a/vendor/github.com/antihax/optional/string.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type String struct { - isSet bool - value string -} - -func NewString(value string) String { - return String{ - true, - value, - } -} - -// EmptyString returns a new String that does not have a value set. -func EmptyString() String { - return String{ - false, - "", - } -} - -func (b String) IsSet() bool { - return b.isSet -} - -func (b String) Value() string { - return b.value -} - -func (b String) Default(defaultValue string) string { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/time.go b/vendor/github.com/antihax/optional/time.go deleted file mode 100644 index a92a55aa4..000000000 --- a/vendor/github.com/antihax/optional/time.go +++ /dev/null @@ -1,38 +0,0 @@ -package optional - -import "time" - -type Time struct { - isSet bool - value time.Time -} - -func NewTime(value time.Time) Time { - return Time{ - true, - value, - } -} - -// EmptyTime returns a new Time that does not have a value set. -func EmptyTime() Time { - return Time{ - false, - time.Time{}, - } -} - -func (b Time) IsSet() bool { - return b.isSet -} - -func (b Time) Value() time.Time { - return b.value -} - -func (b Time) Default(defaultValue time.Time) time.Time { - if b.isSet { - return b.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uint.go b/vendor/github.com/antihax/optional/uint.go deleted file mode 100644 index f9e53a41b..000000000 --- a/vendor/github.com/antihax/optional/uint.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uint struct { - isSet bool - value uint -} - -func NewUint(value uint) Uint { - return Uint{ - true, - value, - } -} - -// EmptyUint returns a new Uint that does not have a value set. -func EmptyUint() Uint { - return Uint{ - false, - 0, - } -} - -func (i Uint) IsSet() bool { - return i.isSet -} - -func (i Uint) Value() uint { - return i.value -} - -func (i Uint) Default(defaultValue uint) uint { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uint16.go b/vendor/github.com/antihax/optional/uint16.go deleted file mode 100644 index 487eb673b..000000000 --- a/vendor/github.com/antihax/optional/uint16.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uint16 struct { - isSet bool - value uint16 -} - -func NewUint16(value uint16) Uint16 { - return Uint16{ - true, - value, - } -} - -// EmptyUint16 returns a new Uint16 that does not have a value set. -func EmptyUint16() Uint16 { - return Uint16{ - false, - 0, - } -} - -func (i Uint16) IsSet() bool { - return i.isSet -} - -func (i Uint16) Value() uint16 { - return i.value -} - -func (i Uint16) Default(defaultValue uint16) uint16 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uint32.go b/vendor/github.com/antihax/optional/uint32.go deleted file mode 100644 index 0e46c8378..000000000 --- a/vendor/github.com/antihax/optional/uint32.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uint32 struct { - isSet bool - value uint32 -} - -func NewUint32(value uint32) Uint32 { - return Uint32{ - true, - value, - } -} - -// EmptyUint32 returns a new Uint32 that does not have a value set. -func EmptyUint32() Uint32 { - return Uint32{ - false, - 0, - } -} - -func (i Uint32) IsSet() bool { - return i.isSet -} - -func (i Uint32) Value() uint32 { - return i.value -} - -func (i Uint32) Default(defaultValue uint32) uint32 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uint64.go b/vendor/github.com/antihax/optional/uint64.go deleted file mode 100644 index 16004df34..000000000 --- a/vendor/github.com/antihax/optional/uint64.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uint64 struct { - isSet bool - value uint64 -} - -func NewUint64(value uint64) Uint64 { - return Uint64{ - true, - value, - } -} - -// EmptyUint64 returns a new Uint64 that does not have a value set. -func EmptyUint64() Uint64 { - return Uint64{ - false, - 0, - } -} - -func (i Uint64) IsSet() bool { - return i.isSet -} - -func (i Uint64) Value() uint64 { - return i.value -} - -func (i Uint64) Default(defaultValue uint64) uint64 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uint8.go b/vendor/github.com/antihax/optional/uint8.go deleted file mode 100644 index 469ceb53a..000000000 --- a/vendor/github.com/antihax/optional/uint8.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uint8 struct { - isSet bool - value uint8 -} - -func NewUint8(value uint8) Uint8 { - return Uint8{ - true, - value, - } -} - -// EmptyUint8 returns a new Uint8 that does not have a value set. -func EmptyUint8() Uint8 { - return Uint8{ - false, - 0, - } -} - -func (i Uint8) IsSet() bool { - return i.isSet -} - -func (i Uint8) Value() uint8 { - return i.value -} - -func (i Uint8) Default(defaultValue uint8) uint8 { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/antihax/optional/uintptr.go b/vendor/github.com/antihax/optional/uintptr.go deleted file mode 100644 index e7e2cabe0..000000000 --- a/vendor/github.com/antihax/optional/uintptr.go +++ /dev/null @@ -1,36 +0,0 @@ -package optional - -type Uintptr struct { - isSet bool - value uintptr -} - -func NewUintptr(value uintptr) Uintptr { - return Uintptr{ - true, - value, - } -} - -// EmptyUintptr returns a new Uintptr that does not have a value set. -func EmptyUintptr() Uintptr { - return Uintptr{ - false, - 0, - } -} - -func (i Uintptr) IsSet() bool { - return i.isSet -} - -func (i Uintptr) Value() uintptr { - return i.value -} - -func (i Uintptr) Default(defaultValue uintptr) uintptr { - if i.isSet { - return i.value - } - return defaultValue -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/.gitignore b/vendor/github.com/marinsalinas/osc-sdk-go/.gitignore deleted file mode 100644 index daf913b1b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/.gitignore +++ /dev/null @@ -1,24 +0,0 @@ -# Compiled Object files, Static and Dynamic libs (Shared Objects) -*.o -*.a -*.so - -# Folders -_obj -_test - -# Architecture specific extensions/prefixes -*.[568vq] -[568vq].out - -*.cgo1.go -*.cgo2.c -_cgo_defun.c -_cgo_gotypes.go -_cgo_export.* - -_testmain.go - -*.exe -*.test -*.prof diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/.openapi-generator-ignore b/vendor/github.com/marinsalinas/osc-sdk-go/.openapi-generator-ignore deleted file mode 100644 index 7484ee590..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/.openapi-generator-ignore +++ /dev/null @@ -1,23 +0,0 @@ -# OpenAPI Generator Ignore -# Generated by openapi-generator https://github.com/openapitools/openapi-generator - -# Use this file to prevent files from being overwritten by the generator. -# The patterns follow closely to .gitignore or .dockerignore. - -# As an example, the C# client generator defines ApiClient.cs. -# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: -#ApiClient.cs - -# You can match any string of characters against a directory, file or extension with a single asterisk (*): -#foo/*/qux -# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux - -# You can recursively match patterns against a directory, file or extension with a double asterisk (**): -#foo/**/qux -# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux - -# You can also negate patterns with an exclamation (!). -# For example, you can ignore all files in a docs folder with the file extension .md: -#docs/*.md -# Then explicitly reverse the ignore rule for a single file: -#!docs/README.md diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/.travis.yml b/vendor/github.com/marinsalinas/osc-sdk-go/.travis.yml deleted file mode 100644 index f5cb2ce9a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/.travis.yml +++ /dev/null @@ -1,8 +0,0 @@ -language: go - -install: - - go get -d -v . - -script: - - go build -v ./ - diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/README.md b/vendor/github.com/marinsalinas/osc-sdk-go/README.md deleted file mode 100644 index 5e32e49d3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/README.md +++ /dev/null @@ -1,681 +0,0 @@ -# Go API client for oscgo - -Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - -## Overview -This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. - -- API version: 1.1 -- Package version: 0.1.1 -- Build package: org.openapitools.codegen.languages.GoClientExperimentalCodegen - -## Installation - -Install the following dependencies: - -```shell -go get github.com/stretchr/testify/assert -go get golang.org/x/oauth2 -go get golang.org/x/net/context -go get github.com/antihax/optional -``` - -Put the package under your project folder and add the following in import: - -```golang -import sw "./oscgo" -``` - -## Documentation for API Endpoints - -All URIs are relative to *https://api.eu-west-2.outscale.com/api/v1* - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -*AccessKeyApi* | [**CreateAccessKey**](docs/AccessKeyApi.md#createaccesskey) | **Post** /CreateAccessKey | -*AccessKeyApi* | [**DeleteAccessKey**](docs/AccessKeyApi.md#deleteaccesskey) | **Post** /DeleteAccessKey | -*AccessKeyApi* | [**ReadAccessKeys**](docs/AccessKeyApi.md#readaccesskeys) | **Post** /ReadAccessKeys | -*AccessKeyApi* | [**ReadSecretAccessKey**](docs/AccessKeyApi.md#readsecretaccesskey) | **Post** /ReadSecretAccessKey | -*AccessKeyApi* | [**UpdateAccessKey**](docs/AccessKeyApi.md#updateaccesskey) | **Post** /UpdateAccessKey | -*AccountApi* | [**CheckAuthentication**](docs/AccountApi.md#checkauthentication) | **Post** /CheckAuthentication | -*AccountApi* | [**CreateAccount**](docs/AccountApi.md#createaccount) | **Post** /CreateAccount | -*AccountApi* | [**ReadAccounts**](docs/AccountApi.md#readaccounts) | **Post** /ReadAccounts | -*AccountApi* | [**ResetAccountPassword**](docs/AccountApi.md#resetaccountpassword) | **Post** /ResetAccountPassword | -*AccountApi* | [**SendResetPasswordEmail**](docs/AccountApi.md#sendresetpasswordemail) | **Post** /SendResetPasswordEmail | -*AccountApi* | [**UpdateAccount**](docs/AccountApi.md#updateaccount) | **Post** /UpdateAccount | -*ApiLogApi* | [**ReadApiLogs**](docs/ApiLogApi.md#readapilogs) | **Post** /ReadApiLogs | -*ClientGatewayApi* | [**CreateClientGateway**](docs/ClientGatewayApi.md#createclientgateway) | **Post** /CreateClientGateway | -*ClientGatewayApi* | [**DeleteClientGateway**](docs/ClientGatewayApi.md#deleteclientgateway) | **Post** /DeleteClientGateway | -*ClientGatewayApi* | [**ReadClientGateways**](docs/ClientGatewayApi.md#readclientgateways) | **Post** /ReadClientGateways | -*DefaultApi* | [**ReadConsumptionAccount**](docs/DefaultApi.md#readconsumptionaccount) | **Post** /ReadConsumptionAccount | -*DhcpOptionApi* | [**CreateDhcpOptions**](docs/DhcpOptionApi.md#createdhcpoptions) | **Post** /CreateDhcpOptions | -*DhcpOptionApi* | [**DeleteDhcpOptions**](docs/DhcpOptionApi.md#deletedhcpoptions) | **Post** /DeleteDhcpOptions | -*DhcpOptionApi* | [**ReadDhcpOptions**](docs/DhcpOptionApi.md#readdhcpoptions) | **Post** /ReadDhcpOptions | -*DirectLinkApi* | [**CreateDirectLink**](docs/DirectLinkApi.md#createdirectlink) | **Post** /CreateDirectLink | -*DirectLinkApi* | [**DeleteDirectLink**](docs/DirectLinkApi.md#deletedirectlink) | **Post** /DeleteDirectLink | -*DirectLinkApi* | [**ReadDirectLinks**](docs/DirectLinkApi.md#readdirectlinks) | **Post** /ReadDirectLinks | -*DirectLinkInterfaceApi* | [**CreateDirectLinkInterface**](docs/DirectLinkInterfaceApi.md#createdirectlinkinterface) | **Post** /CreateDirectLinkInterface | -*DirectLinkInterfaceApi* | [**DeleteDirectLinkInterface**](docs/DirectLinkInterfaceApi.md#deletedirectlinkinterface) | **Post** /DeleteDirectLinkInterface | -*DirectLinkInterfaceApi* | [**ReadDirectLinkInterfaces**](docs/DirectLinkInterfaceApi.md#readdirectlinkinterfaces) | **Post** /ReadDirectLinkInterfaces | -*FlexibleGpuApi* | [**CreateFlexibleGpu**](docs/FlexibleGpuApi.md#createflexiblegpu) | **Post** /CreateFlexibleGpu | -*FlexibleGpuApi* | [**DeleteFlexibleGpu**](docs/FlexibleGpuApi.md#deleteflexiblegpu) | **Post** /DeleteFlexibleGpu | -*FlexibleGpuApi* | [**LinkFlexibleGpu**](docs/FlexibleGpuApi.md#linkflexiblegpu) | **Post** /LinkFlexibleGpu | -*FlexibleGpuApi* | [**ReadFlexibleGpuCatalog**](docs/FlexibleGpuApi.md#readflexiblegpucatalog) | **Post** /ReadFlexibleGpuCatalog | -*FlexibleGpuApi* | [**ReadFlexibleGpus**](docs/FlexibleGpuApi.md#readflexiblegpus) | **Post** /ReadFlexibleGpus | -*FlexibleGpuApi* | [**UnlinkFlexibleGpu**](docs/FlexibleGpuApi.md#unlinkflexiblegpu) | **Post** /UnlinkFlexibleGpu | -*FlexibleGpuApi* | [**UpdateFlexibleGpu**](docs/FlexibleGpuApi.md#updateflexiblegpu) | **Post** /UpdateFlexibleGpu | -*ImageApi* | [**CreateImage**](docs/ImageApi.md#createimage) | **Post** /CreateImage | -*ImageApi* | [**CreateImageExportTask**](docs/ImageApi.md#createimageexporttask) | **Post** /CreateImageExportTask | -*ImageApi* | [**DeleteImage**](docs/ImageApi.md#deleteimage) | **Post** /DeleteImage | -*ImageApi* | [**ReadImageExportTasks**](docs/ImageApi.md#readimageexporttasks) | **Post** /ReadImageExportTasks | -*ImageApi* | [**ReadImages**](docs/ImageApi.md#readimages) | **Post** /ReadImages | -*ImageApi* | [**UpdateImage**](docs/ImageApi.md#updateimage) | **Post** /UpdateImage | -*InternetServiceApi* | [**CreateInternetService**](docs/InternetServiceApi.md#createinternetservice) | **Post** /CreateInternetService | -*InternetServiceApi* | [**DeleteInternetService**](docs/InternetServiceApi.md#deleteinternetservice) | **Post** /DeleteInternetService | -*InternetServiceApi* | [**LinkInternetService**](docs/InternetServiceApi.md#linkinternetservice) | **Post** /LinkInternetService | -*InternetServiceApi* | [**ReadInternetServices**](docs/InternetServiceApi.md#readinternetservices) | **Post** /ReadInternetServices | -*InternetServiceApi* | [**UnlinkInternetService**](docs/InternetServiceApi.md#unlinkinternetservice) | **Post** /UnlinkInternetService | -*KeypairApi* | [**CreateKeypair**](docs/KeypairApi.md#createkeypair) | **Post** /CreateKeypair | -*KeypairApi* | [**DeleteKeypair**](docs/KeypairApi.md#deletekeypair) | **Post** /DeleteKeypair | -*KeypairApi* | [**ReadKeypairs**](docs/KeypairApi.md#readkeypairs) | **Post** /ReadKeypairs | -*ListenerApi* | [**CreateListenerRule**](docs/ListenerApi.md#createlistenerrule) | **Post** /CreateListenerRule | -*ListenerApi* | [**CreateLoadBalancerListeners**](docs/ListenerApi.md#createloadbalancerlisteners) | **Post** /CreateLoadBalancerListeners | -*ListenerApi* | [**DeleteListenerRule**](docs/ListenerApi.md#deletelistenerrule) | **Post** /DeleteListenerRule | -*ListenerApi* | [**DeleteLoadBalancerListeners**](docs/ListenerApi.md#deleteloadbalancerlisteners) | **Post** /DeleteLoadBalancerListeners | -*ListenerApi* | [**ReadListenerRules**](docs/ListenerApi.md#readlistenerrules) | **Post** /ReadListenerRules | -*ListenerApi* | [**UpdateListenerRule**](docs/ListenerApi.md#updatelistenerrule) | **Post** /UpdateListenerRule | -*LoadBalancerApi* | [**CreateLoadBalancer**](docs/LoadBalancerApi.md#createloadbalancer) | **Post** /CreateLoadBalancer | -*LoadBalancerApi* | [**CreateLoadBalancerTags**](docs/LoadBalancerApi.md#createloadbalancertags) | **Post** /CreateLoadBalancerTags | -*LoadBalancerApi* | [**DeleteLoadBalancer**](docs/LoadBalancerApi.md#deleteloadbalancer) | **Post** /DeleteLoadBalancer | -*LoadBalancerApi* | [**DeleteLoadBalancerTags**](docs/LoadBalancerApi.md#deleteloadbalancertags) | **Post** /DeleteLoadBalancerTags | -*LoadBalancerApi* | [**DeregisterVmsInLoadBalancer**](docs/LoadBalancerApi.md#deregistervmsinloadbalancer) | **Post** /DeregisterVmsInLoadBalancer | -*LoadBalancerApi* | [**ReadLoadBalancerTags**](docs/LoadBalancerApi.md#readloadbalancertags) | **Post** /ReadLoadBalancerTags | -*LoadBalancerApi* | [**ReadLoadBalancers**](docs/LoadBalancerApi.md#readloadbalancers) | **Post** /ReadLoadBalancers | -*LoadBalancerApi* | [**ReadVmsHealth**](docs/LoadBalancerApi.md#readvmshealth) | **Post** /ReadVmsHealth | -*LoadBalancerApi* | [**RegisterVmsInLoadBalancer**](docs/LoadBalancerApi.md#registervmsinloadbalancer) | **Post** /RegisterVmsInLoadBalancer | -*LoadBalancerApi* | [**UpdateLoadBalancer**](docs/LoadBalancerApi.md#updateloadbalancer) | **Post** /UpdateLoadBalancer | -*LoadBalancerPolicyApi* | [**CreateLoadBalancerPolicy**](docs/LoadBalancerPolicyApi.md#createloadbalancerpolicy) | **Post** /CreateLoadBalancerPolicy | -*LoadBalancerPolicyApi* | [**DeleteLoadBalancerPolicy**](docs/LoadBalancerPolicyApi.md#deleteloadbalancerpolicy) | **Post** /DeleteLoadBalancerPolicy | -*LocationApi* | [**ReadLocations**](docs/LocationApi.md#readlocations) | **Post** /ReadLocations | -*NatServiceApi* | [**CreateNatService**](docs/NatServiceApi.md#createnatservice) | **Post** /CreateNatService | -*NatServiceApi* | [**DeleteNatService**](docs/NatServiceApi.md#deletenatservice) | **Post** /DeleteNatService | -*NatServiceApi* | [**ReadNatServices**](docs/NatServiceApi.md#readnatservices) | **Post** /ReadNatServices | -*NetApi* | [**CreateNet**](docs/NetApi.md#createnet) | **Post** /CreateNet | -*NetApi* | [**DeleteNet**](docs/NetApi.md#deletenet) | **Post** /DeleteNet | -*NetApi* | [**ReadNets**](docs/NetApi.md#readnets) | **Post** /ReadNets | -*NetApi* | [**UpdateNet**](docs/NetApi.md#updatenet) | **Post** /UpdateNet | -*NetAccessPointApi* | [**CreateNetAccessPoint**](docs/NetAccessPointApi.md#createnetaccesspoint) | **Post** /CreateNetAccessPoint | -*NetAccessPointApi* | [**DeleteNetAccessPoint**](docs/NetAccessPointApi.md#deletenetaccesspoint) | **Post** /DeleteNetAccessPoint | -*NetAccessPointApi* | [**ReadNetAccessPointServices**](docs/NetAccessPointApi.md#readnetaccesspointservices) | **Post** /ReadNetAccessPointServices | -*NetAccessPointApi* | [**ReadNetAccessPoints**](docs/NetAccessPointApi.md#readnetaccesspoints) | **Post** /ReadNetAccessPoints | -*NetAccessPointApi* | [**UpdateNetAccessPoint**](docs/NetAccessPointApi.md#updatenetaccesspoint) | **Post** /UpdateNetAccessPoint | -*NetPeeringApi* | [**AcceptNetPeering**](docs/NetPeeringApi.md#acceptnetpeering) | **Post** /AcceptNetPeering | -*NetPeeringApi* | [**CreateNetPeering**](docs/NetPeeringApi.md#createnetpeering) | **Post** /CreateNetPeering | -*NetPeeringApi* | [**DeleteNetPeering**](docs/NetPeeringApi.md#deletenetpeering) | **Post** /DeleteNetPeering | -*NetPeeringApi* | [**ReadNetPeerings**](docs/NetPeeringApi.md#readnetpeerings) | **Post** /ReadNetPeerings | -*NetPeeringApi* | [**RejectNetPeering**](docs/NetPeeringApi.md#rejectnetpeering) | **Post** /RejectNetPeering | -*NicApi* | [**CreateNic**](docs/NicApi.md#createnic) | **Post** /CreateNic | -*NicApi* | [**DeleteNic**](docs/NicApi.md#deletenic) | **Post** /DeleteNic | -*NicApi* | [**LinkNic**](docs/NicApi.md#linknic) | **Post** /LinkNic | -*NicApi* | [**LinkPrivateIps**](docs/NicApi.md#linkprivateips) | **Post** /LinkPrivateIps | -*NicApi* | [**ReadNics**](docs/NicApi.md#readnics) | **Post** /ReadNics | -*NicApi* | [**UnlinkNic**](docs/NicApi.md#unlinknic) | **Post** /UnlinkNic | -*NicApi* | [**UnlinkPrivateIps**](docs/NicApi.md#unlinkprivateips) | **Post** /UnlinkPrivateIps | -*NicApi* | [**UpdateNic**](docs/NicApi.md#updatenic) | **Post** /UpdateNic | -*ProductTypeApi* | [**ReadProductTypes**](docs/ProductTypeApi.md#readproducttypes) | **Post** /ReadProductTypes | -*PublicIpApi* | [**CreatePublicIp**](docs/PublicIpApi.md#createpublicip) | **Post** /CreatePublicIp | -*PublicIpApi* | [**DeletePublicIp**](docs/PublicIpApi.md#deletepublicip) | **Post** /DeletePublicIp | -*PublicIpApi* | [**LinkPublicIp**](docs/PublicIpApi.md#linkpublicip) | **Post** /LinkPublicIp | -*PublicIpApi* | [**ReadPublicIpRanges**](docs/PublicIpApi.md#readpublicipranges) | **Post** /ReadPublicIpRanges | -*PublicIpApi* | [**ReadPublicIps**](docs/PublicIpApi.md#readpublicips) | **Post** /ReadPublicIps | -*PublicIpApi* | [**UnlinkPublicIp**](docs/PublicIpApi.md#unlinkpublicip) | **Post** /UnlinkPublicIp | -*QuotaApi* | [**ReadQuotas**](docs/QuotaApi.md#readquotas) | **Post** /ReadQuotas | -*RegionApi* | [**ReadRegions**](docs/RegionApi.md#readregions) | **Post** /ReadRegions | -*RouteApi* | [**CreateRoute**](docs/RouteApi.md#createroute) | **Post** /CreateRoute | -*RouteApi* | [**DeleteRoute**](docs/RouteApi.md#deleteroute) | **Post** /DeleteRoute | -*RouteApi* | [**UpdateRoute**](docs/RouteApi.md#updateroute) | **Post** /UpdateRoute | -*RouteTableApi* | [**CreateRouteTable**](docs/RouteTableApi.md#createroutetable) | **Post** /CreateRouteTable | -*RouteTableApi* | [**DeleteRouteTable**](docs/RouteTableApi.md#deleteroutetable) | **Post** /DeleteRouteTable | -*RouteTableApi* | [**LinkRouteTable**](docs/RouteTableApi.md#linkroutetable) | **Post** /LinkRouteTable | -*RouteTableApi* | [**ReadRouteTables**](docs/RouteTableApi.md#readroutetables) | **Post** /ReadRouteTables | -*RouteTableApi* | [**UnlinkRouteTable**](docs/RouteTableApi.md#unlinkroutetable) | **Post** /UnlinkRouteTable | -*SecurityGroupApi* | [**CreateSecurityGroup**](docs/SecurityGroupApi.md#createsecuritygroup) | **Post** /CreateSecurityGroup | -*SecurityGroupApi* | [**DeleteSecurityGroup**](docs/SecurityGroupApi.md#deletesecuritygroup) | **Post** /DeleteSecurityGroup | -*SecurityGroupApi* | [**ReadSecurityGroups**](docs/SecurityGroupApi.md#readsecuritygroups) | **Post** /ReadSecurityGroups | -*SecurityGroupRuleApi* | [**CreateSecurityGroupRule**](docs/SecurityGroupRuleApi.md#createsecuritygrouprule) | **Post** /CreateSecurityGroupRule | -*SecurityGroupRuleApi* | [**DeleteSecurityGroupRule**](docs/SecurityGroupRuleApi.md#deletesecuritygrouprule) | **Post** /DeleteSecurityGroupRule | -*ServerCertificateApi* | [**CreateServerCertificate**](docs/ServerCertificateApi.md#createservercertificate) | **Post** /CreateServerCertificate | -*ServerCertificateApi* | [**DeleteServerCertificate**](docs/ServerCertificateApi.md#deleteservercertificate) | **Post** /DeleteServerCertificate | -*ServerCertificateApi* | [**ReadServerCertificates**](docs/ServerCertificateApi.md#readservercertificates) | **Post** /ReadServerCertificates | -*ServerCertificateApi* | [**UpdateServerCertificate**](docs/ServerCertificateApi.md#updateservercertificate) | **Post** /UpdateServerCertificate | -*SnapshotApi* | [**CreateSnapshot**](docs/SnapshotApi.md#createsnapshot) | **Post** /CreateSnapshot | -*SnapshotApi* | [**CreateSnapshotExportTask**](docs/SnapshotApi.md#createsnapshotexporttask) | **Post** /CreateSnapshotExportTask | -*SnapshotApi* | [**DeleteSnapshot**](docs/SnapshotApi.md#deletesnapshot) | **Post** /DeleteSnapshot | -*SnapshotApi* | [**ReadSnapshotExportTasks**](docs/SnapshotApi.md#readsnapshotexporttasks) | **Post** /ReadSnapshotExportTasks | -*SnapshotApi* | [**ReadSnapshots**](docs/SnapshotApi.md#readsnapshots) | **Post** /ReadSnapshots | -*SnapshotApi* | [**UpdateSnapshot**](docs/SnapshotApi.md#updatesnapshot) | **Post** /UpdateSnapshot | -*SubnetApi* | [**CreateSubnet**](docs/SubnetApi.md#createsubnet) | **Post** /CreateSubnet | -*SubnetApi* | [**DeleteSubnet**](docs/SubnetApi.md#deletesubnet) | **Post** /DeleteSubnet | -*SubnetApi* | [**ReadSubnets**](docs/SubnetApi.md#readsubnets) | **Post** /ReadSubnets | -*SubnetApi* | [**UpdateSubnet**](docs/SubnetApi.md#updatesubnet) | **Post** /UpdateSubnet | -*SubregionApi* | [**ReadSubregions**](docs/SubregionApi.md#readsubregions) | **Post** /ReadSubregions | -*TagApi* | [**CreateTags**](docs/TagApi.md#createtags) | **Post** /CreateTags | -*TagApi* | [**DeleteTags**](docs/TagApi.md#deletetags) | **Post** /DeleteTags | -*TagApi* | [**ReadTags**](docs/TagApi.md#readtags) | **Post** /ReadTags | -*TaskApi* | [**DeleteExportTask**](docs/TaskApi.md#deleteexporttask) | **Post** /DeleteExportTask | -*VirtualGatewayApi* | [**CreateVirtualGateway**](docs/VirtualGatewayApi.md#createvirtualgateway) | **Post** /CreateVirtualGateway | -*VirtualGatewayApi* | [**DeleteVirtualGateway**](docs/VirtualGatewayApi.md#deletevirtualgateway) | **Post** /DeleteVirtualGateway | -*VirtualGatewayApi* | [**LinkVirtualGateway**](docs/VirtualGatewayApi.md#linkvirtualgateway) | **Post** /LinkVirtualGateway | -*VirtualGatewayApi* | [**ReadVirtualGateways**](docs/VirtualGatewayApi.md#readvirtualgateways) | **Post** /ReadVirtualGateways | -*VirtualGatewayApi* | [**UnlinkVirtualGateway**](docs/VirtualGatewayApi.md#unlinkvirtualgateway) | **Post** /UnlinkVirtualGateway | -*VirtualGatewayApi* | [**UpdateRoutePropagation**](docs/VirtualGatewayApi.md#updateroutepropagation) | **Post** /UpdateRoutePropagation | -*VmApi* | [**CreateVms**](docs/VmApi.md#createvms) | **Post** /CreateVms | -*VmApi* | [**DeleteVms**](docs/VmApi.md#deletevms) | **Post** /DeleteVms | -*VmApi* | [**ReadAdminPassword**](docs/VmApi.md#readadminpassword) | **Post** /ReadAdminPassword | -*VmApi* | [**ReadConsoleOutput**](docs/VmApi.md#readconsoleoutput) | **Post** /ReadConsoleOutput | -*VmApi* | [**ReadVmTypes**](docs/VmApi.md#readvmtypes) | **Post** /ReadVmTypes | -*VmApi* | [**ReadVms**](docs/VmApi.md#readvms) | **Post** /ReadVms | -*VmApi* | [**ReadVmsState**](docs/VmApi.md#readvmsstate) | **Post** /ReadVmsState | -*VmApi* | [**RebootVms**](docs/VmApi.md#rebootvms) | **Post** /RebootVms | -*VmApi* | [**StartVms**](docs/VmApi.md#startvms) | **Post** /StartVms | -*VmApi* | [**StopVms**](docs/VmApi.md#stopvms) | **Post** /StopVms | -*VmApi* | [**UpdateVm**](docs/VmApi.md#updatevm) | **Post** /UpdateVm | -*VolumeApi* | [**CreateVolume**](docs/VolumeApi.md#createvolume) | **Post** /CreateVolume | -*VolumeApi* | [**DeleteVolume**](docs/VolumeApi.md#deletevolume) | **Post** /DeleteVolume | -*VolumeApi* | [**LinkVolume**](docs/VolumeApi.md#linkvolume) | **Post** /LinkVolume | -*VolumeApi* | [**ReadVolumes**](docs/VolumeApi.md#readvolumes) | **Post** /ReadVolumes | -*VolumeApi* | [**UnlinkVolume**](docs/VolumeApi.md#unlinkvolume) | **Post** /UnlinkVolume | -*VpnConnectionApi* | [**CreateVpnConnection**](docs/VpnConnectionApi.md#createvpnconnection) | **Post** /CreateVpnConnection | -*VpnConnectionApi* | [**CreateVpnConnectionRoute**](docs/VpnConnectionApi.md#createvpnconnectionroute) | **Post** /CreateVpnConnectionRoute | -*VpnConnectionApi* | [**DeleteVpnConnection**](docs/VpnConnectionApi.md#deletevpnconnection) | **Post** /DeleteVpnConnection | -*VpnConnectionApi* | [**DeleteVpnConnectionRoute**](docs/VpnConnectionApi.md#deletevpnconnectionroute) | **Post** /DeleteVpnConnectionRoute | -*VpnConnectionApi* | [**ReadVpnConnections**](docs/VpnConnectionApi.md#readvpnconnections) | **Post** /ReadVpnConnections | - - -## Documentation For Models - - - [AcceptNetPeeringRequest](docs/AcceptNetPeeringRequest.md) - - [AcceptNetPeeringResponse](docs/AcceptNetPeeringResponse.md) - - [AccepterNet](docs/AccepterNet.md) - - [AccessKey](docs/AccessKey.md) - - [AccessKeySecretKey](docs/AccessKeySecretKey.md) - - [AccessLog](docs/AccessLog.md) - - [Account](docs/Account.md) - - [ApplicationStickyCookiePolicy](docs/ApplicationStickyCookiePolicy.md) - - [BackendVmHealth](docs/BackendVmHealth.md) - - [BlockDeviceMappingCreated](docs/BlockDeviceMappingCreated.md) - - [BlockDeviceMappingImage](docs/BlockDeviceMappingImage.md) - - [BlockDeviceMappingVmCreation](docs/BlockDeviceMappingVmCreation.md) - - [BlockDeviceMappingVmUpdate](docs/BlockDeviceMappingVmUpdate.md) - - [BsuCreated](docs/BsuCreated.md) - - [BsuToCreate](docs/BsuToCreate.md) - - [BsuToUpdateVm](docs/BsuToUpdateVm.md) - - [CheckAuthenticationRequest](docs/CheckAuthenticationRequest.md) - - [CheckAuthenticationResponse](docs/CheckAuthenticationResponse.md) - - [ClientGateway](docs/ClientGateway.md) - - [ConsumptionEntry](docs/ConsumptionEntry.md) - - [CreateAccessKeyResponse](docs/CreateAccessKeyResponse.md) - - [CreateAccountRequest](docs/CreateAccountRequest.md) - - [CreateAccountResponse](docs/CreateAccountResponse.md) - - [CreateClientGatewayRequest](docs/CreateClientGatewayRequest.md) - - [CreateClientGatewayResponse](docs/CreateClientGatewayResponse.md) - - [CreateDhcpOptionsRequest](docs/CreateDhcpOptionsRequest.md) - - [CreateDhcpOptionsResponse](docs/CreateDhcpOptionsResponse.md) - - [CreateDirectLinkInterfaceRequest](docs/CreateDirectLinkInterfaceRequest.md) - - [CreateDirectLinkInterfaceResponse](docs/CreateDirectLinkInterfaceResponse.md) - - [CreateDirectLinkRequest](docs/CreateDirectLinkRequest.md) - - [CreateDirectLinkResponse](docs/CreateDirectLinkResponse.md) - - [CreateFlexibleGpuRequest](docs/CreateFlexibleGpuRequest.md) - - [CreateFlexibleGpuResponse](docs/CreateFlexibleGpuResponse.md) - - [CreateImageExportTaskRequest](docs/CreateImageExportTaskRequest.md) - - [CreateImageExportTaskResponse](docs/CreateImageExportTaskResponse.md) - - [CreateImageRequest](docs/CreateImageRequest.md) - - [CreateImageResponse](docs/CreateImageResponse.md) - - [CreateInternetServiceRequest](docs/CreateInternetServiceRequest.md) - - [CreateInternetServiceResponse](docs/CreateInternetServiceResponse.md) - - [CreateKeypairRequest](docs/CreateKeypairRequest.md) - - [CreateKeypairResponse](docs/CreateKeypairResponse.md) - - [CreateListenerRuleRequest](docs/CreateListenerRuleRequest.md) - - [CreateListenerRuleResponse](docs/CreateListenerRuleResponse.md) - - [CreateLoadBalancerListenersRequest](docs/CreateLoadBalancerListenersRequest.md) - - [CreateLoadBalancerListenersResponse](docs/CreateLoadBalancerListenersResponse.md) - - [CreateLoadBalancerPolicyRequest](docs/CreateLoadBalancerPolicyRequest.md) - - [CreateLoadBalancerPolicyResponse](docs/CreateLoadBalancerPolicyResponse.md) - - [CreateLoadBalancerRequest](docs/CreateLoadBalancerRequest.md) - - [CreateLoadBalancerResponse](docs/CreateLoadBalancerResponse.md) - - [CreateLoadBalancerTagsRequest](docs/CreateLoadBalancerTagsRequest.md) - - [CreateLoadBalancerTagsResponse](docs/CreateLoadBalancerTagsResponse.md) - - [CreateNatServiceRequest](docs/CreateNatServiceRequest.md) - - [CreateNatServiceResponse](docs/CreateNatServiceResponse.md) - - [CreateNetAccessPointRequest](docs/CreateNetAccessPointRequest.md) - - [CreateNetAccessPointResponse](docs/CreateNetAccessPointResponse.md) - - [CreateNetPeeringRequest](docs/CreateNetPeeringRequest.md) - - [CreateNetPeeringResponse](docs/CreateNetPeeringResponse.md) - - [CreateNetRequest](docs/CreateNetRequest.md) - - [CreateNetResponse](docs/CreateNetResponse.md) - - [CreateNicRequest](docs/CreateNicRequest.md) - - [CreateNicResponse](docs/CreateNicResponse.md) - - [CreatePublicIpRequest](docs/CreatePublicIpRequest.md) - - [CreatePublicIpResponse](docs/CreatePublicIpResponse.md) - - [CreateRouteRequest](docs/CreateRouteRequest.md) - - [CreateRouteResponse](docs/CreateRouteResponse.md) - - [CreateRouteTableRequest](docs/CreateRouteTableRequest.md) - - [CreateRouteTableResponse](docs/CreateRouteTableResponse.md) - - [CreateSecurityGroupRequest](docs/CreateSecurityGroupRequest.md) - - [CreateSecurityGroupResponse](docs/CreateSecurityGroupResponse.md) - - [CreateSecurityGroupRuleRequest](docs/CreateSecurityGroupRuleRequest.md) - - [CreateSecurityGroupRuleResponse](docs/CreateSecurityGroupRuleResponse.md) - - [CreateServerCertificateRequest](docs/CreateServerCertificateRequest.md) - - [CreateServerCertificateResponse](docs/CreateServerCertificateResponse.md) - - [CreateSnapshotExportTaskRequest](docs/CreateSnapshotExportTaskRequest.md) - - [CreateSnapshotExportTaskResponse](docs/CreateSnapshotExportTaskResponse.md) - - [CreateSnapshotRequest](docs/CreateSnapshotRequest.md) - - [CreateSnapshotResponse](docs/CreateSnapshotResponse.md) - - [CreateSubnetRequest](docs/CreateSubnetRequest.md) - - [CreateSubnetResponse](docs/CreateSubnetResponse.md) - - [CreateTagsRequest](docs/CreateTagsRequest.md) - - [CreateTagsResponse](docs/CreateTagsResponse.md) - - [CreateVirtualGatewayRequest](docs/CreateVirtualGatewayRequest.md) - - [CreateVirtualGatewayResponse](docs/CreateVirtualGatewayResponse.md) - - [CreateVmsRequest](docs/CreateVmsRequest.md) - - [CreateVmsResponse](docs/CreateVmsResponse.md) - - [CreateVolumeRequest](docs/CreateVolumeRequest.md) - - [CreateVolumeResponse](docs/CreateVolumeResponse.md) - - [CreateVpnConnectionRequest](docs/CreateVpnConnectionRequest.md) - - [CreateVpnConnectionResponse](docs/CreateVpnConnectionResponse.md) - - [CreateVpnConnectionRouteRequest](docs/CreateVpnConnectionRouteRequest.md) - - [CreateVpnConnectionRouteResponse](docs/CreateVpnConnectionRouteResponse.md) - - [DeleteAccessKeyRequest](docs/DeleteAccessKeyRequest.md) - - [DeleteAccessKeyResponse](docs/DeleteAccessKeyResponse.md) - - [DeleteClientGatewayRequest](docs/DeleteClientGatewayRequest.md) - - [DeleteClientGatewayResponse](docs/DeleteClientGatewayResponse.md) - - [DeleteDhcpOptionsRequest](docs/DeleteDhcpOptionsRequest.md) - - [DeleteDhcpOptionsResponse](docs/DeleteDhcpOptionsResponse.md) - - [DeleteDirectLinkInterfaceRequest](docs/DeleteDirectLinkInterfaceRequest.md) - - [DeleteDirectLinkInterfaceResponse](docs/DeleteDirectLinkInterfaceResponse.md) - - [DeleteDirectLinkRequest](docs/DeleteDirectLinkRequest.md) - - [DeleteDirectLinkResponse](docs/DeleteDirectLinkResponse.md) - - [DeleteExportTaskRequest](docs/DeleteExportTaskRequest.md) - - [DeleteExportTaskResponse](docs/DeleteExportTaskResponse.md) - - [DeleteFlexibleGpuRequest](docs/DeleteFlexibleGpuRequest.md) - - [DeleteFlexibleGpuResponse](docs/DeleteFlexibleGpuResponse.md) - - [DeleteImageRequest](docs/DeleteImageRequest.md) - - [DeleteImageResponse](docs/DeleteImageResponse.md) - - [DeleteInternetServiceRequest](docs/DeleteInternetServiceRequest.md) - - [DeleteInternetServiceResponse](docs/DeleteInternetServiceResponse.md) - - [DeleteKeypairRequest](docs/DeleteKeypairRequest.md) - - [DeleteKeypairResponse](docs/DeleteKeypairResponse.md) - - [DeleteListenerRuleRequest](docs/DeleteListenerRuleRequest.md) - - [DeleteListenerRuleResponse](docs/DeleteListenerRuleResponse.md) - - [DeleteLoadBalancerListenersRequest](docs/DeleteLoadBalancerListenersRequest.md) - - [DeleteLoadBalancerListenersResponse](docs/DeleteLoadBalancerListenersResponse.md) - - [DeleteLoadBalancerPolicyRequest](docs/DeleteLoadBalancerPolicyRequest.md) - - [DeleteLoadBalancerPolicyResponse](docs/DeleteLoadBalancerPolicyResponse.md) - - [DeleteLoadBalancerRequest](docs/DeleteLoadBalancerRequest.md) - - [DeleteLoadBalancerResponse](docs/DeleteLoadBalancerResponse.md) - - [DeleteLoadBalancerTagsRequest](docs/DeleteLoadBalancerTagsRequest.md) - - [DeleteLoadBalancerTagsResponse](docs/DeleteLoadBalancerTagsResponse.md) - - [DeleteNatServiceRequest](docs/DeleteNatServiceRequest.md) - - [DeleteNatServiceResponse](docs/DeleteNatServiceResponse.md) - - [DeleteNetAccessPointRequest](docs/DeleteNetAccessPointRequest.md) - - [DeleteNetAccessPointResponse](docs/DeleteNetAccessPointResponse.md) - - [DeleteNetPeeringRequest](docs/DeleteNetPeeringRequest.md) - - [DeleteNetPeeringResponse](docs/DeleteNetPeeringResponse.md) - - [DeleteNetRequest](docs/DeleteNetRequest.md) - - [DeleteNetResponse](docs/DeleteNetResponse.md) - - [DeleteNicRequest](docs/DeleteNicRequest.md) - - [DeleteNicResponse](docs/DeleteNicResponse.md) - - [DeletePublicIpRequest](docs/DeletePublicIpRequest.md) - - [DeletePublicIpResponse](docs/DeletePublicIpResponse.md) - - [DeleteRouteRequest](docs/DeleteRouteRequest.md) - - [DeleteRouteResponse](docs/DeleteRouteResponse.md) - - [DeleteRouteTableRequest](docs/DeleteRouteTableRequest.md) - - [DeleteRouteTableResponse](docs/DeleteRouteTableResponse.md) - - [DeleteSecurityGroupRequest](docs/DeleteSecurityGroupRequest.md) - - [DeleteSecurityGroupResponse](docs/DeleteSecurityGroupResponse.md) - - [DeleteSecurityGroupRuleRequest](docs/DeleteSecurityGroupRuleRequest.md) - - [DeleteSecurityGroupRuleResponse](docs/DeleteSecurityGroupRuleResponse.md) - - [DeleteServerCertificateRequest](docs/DeleteServerCertificateRequest.md) - - [DeleteServerCertificateResponse](docs/DeleteServerCertificateResponse.md) - - [DeleteSnapshotRequest](docs/DeleteSnapshotRequest.md) - - [DeleteSnapshotResponse](docs/DeleteSnapshotResponse.md) - - [DeleteSubnetRequest](docs/DeleteSubnetRequest.md) - - [DeleteSubnetResponse](docs/DeleteSubnetResponse.md) - - [DeleteTagsRequest](docs/DeleteTagsRequest.md) - - [DeleteTagsResponse](docs/DeleteTagsResponse.md) - - [DeleteVirtualGatewayRequest](docs/DeleteVirtualGatewayRequest.md) - - [DeleteVirtualGatewayResponse](docs/DeleteVirtualGatewayResponse.md) - - [DeleteVmsRequest](docs/DeleteVmsRequest.md) - - [DeleteVmsResponse](docs/DeleteVmsResponse.md) - - [DeleteVolumeRequest](docs/DeleteVolumeRequest.md) - - [DeleteVolumeResponse](docs/DeleteVolumeResponse.md) - - [DeleteVpnConnectionRequest](docs/DeleteVpnConnectionRequest.md) - - [DeleteVpnConnectionResponse](docs/DeleteVpnConnectionResponse.md) - - [DeleteVpnConnectionRouteRequest](docs/DeleteVpnConnectionRouteRequest.md) - - [DeleteVpnConnectionRouteResponse](docs/DeleteVpnConnectionRouteResponse.md) - - [DeregisterVmsInLoadBalancerRequest](docs/DeregisterVmsInLoadBalancerRequest.md) - - [DeregisterVmsInLoadBalancerResponse](docs/DeregisterVmsInLoadBalancerResponse.md) - - [DhcpOptionsSet](docs/DhcpOptionsSet.md) - - [DirectLink](docs/DirectLink.md) - - [DirectLinkInterface](docs/DirectLinkInterface.md) - - [DirectLinkInterfaces](docs/DirectLinkInterfaces.md) - - [ErrorResponse](docs/ErrorResponse.md) - - [Errors](docs/Errors.md) - - [FiltersAccessKeys](docs/FiltersAccessKeys.md) - - [FiltersApiLog](docs/FiltersApiLog.md) - - [FiltersClientGateway](docs/FiltersClientGateway.md) - - [FiltersDhcpOptions](docs/FiltersDhcpOptions.md) - - [FiltersDirectLink](docs/FiltersDirectLink.md) - - [FiltersDirectLinkInterface](docs/FiltersDirectLinkInterface.md) - - [FiltersExportTask](docs/FiltersExportTask.md) - - [FiltersFlexibleGpu](docs/FiltersFlexibleGpu.md) - - [FiltersImage](docs/FiltersImage.md) - - [FiltersInternetService](docs/FiltersInternetService.md) - - [FiltersKeypair](docs/FiltersKeypair.md) - - [FiltersListenerRule](docs/FiltersListenerRule.md) - - [FiltersLoadBalancer](docs/FiltersLoadBalancer.md) - - [FiltersNatService](docs/FiltersNatService.md) - - [FiltersNet](docs/FiltersNet.md) - - [FiltersNetAccessPoint](docs/FiltersNetAccessPoint.md) - - [FiltersNetPeering](docs/FiltersNetPeering.md) - - [FiltersNic](docs/FiltersNic.md) - - [FiltersProductType](docs/FiltersProductType.md) - - [FiltersPublicIp](docs/FiltersPublicIp.md) - - [FiltersQuota](docs/FiltersQuota.md) - - [FiltersRouteTable](docs/FiltersRouteTable.md) - - [FiltersSecurityGroup](docs/FiltersSecurityGroup.md) - - [FiltersServerCertificate](docs/FiltersServerCertificate.md) - - [FiltersService](docs/FiltersService.md) - - [FiltersSnapshot](docs/FiltersSnapshot.md) - - [FiltersSubnet](docs/FiltersSubnet.md) - - [FiltersSubregion](docs/FiltersSubregion.md) - - [FiltersTag](docs/FiltersTag.md) - - [FiltersVirtualGateway](docs/FiltersVirtualGateway.md) - - [FiltersVm](docs/FiltersVm.md) - - [FiltersVmType](docs/FiltersVmType.md) - - [FiltersVmsState](docs/FiltersVmsState.md) - - [FiltersVolume](docs/FiltersVolume.md) - - [FiltersVpnConnection](docs/FiltersVpnConnection.md) - - [FlexibleGpu](docs/FlexibleGpu.md) - - [FlexibleGpuCatalog](docs/FlexibleGpuCatalog.md) - - [HealthCheck](docs/HealthCheck.md) - - [Image](docs/Image.md) - - [ImageExportTask](docs/ImageExportTask.md) - - [InternetService](docs/InternetService.md) - - [Keypair](docs/Keypair.md) - - [KeypairCreated](docs/KeypairCreated.md) - - [LinkFlexibleGpuRequest](docs/LinkFlexibleGpuRequest.md) - - [LinkFlexibleGpuResponse](docs/LinkFlexibleGpuResponse.md) - - [LinkInternetServiceRequest](docs/LinkInternetServiceRequest.md) - - [LinkInternetServiceResponse](docs/LinkInternetServiceResponse.md) - - [LinkNic](docs/LinkNic.md) - - [LinkNicLight](docs/LinkNicLight.md) - - [LinkNicRequest](docs/LinkNicRequest.md) - - [LinkNicResponse](docs/LinkNicResponse.md) - - [LinkNicToUpdate](docs/LinkNicToUpdate.md) - - [LinkPrivateIpsRequest](docs/LinkPrivateIpsRequest.md) - - [LinkPrivateIpsResponse](docs/LinkPrivateIpsResponse.md) - - [LinkPublicIp](docs/LinkPublicIp.md) - - [LinkPublicIpLightForVm](docs/LinkPublicIpLightForVm.md) - - [LinkPublicIpRequest](docs/LinkPublicIpRequest.md) - - [LinkPublicIpResponse](docs/LinkPublicIpResponse.md) - - [LinkRouteTable](docs/LinkRouteTable.md) - - [LinkRouteTableRequest](docs/LinkRouteTableRequest.md) - - [LinkRouteTableResponse](docs/LinkRouteTableResponse.md) - - [LinkVirtualGatewayRequest](docs/LinkVirtualGatewayRequest.md) - - [LinkVirtualGatewayResponse](docs/LinkVirtualGatewayResponse.md) - - [LinkVolumeRequest](docs/LinkVolumeRequest.md) - - [LinkVolumeResponse](docs/LinkVolumeResponse.md) - - [LinkedVolume](docs/LinkedVolume.md) - - [Listener](docs/Listener.md) - - [ListenerForCreation](docs/ListenerForCreation.md) - - [ListenerRule](docs/ListenerRule.md) - - [ListenerRuleForCreation](docs/ListenerRuleForCreation.md) - - [LoadBalancer](docs/LoadBalancer.md) - - [LoadBalancerLight](docs/LoadBalancerLight.md) - - [LoadBalancerStickyCookiePolicy](docs/LoadBalancerStickyCookiePolicy.md) - - [LoadBalancerTag](docs/LoadBalancerTag.md) - - [Location](docs/Location.md) - - [Log](docs/Log.md) - - [MaintenanceEvent](docs/MaintenanceEvent.md) - - [NatService](docs/NatService.md) - - [Net](docs/Net.md) - - [NetAccessPoint](docs/NetAccessPoint.md) - - [NetPeering](docs/NetPeering.md) - - [NetPeeringState](docs/NetPeeringState.md) - - [NetToVirtualGatewayLink](docs/NetToVirtualGatewayLink.md) - - [Nic](docs/Nic.md) - - [NicForVmCreation](docs/NicForVmCreation.md) - - [NicLight](docs/NicLight.md) - - [OsuApiKey](docs/OsuApiKey.md) - - [OsuExport](docs/OsuExport.md) - - [PermissionsOnResource](docs/PermissionsOnResource.md) - - [PermissionsOnResourceCreation](docs/PermissionsOnResourceCreation.md) - - [Placement](docs/Placement.md) - - [PrivateIp](docs/PrivateIp.md) - - [PrivateIpLight](docs/PrivateIpLight.md) - - [PrivateIpLightForVm](docs/PrivateIpLightForVm.md) - - [ProductType](docs/ProductType.md) - - [PublicIp](docs/PublicIp.md) - - [PublicIpLight](docs/PublicIpLight.md) - - [Quota](docs/Quota.md) - - [QuotaTypes](docs/QuotaTypes.md) - - [ReadAccessKeysRequest](docs/ReadAccessKeysRequest.md) - - [ReadAccessKeysResponse](docs/ReadAccessKeysResponse.md) - - [ReadAccountsRequest](docs/ReadAccountsRequest.md) - - [ReadAccountsResponse](docs/ReadAccountsResponse.md) - - [ReadAdminPasswordRequest](docs/ReadAdminPasswordRequest.md) - - [ReadAdminPasswordResponse](docs/ReadAdminPasswordResponse.md) - - [ReadApiLogsRequest](docs/ReadApiLogsRequest.md) - - [ReadApiLogsResponse](docs/ReadApiLogsResponse.md) - - [ReadClientGatewaysRequest](docs/ReadClientGatewaysRequest.md) - - [ReadClientGatewaysResponse](docs/ReadClientGatewaysResponse.md) - - [ReadConsoleOutputRequest](docs/ReadConsoleOutputRequest.md) - - [ReadConsoleOutputResponse](docs/ReadConsoleOutputResponse.md) - - [ReadConsumptionAccountRequest](docs/ReadConsumptionAccountRequest.md) - - [ReadConsumptionAccountResponse](docs/ReadConsumptionAccountResponse.md) - - [ReadDhcpOptionsRequest](docs/ReadDhcpOptionsRequest.md) - - [ReadDhcpOptionsResponse](docs/ReadDhcpOptionsResponse.md) - - [ReadDirectLinkInterfacesRequest](docs/ReadDirectLinkInterfacesRequest.md) - - [ReadDirectLinkInterfacesResponse](docs/ReadDirectLinkInterfacesResponse.md) - - [ReadDirectLinksRequest](docs/ReadDirectLinksRequest.md) - - [ReadDirectLinksResponse](docs/ReadDirectLinksResponse.md) - - [ReadFlexibleGpuCatalogRequest](docs/ReadFlexibleGpuCatalogRequest.md) - - [ReadFlexibleGpuCatalogResponse](docs/ReadFlexibleGpuCatalogResponse.md) - - [ReadFlexibleGpusRequest](docs/ReadFlexibleGpusRequest.md) - - [ReadFlexibleGpusResponse](docs/ReadFlexibleGpusResponse.md) - - [ReadImageExportTasksRequest](docs/ReadImageExportTasksRequest.md) - - [ReadImageExportTasksResponse](docs/ReadImageExportTasksResponse.md) - - [ReadImagesRequest](docs/ReadImagesRequest.md) - - [ReadImagesResponse](docs/ReadImagesResponse.md) - - [ReadInternetServicesRequest](docs/ReadInternetServicesRequest.md) - - [ReadInternetServicesResponse](docs/ReadInternetServicesResponse.md) - - [ReadKeypairsRequest](docs/ReadKeypairsRequest.md) - - [ReadKeypairsResponse](docs/ReadKeypairsResponse.md) - - [ReadListenerRulesRequest](docs/ReadListenerRulesRequest.md) - - [ReadListenerRulesResponse](docs/ReadListenerRulesResponse.md) - - [ReadLoadBalancerTagsRequest](docs/ReadLoadBalancerTagsRequest.md) - - [ReadLoadBalancerTagsResponse](docs/ReadLoadBalancerTagsResponse.md) - - [ReadLoadBalancersRequest](docs/ReadLoadBalancersRequest.md) - - [ReadLoadBalancersResponse](docs/ReadLoadBalancersResponse.md) - - [ReadLocationsRequest](docs/ReadLocationsRequest.md) - - [ReadLocationsResponse](docs/ReadLocationsResponse.md) - - [ReadNatServicesRequest](docs/ReadNatServicesRequest.md) - - [ReadNatServicesResponse](docs/ReadNatServicesResponse.md) - - [ReadNetAccessPointServicesRequest](docs/ReadNetAccessPointServicesRequest.md) - - [ReadNetAccessPointServicesResponse](docs/ReadNetAccessPointServicesResponse.md) - - [ReadNetAccessPointsRequest](docs/ReadNetAccessPointsRequest.md) - - [ReadNetAccessPointsResponse](docs/ReadNetAccessPointsResponse.md) - - [ReadNetPeeringsRequest](docs/ReadNetPeeringsRequest.md) - - [ReadNetPeeringsResponse](docs/ReadNetPeeringsResponse.md) - - [ReadNetsRequest](docs/ReadNetsRequest.md) - - [ReadNetsResponse](docs/ReadNetsResponse.md) - - [ReadNicsRequest](docs/ReadNicsRequest.md) - - [ReadNicsResponse](docs/ReadNicsResponse.md) - - [ReadProductTypesRequest](docs/ReadProductTypesRequest.md) - - [ReadProductTypesResponse](docs/ReadProductTypesResponse.md) - - [ReadPublicIpRangesRequest](docs/ReadPublicIpRangesRequest.md) - - [ReadPublicIpRangesResponse](docs/ReadPublicIpRangesResponse.md) - - [ReadPublicIpsRequest](docs/ReadPublicIpsRequest.md) - - [ReadPublicIpsResponse](docs/ReadPublicIpsResponse.md) - - [ReadQuotasRequest](docs/ReadQuotasRequest.md) - - [ReadQuotasResponse](docs/ReadQuotasResponse.md) - - [ReadRegionsRequest](docs/ReadRegionsRequest.md) - - [ReadRegionsResponse](docs/ReadRegionsResponse.md) - - [ReadRouteTablesRequest](docs/ReadRouteTablesRequest.md) - - [ReadRouteTablesResponse](docs/ReadRouteTablesResponse.md) - - [ReadSecretAccessKeyRequest](docs/ReadSecretAccessKeyRequest.md) - - [ReadSecretAccessKeyResponse](docs/ReadSecretAccessKeyResponse.md) - - [ReadSecurityGroupsRequest](docs/ReadSecurityGroupsRequest.md) - - [ReadSecurityGroupsResponse](docs/ReadSecurityGroupsResponse.md) - - [ReadServerCertificatesRequest](docs/ReadServerCertificatesRequest.md) - - [ReadServerCertificatesResponse](docs/ReadServerCertificatesResponse.md) - - [ReadSnapshotExportTasksRequest](docs/ReadSnapshotExportTasksRequest.md) - - [ReadSnapshotExportTasksResponse](docs/ReadSnapshotExportTasksResponse.md) - - [ReadSnapshotsRequest](docs/ReadSnapshotsRequest.md) - - [ReadSnapshotsResponse](docs/ReadSnapshotsResponse.md) - - [ReadSubnetsRequest](docs/ReadSubnetsRequest.md) - - [ReadSubnetsResponse](docs/ReadSubnetsResponse.md) - - [ReadSubregionsRequest](docs/ReadSubregionsRequest.md) - - [ReadSubregionsResponse](docs/ReadSubregionsResponse.md) - - [ReadTagsRequest](docs/ReadTagsRequest.md) - - [ReadTagsResponse](docs/ReadTagsResponse.md) - - [ReadVirtualGatewaysRequest](docs/ReadVirtualGatewaysRequest.md) - - [ReadVirtualGatewaysResponse](docs/ReadVirtualGatewaysResponse.md) - - [ReadVmTypesRequest](docs/ReadVmTypesRequest.md) - - [ReadVmTypesResponse](docs/ReadVmTypesResponse.md) - - [ReadVmsHealthRequest](docs/ReadVmsHealthRequest.md) - - [ReadVmsHealthResponse](docs/ReadVmsHealthResponse.md) - - [ReadVmsRequest](docs/ReadVmsRequest.md) - - [ReadVmsResponse](docs/ReadVmsResponse.md) - - [ReadVmsStateRequest](docs/ReadVmsStateRequest.md) - - [ReadVmsStateResponse](docs/ReadVmsStateResponse.md) - - [ReadVolumesRequest](docs/ReadVolumesRequest.md) - - [ReadVolumesResponse](docs/ReadVolumesResponse.md) - - [ReadVpnConnectionsRequest](docs/ReadVpnConnectionsRequest.md) - - [ReadVpnConnectionsResponse](docs/ReadVpnConnectionsResponse.md) - - [RebootVmsRequest](docs/RebootVmsRequest.md) - - [RebootVmsResponse](docs/RebootVmsResponse.md) - - [Region](docs/Region.md) - - [RegisterVmsInLoadBalancerRequest](docs/RegisterVmsInLoadBalancerRequest.md) - - [RegisterVmsInLoadBalancerResponse](docs/RegisterVmsInLoadBalancerResponse.md) - - [RejectNetPeeringRequest](docs/RejectNetPeeringRequest.md) - - [RejectNetPeeringResponse](docs/RejectNetPeeringResponse.md) - - [ResetAccountPasswordRequest](docs/ResetAccountPasswordRequest.md) - - [ResetAccountPasswordResponse](docs/ResetAccountPasswordResponse.md) - - [ResourceLoadBalancerTag](docs/ResourceLoadBalancerTag.md) - - [ResourceTag](docs/ResourceTag.md) - - [ResponseContext](docs/ResponseContext.md) - - [Route](docs/Route.md) - - [RouteLight](docs/RouteLight.md) - - [RoutePropagatingVirtualGateway](docs/RoutePropagatingVirtualGateway.md) - - [RouteTable](docs/RouteTable.md) - - [SecurityGroup](docs/SecurityGroup.md) - - [SecurityGroupLight](docs/SecurityGroupLight.md) - - [SecurityGroupRule](docs/SecurityGroupRule.md) - - [SecurityGroupsMember](docs/SecurityGroupsMember.md) - - [SendResetPasswordEmailRequest](docs/SendResetPasswordEmailRequest.md) - - [SendResetPasswordEmailResponse](docs/SendResetPasswordEmailResponse.md) - - [ServerCertificate](docs/ServerCertificate.md) - - [Service](docs/Service.md) - - [Snapshot](docs/Snapshot.md) - - [SnapshotExportTask](docs/SnapshotExportTask.md) - - [SourceNet](docs/SourceNet.md) - - [SourceSecurityGroup](docs/SourceSecurityGroup.md) - - [StartVmsRequest](docs/StartVmsRequest.md) - - [StartVmsResponse](docs/StartVmsResponse.md) - - [StateComment](docs/StateComment.md) - - [StopVmsRequest](docs/StopVmsRequest.md) - - [StopVmsResponse](docs/StopVmsResponse.md) - - [Subnet](docs/Subnet.md) - - [Subregion](docs/Subregion.md) - - [Tag](docs/Tag.md) - - [UnlinkFlexibleGpuRequest](docs/UnlinkFlexibleGpuRequest.md) - - [UnlinkFlexibleGpuResponse](docs/UnlinkFlexibleGpuResponse.md) - - [UnlinkInternetServiceRequest](docs/UnlinkInternetServiceRequest.md) - - [UnlinkInternetServiceResponse](docs/UnlinkInternetServiceResponse.md) - - [UnlinkNicRequest](docs/UnlinkNicRequest.md) - - [UnlinkNicResponse](docs/UnlinkNicResponse.md) - - [UnlinkPrivateIpsRequest](docs/UnlinkPrivateIpsRequest.md) - - [UnlinkPrivateIpsResponse](docs/UnlinkPrivateIpsResponse.md) - - [UnlinkPublicIpRequest](docs/UnlinkPublicIpRequest.md) - - [UnlinkPublicIpResponse](docs/UnlinkPublicIpResponse.md) - - [UnlinkRouteTableRequest](docs/UnlinkRouteTableRequest.md) - - [UnlinkRouteTableResponse](docs/UnlinkRouteTableResponse.md) - - [UnlinkVirtualGatewayRequest](docs/UnlinkVirtualGatewayRequest.md) - - [UnlinkVirtualGatewayResponse](docs/UnlinkVirtualGatewayResponse.md) - - [UnlinkVolumeRequest](docs/UnlinkVolumeRequest.md) - - [UnlinkVolumeResponse](docs/UnlinkVolumeResponse.md) - - [UpdateAccessKeyRequest](docs/UpdateAccessKeyRequest.md) - - [UpdateAccessKeyResponse](docs/UpdateAccessKeyResponse.md) - - [UpdateAccountRequest](docs/UpdateAccountRequest.md) - - [UpdateAccountResponse](docs/UpdateAccountResponse.md) - - [UpdateFlexibleGpuRequest](docs/UpdateFlexibleGpuRequest.md) - - [UpdateFlexibleGpuResponse](docs/UpdateFlexibleGpuResponse.md) - - [UpdateImageRequest](docs/UpdateImageRequest.md) - - [UpdateImageResponse](docs/UpdateImageResponse.md) - - [UpdateListenerRuleRequest](docs/UpdateListenerRuleRequest.md) - - [UpdateListenerRuleResponse](docs/UpdateListenerRuleResponse.md) - - [UpdateLoadBalancerRequest](docs/UpdateLoadBalancerRequest.md) - - [UpdateLoadBalancerResponse](docs/UpdateLoadBalancerResponse.md) - - [UpdateNetAccessPointRequest](docs/UpdateNetAccessPointRequest.md) - - [UpdateNetAccessPointResponse](docs/UpdateNetAccessPointResponse.md) - - [UpdateNetRequest](docs/UpdateNetRequest.md) - - [UpdateNetResponse](docs/UpdateNetResponse.md) - - [UpdateNicRequest](docs/UpdateNicRequest.md) - - [UpdateNicResponse](docs/UpdateNicResponse.md) - - [UpdateRoutePropagationRequest](docs/UpdateRoutePropagationRequest.md) - - [UpdateRoutePropagationResponse](docs/UpdateRoutePropagationResponse.md) - - [UpdateRouteRequest](docs/UpdateRouteRequest.md) - - [UpdateRouteResponse](docs/UpdateRouteResponse.md) - - [UpdateServerCertificateRequest](docs/UpdateServerCertificateRequest.md) - - [UpdateServerCertificateResponse](docs/UpdateServerCertificateResponse.md) - - [UpdateSnapshotRequest](docs/UpdateSnapshotRequest.md) - - [UpdateSnapshotResponse](docs/UpdateSnapshotResponse.md) - - [UpdateSubnetRequest](docs/UpdateSubnetRequest.md) - - [UpdateSubnetResponse](docs/UpdateSubnetResponse.md) - - [UpdateVmRequest](docs/UpdateVmRequest.md) - - [UpdateVmResponse](docs/UpdateVmResponse.md) - - [VirtualGateway](docs/VirtualGateway.md) - - [Vm](docs/Vm.md) - - [VmState](docs/VmState.md) - - [VmStates](docs/VmStates.md) - - [VmType](docs/VmType.md) - - [Volume](docs/Volume.md) - - [VpnConnection](docs/VpnConnection.md) - - [With](docs/With.md) - - -## Documentation For Authorization - - - -### ApiKeyAuth - -- **Type**: API key -- **API key parameter name**: Authorization -- **Location**: HTTP header - -Note, each API key must be added to a map of `map[string]APIKey` where the key is: Authorization and passed in as the auth context for each request. - - -## Documentation for Utility Methods - -Due to the fact that model structure members are all pointers, this package contains -a number of utility functions to easily obtain pointers to values of basic types. -Each of these functions takes a value of the given basic type and returns a pointer to it: - -* `PtrBool` -* `PtrInt` -* `PtrInt32` -* `PtrInt64` -* `PtrFloat` -* `PtrFloat32` -* `PtrFloat64` -* `PtrString` -* `PtrTime` - -## Author - -support@outscale.com - diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_access_key.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_access_key.go deleted file mode 100644 index d917096b9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_access_key.go +++ /dev/null @@ -1,585 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// AccessKeyApiService AccessKeyApi service -type AccessKeyApiService service - -/* - CreateAccessKey Method for CreateAccessKey - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @return CreateAccessKeyResponse -*/ -func (a *AccessKeyApiService) CreateAccessKey(ctx _context.Context) (CreateAccessKeyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateAccessKeyResponse - ) - - localVarPostBody = "{}" - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateAccessKey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateAccessKeyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteAccessKeyOpts Optional parameters for the method 'DeleteAccessKey' -type DeleteAccessKeyOpts struct { - DeleteAccessKeyRequest optional.Interface -} - -/* - DeleteAccessKey Method for DeleteAccessKey - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteAccessKeyOpts - Optional Parameters: - * @param "DeleteAccessKeyRequest" (optional.Interface of DeleteAccessKeyRequest) - - @return DeleteAccessKeyResponse -*/ -func (a *AccessKeyApiService) DeleteAccessKey(ctx _context.Context, localVarOptionals *DeleteAccessKeyOpts) (DeleteAccessKeyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteAccessKeyResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteAccessKey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteAccessKeyRequest.IsSet() { - localVarOptionalDeleteAccessKeyRequest, localVarOptionalDeleteAccessKeyRequestok := localVarOptionals.DeleteAccessKeyRequest.Value().(DeleteAccessKeyRequest) - if !localVarOptionalDeleteAccessKeyRequestok { - return localVarReturnValue, nil, reportError("deleteAccessKeyRequest should be DeleteAccessKeyRequest") - } - localVarPostBody = &localVarOptionalDeleteAccessKeyRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteAccessKeyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadAccessKeysOpts Optional parameters for the method 'ReadAccessKeys' -type ReadAccessKeysOpts struct { - ReadAccessKeysRequest optional.Interface -} - -/* - ReadAccessKeys Method for ReadAccessKeys - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadAccessKeysOpts - Optional Parameters: - * @param "ReadAccessKeysRequest" (optional.Interface of ReadAccessKeysRequest) - - @return ReadAccessKeysResponse -*/ -func (a *AccessKeyApiService) ReadAccessKeys(ctx _context.Context, localVarOptionals *ReadAccessKeysOpts) (ReadAccessKeysResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadAccessKeysResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadAccessKeys" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadAccessKeysRequest.IsSet() { - localVarOptionalReadAccessKeysRequest, localVarOptionalReadAccessKeysRequestok := localVarOptionals.ReadAccessKeysRequest.Value().(ReadAccessKeysRequest) - if !localVarOptionalReadAccessKeysRequestok { - return localVarReturnValue, nil, reportError("readAccessKeysRequest should be ReadAccessKeysRequest") - } - localVarPostBody = &localVarOptionalReadAccessKeysRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadAccessKeysResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadSecretAccessKeyOpts Optional parameters for the method 'ReadSecretAccessKey' -type ReadSecretAccessKeyOpts struct { - ReadSecretAccessKeyRequest optional.Interface -} - -/* - ReadSecretAccessKey Method for ReadSecretAccessKey - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSecretAccessKeyOpts - Optional Parameters: - * @param "ReadSecretAccessKeyRequest" (optional.Interface of ReadSecretAccessKeyRequest) - - @return ReadSecretAccessKeyResponse -*/ -func (a *AccessKeyApiService) ReadSecretAccessKey(ctx _context.Context, localVarOptionals *ReadSecretAccessKeyOpts) (ReadSecretAccessKeyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSecretAccessKeyResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSecretAccessKey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSecretAccessKeyRequest.IsSet() { - localVarOptionalReadSecretAccessKeyRequest, localVarOptionalReadSecretAccessKeyRequestok := localVarOptionals.ReadSecretAccessKeyRequest.Value().(ReadSecretAccessKeyRequest) - if !localVarOptionalReadSecretAccessKeyRequestok { - return localVarReturnValue, nil, reportError("readSecretAccessKeyRequest should be ReadSecretAccessKeyRequest") - } - localVarPostBody = &localVarOptionalReadSecretAccessKeyRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSecretAccessKeyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateAccessKeyOpts Optional parameters for the method 'UpdateAccessKey' -type UpdateAccessKeyOpts struct { - UpdateAccessKeyRequest optional.Interface -} - -/* - UpdateAccessKey Method for UpdateAccessKey - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateAccessKeyOpts - Optional Parameters: - * @param "UpdateAccessKeyRequest" (optional.Interface of UpdateAccessKeyRequest) - - @return UpdateAccessKeyResponse -*/ -func (a *AccessKeyApiService) UpdateAccessKey(ctx _context.Context, localVarOptionals *UpdateAccessKeyOpts) (UpdateAccessKeyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateAccessKeyResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateAccessKey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateAccessKeyRequest.IsSet() { - localVarOptionalUpdateAccessKeyRequest, localVarOptionalUpdateAccessKeyRequestok := localVarOptionals.UpdateAccessKeyRequest.Value().(UpdateAccessKeyRequest) - if !localVarOptionalUpdateAccessKeyRequestok { - return localVarReturnValue, nil, reportError("updateAccessKeyRequest should be UpdateAccessKeyRequest") - } - localVarPostBody = &localVarOptionalUpdateAccessKeyRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateAccessKeyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_account.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_account.go deleted file mode 100644 index a1378e524..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_account.go +++ /dev/null @@ -1,711 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// AccountApiService AccountApi service -type AccountApiService service - -// CheckAuthenticationOpts Optional parameters for the method 'CheckAuthentication' -type CheckAuthenticationOpts struct { - CheckAuthenticationRequest optional.Interface -} - -/* -CheckAuthentication Method for CheckAuthentication - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CheckAuthenticationOpts - Optional Parameters: - * @param "CheckAuthenticationRequest" (optional.Interface of CheckAuthenticationRequest) - -@return CheckAuthenticationResponse -*/ -func (a *AccountApiService) CheckAuthentication(ctx _context.Context, localVarOptionals *CheckAuthenticationOpts) (CheckAuthenticationResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CheckAuthenticationResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CheckAuthentication" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CheckAuthenticationRequest.IsSet() { - localVarOptionalCheckAuthenticationRequest, localVarOptionalCheckAuthenticationRequestok := localVarOptionals.CheckAuthenticationRequest.Value().(CheckAuthenticationRequest) - if !localVarOptionalCheckAuthenticationRequestok { - return localVarReturnValue, nil, reportError("checkAuthenticationRequest should be CheckAuthenticationRequest") - } - localVarPostBody = &localVarOptionalCheckAuthenticationRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CheckAuthenticationResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateAccountOpts Optional parameters for the method 'CreateAccount' -type CreateAccountOpts struct { - CreateAccountRequest optional.Interface -} - -/* -CreateAccount Method for CreateAccount - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateAccountOpts - Optional Parameters: - * @param "CreateAccountRequest" (optional.Interface of CreateAccountRequest) - -@return CreateAccountResponse -*/ -func (a *AccountApiService) CreateAccount(ctx _context.Context, localVarOptionals *CreateAccountOpts) (CreateAccountResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateAccountResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateAccount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateAccountRequest.IsSet() { - localVarOptionalCreateAccountRequest, localVarOptionalCreateAccountRequestok := localVarOptionals.CreateAccountRequest.Value().(CreateAccountRequest) - if !localVarOptionalCreateAccountRequestok { - return localVarReturnValue, nil, reportError("createAccountRequest should be CreateAccountRequest") - } - localVarPostBody = &localVarOptionalCreateAccountRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateAccountResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadAccountsOpts Optional parameters for the method 'ReadAccounts' -type ReadAccountsOpts struct { - ReadAccountsRequest optional.Interface -} - -/* -ReadAccounts Method for ReadAccounts - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadAccountsOpts - Optional Parameters: - * @param "ReadAccountsRequest" (optional.Interface of ReadAccountsRequest) - -@return ReadAccountsResponse -*/ -func (a *AccountApiService) ReadAccounts(ctx _context.Context, localVarOptionals *ReadAccountsOpts) (ReadAccountsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadAccountsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadAccounts" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadAccountsRequest.IsSet() { - localVarOptionalReadAccountsRequest, localVarOptionalReadAccountsRequestok := localVarOptionals.ReadAccountsRequest.Value().(ReadAccountsRequest) - if !localVarOptionalReadAccountsRequestok { - return localVarReturnValue, nil, reportError("readAccountsRequest should be ReadAccountsRequest") - } - localVarPostBody = &localVarOptionalReadAccountsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadAccountsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ResetAccountPasswordOpts Optional parameters for the method 'ResetAccountPassword' -type ResetAccountPasswordOpts struct { - ResetAccountPasswordRequest optional.Interface -} - -/* -ResetAccountPassword Method for ResetAccountPassword - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ResetAccountPasswordOpts - Optional Parameters: - * @param "ResetAccountPasswordRequest" (optional.Interface of ResetAccountPasswordRequest) - -@return ResetAccountPasswordResponse -*/ -func (a *AccountApiService) ResetAccountPassword(ctx _context.Context, localVarOptionals *ResetAccountPasswordOpts) (ResetAccountPasswordResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResetAccountPasswordResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ResetAccountPassword" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ResetAccountPasswordRequest.IsSet() { - localVarOptionalResetAccountPasswordRequest, localVarOptionalResetAccountPasswordRequestok := localVarOptionals.ResetAccountPasswordRequest.Value().(ResetAccountPasswordRequest) - if !localVarOptionalResetAccountPasswordRequestok { - return localVarReturnValue, nil, reportError("resetAccountPasswordRequest should be ResetAccountPasswordRequest") - } - localVarPostBody = &localVarOptionalResetAccountPasswordRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ResetAccountPasswordResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// SendResetPasswordEmailOpts Optional parameters for the method 'SendResetPasswordEmail' -type SendResetPasswordEmailOpts struct { - SendResetPasswordEmailRequest optional.Interface -} - -/* -SendResetPasswordEmail Method for SendResetPasswordEmail - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *SendResetPasswordEmailOpts - Optional Parameters: - * @param "SendResetPasswordEmailRequest" (optional.Interface of SendResetPasswordEmailRequest) - -@return SendResetPasswordEmailResponse -*/ -func (a *AccountApiService) SendResetPasswordEmail(ctx _context.Context, localVarOptionals *SendResetPasswordEmailOpts) (SendResetPasswordEmailResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue SendResetPasswordEmailResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/SendResetPasswordEmail" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.SendResetPasswordEmailRequest.IsSet() { - localVarOptionalSendResetPasswordEmailRequest, localVarOptionalSendResetPasswordEmailRequestok := localVarOptionals.SendResetPasswordEmailRequest.Value().(SendResetPasswordEmailRequest) - if !localVarOptionalSendResetPasswordEmailRequestok { - return localVarReturnValue, nil, reportError("sendResetPasswordEmailRequest should be SendResetPasswordEmailRequest") - } - localVarPostBody = &localVarOptionalSendResetPasswordEmailRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v SendResetPasswordEmailResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateAccountOpts Optional parameters for the method 'UpdateAccount' -type UpdateAccountOpts struct { - UpdateAccountRequest optional.Interface -} - -/* -UpdateAccount Method for UpdateAccount - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateAccountOpts - Optional Parameters: - * @param "UpdateAccountRequest" (optional.Interface of UpdateAccountRequest) - -@return UpdateAccountResponse -*/ -func (a *AccountApiService) UpdateAccount(ctx _context.Context, localVarOptionals *UpdateAccountOpts) (UpdateAccountResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateAccountResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateAccount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateAccountRequest.IsSet() { - localVarOptionalUpdateAccountRequest, localVarOptionalUpdateAccountRequestok := localVarOptionals.UpdateAccountRequest.Value().(UpdateAccountRequest) - if !localVarOptionalUpdateAccountRequestok { - return localVarReturnValue, nil, reportError("updateAccountRequest should be UpdateAccountRequest") - } - localVarPostBody = &localVarOptionalUpdateAccountRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateAccountResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_api_log.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_api_log.go deleted file mode 100644 index 1395d9e39..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_api_log.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// ApiLogApiService ApiLogApi service -type ApiLogApiService service - -// ReadApiLogsOpts Optional parameters for the method 'ReadApiLogs' -type ReadApiLogsOpts struct { - ReadApiLogsRequest optional.Interface -} - -/* -ReadApiLogs Method for ReadApiLogs - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadApiLogsOpts - Optional Parameters: - * @param "ReadApiLogsRequest" (optional.Interface of ReadApiLogsRequest) - -@return ReadApiLogsResponse -*/ -func (a *ApiLogApiService) ReadApiLogs(ctx _context.Context, localVarOptionals *ReadApiLogsOpts) (ReadApiLogsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadApiLogsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadApiLogs" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadApiLogsRequest.IsSet() { - localVarOptionalReadApiLogsRequest, localVarOptionalReadApiLogsRequestok := localVarOptionals.ReadApiLogsRequest.Value().(ReadApiLogsRequest) - if !localVarOptionalReadApiLogsRequestok { - return localVarReturnValue, nil, reportError("readApiLogsRequest should be ReadApiLogsRequest") - } - localVarPostBody = &localVarOptionalReadApiLogsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadApiLogsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_client_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_client_gateway.go deleted file mode 100644 index 685ba8fdb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_client_gateway.go +++ /dev/null @@ -1,369 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// ClientGatewayApiService ClientGatewayApi service -type ClientGatewayApiService service - -// CreateClientGatewayOpts Optional parameters for the method 'CreateClientGateway' -type CreateClientGatewayOpts struct { - CreateClientGatewayRequest optional.Interface -} - -/* -CreateClientGateway Method for CreateClientGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateClientGatewayOpts - Optional Parameters: - * @param "CreateClientGatewayRequest" (optional.Interface of CreateClientGatewayRequest) - -@return CreateClientGatewayResponse -*/ -func (a *ClientGatewayApiService) CreateClientGateway(ctx _context.Context, localVarOptionals *CreateClientGatewayOpts) (CreateClientGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateClientGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateClientGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateClientGatewayRequest.IsSet() { - localVarOptionalCreateClientGatewayRequest, localVarOptionalCreateClientGatewayRequestok := localVarOptionals.CreateClientGatewayRequest.Value().(CreateClientGatewayRequest) - if !localVarOptionalCreateClientGatewayRequestok { - return localVarReturnValue, nil, reportError("createClientGatewayRequest should be CreateClientGatewayRequest") - } - localVarPostBody = &localVarOptionalCreateClientGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateClientGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteClientGatewayOpts Optional parameters for the method 'DeleteClientGateway' -type DeleteClientGatewayOpts struct { - DeleteClientGatewayRequest optional.Interface -} - -/* -DeleteClientGateway Method for DeleteClientGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteClientGatewayOpts - Optional Parameters: - * @param "DeleteClientGatewayRequest" (optional.Interface of DeleteClientGatewayRequest) - -@return DeleteClientGatewayResponse -*/ -func (a *ClientGatewayApiService) DeleteClientGateway(ctx _context.Context, localVarOptionals *DeleteClientGatewayOpts) (DeleteClientGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteClientGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteClientGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteClientGatewayRequest.IsSet() { - localVarOptionalDeleteClientGatewayRequest, localVarOptionalDeleteClientGatewayRequestok := localVarOptionals.DeleteClientGatewayRequest.Value().(DeleteClientGatewayRequest) - if !localVarOptionalDeleteClientGatewayRequestok { - return localVarReturnValue, nil, reportError("deleteClientGatewayRequest should be DeleteClientGatewayRequest") - } - localVarPostBody = &localVarOptionalDeleteClientGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteClientGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadClientGatewaysOpts Optional parameters for the method 'ReadClientGateways' -type ReadClientGatewaysOpts struct { - ReadClientGatewaysRequest optional.Interface -} - -/* -ReadClientGateways Method for ReadClientGateways - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadClientGatewaysOpts - Optional Parameters: - * @param "ReadClientGatewaysRequest" (optional.Interface of ReadClientGatewaysRequest) - -@return ReadClientGatewaysResponse -*/ -func (a *ClientGatewayApiService) ReadClientGateways(ctx _context.Context, localVarOptionals *ReadClientGatewaysOpts) (ReadClientGatewaysResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadClientGatewaysResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadClientGateways" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadClientGatewaysRequest.IsSet() { - localVarOptionalReadClientGatewaysRequest, localVarOptionalReadClientGatewaysRequestok := localVarOptionals.ReadClientGatewaysRequest.Value().(ReadClientGatewaysRequest) - if !localVarOptionalReadClientGatewaysRequestok { - return localVarReturnValue, nil, reportError("readClientGatewaysRequest should be ReadClientGatewaysRequest") - } - localVarPostBody = &localVarOptionalReadClientGatewaysRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadClientGatewaysResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_default.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_default.go deleted file mode 100644 index df95b25e1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_default.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// DefaultApiService DefaultApi service -type DefaultApiService service - -// ReadConsumptionAccountOpts Optional parameters for the method 'ReadConsumptionAccount' -type ReadConsumptionAccountOpts struct { - ReadConsumptionAccountRequest optional.Interface -} - -/* -ReadConsumptionAccount Method for ReadConsumptionAccount - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadConsumptionAccountOpts - Optional Parameters: - * @param "ReadConsumptionAccountRequest" (optional.Interface of ReadConsumptionAccountRequest) - -@return ReadConsumptionAccountResponse -*/ -func (a *DefaultApiService) ReadConsumptionAccount(ctx _context.Context, localVarOptionals *ReadConsumptionAccountOpts) (ReadConsumptionAccountResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadConsumptionAccountResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadConsumptionAccount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadConsumptionAccountRequest.IsSet() { - localVarOptionalReadConsumptionAccountRequest, localVarOptionalReadConsumptionAccountRequestok := localVarOptionals.ReadConsumptionAccountRequest.Value().(ReadConsumptionAccountRequest) - if !localVarOptionalReadConsumptionAccountRequestok { - return localVarReturnValue, nil, reportError("readConsumptionAccountRequest should be ReadConsumptionAccountRequest") - } - localVarPostBody = &localVarOptionalReadConsumptionAccountRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadConsumptionAccountResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_dhcp_option.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_dhcp_option.go deleted file mode 100644 index 01b0af35e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_dhcp_option.go +++ /dev/null @@ -1,369 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// DhcpOptionApiService DhcpOptionApi service -type DhcpOptionApiService service - -// CreateDhcpOptionsOpts Optional parameters for the method 'CreateDhcpOptions' -type CreateDhcpOptionsOpts struct { - CreateDhcpOptionsRequest optional.Interface -} - -/* -CreateDhcpOptions Method for CreateDhcpOptions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateDhcpOptionsOpts - Optional Parameters: - * @param "CreateDhcpOptionsRequest" (optional.Interface of CreateDhcpOptionsRequest) - -@return CreateDhcpOptionsResponse -*/ -func (a *DhcpOptionApiService) CreateDhcpOptions(ctx _context.Context, localVarOptionals *CreateDhcpOptionsOpts) (CreateDhcpOptionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateDhcpOptionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateDhcpOptions" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateDhcpOptionsRequest.IsSet() { - localVarOptionalCreateDhcpOptionsRequest, localVarOptionalCreateDhcpOptionsRequestok := localVarOptionals.CreateDhcpOptionsRequest.Value().(CreateDhcpOptionsRequest) - if !localVarOptionalCreateDhcpOptionsRequestok { - return localVarReturnValue, nil, reportError("createDhcpOptionsRequest should be CreateDhcpOptionsRequest") - } - localVarPostBody = &localVarOptionalCreateDhcpOptionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateDhcpOptionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteDhcpOptionsOpts Optional parameters for the method 'DeleteDhcpOptions' -type DeleteDhcpOptionsOpts struct { - DeleteDhcpOptionsRequest optional.Interface -} - -/* -DeleteDhcpOptions Method for DeleteDhcpOptions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteDhcpOptionsOpts - Optional Parameters: - * @param "DeleteDhcpOptionsRequest" (optional.Interface of DeleteDhcpOptionsRequest) - -@return DeleteDhcpOptionsResponse -*/ -func (a *DhcpOptionApiService) DeleteDhcpOptions(ctx _context.Context, localVarOptionals *DeleteDhcpOptionsOpts) (DeleteDhcpOptionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteDhcpOptionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteDhcpOptions" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteDhcpOptionsRequest.IsSet() { - localVarOptionalDeleteDhcpOptionsRequest, localVarOptionalDeleteDhcpOptionsRequestok := localVarOptionals.DeleteDhcpOptionsRequest.Value().(DeleteDhcpOptionsRequest) - if !localVarOptionalDeleteDhcpOptionsRequestok { - return localVarReturnValue, nil, reportError("deleteDhcpOptionsRequest should be DeleteDhcpOptionsRequest") - } - localVarPostBody = &localVarOptionalDeleteDhcpOptionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteDhcpOptionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadDhcpOptionsOpts Optional parameters for the method 'ReadDhcpOptions' -type ReadDhcpOptionsOpts struct { - ReadDhcpOptionsRequest optional.Interface -} - -/* -ReadDhcpOptions Method for ReadDhcpOptions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadDhcpOptionsOpts - Optional Parameters: - * @param "ReadDhcpOptionsRequest" (optional.Interface of ReadDhcpOptionsRequest) - -@return ReadDhcpOptionsResponse -*/ -func (a *DhcpOptionApiService) ReadDhcpOptions(ctx _context.Context, localVarOptionals *ReadDhcpOptionsOpts) (ReadDhcpOptionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadDhcpOptionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadDhcpOptions" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadDhcpOptionsRequest.IsSet() { - localVarOptionalReadDhcpOptionsRequest, localVarOptionalReadDhcpOptionsRequestok := localVarOptionals.ReadDhcpOptionsRequest.Value().(ReadDhcpOptionsRequest) - if !localVarOptionalReadDhcpOptionsRequestok { - return localVarReturnValue, nil, reportError("readDhcpOptionsRequest should be ReadDhcpOptionsRequest") - } - localVarPostBody = &localVarOptionalReadDhcpOptionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadDhcpOptionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link.go deleted file mode 100644 index 6390991e4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link.go +++ /dev/null @@ -1,369 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// DirectLinkApiService DirectLinkApi service -type DirectLinkApiService service - -// CreateDirectLinkOpts Optional parameters for the method 'CreateDirectLink' -type CreateDirectLinkOpts struct { - CreateDirectLinkRequest optional.Interface -} - -/* -CreateDirectLink Method for CreateDirectLink - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateDirectLinkOpts - Optional Parameters: - * @param "CreateDirectLinkRequest" (optional.Interface of CreateDirectLinkRequest) - -@return CreateDirectLinkResponse -*/ -func (a *DirectLinkApiService) CreateDirectLink(ctx _context.Context, localVarOptionals *CreateDirectLinkOpts) (CreateDirectLinkResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateDirectLinkResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateDirectLink" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateDirectLinkRequest.IsSet() { - localVarOptionalCreateDirectLinkRequest, localVarOptionalCreateDirectLinkRequestok := localVarOptionals.CreateDirectLinkRequest.Value().(CreateDirectLinkRequest) - if !localVarOptionalCreateDirectLinkRequestok { - return localVarReturnValue, nil, reportError("createDirectLinkRequest should be CreateDirectLinkRequest") - } - localVarPostBody = &localVarOptionalCreateDirectLinkRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateDirectLinkResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteDirectLinkOpts Optional parameters for the method 'DeleteDirectLink' -type DeleteDirectLinkOpts struct { - DeleteDirectLinkRequest optional.Interface -} - -/* -DeleteDirectLink Method for DeleteDirectLink - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteDirectLinkOpts - Optional Parameters: - * @param "DeleteDirectLinkRequest" (optional.Interface of DeleteDirectLinkRequest) - -@return DeleteDirectLinkResponse -*/ -func (a *DirectLinkApiService) DeleteDirectLink(ctx _context.Context, localVarOptionals *DeleteDirectLinkOpts) (DeleteDirectLinkResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteDirectLinkResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteDirectLink" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteDirectLinkRequest.IsSet() { - localVarOptionalDeleteDirectLinkRequest, localVarOptionalDeleteDirectLinkRequestok := localVarOptionals.DeleteDirectLinkRequest.Value().(DeleteDirectLinkRequest) - if !localVarOptionalDeleteDirectLinkRequestok { - return localVarReturnValue, nil, reportError("deleteDirectLinkRequest should be DeleteDirectLinkRequest") - } - localVarPostBody = &localVarOptionalDeleteDirectLinkRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteDirectLinkResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadDirectLinksOpts Optional parameters for the method 'ReadDirectLinks' -type ReadDirectLinksOpts struct { - ReadDirectLinksRequest optional.Interface -} - -/* -ReadDirectLinks Method for ReadDirectLinks - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadDirectLinksOpts - Optional Parameters: - * @param "ReadDirectLinksRequest" (optional.Interface of ReadDirectLinksRequest) - -@return ReadDirectLinksResponse -*/ -func (a *DirectLinkApiService) ReadDirectLinks(ctx _context.Context, localVarOptionals *ReadDirectLinksOpts) (ReadDirectLinksResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadDirectLinksResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadDirectLinks" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadDirectLinksRequest.IsSet() { - localVarOptionalReadDirectLinksRequest, localVarOptionalReadDirectLinksRequestok := localVarOptionals.ReadDirectLinksRequest.Value().(ReadDirectLinksRequest) - if !localVarOptionalReadDirectLinksRequestok { - return localVarReturnValue, nil, reportError("readDirectLinksRequest should be ReadDirectLinksRequest") - } - localVarPostBody = &localVarOptionalReadDirectLinksRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadDirectLinksResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link_interface.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link_interface.go deleted file mode 100644 index 8ee74893c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_direct_link_interface.go +++ /dev/null @@ -1,369 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// DirectLinkInterfaceApiService DirectLinkInterfaceApi service -type DirectLinkInterfaceApiService service - -// CreateDirectLinkInterfaceOpts Optional parameters for the method 'CreateDirectLinkInterface' -type CreateDirectLinkInterfaceOpts struct { - CreateDirectLinkInterfaceRequest optional.Interface -} - -/* -CreateDirectLinkInterface Method for CreateDirectLinkInterface - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateDirectLinkInterfaceOpts - Optional Parameters: - * @param "CreateDirectLinkInterfaceRequest" (optional.Interface of CreateDirectLinkInterfaceRequest) - -@return CreateDirectLinkInterfaceResponse -*/ -func (a *DirectLinkInterfaceApiService) CreateDirectLinkInterface(ctx _context.Context, localVarOptionals *CreateDirectLinkInterfaceOpts) (CreateDirectLinkInterfaceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateDirectLinkInterfaceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateDirectLinkInterface" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateDirectLinkInterfaceRequest.IsSet() { - localVarOptionalCreateDirectLinkInterfaceRequest, localVarOptionalCreateDirectLinkInterfaceRequestok := localVarOptionals.CreateDirectLinkInterfaceRequest.Value().(CreateDirectLinkInterfaceRequest) - if !localVarOptionalCreateDirectLinkInterfaceRequestok { - return localVarReturnValue, nil, reportError("createDirectLinkInterfaceRequest should be CreateDirectLinkInterfaceRequest") - } - localVarPostBody = &localVarOptionalCreateDirectLinkInterfaceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateDirectLinkInterfaceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteDirectLinkInterfaceOpts Optional parameters for the method 'DeleteDirectLinkInterface' -type DeleteDirectLinkInterfaceOpts struct { - DeleteDirectLinkInterfaceRequest optional.Interface -} - -/* -DeleteDirectLinkInterface Method for DeleteDirectLinkInterface - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteDirectLinkInterfaceOpts - Optional Parameters: - * @param "DeleteDirectLinkInterfaceRequest" (optional.Interface of DeleteDirectLinkInterfaceRequest) - -@return DeleteDirectLinkInterfaceResponse -*/ -func (a *DirectLinkInterfaceApiService) DeleteDirectLinkInterface(ctx _context.Context, localVarOptionals *DeleteDirectLinkInterfaceOpts) (DeleteDirectLinkInterfaceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteDirectLinkInterfaceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteDirectLinkInterface" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteDirectLinkInterfaceRequest.IsSet() { - localVarOptionalDeleteDirectLinkInterfaceRequest, localVarOptionalDeleteDirectLinkInterfaceRequestok := localVarOptionals.DeleteDirectLinkInterfaceRequest.Value().(DeleteDirectLinkInterfaceRequest) - if !localVarOptionalDeleteDirectLinkInterfaceRequestok { - return localVarReturnValue, nil, reportError("deleteDirectLinkInterfaceRequest should be DeleteDirectLinkInterfaceRequest") - } - localVarPostBody = &localVarOptionalDeleteDirectLinkInterfaceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteDirectLinkInterfaceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadDirectLinkInterfacesOpts Optional parameters for the method 'ReadDirectLinkInterfaces' -type ReadDirectLinkInterfacesOpts struct { - ReadDirectLinkInterfacesRequest optional.Interface -} - -/* -ReadDirectLinkInterfaces Method for ReadDirectLinkInterfaces - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadDirectLinkInterfacesOpts - Optional Parameters: - * @param "ReadDirectLinkInterfacesRequest" (optional.Interface of ReadDirectLinkInterfacesRequest) - -@return ReadDirectLinkInterfacesResponse -*/ -func (a *DirectLinkInterfaceApiService) ReadDirectLinkInterfaces(ctx _context.Context, localVarOptionals *ReadDirectLinkInterfacesOpts) (ReadDirectLinkInterfacesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadDirectLinkInterfacesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadDirectLinkInterfaces" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadDirectLinkInterfacesRequest.IsSet() { - localVarOptionalReadDirectLinkInterfacesRequest, localVarOptionalReadDirectLinkInterfacesRequestok := localVarOptionals.ReadDirectLinkInterfacesRequest.Value().(ReadDirectLinkInterfacesRequest) - if !localVarOptionalReadDirectLinkInterfacesRequestok { - return localVarReturnValue, nil, reportError("readDirectLinkInterfacesRequest should be ReadDirectLinkInterfacesRequest") - } - localVarPostBody = &localVarOptionalReadDirectLinkInterfacesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadDirectLinkInterfacesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_flexible_gpu.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_flexible_gpu.go deleted file mode 100644 index 89fe90b6a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_flexible_gpu.go +++ /dev/null @@ -1,811 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// FlexibleGpuApiService FlexibleGpuApi service -type FlexibleGpuApiService service - -// CreateFlexibleGpuOpts Optional parameters for the method 'CreateFlexibleGpu' -type CreateFlexibleGpuOpts struct { - CreateFlexibleGpuRequest optional.Interface -} - -/* -CreateFlexibleGpu Method for CreateFlexibleGpu - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateFlexibleGpuOpts - Optional Parameters: - * @param "CreateFlexibleGpuRequest" (optional.Interface of CreateFlexibleGpuRequest) - -@return CreateFlexibleGpuResponse -*/ -func (a *FlexibleGpuApiService) CreateFlexibleGpu(ctx _context.Context, localVarOptionals *CreateFlexibleGpuOpts) (CreateFlexibleGpuResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateFlexibleGpuResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateFlexibleGpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateFlexibleGpuRequest.IsSet() { - localVarOptionalCreateFlexibleGpuRequest, localVarOptionalCreateFlexibleGpuRequestok := localVarOptionals.CreateFlexibleGpuRequest.Value().(CreateFlexibleGpuRequest) - if !localVarOptionalCreateFlexibleGpuRequestok { - return localVarReturnValue, nil, reportError("createFlexibleGpuRequest should be CreateFlexibleGpuRequest") - } - localVarPostBody = &localVarOptionalCreateFlexibleGpuRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateFlexibleGpuResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteFlexibleGpuOpts Optional parameters for the method 'DeleteFlexibleGpu' -type DeleteFlexibleGpuOpts struct { - DeleteFlexibleGpuRequest optional.Interface -} - -/* -DeleteFlexibleGpu Method for DeleteFlexibleGpu - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteFlexibleGpuOpts - Optional Parameters: - * @param "DeleteFlexibleGpuRequest" (optional.Interface of DeleteFlexibleGpuRequest) - -@return DeleteFlexibleGpuResponse -*/ -func (a *FlexibleGpuApiService) DeleteFlexibleGpu(ctx _context.Context, localVarOptionals *DeleteFlexibleGpuOpts) (DeleteFlexibleGpuResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteFlexibleGpuResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteFlexibleGpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteFlexibleGpuRequest.IsSet() { - localVarOptionalDeleteFlexibleGpuRequest, localVarOptionalDeleteFlexibleGpuRequestok := localVarOptionals.DeleteFlexibleGpuRequest.Value().(DeleteFlexibleGpuRequest) - if !localVarOptionalDeleteFlexibleGpuRequestok { - return localVarReturnValue, nil, reportError("deleteFlexibleGpuRequest should be DeleteFlexibleGpuRequest") - } - localVarPostBody = &localVarOptionalDeleteFlexibleGpuRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteFlexibleGpuResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkFlexibleGpuOpts Optional parameters for the method 'LinkFlexibleGpu' -type LinkFlexibleGpuOpts struct { - LinkFlexibleGpuRequest optional.Interface -} - -/* -LinkFlexibleGpu Method for LinkFlexibleGpu - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkFlexibleGpuOpts - Optional Parameters: - * @param "LinkFlexibleGpuRequest" (optional.Interface of LinkFlexibleGpuRequest) - -@return LinkFlexibleGpuResponse -*/ -func (a *FlexibleGpuApiService) LinkFlexibleGpu(ctx _context.Context, localVarOptionals *LinkFlexibleGpuOpts) (LinkFlexibleGpuResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkFlexibleGpuResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkFlexibleGpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkFlexibleGpuRequest.IsSet() { - localVarOptionalLinkFlexibleGpuRequest, localVarOptionalLinkFlexibleGpuRequestok := localVarOptionals.LinkFlexibleGpuRequest.Value().(LinkFlexibleGpuRequest) - if !localVarOptionalLinkFlexibleGpuRequestok { - return localVarReturnValue, nil, reportError("linkFlexibleGpuRequest should be LinkFlexibleGpuRequest") - } - localVarPostBody = &localVarOptionalLinkFlexibleGpuRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkFlexibleGpuResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadFlexibleGpuCatalogOpts Optional parameters for the method 'ReadFlexibleGpuCatalog' -type ReadFlexibleGpuCatalogOpts struct { - ReadFlexibleGpuCatalogRequest optional.Interface -} - -/* -ReadFlexibleGpuCatalog Method for ReadFlexibleGpuCatalog - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadFlexibleGpuCatalogOpts - Optional Parameters: - * @param "ReadFlexibleGpuCatalogRequest" (optional.Interface of ReadFlexibleGpuCatalogRequest) - -@return ReadFlexibleGpuCatalogResponse -*/ -func (a *FlexibleGpuApiService) ReadFlexibleGpuCatalog(ctx _context.Context, localVarOptionals *ReadFlexibleGpuCatalogOpts) (ReadFlexibleGpuCatalogResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadFlexibleGpuCatalogResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadFlexibleGpuCatalog" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadFlexibleGpuCatalogRequest.IsSet() { - localVarOptionalReadFlexibleGpuCatalogRequest, localVarOptionalReadFlexibleGpuCatalogRequestok := localVarOptionals.ReadFlexibleGpuCatalogRequest.Value().(ReadFlexibleGpuCatalogRequest) - if !localVarOptionalReadFlexibleGpuCatalogRequestok { - return localVarReturnValue, nil, reportError("readFlexibleGpuCatalogRequest should be ReadFlexibleGpuCatalogRequest") - } - localVarPostBody = &localVarOptionalReadFlexibleGpuCatalogRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadFlexibleGpuCatalogResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadFlexibleGpusOpts Optional parameters for the method 'ReadFlexibleGpus' -type ReadFlexibleGpusOpts struct { - ReadFlexibleGpusRequest optional.Interface -} - -/* -ReadFlexibleGpus Method for ReadFlexibleGpus - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadFlexibleGpusOpts - Optional Parameters: - * @param "ReadFlexibleGpusRequest" (optional.Interface of ReadFlexibleGpusRequest) - -@return ReadFlexibleGpusResponse -*/ -func (a *FlexibleGpuApiService) ReadFlexibleGpus(ctx _context.Context, localVarOptionals *ReadFlexibleGpusOpts) (ReadFlexibleGpusResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadFlexibleGpusResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadFlexibleGpus" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadFlexibleGpusRequest.IsSet() { - localVarOptionalReadFlexibleGpusRequest, localVarOptionalReadFlexibleGpusRequestok := localVarOptionals.ReadFlexibleGpusRequest.Value().(ReadFlexibleGpusRequest) - if !localVarOptionalReadFlexibleGpusRequestok { - return localVarReturnValue, nil, reportError("readFlexibleGpusRequest should be ReadFlexibleGpusRequest") - } - localVarPostBody = &localVarOptionalReadFlexibleGpusRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadFlexibleGpusResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkFlexibleGpuOpts Optional parameters for the method 'UnlinkFlexibleGpu' -type UnlinkFlexibleGpuOpts struct { - UnlinkFlexibleGpuRequest optional.Interface -} - -/* -UnlinkFlexibleGpu Method for UnlinkFlexibleGpu - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkFlexibleGpuOpts - Optional Parameters: - * @param "UnlinkFlexibleGpuRequest" (optional.Interface of UnlinkFlexibleGpuRequest) - -@return UnlinkFlexibleGpuResponse -*/ -func (a *FlexibleGpuApiService) UnlinkFlexibleGpu(ctx _context.Context, localVarOptionals *UnlinkFlexibleGpuOpts) (UnlinkFlexibleGpuResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkFlexibleGpuResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkFlexibleGpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkFlexibleGpuRequest.IsSet() { - localVarOptionalUnlinkFlexibleGpuRequest, localVarOptionalUnlinkFlexibleGpuRequestok := localVarOptionals.UnlinkFlexibleGpuRequest.Value().(UnlinkFlexibleGpuRequest) - if !localVarOptionalUnlinkFlexibleGpuRequestok { - return localVarReturnValue, nil, reportError("unlinkFlexibleGpuRequest should be UnlinkFlexibleGpuRequest") - } - localVarPostBody = &localVarOptionalUnlinkFlexibleGpuRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkFlexibleGpuResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateFlexibleGpuOpts Optional parameters for the method 'UpdateFlexibleGpu' -type UpdateFlexibleGpuOpts struct { - UpdateFlexibleGpuRequest optional.Interface -} - -/* -UpdateFlexibleGpu Method for UpdateFlexibleGpu - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateFlexibleGpuOpts - Optional Parameters: - * @param "UpdateFlexibleGpuRequest" (optional.Interface of UpdateFlexibleGpuRequest) - -@return UpdateFlexibleGpuResponse -*/ -func (a *FlexibleGpuApiService) UpdateFlexibleGpu(ctx _context.Context, localVarOptionals *UpdateFlexibleGpuOpts) (UpdateFlexibleGpuResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateFlexibleGpuResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateFlexibleGpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateFlexibleGpuRequest.IsSet() { - localVarOptionalUpdateFlexibleGpuRequest, localVarOptionalUpdateFlexibleGpuRequestok := localVarOptionals.UpdateFlexibleGpuRequest.Value().(UpdateFlexibleGpuRequest) - if !localVarOptionalUpdateFlexibleGpuRequestok { - return localVarReturnValue, nil, reportError("updateFlexibleGpuRequest should be UpdateFlexibleGpuRequest") - } - localVarPostBody = &localVarOptionalUpdateFlexibleGpuRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateFlexibleGpuResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_image.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_image.go deleted file mode 100644 index 9f3e63b91..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_image.go +++ /dev/null @@ -1,832 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// ImageApiService ImageApi service -type ImageApiService service - -// CreateImageOpts Optional parameters for the method 'CreateImage' -type CreateImageOpts struct { - CreateImageRequest optional.Interface -} - -/* -CreateImage Method for CreateImage - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateImageOpts - Optional Parameters: - * @param "CreateImageRequest" (optional.Interface of CreateImageRequest) - -@return CreateImageResponse -*/ -func (a *ImageApiService) CreateImage(ctx _context.Context, localVarOptionals *CreateImageOpts) (CreateImageResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateImageResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateImage" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateImageRequest.IsSet() { - localVarOptionalCreateImageRequest, localVarOptionalCreateImageRequestok := localVarOptionals.CreateImageRequest.Value().(CreateImageRequest) - if !localVarOptionalCreateImageRequestok { - return localVarReturnValue, nil, reportError("createImageRequest should be CreateImageRequest") - } - localVarPostBody = &localVarOptionalCreateImageRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateImageResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateImageExportTaskOpts Optional parameters for the method 'CreateImageExportTask' -type CreateImageExportTaskOpts struct { - CreateImageExportTaskRequest optional.Interface -} - -/* -CreateImageExportTask Method for CreateImageExportTask - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateImageExportTaskOpts - Optional Parameters: - * @param "CreateImageExportTaskRequest" (optional.Interface of CreateImageExportTaskRequest) - -@return CreateImageExportTaskResponse -*/ -func (a *ImageApiService) CreateImageExportTask(ctx _context.Context, localVarOptionals *CreateImageExportTaskOpts) (CreateImageExportTaskResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateImageExportTaskResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateImageExportTask" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateImageExportTaskRequest.IsSet() { - localVarOptionalCreateImageExportTaskRequest, localVarOptionalCreateImageExportTaskRequestok := localVarOptionals.CreateImageExportTaskRequest.Value().(CreateImageExportTaskRequest) - if !localVarOptionalCreateImageExportTaskRequestok { - return localVarReturnValue, nil, reportError("createImageExportTaskRequest should be CreateImageExportTaskRequest") - } - localVarPostBody = &localVarOptionalCreateImageExportTaskRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateImageExportTaskResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteImageOpts Optional parameters for the method 'DeleteImage' -type DeleteImageOpts struct { - DeleteImageRequest optional.Interface -} - -/* -DeleteImage Method for DeleteImage - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteImageOpts - Optional Parameters: - * @param "DeleteImageRequest" (optional.Interface of DeleteImageRequest) - -@return DeleteImageResponse -*/ -func (a *ImageApiService) DeleteImage(ctx _context.Context, localVarOptionals *DeleteImageOpts) (DeleteImageResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteImageResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteImage" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteImageRequest.IsSet() { - localVarOptionalDeleteImageRequest, localVarOptionalDeleteImageRequestok := localVarOptionals.DeleteImageRequest.Value().(DeleteImageRequest) - if !localVarOptionalDeleteImageRequestok { - return localVarReturnValue, nil, reportError("deleteImageRequest should be DeleteImageRequest") - } - localVarPostBody = &localVarOptionalDeleteImageRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteImageResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadImageExportTasksOpts Optional parameters for the method 'ReadImageExportTasks' -type ReadImageExportTasksOpts struct { - ReadImageExportTasksRequest optional.Interface -} - -/* -ReadImageExportTasks Method for ReadImageExportTasks - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadImageExportTasksOpts - Optional Parameters: - * @param "ReadImageExportTasksRequest" (optional.Interface of ReadImageExportTasksRequest) - -@return ReadImageExportTasksResponse -*/ -func (a *ImageApiService) ReadImageExportTasks(ctx _context.Context, localVarOptionals *ReadImageExportTasksOpts) (ReadImageExportTasksResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadImageExportTasksResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadImageExportTasks" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadImageExportTasksRequest.IsSet() { - localVarOptionalReadImageExportTasksRequest, localVarOptionalReadImageExportTasksRequestok := localVarOptionals.ReadImageExportTasksRequest.Value().(ReadImageExportTasksRequest) - if !localVarOptionalReadImageExportTasksRequestok { - return localVarReturnValue, nil, reportError("readImageExportTasksRequest should be ReadImageExportTasksRequest") - } - localVarPostBody = &localVarOptionalReadImageExportTasksRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadImageExportTasksResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadImagesOpts Optional parameters for the method 'ReadImages' -type ReadImagesOpts struct { - ReadImagesRequest optional.Interface -} - -/* -ReadImages Method for ReadImages - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadImagesOpts - Optional Parameters: - * @param "ReadImagesRequest" (optional.Interface of ReadImagesRequest) - -@return ReadImagesResponse -*/ -func (a *ImageApiService) ReadImages(ctx _context.Context, localVarOptionals *ReadImagesOpts) (ReadImagesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadImagesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadImages" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadImagesRequest.IsSet() { - localVarOptionalReadImagesRequest, localVarOptionalReadImagesRequestok := localVarOptionals.ReadImagesRequest.Value().(ReadImagesRequest) - if !localVarOptionalReadImagesRequestok { - return localVarReturnValue, nil, reportError("readImagesRequest should be ReadImagesRequest") - } - localVarPostBody = &localVarOptionalReadImagesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadImagesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateImageOpts Optional parameters for the method 'UpdateImage' -type UpdateImageOpts struct { - UpdateImageRequest optional.Interface -} - -/* -UpdateImage Method for UpdateImage - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateImageOpts - Optional Parameters: - * @param "UpdateImageRequest" (optional.Interface of UpdateImageRequest) - -@return UpdateImageResponse -*/ -func (a *ImageApiService) UpdateImage(ctx _context.Context, localVarOptionals *UpdateImageOpts) (UpdateImageResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateImageResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateImage" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateImageRequest.IsSet() { - localVarOptionalUpdateImageRequest, localVarOptionalUpdateImageRequestok := localVarOptionals.UpdateImageRequest.Value().(UpdateImageRequest) - if !localVarOptionalUpdateImageRequestok { - return localVarReturnValue, nil, reportError("updateImageRequest should be UpdateImageRequest") - } - localVarPostBody = &localVarOptionalUpdateImageRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateImageResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_internet_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_internet_service.go deleted file mode 100644 index 48b6ba55a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_internet_service.go +++ /dev/null @@ -1,748 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// InternetServiceApiService InternetServiceApi service -type InternetServiceApiService service - -// CreateInternetServiceOpts Optional parameters for the method 'CreateInternetService' -type CreateInternetServiceOpts struct { - CreateInternetServiceRequest optional.Interface -} - -/* -CreateInternetService Method for CreateInternetService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateInternetServiceOpts - Optional Parameters: - * @param "CreateInternetServiceRequest" (optional.Interface of CreateInternetServiceRequest) - -@return CreateInternetServiceResponse -*/ -func (a *InternetServiceApiService) CreateInternetService(ctx _context.Context, localVarOptionals *CreateInternetServiceOpts) (CreateInternetServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateInternetServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateInternetService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateInternetServiceRequest.IsSet() { - localVarOptionalCreateInternetServiceRequest, localVarOptionalCreateInternetServiceRequestok := localVarOptionals.CreateInternetServiceRequest.Value().(CreateInternetServiceRequest) - if !localVarOptionalCreateInternetServiceRequestok { - return localVarReturnValue, nil, reportError("createInternetServiceRequest should be CreateInternetServiceRequest") - } - localVarPostBody = &localVarOptionalCreateInternetServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateInternetServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteInternetServiceOpts Optional parameters for the method 'DeleteInternetService' -type DeleteInternetServiceOpts struct { - DeleteInternetServiceRequest optional.Interface -} - -/* -DeleteInternetService Method for DeleteInternetService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteInternetServiceOpts - Optional Parameters: - * @param "DeleteInternetServiceRequest" (optional.Interface of DeleteInternetServiceRequest) - -@return DeleteInternetServiceResponse -*/ -func (a *InternetServiceApiService) DeleteInternetService(ctx _context.Context, localVarOptionals *DeleteInternetServiceOpts) (DeleteInternetServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteInternetServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteInternetService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteInternetServiceRequest.IsSet() { - localVarOptionalDeleteInternetServiceRequest, localVarOptionalDeleteInternetServiceRequestok := localVarOptionals.DeleteInternetServiceRequest.Value().(DeleteInternetServiceRequest) - if !localVarOptionalDeleteInternetServiceRequestok { - return localVarReturnValue, nil, reportError("deleteInternetServiceRequest should be DeleteInternetServiceRequest") - } - localVarPostBody = &localVarOptionalDeleteInternetServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteInternetServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkInternetServiceOpts Optional parameters for the method 'LinkInternetService' -type LinkInternetServiceOpts struct { - LinkInternetServiceRequest optional.Interface -} - -/* -LinkInternetService Method for LinkInternetService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkInternetServiceOpts - Optional Parameters: - * @param "LinkInternetServiceRequest" (optional.Interface of LinkInternetServiceRequest) - -@return LinkInternetServiceResponse -*/ -func (a *InternetServiceApiService) LinkInternetService(ctx _context.Context, localVarOptionals *LinkInternetServiceOpts) (LinkInternetServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkInternetServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkInternetService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkInternetServiceRequest.IsSet() { - localVarOptionalLinkInternetServiceRequest, localVarOptionalLinkInternetServiceRequestok := localVarOptionals.LinkInternetServiceRequest.Value().(LinkInternetServiceRequest) - if !localVarOptionalLinkInternetServiceRequestok { - return localVarReturnValue, nil, reportError("linkInternetServiceRequest should be LinkInternetServiceRequest") - } - localVarPostBody = &localVarOptionalLinkInternetServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkInternetServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadInternetServicesOpts Optional parameters for the method 'ReadInternetServices' -type ReadInternetServicesOpts struct { - ReadInternetServicesRequest optional.Interface -} - -/* -ReadInternetServices Method for ReadInternetServices - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadInternetServicesOpts - Optional Parameters: - * @param "ReadInternetServicesRequest" (optional.Interface of ReadInternetServicesRequest) - -@return ReadInternetServicesResponse -*/ -func (a *InternetServiceApiService) ReadInternetServices(ctx _context.Context, localVarOptionals *ReadInternetServicesOpts) (ReadInternetServicesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadInternetServicesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadInternetServices" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadInternetServicesRequest.IsSet() { - localVarOptionalReadInternetServicesRequest, localVarOptionalReadInternetServicesRequestok := localVarOptionals.ReadInternetServicesRequest.Value().(ReadInternetServicesRequest) - if !localVarOptionalReadInternetServicesRequestok { - return localVarReturnValue, nil, reportError("readInternetServicesRequest should be ReadInternetServicesRequest") - } - localVarPostBody = &localVarOptionalReadInternetServicesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadInternetServicesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkInternetServiceOpts Optional parameters for the method 'UnlinkInternetService' -type UnlinkInternetServiceOpts struct { - UnlinkInternetServiceRequest optional.Interface -} - -/* -UnlinkInternetService Method for UnlinkInternetService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkInternetServiceOpts - Optional Parameters: - * @param "UnlinkInternetServiceRequest" (optional.Interface of UnlinkInternetServiceRequest) - -@return UnlinkInternetServiceResponse -*/ -func (a *InternetServiceApiService) UnlinkInternetService(ctx _context.Context, localVarOptionals *UnlinkInternetServiceOpts) (UnlinkInternetServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkInternetServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkInternetService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkInternetServiceRequest.IsSet() { - localVarOptionalUnlinkInternetServiceRequest, localVarOptionalUnlinkInternetServiceRequestok := localVarOptionals.UnlinkInternetServiceRequest.Value().(UnlinkInternetServiceRequest) - if !localVarOptionalUnlinkInternetServiceRequestok { - return localVarReturnValue, nil, reportError("unlinkInternetServiceRequest should be UnlinkInternetServiceRequest") - } - localVarPostBody = &localVarOptionalUnlinkInternetServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkInternetServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_keypair.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_keypair.go deleted file mode 100644 index 289c56e50..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_keypair.go +++ /dev/null @@ -1,470 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// KeypairApiService KeypairApi service -type KeypairApiService service - -// CreateKeypairOpts Optional parameters for the method 'CreateKeypair' -type CreateKeypairOpts struct { - CreateKeypairRequest optional.Interface -} - -/* -CreateKeypair Method for CreateKeypair - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateKeypairOpts - Optional Parameters: - * @param "CreateKeypairRequest" (optional.Interface of CreateKeypairRequest) - -@return CreateKeypairResponse -*/ -func (a *KeypairApiService) CreateKeypair(ctx _context.Context, localVarOptionals *CreateKeypairOpts) (CreateKeypairResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateKeypairResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateKeypair" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateKeypairRequest.IsSet() { - localVarOptionalCreateKeypairRequest, localVarOptionalCreateKeypairRequestok := localVarOptionals.CreateKeypairRequest.Value().(CreateKeypairRequest) - if !localVarOptionalCreateKeypairRequestok { - return localVarReturnValue, nil, reportError("createKeypairRequest should be CreateKeypairRequest") - } - localVarPostBody = &localVarOptionalCreateKeypairRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateKeypairResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteKeypairOpts Optional parameters for the method 'DeleteKeypair' -type DeleteKeypairOpts struct { - DeleteKeypairRequest optional.Interface -} - -/* -DeleteKeypair Method for DeleteKeypair - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteKeypairOpts - Optional Parameters: - * @param "DeleteKeypairRequest" (optional.Interface of DeleteKeypairRequest) - -@return DeleteKeypairResponse -*/ -func (a *KeypairApiService) DeleteKeypair(ctx _context.Context, localVarOptionals *DeleteKeypairOpts) (DeleteKeypairResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteKeypairResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteKeypair" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteKeypairRequest.IsSet() { - localVarOptionalDeleteKeypairRequest, localVarOptionalDeleteKeypairRequestok := localVarOptionals.DeleteKeypairRequest.Value().(DeleteKeypairRequest) - if !localVarOptionalDeleteKeypairRequestok { - return localVarReturnValue, nil, reportError("deleteKeypairRequest should be DeleteKeypairRequest") - } - localVarPostBody = &localVarOptionalDeleteKeypairRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteKeypairResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadKeypairsOpts Optional parameters for the method 'ReadKeypairs' -type ReadKeypairsOpts struct { - ReadKeypairsRequest optional.Interface -} - -/* -ReadKeypairs Method for ReadKeypairs - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadKeypairsOpts - Optional Parameters: - * @param "ReadKeypairsRequest" (optional.Interface of ReadKeypairsRequest) - -@return ReadKeypairsResponse -*/ -func (a *KeypairApiService) ReadKeypairs(ctx _context.Context, localVarOptionals *ReadKeypairsOpts) (ReadKeypairsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadKeypairsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadKeypairs" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadKeypairsRequest.IsSet() { - localVarOptionalReadKeypairsRequest, localVarOptionalReadKeypairsRequestok := localVarOptionals.ReadKeypairsRequest.Value().(ReadKeypairsRequest) - if !localVarOptionalReadKeypairsRequestok { - return localVarReturnValue, nil, reportError("readKeypairsRequest should be ReadKeypairsRequest") - } - localVarPostBody = &localVarOptionalReadKeypairsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadKeypairsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_listener.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_listener.go deleted file mode 100644 index acf48d18c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_listener.go +++ /dev/null @@ -1,711 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// ListenerApiService ListenerApi service -type ListenerApiService service - -// CreateListenerRuleOpts Optional parameters for the method 'CreateListenerRule' -type CreateListenerRuleOpts struct { - CreateListenerRuleRequest optional.Interface -} - -/* -CreateListenerRule Method for CreateListenerRule - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateListenerRuleOpts - Optional Parameters: - * @param "CreateListenerRuleRequest" (optional.Interface of CreateListenerRuleRequest) - -@return CreateListenerRuleResponse -*/ -func (a *ListenerApiService) CreateListenerRule(ctx _context.Context, localVarOptionals *CreateListenerRuleOpts) (CreateListenerRuleResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateListenerRuleResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateListenerRule" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateListenerRuleRequest.IsSet() { - localVarOptionalCreateListenerRuleRequest, localVarOptionalCreateListenerRuleRequestok := localVarOptionals.CreateListenerRuleRequest.Value().(CreateListenerRuleRequest) - if !localVarOptionalCreateListenerRuleRequestok { - return localVarReturnValue, nil, reportError("createListenerRuleRequest should be CreateListenerRuleRequest") - } - localVarPostBody = &localVarOptionalCreateListenerRuleRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateListenerRuleResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateLoadBalancerListenersOpts Optional parameters for the method 'CreateLoadBalancerListeners' -type CreateLoadBalancerListenersOpts struct { - CreateLoadBalancerListenersRequest optional.Interface -} - -/* -CreateLoadBalancerListeners Method for CreateLoadBalancerListeners - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateLoadBalancerListenersOpts - Optional Parameters: - * @param "CreateLoadBalancerListenersRequest" (optional.Interface of CreateLoadBalancerListenersRequest) - -@return CreateLoadBalancerListenersResponse -*/ -func (a *ListenerApiService) CreateLoadBalancerListeners(ctx _context.Context, localVarOptionals *CreateLoadBalancerListenersOpts) (CreateLoadBalancerListenersResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateLoadBalancerListenersResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateLoadBalancerListeners" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateLoadBalancerListenersRequest.IsSet() { - localVarOptionalCreateLoadBalancerListenersRequest, localVarOptionalCreateLoadBalancerListenersRequestok := localVarOptionals.CreateLoadBalancerListenersRequest.Value().(CreateLoadBalancerListenersRequest) - if !localVarOptionalCreateLoadBalancerListenersRequestok { - return localVarReturnValue, nil, reportError("createLoadBalancerListenersRequest should be CreateLoadBalancerListenersRequest") - } - localVarPostBody = &localVarOptionalCreateLoadBalancerListenersRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateLoadBalancerListenersResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteListenerRuleOpts Optional parameters for the method 'DeleteListenerRule' -type DeleteListenerRuleOpts struct { - DeleteListenerRuleRequest optional.Interface -} - -/* -DeleteListenerRule Method for DeleteListenerRule - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteListenerRuleOpts - Optional Parameters: - * @param "DeleteListenerRuleRequest" (optional.Interface of DeleteListenerRuleRequest) - -@return DeleteListenerRuleResponse -*/ -func (a *ListenerApiService) DeleteListenerRule(ctx _context.Context, localVarOptionals *DeleteListenerRuleOpts) (DeleteListenerRuleResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteListenerRuleResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteListenerRule" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteListenerRuleRequest.IsSet() { - localVarOptionalDeleteListenerRuleRequest, localVarOptionalDeleteListenerRuleRequestok := localVarOptionals.DeleteListenerRuleRequest.Value().(DeleteListenerRuleRequest) - if !localVarOptionalDeleteListenerRuleRequestok { - return localVarReturnValue, nil, reportError("deleteListenerRuleRequest should be DeleteListenerRuleRequest") - } - localVarPostBody = &localVarOptionalDeleteListenerRuleRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteListenerRuleResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteLoadBalancerListenersOpts Optional parameters for the method 'DeleteLoadBalancerListeners' -type DeleteLoadBalancerListenersOpts struct { - DeleteLoadBalancerListenersRequest optional.Interface -} - -/* -DeleteLoadBalancerListeners Method for DeleteLoadBalancerListeners - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteLoadBalancerListenersOpts - Optional Parameters: - * @param "DeleteLoadBalancerListenersRequest" (optional.Interface of DeleteLoadBalancerListenersRequest) - -@return DeleteLoadBalancerListenersResponse -*/ -func (a *ListenerApiService) DeleteLoadBalancerListeners(ctx _context.Context, localVarOptionals *DeleteLoadBalancerListenersOpts) (DeleteLoadBalancerListenersResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteLoadBalancerListenersResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteLoadBalancerListeners" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteLoadBalancerListenersRequest.IsSet() { - localVarOptionalDeleteLoadBalancerListenersRequest, localVarOptionalDeleteLoadBalancerListenersRequestok := localVarOptionals.DeleteLoadBalancerListenersRequest.Value().(DeleteLoadBalancerListenersRequest) - if !localVarOptionalDeleteLoadBalancerListenersRequestok { - return localVarReturnValue, nil, reportError("deleteLoadBalancerListenersRequest should be DeleteLoadBalancerListenersRequest") - } - localVarPostBody = &localVarOptionalDeleteLoadBalancerListenersRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteLoadBalancerListenersResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadListenerRulesOpts Optional parameters for the method 'ReadListenerRules' -type ReadListenerRulesOpts struct { - ReadListenerRulesRequest optional.Interface -} - -/* -ReadListenerRules Method for ReadListenerRules - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadListenerRulesOpts - Optional Parameters: - * @param "ReadListenerRulesRequest" (optional.Interface of ReadListenerRulesRequest) - -@return ReadListenerRulesResponse -*/ -func (a *ListenerApiService) ReadListenerRules(ctx _context.Context, localVarOptionals *ReadListenerRulesOpts) (ReadListenerRulesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadListenerRulesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadListenerRules" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadListenerRulesRequest.IsSet() { - localVarOptionalReadListenerRulesRequest, localVarOptionalReadListenerRulesRequestok := localVarOptionals.ReadListenerRulesRequest.Value().(ReadListenerRulesRequest) - if !localVarOptionalReadListenerRulesRequestok { - return localVarReturnValue, nil, reportError("readListenerRulesRequest should be ReadListenerRulesRequest") - } - localVarPostBody = &localVarOptionalReadListenerRulesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadListenerRulesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateListenerRuleOpts Optional parameters for the method 'UpdateListenerRule' -type UpdateListenerRuleOpts struct { - UpdateListenerRuleRequest optional.Interface -} - -/* -UpdateListenerRule Method for UpdateListenerRule - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateListenerRuleOpts - Optional Parameters: - * @param "UpdateListenerRuleRequest" (optional.Interface of UpdateListenerRuleRequest) - -@return UpdateListenerRuleResponse -*/ -func (a *ListenerApiService) UpdateListenerRule(ctx _context.Context, localVarOptionals *UpdateListenerRuleOpts) (UpdateListenerRuleResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateListenerRuleResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateListenerRule" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateListenerRuleRequest.IsSet() { - localVarOptionalUpdateListenerRuleRequest, localVarOptionalUpdateListenerRuleRequestok := localVarOptionals.UpdateListenerRuleRequest.Value().(UpdateListenerRuleRequest) - if !localVarOptionalUpdateListenerRuleRequestok { - return localVarReturnValue, nil, reportError("updateListenerRuleRequest should be UpdateListenerRuleRequest") - } - localVarPostBody = &localVarOptionalUpdateListenerRuleRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateListenerRuleResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer.go deleted file mode 100644 index cc869c1fd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer.go +++ /dev/null @@ -1,1167 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// LoadBalancerApiService LoadBalancerApi service -type LoadBalancerApiService service - -// CreateLoadBalancerOpts Optional parameters for the method 'CreateLoadBalancer' -type CreateLoadBalancerOpts struct { - CreateLoadBalancerRequest optional.Interface -} - -/* -CreateLoadBalancer Method for CreateLoadBalancer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateLoadBalancerOpts - Optional Parameters: - * @param "CreateLoadBalancerRequest" (optional.Interface of CreateLoadBalancerRequest) - -@return CreateLoadBalancerResponse -*/ -func (a *LoadBalancerApiService) CreateLoadBalancer(ctx _context.Context, localVarOptionals *CreateLoadBalancerOpts) (CreateLoadBalancerResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateLoadBalancerResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateLoadBalancer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateLoadBalancerRequest.IsSet() { - localVarOptionalCreateLoadBalancerRequest, localVarOptionalCreateLoadBalancerRequestok := localVarOptionals.CreateLoadBalancerRequest.Value().(CreateLoadBalancerRequest) - if !localVarOptionalCreateLoadBalancerRequestok { - return localVarReturnValue, nil, reportError("createLoadBalancerRequest should be CreateLoadBalancerRequest") - } - localVarPostBody = &localVarOptionalCreateLoadBalancerRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateLoadBalancerResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateLoadBalancerTagsOpts Optional parameters for the method 'CreateLoadBalancerTags' -type CreateLoadBalancerTagsOpts struct { - CreateLoadBalancerTagsRequest optional.Interface -} - -/* -CreateLoadBalancerTags Method for CreateLoadBalancerTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateLoadBalancerTagsOpts - Optional Parameters: - * @param "CreateLoadBalancerTagsRequest" (optional.Interface of CreateLoadBalancerTagsRequest) - -@return CreateLoadBalancerTagsResponse -*/ -func (a *LoadBalancerApiService) CreateLoadBalancerTags(ctx _context.Context, localVarOptionals *CreateLoadBalancerTagsOpts) (CreateLoadBalancerTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateLoadBalancerTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateLoadBalancerTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateLoadBalancerTagsRequest.IsSet() { - localVarOptionalCreateLoadBalancerTagsRequest, localVarOptionalCreateLoadBalancerTagsRequestok := localVarOptionals.CreateLoadBalancerTagsRequest.Value().(CreateLoadBalancerTagsRequest) - if !localVarOptionalCreateLoadBalancerTagsRequestok { - return localVarReturnValue, nil, reportError("createLoadBalancerTagsRequest should be CreateLoadBalancerTagsRequest") - } - localVarPostBody = &localVarOptionalCreateLoadBalancerTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateLoadBalancerTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteLoadBalancerOpts Optional parameters for the method 'DeleteLoadBalancer' -type DeleteLoadBalancerOpts struct { - DeleteLoadBalancerRequest optional.Interface -} - -/* -DeleteLoadBalancer Method for DeleteLoadBalancer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteLoadBalancerOpts - Optional Parameters: - * @param "DeleteLoadBalancerRequest" (optional.Interface of DeleteLoadBalancerRequest) - -@return DeleteLoadBalancerResponse -*/ -func (a *LoadBalancerApiService) DeleteLoadBalancer(ctx _context.Context, localVarOptionals *DeleteLoadBalancerOpts) (DeleteLoadBalancerResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteLoadBalancerResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteLoadBalancer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteLoadBalancerRequest.IsSet() { - localVarOptionalDeleteLoadBalancerRequest, localVarOptionalDeleteLoadBalancerRequestok := localVarOptionals.DeleteLoadBalancerRequest.Value().(DeleteLoadBalancerRequest) - if !localVarOptionalDeleteLoadBalancerRequestok { - return localVarReturnValue, nil, reportError("deleteLoadBalancerRequest should be DeleteLoadBalancerRequest") - } - localVarPostBody = &localVarOptionalDeleteLoadBalancerRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteLoadBalancerResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteLoadBalancerTagsOpts Optional parameters for the method 'DeleteLoadBalancerTags' -type DeleteLoadBalancerTagsOpts struct { - DeleteLoadBalancerTagsRequest optional.Interface -} - -/* -DeleteLoadBalancerTags Method for DeleteLoadBalancerTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteLoadBalancerTagsOpts - Optional Parameters: - * @param "DeleteLoadBalancerTagsRequest" (optional.Interface of DeleteLoadBalancerTagsRequest) - -@return DeleteLoadBalancerTagsResponse -*/ -func (a *LoadBalancerApiService) DeleteLoadBalancerTags(ctx _context.Context, localVarOptionals *DeleteLoadBalancerTagsOpts) (DeleteLoadBalancerTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteLoadBalancerTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteLoadBalancerTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteLoadBalancerTagsRequest.IsSet() { - localVarOptionalDeleteLoadBalancerTagsRequest, localVarOptionalDeleteLoadBalancerTagsRequestok := localVarOptionals.DeleteLoadBalancerTagsRequest.Value().(DeleteLoadBalancerTagsRequest) - if !localVarOptionalDeleteLoadBalancerTagsRequestok { - return localVarReturnValue, nil, reportError("deleteLoadBalancerTagsRequest should be DeleteLoadBalancerTagsRequest") - } - localVarPostBody = &localVarOptionalDeleteLoadBalancerTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteLoadBalancerTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeregisterVmsInLoadBalancerOpts Optional parameters for the method 'DeregisterVmsInLoadBalancer' -type DeregisterVmsInLoadBalancerOpts struct { - DeregisterVmsInLoadBalancerRequest optional.Interface -} - -/* -DeregisterVmsInLoadBalancer Method for DeregisterVmsInLoadBalancer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeregisterVmsInLoadBalancerOpts - Optional Parameters: - * @param "DeregisterVmsInLoadBalancerRequest" (optional.Interface of DeregisterVmsInLoadBalancerRequest) - -@return DeregisterVmsInLoadBalancerResponse -*/ -func (a *LoadBalancerApiService) DeregisterVmsInLoadBalancer(ctx _context.Context, localVarOptionals *DeregisterVmsInLoadBalancerOpts) (DeregisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeregisterVmsInLoadBalancerResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeregisterVmsInLoadBalancer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeregisterVmsInLoadBalancerRequest.IsSet() { - localVarOptionalDeregisterVmsInLoadBalancerRequest, localVarOptionalDeregisterVmsInLoadBalancerRequestok := localVarOptionals.DeregisterVmsInLoadBalancerRequest.Value().(DeregisterVmsInLoadBalancerRequest) - if !localVarOptionalDeregisterVmsInLoadBalancerRequestok { - return localVarReturnValue, nil, reportError("deregisterVmsInLoadBalancerRequest should be DeregisterVmsInLoadBalancerRequest") - } - localVarPostBody = &localVarOptionalDeregisterVmsInLoadBalancerRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeregisterVmsInLoadBalancerResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadLoadBalancerTagsOpts Optional parameters for the method 'ReadLoadBalancerTags' -type ReadLoadBalancerTagsOpts struct { - ReadLoadBalancerTagsRequest optional.Interface -} - -/* -ReadLoadBalancerTags Method for ReadLoadBalancerTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadLoadBalancerTagsOpts - Optional Parameters: - * @param "ReadLoadBalancerTagsRequest" (optional.Interface of ReadLoadBalancerTagsRequest) - -@return ReadLoadBalancerTagsResponse -*/ -func (a *LoadBalancerApiService) ReadLoadBalancerTags(ctx _context.Context, localVarOptionals *ReadLoadBalancerTagsOpts) (ReadLoadBalancerTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadLoadBalancerTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadLoadBalancerTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadLoadBalancerTagsRequest.IsSet() { - localVarOptionalReadLoadBalancerTagsRequest, localVarOptionalReadLoadBalancerTagsRequestok := localVarOptionals.ReadLoadBalancerTagsRequest.Value().(ReadLoadBalancerTagsRequest) - if !localVarOptionalReadLoadBalancerTagsRequestok { - return localVarReturnValue, nil, reportError("readLoadBalancerTagsRequest should be ReadLoadBalancerTagsRequest") - } - localVarPostBody = &localVarOptionalReadLoadBalancerTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadLoadBalancerTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadLoadBalancersOpts Optional parameters for the method 'ReadLoadBalancers' -type ReadLoadBalancersOpts struct { - ReadLoadBalancersRequest optional.Interface -} - -/* -ReadLoadBalancers Method for ReadLoadBalancers - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadLoadBalancersOpts - Optional Parameters: - * @param "ReadLoadBalancersRequest" (optional.Interface of ReadLoadBalancersRequest) - -@return ReadLoadBalancersResponse -*/ -func (a *LoadBalancerApiService) ReadLoadBalancers(ctx _context.Context, localVarOptionals *ReadLoadBalancersOpts) (ReadLoadBalancersResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadLoadBalancersResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadLoadBalancers" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadLoadBalancersRequest.IsSet() { - localVarOptionalReadLoadBalancersRequest, localVarOptionalReadLoadBalancersRequestok := localVarOptionals.ReadLoadBalancersRequest.Value().(ReadLoadBalancersRequest) - if !localVarOptionalReadLoadBalancersRequestok { - return localVarReturnValue, nil, reportError("readLoadBalancersRequest should be ReadLoadBalancersRequest") - } - localVarPostBody = &localVarOptionalReadLoadBalancersRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadLoadBalancersResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVmsHealthOpts Optional parameters for the method 'ReadVmsHealth' -type ReadVmsHealthOpts struct { - ReadVmsHealthRequest optional.Interface -} - -/* -ReadVmsHealth Method for ReadVmsHealth - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVmsHealthOpts - Optional Parameters: - * @param "ReadVmsHealthRequest" (optional.Interface of ReadVmsHealthRequest) - -@return ReadVmsHealthResponse -*/ -func (a *LoadBalancerApiService) ReadVmsHealth(ctx _context.Context, localVarOptionals *ReadVmsHealthOpts) (ReadVmsHealthResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVmsHealthResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVmsHealth" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVmsHealthRequest.IsSet() { - localVarOptionalReadVmsHealthRequest, localVarOptionalReadVmsHealthRequestok := localVarOptionals.ReadVmsHealthRequest.Value().(ReadVmsHealthRequest) - if !localVarOptionalReadVmsHealthRequestok { - return localVarReturnValue, nil, reportError("readVmsHealthRequest should be ReadVmsHealthRequest") - } - localVarPostBody = &localVarOptionalReadVmsHealthRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVmsHealthResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// RegisterVmsInLoadBalancerOpts Optional parameters for the method 'RegisterVmsInLoadBalancer' -type RegisterVmsInLoadBalancerOpts struct { - RegisterVmsInLoadBalancerRequest optional.Interface -} - -/* -RegisterVmsInLoadBalancer Method for RegisterVmsInLoadBalancer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *RegisterVmsInLoadBalancerOpts - Optional Parameters: - * @param "RegisterVmsInLoadBalancerRequest" (optional.Interface of RegisterVmsInLoadBalancerRequest) - -@return RegisterVmsInLoadBalancerResponse -*/ -func (a *LoadBalancerApiService) RegisterVmsInLoadBalancer(ctx _context.Context, localVarOptionals *RegisterVmsInLoadBalancerOpts) (RegisterVmsInLoadBalancerResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RegisterVmsInLoadBalancerResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/RegisterVmsInLoadBalancer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.RegisterVmsInLoadBalancerRequest.IsSet() { - localVarOptionalRegisterVmsInLoadBalancerRequest, localVarOptionalRegisterVmsInLoadBalancerRequestok := localVarOptionals.RegisterVmsInLoadBalancerRequest.Value().(RegisterVmsInLoadBalancerRequest) - if !localVarOptionalRegisterVmsInLoadBalancerRequestok { - return localVarReturnValue, nil, reportError("registerVmsInLoadBalancerRequest should be RegisterVmsInLoadBalancerRequest") - } - localVarPostBody = &localVarOptionalRegisterVmsInLoadBalancerRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v RegisterVmsInLoadBalancerResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateLoadBalancerOpts Optional parameters for the method 'UpdateLoadBalancer' -type UpdateLoadBalancerOpts struct { - UpdateLoadBalancerRequest optional.Interface -} - -/* -UpdateLoadBalancer Method for UpdateLoadBalancer - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateLoadBalancerOpts - Optional Parameters: - * @param "UpdateLoadBalancerRequest" (optional.Interface of UpdateLoadBalancerRequest) - -@return UpdateLoadBalancerResponse -*/ -func (a *LoadBalancerApiService) UpdateLoadBalancer(ctx _context.Context, localVarOptionals *UpdateLoadBalancerOpts) (UpdateLoadBalancerResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateLoadBalancerResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateLoadBalancer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateLoadBalancerRequest.IsSet() { - localVarOptionalUpdateLoadBalancerRequest, localVarOptionalUpdateLoadBalancerRequestok := localVarOptionals.UpdateLoadBalancerRequest.Value().(UpdateLoadBalancerRequest) - if !localVarOptionalUpdateLoadBalancerRequestok { - return localVarReturnValue, nil, reportError("updateLoadBalancerRequest should be UpdateLoadBalancerRequest") - } - localVarPostBody = &localVarOptionalUpdateLoadBalancerRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateLoadBalancerResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer_policy.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer_policy.go deleted file mode 100644 index 0d5f2564a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_load_balancer_policy.go +++ /dev/null @@ -1,255 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// LoadBalancerPolicyApiService LoadBalancerPolicyApi service -type LoadBalancerPolicyApiService service - -// CreateLoadBalancerPolicyOpts Optional parameters for the method 'CreateLoadBalancerPolicy' -type CreateLoadBalancerPolicyOpts struct { - CreateLoadBalancerPolicyRequest optional.Interface -} - -/* -CreateLoadBalancerPolicy Method for CreateLoadBalancerPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateLoadBalancerPolicyOpts - Optional Parameters: - * @param "CreateLoadBalancerPolicyRequest" (optional.Interface of CreateLoadBalancerPolicyRequest) - -@return CreateLoadBalancerPolicyResponse -*/ -func (a *LoadBalancerPolicyApiService) CreateLoadBalancerPolicy(ctx _context.Context, localVarOptionals *CreateLoadBalancerPolicyOpts) (CreateLoadBalancerPolicyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateLoadBalancerPolicyResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateLoadBalancerPolicy" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateLoadBalancerPolicyRequest.IsSet() { - localVarOptionalCreateLoadBalancerPolicyRequest, localVarOptionalCreateLoadBalancerPolicyRequestok := localVarOptionals.CreateLoadBalancerPolicyRequest.Value().(CreateLoadBalancerPolicyRequest) - if !localVarOptionalCreateLoadBalancerPolicyRequestok { - return localVarReturnValue, nil, reportError("createLoadBalancerPolicyRequest should be CreateLoadBalancerPolicyRequest") - } - localVarPostBody = &localVarOptionalCreateLoadBalancerPolicyRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateLoadBalancerPolicyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteLoadBalancerPolicyOpts Optional parameters for the method 'DeleteLoadBalancerPolicy' -type DeleteLoadBalancerPolicyOpts struct { - DeleteLoadBalancerPolicyRequest optional.Interface -} - -/* -DeleteLoadBalancerPolicy Method for DeleteLoadBalancerPolicy - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteLoadBalancerPolicyOpts - Optional Parameters: - * @param "DeleteLoadBalancerPolicyRequest" (optional.Interface of DeleteLoadBalancerPolicyRequest) - -@return DeleteLoadBalancerPolicyResponse -*/ -func (a *LoadBalancerPolicyApiService) DeleteLoadBalancerPolicy(ctx _context.Context, localVarOptionals *DeleteLoadBalancerPolicyOpts) (DeleteLoadBalancerPolicyResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteLoadBalancerPolicyResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteLoadBalancerPolicy" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteLoadBalancerPolicyRequest.IsSet() { - localVarOptionalDeleteLoadBalancerPolicyRequest, localVarOptionalDeleteLoadBalancerPolicyRequestok := localVarOptionals.DeleteLoadBalancerPolicyRequest.Value().(DeleteLoadBalancerPolicyRequest) - if !localVarOptionalDeleteLoadBalancerPolicyRequestok { - return localVarReturnValue, nil, reportError("deleteLoadBalancerPolicyRequest should be DeleteLoadBalancerPolicyRequest") - } - localVarPostBody = &localVarOptionalDeleteLoadBalancerPolicyRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteLoadBalancerPolicyResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_location.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_location.go deleted file mode 100644 index 54a2a1392..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_location.go +++ /dev/null @@ -1,127 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// LocationApiService LocationApi service -type LocationApiService service - -// ReadLocationsOpts Optional parameters for the method 'ReadLocations' -type ReadLocationsOpts struct { - ReadLocationsRequest optional.Interface -} - -/* -ReadLocations Method for ReadLocations - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadLocationsOpts - Optional Parameters: - * @param "ReadLocationsRequest" (optional.Interface of ReadLocationsRequest) - -@return ReadLocationsResponse -*/ -func (a *LocationApiService) ReadLocations(ctx _context.Context, localVarOptionals *ReadLocationsOpts) (ReadLocationsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadLocationsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadLocations" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadLocationsRequest.IsSet() { - localVarOptionalReadLocationsRequest, localVarOptionalReadLocationsRequestok := localVarOptionals.ReadLocationsRequest.Value().(ReadLocationsRequest) - if !localVarOptionalReadLocationsRequestok { - return localVarReturnValue, nil, reportError("readLocationsRequest should be ReadLocationsRequest") - } - localVarPostBody = &localVarOptionalReadLocationsRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadLocationsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_nat_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_nat_service.go deleted file mode 100644 index 5f4e73284..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_nat_service.go +++ /dev/null @@ -1,460 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// NatServiceApiService NatServiceApi service -type NatServiceApiService service - -// CreateNatServiceOpts Optional parameters for the method 'CreateNatService' -type CreateNatServiceOpts struct { - CreateNatServiceRequest optional.Interface -} - -/* -CreateNatService Method for CreateNatService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateNatServiceOpts - Optional Parameters: - * @param "CreateNatServiceRequest" (optional.Interface of CreateNatServiceRequest) - -@return CreateNatServiceResponse -*/ -func (a *NatServiceApiService) CreateNatService(ctx _context.Context, localVarOptionals *CreateNatServiceOpts) (CreateNatServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateNatServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateNatService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateNatServiceRequest.IsSet() { - localVarOptionalCreateNatServiceRequest, localVarOptionalCreateNatServiceRequestok := localVarOptionals.CreateNatServiceRequest.Value().(CreateNatServiceRequest) - if !localVarOptionalCreateNatServiceRequestok { - return localVarReturnValue, nil, reportError("createNatServiceRequest should be CreateNatServiceRequest") - } - localVarPostBody = &localVarOptionalCreateNatServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateNatServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteNatServiceOpts Optional parameters for the method 'DeleteNatService' -type DeleteNatServiceOpts struct { - DeleteNatServiceRequest optional.Interface -} - -/* -DeleteNatService Method for DeleteNatService - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteNatServiceOpts - Optional Parameters: - * @param "DeleteNatServiceRequest" (optional.Interface of DeleteNatServiceRequest) - -@return DeleteNatServiceResponse -*/ -func (a *NatServiceApiService) DeleteNatService(ctx _context.Context, localVarOptionals *DeleteNatServiceOpts) (DeleteNatServiceResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteNatServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteNatService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteNatServiceRequest.IsSet() { - localVarOptionalDeleteNatServiceRequest, localVarOptionalDeleteNatServiceRequestok := localVarOptionals.DeleteNatServiceRequest.Value().(DeleteNatServiceRequest) - if !localVarOptionalDeleteNatServiceRequestok { - return localVarReturnValue, nil, reportError("deleteNatServiceRequest should be DeleteNatServiceRequest") - } - localVarPostBody = &localVarOptionalDeleteNatServiceRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteNatServiceResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNatServicesOpts Optional parameters for the method 'ReadNatServices' -type ReadNatServicesOpts struct { - ReadNatServicesRequest optional.Interface -} - -/* -ReadNatServices Method for ReadNatServices - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNatServicesOpts - Optional Parameters: - * @param "ReadNatServicesRequest" (optional.Interface of ReadNatServicesRequest) - -@return ReadNatServicesResponse -*/ -func (a *NatServiceApiService) ReadNatServices(ctx _context.Context, localVarOptionals *ReadNatServicesOpts) (ReadNatServicesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNatServicesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNatServices" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNatServicesRequest.IsSet() { - localVarOptionalReadNatServicesRequest, localVarOptionalReadNatServicesRequestok := localVarOptionals.ReadNatServicesRequest.Value().(ReadNatServicesRequest) - if !localVarOptionalReadNatServicesRequestok { - return localVarReturnValue, nil, reportError("readNatServicesRequest should be ReadNatServicesRequest") - } - localVarPostBody = &localVarOptionalReadNatServicesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNatServicesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_net.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_net.go deleted file mode 100644 index ee6836ef6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_net.go +++ /dev/null @@ -1,614 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// NetApiService NetApi service -type NetApiService service - -// CreateNetOpts Optional parameters for the method 'CreateNet' -type CreateNetOpts struct { - CreateNetRequest optional.Interface -} - -/* -CreateNet Method for CreateNet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateNetOpts - Optional Parameters: - * @param "CreateNetRequest" (optional.Interface of CreateNetRequest) - -@return CreateNetResponse -*/ -func (a *NetApiService) CreateNet(ctx _context.Context, localVarOptionals *CreateNetOpts) (CreateNetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateNetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateNet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateNetRequest.IsSet() { - localVarOptionalCreateNetRequest, localVarOptionalCreateNetRequestok := localVarOptionals.CreateNetRequest.Value().(CreateNetRequest) - if !localVarOptionalCreateNetRequestok { - return localVarReturnValue, nil, reportError("createNetRequest should be CreateNetRequest") - } - localVarPostBody = &localVarOptionalCreateNetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateNetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteNetOpts Optional parameters for the method 'DeleteNet' -type DeleteNetOpts struct { - DeleteNetRequest optional.Interface -} - -/* -DeleteNet Method for DeleteNet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteNetOpts - Optional Parameters: - * @param "DeleteNetRequest" (optional.Interface of DeleteNetRequest) - -@return DeleteNetResponse -*/ -func (a *NetApiService) DeleteNet(ctx _context.Context, localVarOptionals *DeleteNetOpts) (DeleteNetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteNetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteNet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteNetRequest.IsSet() { - localVarOptionalDeleteNetRequest, localVarOptionalDeleteNetRequestok := localVarOptionals.DeleteNetRequest.Value().(DeleteNetRequest) - if !localVarOptionalDeleteNetRequestok { - return localVarReturnValue, nil, reportError("deleteNetRequest should be DeleteNetRequest") - } - localVarPostBody = &localVarOptionalDeleteNetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteNetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNetsOpts Optional parameters for the method 'ReadNets' -type ReadNetsOpts struct { - ReadNetsRequest optional.Interface -} - -/* -ReadNets Method for ReadNets - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNetsOpts - Optional Parameters: - * @param "ReadNetsRequest" (optional.Interface of ReadNetsRequest) - -@return ReadNetsResponse -*/ -func (a *NetApiService) ReadNets(ctx _context.Context, localVarOptionals *ReadNetsOpts) (ReadNetsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNetsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNetsRequest.IsSet() { - localVarOptionalReadNetsRequest, localVarOptionalReadNetsRequestok := localVarOptionals.ReadNetsRequest.Value().(ReadNetsRequest) - if !localVarOptionalReadNetsRequestok { - return localVarReturnValue, nil, reportError("readNetsRequest should be ReadNetsRequest") - } - localVarPostBody = &localVarOptionalReadNetsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNetsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateNetOpts Optional parameters for the method 'UpdateNet' -type UpdateNetOpts struct { - UpdateNetRequest optional.Interface -} - -/* -UpdateNet Method for UpdateNet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateNetOpts - Optional Parameters: - * @param "UpdateNetRequest" (optional.Interface of UpdateNetRequest) - -@return UpdateNetResponse -*/ -func (a *NetApiService) UpdateNet(ctx _context.Context, localVarOptionals *UpdateNetOpts) (UpdateNetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateNetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateNet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateNetRequest.IsSet() { - localVarOptionalUpdateNetRequest, localVarOptionalUpdateNetRequestok := localVarOptionals.UpdateNetRequest.Value().(UpdateNetRequest) - if !localVarOptionalUpdateNetRequestok { - return localVarReturnValue, nil, reportError("updateNetRequest should be UpdateNetRequest") - } - localVarPostBody = &localVarOptionalUpdateNetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateNetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_net_access_point.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_net_access_point.go deleted file mode 100644 index 1618c408d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_net_access_point.go +++ /dev/null @@ -1,583 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// NetAccessPointApiService NetAccessPointApi service -type NetAccessPointApiService service - -// CreateNetAccessPointOpts Optional parameters for the method 'CreateNetAccessPoint' -type CreateNetAccessPointOpts struct { - CreateNetAccessPointRequest optional.Interface -} - -/* -CreateNetAccessPoint Method for CreateNetAccessPoint - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateNetAccessPointOpts - Optional Parameters: - * @param "CreateNetAccessPointRequest" (optional.Interface of CreateNetAccessPointRequest) - -@return CreateNetAccessPointResponse -*/ -func (a *NetAccessPointApiService) CreateNetAccessPoint(ctx _context.Context, localVarOptionals *CreateNetAccessPointOpts) (CreateNetAccessPointResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateNetAccessPointResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateNetAccessPoint" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateNetAccessPointRequest.IsSet() { - localVarOptionalCreateNetAccessPointRequest, localVarOptionalCreateNetAccessPointRequestok := localVarOptionals.CreateNetAccessPointRequest.Value().(CreateNetAccessPointRequest) - if !localVarOptionalCreateNetAccessPointRequestok { - return localVarReturnValue, nil, reportError("createNetAccessPointRequest should be CreateNetAccessPointRequest") - } - localVarPostBody = &localVarOptionalCreateNetAccessPointRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateNetAccessPointResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteNetAccessPointOpts Optional parameters for the method 'DeleteNetAccessPoint' -type DeleteNetAccessPointOpts struct { - DeleteNetAccessPointRequest optional.Interface -} - -/* -DeleteNetAccessPoint Method for DeleteNetAccessPoint - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteNetAccessPointOpts - Optional Parameters: - * @param "DeleteNetAccessPointRequest" (optional.Interface of DeleteNetAccessPointRequest) - -@return DeleteNetAccessPointResponse -*/ -func (a *NetAccessPointApiService) DeleteNetAccessPoint(ctx _context.Context, localVarOptionals *DeleteNetAccessPointOpts) (DeleteNetAccessPointResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteNetAccessPointResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteNetAccessPoint" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteNetAccessPointRequest.IsSet() { - localVarOptionalDeleteNetAccessPointRequest, localVarOptionalDeleteNetAccessPointRequestok := localVarOptionals.DeleteNetAccessPointRequest.Value().(DeleteNetAccessPointRequest) - if !localVarOptionalDeleteNetAccessPointRequestok { - return localVarReturnValue, nil, reportError("deleteNetAccessPointRequest should be DeleteNetAccessPointRequest") - } - localVarPostBody = &localVarOptionalDeleteNetAccessPointRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteNetAccessPointResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNetAccessPointServicesOpts Optional parameters for the method 'ReadNetAccessPointServices' -type ReadNetAccessPointServicesOpts struct { - ReadNetAccessPointServicesRequest optional.Interface -} - -/* -ReadNetAccessPointServices Method for ReadNetAccessPointServices - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNetAccessPointServicesOpts - Optional Parameters: - * @param "ReadNetAccessPointServicesRequest" (optional.Interface of ReadNetAccessPointServicesRequest) - -@return ReadNetAccessPointServicesResponse -*/ -func (a *NetAccessPointApiService) ReadNetAccessPointServices(ctx _context.Context, localVarOptionals *ReadNetAccessPointServicesOpts) (ReadNetAccessPointServicesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNetAccessPointServicesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNetAccessPointServices" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNetAccessPointServicesRequest.IsSet() { - localVarOptionalReadNetAccessPointServicesRequest, localVarOptionalReadNetAccessPointServicesRequestok := localVarOptionals.ReadNetAccessPointServicesRequest.Value().(ReadNetAccessPointServicesRequest) - if !localVarOptionalReadNetAccessPointServicesRequestok { - return localVarReturnValue, nil, reportError("readNetAccessPointServicesRequest should be ReadNetAccessPointServicesRequest") - } - localVarPostBody = &localVarOptionalReadNetAccessPointServicesRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNetAccessPointServicesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNetAccessPointsOpts Optional parameters for the method 'ReadNetAccessPoints' -type ReadNetAccessPointsOpts struct { - ReadNetAccessPointsRequest optional.Interface -} - -/* -ReadNetAccessPoints Method for ReadNetAccessPoints - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNetAccessPointsOpts - Optional Parameters: - * @param "ReadNetAccessPointsRequest" (optional.Interface of ReadNetAccessPointsRequest) - -@return ReadNetAccessPointsResponse -*/ -func (a *NetAccessPointApiService) ReadNetAccessPoints(ctx _context.Context, localVarOptionals *ReadNetAccessPointsOpts) (ReadNetAccessPointsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNetAccessPointsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNetAccessPoints" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNetAccessPointsRequest.IsSet() { - localVarOptionalReadNetAccessPointsRequest, localVarOptionalReadNetAccessPointsRequestok := localVarOptionals.ReadNetAccessPointsRequest.Value().(ReadNetAccessPointsRequest) - if !localVarOptionalReadNetAccessPointsRequestok { - return localVarReturnValue, nil, reportError("readNetAccessPointsRequest should be ReadNetAccessPointsRequest") - } - localVarPostBody = &localVarOptionalReadNetAccessPointsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNetAccessPointsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateNetAccessPointOpts Optional parameters for the method 'UpdateNetAccessPoint' -type UpdateNetAccessPointOpts struct { - UpdateNetAccessPointRequest optional.Interface -} - -/* -UpdateNetAccessPoint Method for UpdateNetAccessPoint - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateNetAccessPointOpts - Optional Parameters: - * @param "UpdateNetAccessPointRequest" (optional.Interface of UpdateNetAccessPointRequest) - -@return UpdateNetAccessPointResponse -*/ -func (a *NetAccessPointApiService) UpdateNetAccessPoint(ctx _context.Context, localVarOptionals *UpdateNetAccessPointOpts) (UpdateNetAccessPointResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateNetAccessPointResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateNetAccessPoint" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateNetAccessPointRequest.IsSet() { - localVarOptionalUpdateNetAccessPointRequest, localVarOptionalUpdateNetAccessPointRequestok := localVarOptionals.UpdateNetAccessPointRequest.Value().(UpdateNetAccessPointRequest) - if !localVarOptionalUpdateNetAccessPointRequestok { - return localVarReturnValue, nil, reportError("updateNetAccessPointRequest should be UpdateNetAccessPointRequest") - } - localVarPostBody = &localVarOptionalUpdateNetAccessPointRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateNetAccessPointResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_net_peering.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_net_peering.go deleted file mode 100644 index b838780de..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_net_peering.go +++ /dev/null @@ -1,778 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// NetPeeringApiService NetPeeringApi service -type NetPeeringApiService service - -// AcceptNetPeeringOpts Optional parameters for the method 'AcceptNetPeering' -type AcceptNetPeeringOpts struct { - AcceptNetPeeringRequest optional.Interface -} - -/* -AcceptNetPeering Method for AcceptNetPeering - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *AcceptNetPeeringOpts - Optional Parameters: - * @param "AcceptNetPeeringRequest" (optional.Interface of AcceptNetPeeringRequest) - -@return AcceptNetPeeringResponse -*/ -func (a *NetPeeringApiService) AcceptNetPeering(ctx _context.Context, localVarOptionals *AcceptNetPeeringOpts) (AcceptNetPeeringResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue AcceptNetPeeringResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/AcceptNetPeering" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.AcceptNetPeeringRequest.IsSet() { - localVarOptionalAcceptNetPeeringRequest, localVarOptionalAcceptNetPeeringRequestok := localVarOptionals.AcceptNetPeeringRequest.Value().(AcceptNetPeeringRequest) - if !localVarOptionalAcceptNetPeeringRequestok { - return localVarReturnValue, nil, reportError("acceptNetPeeringRequest should be AcceptNetPeeringRequest") - } - localVarPostBody = &localVarOptionalAcceptNetPeeringRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v AcceptNetPeeringResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateNetPeeringOpts Optional parameters for the method 'CreateNetPeering' -type CreateNetPeeringOpts struct { - CreateNetPeeringRequest optional.Interface -} - -/* -CreateNetPeering Method for CreateNetPeering - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateNetPeeringOpts - Optional Parameters: - * @param "CreateNetPeeringRequest" (optional.Interface of CreateNetPeeringRequest) - -@return CreateNetPeeringResponse -*/ -func (a *NetPeeringApiService) CreateNetPeering(ctx _context.Context, localVarOptionals *CreateNetPeeringOpts) (CreateNetPeeringResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateNetPeeringResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateNetPeering" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateNetPeeringRequest.IsSet() { - localVarOptionalCreateNetPeeringRequest, localVarOptionalCreateNetPeeringRequestok := localVarOptionals.CreateNetPeeringRequest.Value().(CreateNetPeeringRequest) - if !localVarOptionalCreateNetPeeringRequestok { - return localVarReturnValue, nil, reportError("createNetPeeringRequest should be CreateNetPeeringRequest") - } - localVarPostBody = &localVarOptionalCreateNetPeeringRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateNetPeeringResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteNetPeeringOpts Optional parameters for the method 'DeleteNetPeering' -type DeleteNetPeeringOpts struct { - DeleteNetPeeringRequest optional.Interface -} - -/* -DeleteNetPeering Method for DeleteNetPeering - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteNetPeeringOpts - Optional Parameters: - * @param "DeleteNetPeeringRequest" (optional.Interface of DeleteNetPeeringRequest) - -@return DeleteNetPeeringResponse -*/ -func (a *NetPeeringApiService) DeleteNetPeering(ctx _context.Context, localVarOptionals *DeleteNetPeeringOpts) (DeleteNetPeeringResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteNetPeeringResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteNetPeering" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteNetPeeringRequest.IsSet() { - localVarOptionalDeleteNetPeeringRequest, localVarOptionalDeleteNetPeeringRequestok := localVarOptionals.DeleteNetPeeringRequest.Value().(DeleteNetPeeringRequest) - if !localVarOptionalDeleteNetPeeringRequestok { - return localVarReturnValue, nil, reportError("deleteNetPeeringRequest should be DeleteNetPeeringRequest") - } - localVarPostBody = &localVarOptionalDeleteNetPeeringRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteNetPeeringResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNetPeeringsOpts Optional parameters for the method 'ReadNetPeerings' -type ReadNetPeeringsOpts struct { - ReadNetPeeringsRequest optional.Interface -} - -/* -ReadNetPeerings Method for ReadNetPeerings - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNetPeeringsOpts - Optional Parameters: - * @param "ReadNetPeeringsRequest" (optional.Interface of ReadNetPeeringsRequest) - -@return ReadNetPeeringsResponse -*/ -func (a *NetPeeringApiService) ReadNetPeerings(ctx _context.Context, localVarOptionals *ReadNetPeeringsOpts) (ReadNetPeeringsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNetPeeringsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNetPeerings" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNetPeeringsRequest.IsSet() { - localVarOptionalReadNetPeeringsRequest, localVarOptionalReadNetPeeringsRequestok := localVarOptionals.ReadNetPeeringsRequest.Value().(ReadNetPeeringsRequest) - if !localVarOptionalReadNetPeeringsRequestok { - return localVarReturnValue, nil, reportError("readNetPeeringsRequest should be ReadNetPeeringsRequest") - } - localVarPostBody = &localVarOptionalReadNetPeeringsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNetPeeringsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// RejectNetPeeringOpts Optional parameters for the method 'RejectNetPeering' -type RejectNetPeeringOpts struct { - RejectNetPeeringRequest optional.Interface -} - -/* -RejectNetPeering Method for RejectNetPeering - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *RejectNetPeeringOpts - Optional Parameters: - * @param "RejectNetPeeringRequest" (optional.Interface of RejectNetPeeringRequest) - -@return RejectNetPeeringResponse -*/ -func (a *NetPeeringApiService) RejectNetPeering(ctx _context.Context, localVarOptionals *RejectNetPeeringOpts) (RejectNetPeeringResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RejectNetPeeringResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/RejectNetPeering" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.RejectNetPeeringRequest.IsSet() { - localVarOptionalRejectNetPeeringRequest, localVarOptionalRejectNetPeeringRequestok := localVarOptionals.RejectNetPeeringRequest.Value().(RejectNetPeeringRequest) - if !localVarOptionalRejectNetPeeringRequestok { - return localVarReturnValue, nil, reportError("rejectNetPeeringRequest should be RejectNetPeeringRequest") - } - localVarPostBody = &localVarOptionalRejectNetPeeringRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v RejectNetPeeringResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_nic.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_nic.go deleted file mode 100644 index ba8ba1d8b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_nic.go +++ /dev/null @@ -1,1180 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// NicApiService NicApi service -type NicApiService service - -// CreateNicOpts Optional parameters for the method 'CreateNic' -type CreateNicOpts struct { - CreateNicRequest optional.Interface -} - -/* -CreateNic Method for CreateNic - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateNicOpts - Optional Parameters: - * @param "CreateNicRequest" (optional.Interface of CreateNicRequest) - -@return CreateNicResponse -*/ -func (a *NicApiService) CreateNic(ctx _context.Context, localVarOptionals *CreateNicOpts) (CreateNicResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateNicResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateNic" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateNicRequest.IsSet() { - localVarOptionalCreateNicRequest, localVarOptionalCreateNicRequestok := localVarOptionals.CreateNicRequest.Value().(CreateNicRequest) - if !localVarOptionalCreateNicRequestok { - return localVarReturnValue, nil, reportError("createNicRequest should be CreateNicRequest") - } - localVarPostBody = &localVarOptionalCreateNicRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateNicResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteNicOpts Optional parameters for the method 'DeleteNic' -type DeleteNicOpts struct { - DeleteNicRequest optional.Interface -} - -/* -DeleteNic Method for DeleteNic - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteNicOpts - Optional Parameters: - * @param "DeleteNicRequest" (optional.Interface of DeleteNicRequest) - -@return DeleteNicResponse -*/ -func (a *NicApiService) DeleteNic(ctx _context.Context, localVarOptionals *DeleteNicOpts) (DeleteNicResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteNicResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteNic" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteNicRequest.IsSet() { - localVarOptionalDeleteNicRequest, localVarOptionalDeleteNicRequestok := localVarOptionals.DeleteNicRequest.Value().(DeleteNicRequest) - if !localVarOptionalDeleteNicRequestok { - return localVarReturnValue, nil, reportError("deleteNicRequest should be DeleteNicRequest") - } - localVarPostBody = &localVarOptionalDeleteNicRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteNicResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkNicOpts Optional parameters for the method 'LinkNic' -type LinkNicOpts struct { - LinkNicRequest optional.Interface -} - -/* -LinkNic Method for LinkNic - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkNicOpts - Optional Parameters: - * @param "LinkNicRequest" (optional.Interface of LinkNicRequest) - -@return LinkNicResponse -*/ -func (a *NicApiService) LinkNic(ctx _context.Context, localVarOptionals *LinkNicOpts) (LinkNicResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkNicResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkNic" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkNicRequest.IsSet() { - localVarOptionalLinkNicRequest, localVarOptionalLinkNicRequestok := localVarOptionals.LinkNicRequest.Value().(LinkNicRequest) - if !localVarOptionalLinkNicRequestok { - return localVarReturnValue, nil, reportError("linkNicRequest should be LinkNicRequest") - } - localVarPostBody = &localVarOptionalLinkNicRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkNicResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkPrivateIpsOpts Optional parameters for the method 'LinkPrivateIps' -type LinkPrivateIpsOpts struct { - LinkPrivateIpsRequest optional.Interface -} - -/* -LinkPrivateIps Method for LinkPrivateIps - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkPrivateIpsOpts - Optional Parameters: - * @param "LinkPrivateIpsRequest" (optional.Interface of LinkPrivateIpsRequest) - -@return LinkPrivateIpsResponse -*/ -func (a *NicApiService) LinkPrivateIps(ctx _context.Context, localVarOptionals *LinkPrivateIpsOpts) (LinkPrivateIpsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkPrivateIpsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkPrivateIps" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkPrivateIpsRequest.IsSet() { - localVarOptionalLinkPrivateIpsRequest, localVarOptionalLinkPrivateIpsRequestok := localVarOptionals.LinkPrivateIpsRequest.Value().(LinkPrivateIpsRequest) - if !localVarOptionalLinkPrivateIpsRequestok { - return localVarReturnValue, nil, reportError("linkPrivateIpsRequest should be LinkPrivateIpsRequest") - } - localVarPostBody = &localVarOptionalLinkPrivateIpsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkPrivateIpsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadNicsOpts Optional parameters for the method 'ReadNics' -type ReadNicsOpts struct { - ReadNicsRequest optional.Interface -} - -/* -ReadNics Method for ReadNics - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadNicsOpts - Optional Parameters: - * @param "ReadNicsRequest" (optional.Interface of ReadNicsRequest) - -@return ReadNicsResponse -*/ -func (a *NicApiService) ReadNics(ctx _context.Context, localVarOptionals *ReadNicsOpts) (ReadNicsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadNicsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadNics" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadNicsRequest.IsSet() { - localVarOptionalReadNicsRequest, localVarOptionalReadNicsRequestok := localVarOptionals.ReadNicsRequest.Value().(ReadNicsRequest) - if !localVarOptionalReadNicsRequestok { - return localVarReturnValue, nil, reportError("readNicsRequest should be ReadNicsRequest") - } - localVarPostBody = &localVarOptionalReadNicsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadNicsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkNicOpts Optional parameters for the method 'UnlinkNic' -type UnlinkNicOpts struct { - UnlinkNicRequest optional.Interface -} - -/* -UnlinkNic Method for UnlinkNic - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkNicOpts - Optional Parameters: - * @param "UnlinkNicRequest" (optional.Interface of UnlinkNicRequest) - -@return UnlinkNicResponse -*/ -func (a *NicApiService) UnlinkNic(ctx _context.Context, localVarOptionals *UnlinkNicOpts) (UnlinkNicResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkNicResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkNic" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkNicRequest.IsSet() { - localVarOptionalUnlinkNicRequest, localVarOptionalUnlinkNicRequestok := localVarOptionals.UnlinkNicRequest.Value().(UnlinkNicRequest) - if !localVarOptionalUnlinkNicRequestok { - return localVarReturnValue, nil, reportError("unlinkNicRequest should be UnlinkNicRequest") - } - localVarPostBody = &localVarOptionalUnlinkNicRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkNicResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkPrivateIpsOpts Optional parameters for the method 'UnlinkPrivateIps' -type UnlinkPrivateIpsOpts struct { - UnlinkPrivateIpsRequest optional.Interface -} - -/* -UnlinkPrivateIps Method for UnlinkPrivateIps - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkPrivateIpsOpts - Optional Parameters: - * @param "UnlinkPrivateIpsRequest" (optional.Interface of UnlinkPrivateIpsRequest) - -@return UnlinkPrivateIpsResponse -*/ -func (a *NicApiService) UnlinkPrivateIps(ctx _context.Context, localVarOptionals *UnlinkPrivateIpsOpts) (UnlinkPrivateIpsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkPrivateIpsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkPrivateIps" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkPrivateIpsRequest.IsSet() { - localVarOptionalUnlinkPrivateIpsRequest, localVarOptionalUnlinkPrivateIpsRequestok := localVarOptionals.UnlinkPrivateIpsRequest.Value().(UnlinkPrivateIpsRequest) - if !localVarOptionalUnlinkPrivateIpsRequestok { - return localVarReturnValue, nil, reportError("unlinkPrivateIpsRequest should be UnlinkPrivateIpsRequest") - } - localVarPostBody = &localVarOptionalUnlinkPrivateIpsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkPrivateIpsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateNicOpts Optional parameters for the method 'UpdateNic' -type UpdateNicOpts struct { - UpdateNicRequest optional.Interface -} - -/* -UpdateNic Method for UpdateNic - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateNicOpts - Optional Parameters: - * @param "UpdateNicRequest" (optional.Interface of UpdateNicRequest) - -@return UpdateNicResponse -*/ -func (a *NicApiService) UpdateNic(ctx _context.Context, localVarOptionals *UpdateNicOpts) (UpdateNicResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateNicResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateNic" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateNicRequest.IsSet() { - localVarOptionalUpdateNicRequest, localVarOptionalUpdateNicRequestok := localVarOptionals.UpdateNicRequest.Value().(UpdateNicRequest) - if !localVarOptionalUpdateNicRequestok { - return localVarReturnValue, nil, reportError("updateNicRequest should be UpdateNicRequest") - } - localVarPostBody = &localVarOptionalUpdateNicRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateNicResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_product_type.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_product_type.go deleted file mode 100644 index 04741121a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_product_type.go +++ /dev/null @@ -1,127 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// ProductTypeApiService ProductTypeApi service -type ProductTypeApiService service - -// ReadProductTypesOpts Optional parameters for the method 'ReadProductTypes' -type ReadProductTypesOpts struct { - ReadProductTypesRequest optional.Interface -} - -/* -ReadProductTypes Method for ReadProductTypes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadProductTypesOpts - Optional Parameters: - * @param "ReadProductTypesRequest" (optional.Interface of ReadProductTypesRequest) - -@return ReadProductTypesResponse -*/ -func (a *ProductTypeApiService) ReadProductTypes(ctx _context.Context, localVarOptionals *ReadProductTypesOpts) (ReadProductTypesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadProductTypesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadProductTypes" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadProductTypesRequest.IsSet() { - localVarOptionalReadProductTypesRequest, localVarOptionalReadProductTypesRequestok := localVarOptionals.ReadProductTypesRequest.Value().(ReadProductTypesRequest) - if !localVarOptionalReadProductTypesRequestok { - return localVarReturnValue, nil, reportError("readProductTypesRequest should be ReadProductTypesRequest") - } - localVarPostBody = &localVarOptionalReadProductTypesRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadProductTypesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_public_ip.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_public_ip.go deleted file mode 100644 index c4e0aca02..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_public_ip.go +++ /dev/null @@ -1,848 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// PublicIpApiService PublicIpApi service -type PublicIpApiService service - -// CreatePublicIpOpts Optional parameters for the method 'CreatePublicIp' -type CreatePublicIpOpts struct { - CreatePublicIpRequest optional.Interface -} - -/* -CreatePublicIp Method for CreatePublicIp - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreatePublicIpOpts - Optional Parameters: - * @param "CreatePublicIpRequest" (optional.Interface of CreatePublicIpRequest) - -@return CreatePublicIpResponse -*/ -func (a *PublicIpApiService) CreatePublicIp(ctx _context.Context, localVarOptionals *CreatePublicIpOpts) (CreatePublicIpResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreatePublicIpResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreatePublicIp" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreatePublicIpRequest.IsSet() { - localVarOptionalCreatePublicIpRequest, localVarOptionalCreatePublicIpRequestok := localVarOptionals.CreatePublicIpRequest.Value().(CreatePublicIpRequest) - if !localVarOptionalCreatePublicIpRequestok { - return localVarReturnValue, nil, reportError("createPublicIpRequest should be CreatePublicIpRequest") - } - localVarPostBody = &localVarOptionalCreatePublicIpRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreatePublicIpResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeletePublicIpOpts Optional parameters for the method 'DeletePublicIp' -type DeletePublicIpOpts struct { - DeletePublicIpRequest optional.Interface -} - -/* -DeletePublicIp Method for DeletePublicIp - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeletePublicIpOpts - Optional Parameters: - * @param "DeletePublicIpRequest" (optional.Interface of DeletePublicIpRequest) - -@return DeletePublicIpResponse -*/ -func (a *PublicIpApiService) DeletePublicIp(ctx _context.Context, localVarOptionals *DeletePublicIpOpts) (DeletePublicIpResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeletePublicIpResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeletePublicIp" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeletePublicIpRequest.IsSet() { - localVarOptionalDeletePublicIpRequest, localVarOptionalDeletePublicIpRequestok := localVarOptionals.DeletePublicIpRequest.Value().(DeletePublicIpRequest) - if !localVarOptionalDeletePublicIpRequestok { - return localVarReturnValue, nil, reportError("deletePublicIpRequest should be DeletePublicIpRequest") - } - localVarPostBody = &localVarOptionalDeletePublicIpRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeletePublicIpResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkPublicIpOpts Optional parameters for the method 'LinkPublicIp' -type LinkPublicIpOpts struct { - LinkPublicIpRequest optional.Interface -} - -/* -LinkPublicIp Method for LinkPublicIp - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkPublicIpOpts - Optional Parameters: - * @param "LinkPublicIpRequest" (optional.Interface of LinkPublicIpRequest) - -@return LinkPublicIpResponse -*/ -func (a *PublicIpApiService) LinkPublicIp(ctx _context.Context, localVarOptionals *LinkPublicIpOpts) (LinkPublicIpResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkPublicIpResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkPublicIp" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkPublicIpRequest.IsSet() { - localVarOptionalLinkPublicIpRequest, localVarOptionalLinkPublicIpRequestok := localVarOptionals.LinkPublicIpRequest.Value().(LinkPublicIpRequest) - if !localVarOptionalLinkPublicIpRequestok { - return localVarReturnValue, nil, reportError("linkPublicIpRequest should be LinkPublicIpRequest") - } - localVarPostBody = &localVarOptionalLinkPublicIpRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkPublicIpResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadPublicIpRangesOpts Optional parameters for the method 'ReadPublicIpRanges' -type ReadPublicIpRangesOpts struct { - ReadPublicIpRangesRequest optional.Interface -} - -/* -ReadPublicIpRanges Method for ReadPublicIpRanges - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadPublicIpRangesOpts - Optional Parameters: - * @param "ReadPublicIpRangesRequest" (optional.Interface of ReadPublicIpRangesRequest) - -@return ReadPublicIpRangesResponse -*/ -func (a *PublicIpApiService) ReadPublicIpRanges(ctx _context.Context, localVarOptionals *ReadPublicIpRangesOpts) (ReadPublicIpRangesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadPublicIpRangesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadPublicIpRanges" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadPublicIpRangesRequest.IsSet() { - localVarOptionalReadPublicIpRangesRequest, localVarOptionalReadPublicIpRangesRequestok := localVarOptionals.ReadPublicIpRangesRequest.Value().(ReadPublicIpRangesRequest) - if !localVarOptionalReadPublicIpRangesRequestok { - return localVarReturnValue, nil, reportError("readPublicIpRangesRequest should be ReadPublicIpRangesRequest") - } - localVarPostBody = &localVarOptionalReadPublicIpRangesRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadPublicIpRangesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadPublicIpsOpts Optional parameters for the method 'ReadPublicIps' -type ReadPublicIpsOpts struct { - ReadPublicIpsRequest optional.Interface -} - -/* -ReadPublicIps Method for ReadPublicIps - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadPublicIpsOpts - Optional Parameters: - * @param "ReadPublicIpsRequest" (optional.Interface of ReadPublicIpsRequest) - -@return ReadPublicIpsResponse -*/ -func (a *PublicIpApiService) ReadPublicIps(ctx _context.Context, localVarOptionals *ReadPublicIpsOpts) (ReadPublicIpsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadPublicIpsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadPublicIps" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadPublicIpsRequest.IsSet() { - localVarOptionalReadPublicIpsRequest, localVarOptionalReadPublicIpsRequestok := localVarOptionals.ReadPublicIpsRequest.Value().(ReadPublicIpsRequest) - if !localVarOptionalReadPublicIpsRequestok { - return localVarReturnValue, nil, reportError("readPublicIpsRequest should be ReadPublicIpsRequest") - } - localVarPostBody = &localVarOptionalReadPublicIpsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadPublicIpsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkPublicIpOpts Optional parameters for the method 'UnlinkPublicIp' -type UnlinkPublicIpOpts struct { - UnlinkPublicIpRequest optional.Interface -} - -/* -UnlinkPublicIp Method for UnlinkPublicIp - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkPublicIpOpts - Optional Parameters: - * @param "UnlinkPublicIpRequest" (optional.Interface of UnlinkPublicIpRequest) - -@return UnlinkPublicIpResponse -*/ -func (a *PublicIpApiService) UnlinkPublicIp(ctx _context.Context, localVarOptionals *UnlinkPublicIpOpts) (UnlinkPublicIpResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkPublicIpResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkPublicIp" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkPublicIpRequest.IsSet() { - localVarOptionalUnlinkPublicIpRequest, localVarOptionalUnlinkPublicIpRequestok := localVarOptionals.UnlinkPublicIpRequest.Value().(UnlinkPublicIpRequest) - if !localVarOptionalUnlinkPublicIpRequestok { - return localVarReturnValue, nil, reportError("unlinkPublicIpRequest should be UnlinkPublicIpRequest") - } - localVarPostBody = &localVarOptionalUnlinkPublicIpRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkPublicIpResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_quota.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_quota.go deleted file mode 100644 index 0ff7b20cf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_quota.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// QuotaApiService QuotaApi service -type QuotaApiService service - -// ReadQuotasOpts Optional parameters for the method 'ReadQuotas' -type ReadQuotasOpts struct { - ReadQuotasRequest optional.Interface -} - -/* -ReadQuotas Method for ReadQuotas - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadQuotasOpts - Optional Parameters: - * @param "ReadQuotasRequest" (optional.Interface of ReadQuotasRequest) - -@return ReadQuotasResponse -*/ -func (a *QuotaApiService) ReadQuotas(ctx _context.Context, localVarOptionals *ReadQuotasOpts) (ReadQuotasResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadQuotasResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadQuotas" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadQuotasRequest.IsSet() { - localVarOptionalReadQuotasRequest, localVarOptionalReadQuotasRequestok := localVarOptionals.ReadQuotasRequest.Value().(ReadQuotasRequest) - if !localVarOptionalReadQuotasRequestok { - return localVarReturnValue, nil, reportError("readQuotasRequest should be ReadQuotasRequest") - } - localVarPostBody = &localVarOptionalReadQuotasRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadQuotasResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_region.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_region.go deleted file mode 100644 index 62051553d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_region.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// RegionApiService RegionApi service -type RegionApiService service - -// ReadRegionsOpts Optional parameters for the method 'ReadRegions' -type ReadRegionsOpts struct { - ReadRegionsRequest optional.Interface -} - -/* -ReadRegions Method for ReadRegions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadRegionsOpts - Optional Parameters: - * @param "ReadRegionsRequest" (optional.Interface of ReadRegionsRequest) - -@return ReadRegionsResponse -*/ -func (a *RegionApiService) ReadRegions(ctx _context.Context, localVarOptionals *ReadRegionsOpts) (ReadRegionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadRegionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadRegions" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadRegionsRequest.IsSet() { - localVarOptionalReadRegionsRequest, localVarOptionalReadRegionsRequestok := localVarOptionals.ReadRegionsRequest.Value().(ReadRegionsRequest) - if !localVarOptionalReadRegionsRequestok { - return localVarReturnValue, nil, reportError("readRegionsRequest should be ReadRegionsRequest") - } - localVarPostBody = &localVarOptionalReadRegionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadRegionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_route.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_route.go deleted file mode 100644 index 69d52467f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_route.go +++ /dev/null @@ -1,460 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// RouteApiService RouteApi service -type RouteApiService service - -// CreateRouteOpts Optional parameters for the method 'CreateRoute' -type CreateRouteOpts struct { - CreateRouteRequest optional.Interface -} - -/* -CreateRoute Method for CreateRoute - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateRouteOpts - Optional Parameters: - * @param "CreateRouteRequest" (optional.Interface of CreateRouteRequest) - -@return CreateRouteResponse -*/ -func (a *RouteApiService) CreateRoute(ctx _context.Context, localVarOptionals *CreateRouteOpts) (CreateRouteResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateRouteResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateRoute" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateRouteRequest.IsSet() { - localVarOptionalCreateRouteRequest, localVarOptionalCreateRouteRequestok := localVarOptionals.CreateRouteRequest.Value().(CreateRouteRequest) - if !localVarOptionalCreateRouteRequestok { - return localVarReturnValue, nil, reportError("createRouteRequest should be CreateRouteRequest") - } - localVarPostBody = &localVarOptionalCreateRouteRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateRouteResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteRouteOpts Optional parameters for the method 'DeleteRoute' -type DeleteRouteOpts struct { - DeleteRouteRequest optional.Interface -} - -/* -DeleteRoute Method for DeleteRoute - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteRouteOpts - Optional Parameters: - * @param "DeleteRouteRequest" (optional.Interface of DeleteRouteRequest) - -@return DeleteRouteResponse -*/ -func (a *RouteApiService) DeleteRoute(ctx _context.Context, localVarOptionals *DeleteRouteOpts) (DeleteRouteResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteRouteResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteRoute" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteRouteRequest.IsSet() { - localVarOptionalDeleteRouteRequest, localVarOptionalDeleteRouteRequestok := localVarOptionals.DeleteRouteRequest.Value().(DeleteRouteRequest) - if !localVarOptionalDeleteRouteRequestok { - return localVarReturnValue, nil, reportError("deleteRouteRequest should be DeleteRouteRequest") - } - localVarPostBody = &localVarOptionalDeleteRouteRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteRouteResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateRouteOpts Optional parameters for the method 'UpdateRoute' -type UpdateRouteOpts struct { - UpdateRouteRequest optional.Interface -} - -/* -UpdateRoute Method for UpdateRoute - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateRouteOpts - Optional Parameters: - * @param "UpdateRouteRequest" (optional.Interface of UpdateRouteRequest) - -@return UpdateRouteResponse -*/ -func (a *RouteApiService) UpdateRoute(ctx _context.Context, localVarOptionals *UpdateRouteOpts) (UpdateRouteResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateRouteResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateRoute" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateRouteRequest.IsSet() { - localVarOptionalUpdateRouteRequest, localVarOptionalUpdateRouteRequestok := localVarOptionals.UpdateRouteRequest.Value().(UpdateRouteRequest) - if !localVarOptionalUpdateRouteRequestok { - return localVarReturnValue, nil, reportError("updateRouteRequest should be UpdateRouteRequest") - } - localVarPostBody = &localVarOptionalUpdateRouteRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateRouteResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_route_table.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_route_table.go deleted file mode 100644 index e81fa3a70..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_route_table.go +++ /dev/null @@ -1,748 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// RouteTableApiService RouteTableApi service -type RouteTableApiService service - -// CreateRouteTableOpts Optional parameters for the method 'CreateRouteTable' -type CreateRouteTableOpts struct { - CreateRouteTableRequest optional.Interface -} - -/* -CreateRouteTable Method for CreateRouteTable - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateRouteTableOpts - Optional Parameters: - * @param "CreateRouteTableRequest" (optional.Interface of CreateRouteTableRequest) - -@return CreateRouteTableResponse -*/ -func (a *RouteTableApiService) CreateRouteTable(ctx _context.Context, localVarOptionals *CreateRouteTableOpts) (CreateRouteTableResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateRouteTableResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateRouteTable" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateRouteTableRequest.IsSet() { - localVarOptionalCreateRouteTableRequest, localVarOptionalCreateRouteTableRequestok := localVarOptionals.CreateRouteTableRequest.Value().(CreateRouteTableRequest) - if !localVarOptionalCreateRouteTableRequestok { - return localVarReturnValue, nil, reportError("createRouteTableRequest should be CreateRouteTableRequest") - } - localVarPostBody = &localVarOptionalCreateRouteTableRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateRouteTableResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteRouteTableOpts Optional parameters for the method 'DeleteRouteTable' -type DeleteRouteTableOpts struct { - DeleteRouteTableRequest optional.Interface -} - -/* -DeleteRouteTable Method for DeleteRouteTable - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteRouteTableOpts - Optional Parameters: - * @param "DeleteRouteTableRequest" (optional.Interface of DeleteRouteTableRequest) - -@return DeleteRouteTableResponse -*/ -func (a *RouteTableApiService) DeleteRouteTable(ctx _context.Context, localVarOptionals *DeleteRouteTableOpts) (DeleteRouteTableResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteRouteTableResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteRouteTable" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteRouteTableRequest.IsSet() { - localVarOptionalDeleteRouteTableRequest, localVarOptionalDeleteRouteTableRequestok := localVarOptionals.DeleteRouteTableRequest.Value().(DeleteRouteTableRequest) - if !localVarOptionalDeleteRouteTableRequestok { - return localVarReturnValue, nil, reportError("deleteRouteTableRequest should be DeleteRouteTableRequest") - } - localVarPostBody = &localVarOptionalDeleteRouteTableRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteRouteTableResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkRouteTableOpts Optional parameters for the method 'LinkRouteTable' -type LinkRouteTableOpts struct { - LinkRouteTableRequest optional.Interface -} - -/* -LinkRouteTable Method for LinkRouteTable - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkRouteTableOpts - Optional Parameters: - * @param "LinkRouteTableRequest" (optional.Interface of LinkRouteTableRequest) - -@return LinkRouteTableResponse -*/ -func (a *RouteTableApiService) LinkRouteTable(ctx _context.Context, localVarOptionals *LinkRouteTableOpts) (LinkRouteTableResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkRouteTableResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkRouteTable" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkRouteTableRequest.IsSet() { - localVarOptionalLinkRouteTableRequest, localVarOptionalLinkRouteTableRequestok := localVarOptionals.LinkRouteTableRequest.Value().(LinkRouteTableRequest) - if !localVarOptionalLinkRouteTableRequestok { - return localVarReturnValue, nil, reportError("linkRouteTableRequest should be LinkRouteTableRequest") - } - localVarPostBody = &localVarOptionalLinkRouteTableRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkRouteTableResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadRouteTablesOpts Optional parameters for the method 'ReadRouteTables' -type ReadRouteTablesOpts struct { - ReadRouteTablesRequest optional.Interface -} - -/* -ReadRouteTables Method for ReadRouteTables - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadRouteTablesOpts - Optional Parameters: - * @param "ReadRouteTablesRequest" (optional.Interface of ReadRouteTablesRequest) - -@return ReadRouteTablesResponse -*/ -func (a *RouteTableApiService) ReadRouteTables(ctx _context.Context, localVarOptionals *ReadRouteTablesOpts) (ReadRouteTablesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadRouteTablesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadRouteTables" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadRouteTablesRequest.IsSet() { - localVarOptionalReadRouteTablesRequest, localVarOptionalReadRouteTablesRequestok := localVarOptionals.ReadRouteTablesRequest.Value().(ReadRouteTablesRequest) - if !localVarOptionalReadRouteTablesRequestok { - return localVarReturnValue, nil, reportError("readRouteTablesRequest should be ReadRouteTablesRequest") - } - localVarPostBody = &localVarOptionalReadRouteTablesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadRouteTablesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkRouteTableOpts Optional parameters for the method 'UnlinkRouteTable' -type UnlinkRouteTableOpts struct { - UnlinkRouteTableRequest optional.Interface -} - -/* -UnlinkRouteTable Method for UnlinkRouteTable - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkRouteTableOpts - Optional Parameters: - * @param "UnlinkRouteTableRequest" (optional.Interface of UnlinkRouteTableRequest) - -@return UnlinkRouteTableResponse -*/ -func (a *RouteTableApiService) UnlinkRouteTable(ctx _context.Context, localVarOptionals *UnlinkRouteTableOpts) (UnlinkRouteTableResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkRouteTableResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkRouteTable" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkRouteTableRequest.IsSet() { - localVarOptionalUnlinkRouteTableRequest, localVarOptionalUnlinkRouteTableRequestok := localVarOptionals.UnlinkRouteTableRequest.Value().(UnlinkRouteTableRequest) - if !localVarOptionalUnlinkRouteTableRequestok { - return localVarReturnValue, nil, reportError("unlinkRouteTableRequest should be UnlinkRouteTableRequest") - } - localVarPostBody = &localVarOptionalUnlinkRouteTableRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkRouteTableResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group.go deleted file mode 100644 index 6632a1a3a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group.go +++ /dev/null @@ -1,460 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// SecurityGroupApiService SecurityGroupApi service -type SecurityGroupApiService service - -// CreateSecurityGroupOpts Optional parameters for the method 'CreateSecurityGroup' -type CreateSecurityGroupOpts struct { - CreateSecurityGroupRequest optional.Interface -} - -/* -CreateSecurityGroup Method for CreateSecurityGroup - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateSecurityGroupOpts - Optional Parameters: - * @param "CreateSecurityGroupRequest" (optional.Interface of CreateSecurityGroupRequest) - -@return CreateSecurityGroupResponse -*/ -func (a *SecurityGroupApiService) CreateSecurityGroup(ctx _context.Context, localVarOptionals *CreateSecurityGroupOpts) (CreateSecurityGroupResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateSecurityGroupResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateSecurityGroup" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateSecurityGroupRequest.IsSet() { - localVarOptionalCreateSecurityGroupRequest, localVarOptionalCreateSecurityGroupRequestok := localVarOptionals.CreateSecurityGroupRequest.Value().(CreateSecurityGroupRequest) - if !localVarOptionalCreateSecurityGroupRequestok { - return localVarReturnValue, nil, reportError("createSecurityGroupRequest should be CreateSecurityGroupRequest") - } - localVarPostBody = &localVarOptionalCreateSecurityGroupRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateSecurityGroupResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteSecurityGroupOpts Optional parameters for the method 'DeleteSecurityGroup' -type DeleteSecurityGroupOpts struct { - DeleteSecurityGroupRequest optional.Interface -} - -/* -DeleteSecurityGroup Method for DeleteSecurityGroup - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteSecurityGroupOpts - Optional Parameters: - * @param "DeleteSecurityGroupRequest" (optional.Interface of DeleteSecurityGroupRequest) - -@return DeleteSecurityGroupResponse -*/ -func (a *SecurityGroupApiService) DeleteSecurityGroup(ctx _context.Context, localVarOptionals *DeleteSecurityGroupOpts) (DeleteSecurityGroupResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteSecurityGroupResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteSecurityGroup" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteSecurityGroupRequest.IsSet() { - localVarOptionalDeleteSecurityGroupRequest, localVarOptionalDeleteSecurityGroupRequestok := localVarOptionals.DeleteSecurityGroupRequest.Value().(DeleteSecurityGroupRequest) - if !localVarOptionalDeleteSecurityGroupRequestok { - return localVarReturnValue, nil, reportError("deleteSecurityGroupRequest should be DeleteSecurityGroupRequest") - } - localVarPostBody = &localVarOptionalDeleteSecurityGroupRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteSecurityGroupResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadSecurityGroupsOpts Optional parameters for the method 'ReadSecurityGroups' -type ReadSecurityGroupsOpts struct { - ReadSecurityGroupsRequest optional.Interface -} - -/* -ReadSecurityGroups Method for ReadSecurityGroups - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSecurityGroupsOpts - Optional Parameters: - * @param "ReadSecurityGroupsRequest" (optional.Interface of ReadSecurityGroupsRequest) - -@return ReadSecurityGroupsResponse -*/ -func (a *SecurityGroupApiService) ReadSecurityGroups(ctx _context.Context, localVarOptionals *ReadSecurityGroupsOpts) (ReadSecurityGroupsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSecurityGroupsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSecurityGroups" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSecurityGroupsRequest.IsSet() { - localVarOptionalReadSecurityGroupsRequest, localVarOptionalReadSecurityGroupsRequestok := localVarOptionals.ReadSecurityGroupsRequest.Value().(ReadSecurityGroupsRequest) - if !localVarOptionalReadSecurityGroupsRequestok { - return localVarReturnValue, nil, reportError("readSecurityGroupsRequest should be ReadSecurityGroupsRequest") - } - localVarPostBody = &localVarOptionalReadSecurityGroupsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSecurityGroupsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group_rule.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group_rule.go deleted file mode 100644 index cbea71ee1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_security_group_rule.go +++ /dev/null @@ -1,316 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// SecurityGroupRuleApiService SecurityGroupRuleApi service -type SecurityGroupRuleApiService service - -// CreateSecurityGroupRuleOpts Optional parameters for the method 'CreateSecurityGroupRule' -type CreateSecurityGroupRuleOpts struct { - CreateSecurityGroupRuleRequest optional.Interface -} - -/* -CreateSecurityGroupRule Method for CreateSecurityGroupRule - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateSecurityGroupRuleOpts - Optional Parameters: - * @param "CreateSecurityGroupRuleRequest" (optional.Interface of CreateSecurityGroupRuleRequest) - -@return CreateSecurityGroupRuleResponse -*/ -func (a *SecurityGroupRuleApiService) CreateSecurityGroupRule(ctx _context.Context, localVarOptionals *CreateSecurityGroupRuleOpts) (CreateSecurityGroupRuleResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateSecurityGroupRuleResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateSecurityGroupRule" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateSecurityGroupRuleRequest.IsSet() { - localVarOptionalCreateSecurityGroupRuleRequest, localVarOptionalCreateSecurityGroupRuleRequestok := localVarOptionals.CreateSecurityGroupRuleRequest.Value().(CreateSecurityGroupRuleRequest) - if !localVarOptionalCreateSecurityGroupRuleRequestok { - return localVarReturnValue, nil, reportError("createSecurityGroupRuleRequest should be CreateSecurityGroupRuleRequest") - } - localVarPostBody = &localVarOptionalCreateSecurityGroupRuleRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateSecurityGroupRuleResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteSecurityGroupRuleOpts Optional parameters for the method 'DeleteSecurityGroupRule' -type DeleteSecurityGroupRuleOpts struct { - DeleteSecurityGroupRuleRequest optional.Interface -} - -/* -DeleteSecurityGroupRule Method for DeleteSecurityGroupRule - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteSecurityGroupRuleOpts - Optional Parameters: - * @param "DeleteSecurityGroupRuleRequest" (optional.Interface of DeleteSecurityGroupRuleRequest) - -@return DeleteSecurityGroupRuleResponse -*/ -func (a *SecurityGroupRuleApiService) DeleteSecurityGroupRule(ctx _context.Context, localVarOptionals *DeleteSecurityGroupRuleOpts) (DeleteSecurityGroupRuleResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteSecurityGroupRuleResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteSecurityGroupRule" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteSecurityGroupRuleRequest.IsSet() { - localVarOptionalDeleteSecurityGroupRuleRequest, localVarOptionalDeleteSecurityGroupRuleRequestok := localVarOptionals.DeleteSecurityGroupRuleRequest.Value().(DeleteSecurityGroupRuleRequest) - if !localVarOptionalDeleteSecurityGroupRuleRequestok { - return localVarReturnValue, nil, reportError("deleteSecurityGroupRuleRequest should be DeleteSecurityGroupRuleRequest") - } - localVarPostBody = &localVarOptionalDeleteSecurityGroupRuleRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteSecurityGroupRuleResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_server_certificate.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_server_certificate.go deleted file mode 100644 index 5682604d9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_server_certificate.go +++ /dev/null @@ -1,483 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// ServerCertificateApiService ServerCertificateApi service -type ServerCertificateApiService service - -// CreateServerCertificateOpts Optional parameters for the method 'CreateServerCertificate' -type CreateServerCertificateOpts struct { - CreateServerCertificateRequest optional.Interface -} - -/* -CreateServerCertificate Method for CreateServerCertificate - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateServerCertificateOpts - Optional Parameters: - * @param "CreateServerCertificateRequest" (optional.Interface of CreateServerCertificateRequest) - -@return CreateServerCertificateResponse -*/ -func (a *ServerCertificateApiService) CreateServerCertificate(ctx _context.Context, localVarOptionals *CreateServerCertificateOpts) (CreateServerCertificateResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateServerCertificateResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateServerCertificate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateServerCertificateRequest.IsSet() { - localVarOptionalCreateServerCertificateRequest, localVarOptionalCreateServerCertificateRequestok := localVarOptionals.CreateServerCertificateRequest.Value().(CreateServerCertificateRequest) - if !localVarOptionalCreateServerCertificateRequestok { - return localVarReturnValue, nil, reportError("createServerCertificateRequest should be CreateServerCertificateRequest") - } - localVarPostBody = &localVarOptionalCreateServerCertificateRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateServerCertificateResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteServerCertificateOpts Optional parameters for the method 'DeleteServerCertificate' -type DeleteServerCertificateOpts struct { - DeleteServerCertificateRequest optional.Interface -} - -/* -DeleteServerCertificate Method for DeleteServerCertificate - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteServerCertificateOpts - Optional Parameters: - * @param "DeleteServerCertificateRequest" (optional.Interface of DeleteServerCertificateRequest) - -@return DeleteServerCertificateResponse -*/ -func (a *ServerCertificateApiService) DeleteServerCertificate(ctx _context.Context, localVarOptionals *DeleteServerCertificateOpts) (DeleteServerCertificateResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteServerCertificateResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteServerCertificate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteServerCertificateRequest.IsSet() { - localVarOptionalDeleteServerCertificateRequest, localVarOptionalDeleteServerCertificateRequestok := localVarOptionals.DeleteServerCertificateRequest.Value().(DeleteServerCertificateRequest) - if !localVarOptionalDeleteServerCertificateRequestok { - return localVarReturnValue, nil, reportError("deleteServerCertificateRequest should be DeleteServerCertificateRequest") - } - localVarPostBody = &localVarOptionalDeleteServerCertificateRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteServerCertificateResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadServerCertificatesOpts Optional parameters for the method 'ReadServerCertificates' -type ReadServerCertificatesOpts struct { - ReadServerCertificatesRequest optional.Interface -} - -/* -ReadServerCertificates Method for ReadServerCertificates - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadServerCertificatesOpts - Optional Parameters: - * @param "ReadServerCertificatesRequest" (optional.Interface of ReadServerCertificatesRequest) - -@return ReadServerCertificatesResponse -*/ -func (a *ServerCertificateApiService) ReadServerCertificates(ctx _context.Context, localVarOptionals *ReadServerCertificatesOpts) (ReadServerCertificatesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadServerCertificatesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadServerCertificates" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadServerCertificatesRequest.IsSet() { - localVarOptionalReadServerCertificatesRequest, localVarOptionalReadServerCertificatesRequestok := localVarOptionals.ReadServerCertificatesRequest.Value().(ReadServerCertificatesRequest) - if !localVarOptionalReadServerCertificatesRequestok { - return localVarReturnValue, nil, reportError("readServerCertificatesRequest should be ReadServerCertificatesRequest") - } - localVarPostBody = &localVarOptionalReadServerCertificatesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadServerCertificatesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateServerCertificateOpts Optional parameters for the method 'UpdateServerCertificate' -type UpdateServerCertificateOpts struct { - UpdateServerCertificateRequest optional.Interface -} - -/* -UpdateServerCertificate Method for UpdateServerCertificate - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateServerCertificateOpts - Optional Parameters: - * @param "UpdateServerCertificateRequest" (optional.Interface of UpdateServerCertificateRequest) - -@return UpdateServerCertificateResponse -*/ -func (a *ServerCertificateApiService) UpdateServerCertificate(ctx _context.Context, localVarOptionals *UpdateServerCertificateOpts) (UpdateServerCertificateResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateServerCertificateResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateServerCertificate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateServerCertificateRequest.IsSet() { - localVarOptionalUpdateServerCertificateRequest, localVarOptionalUpdateServerCertificateRequestok := localVarOptionals.UpdateServerCertificateRequest.Value().(UpdateServerCertificateRequest) - if !localVarOptionalUpdateServerCertificateRequestok { - return localVarReturnValue, nil, reportError("updateServerCertificateRequest should be UpdateServerCertificateRequest") - } - localVarPostBody = &localVarOptionalUpdateServerCertificateRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateServerCertificateResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_snapshot.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_snapshot.go deleted file mode 100644 index 3e8762a3f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_snapshot.go +++ /dev/null @@ -1,832 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// SnapshotApiService SnapshotApi service -type SnapshotApiService service - -// CreateSnapshotOpts Optional parameters for the method 'CreateSnapshot' -type CreateSnapshotOpts struct { - CreateSnapshotRequest optional.Interface -} - -/* -CreateSnapshot Method for CreateSnapshot - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateSnapshotOpts - Optional Parameters: - * @param "CreateSnapshotRequest" (optional.Interface of CreateSnapshotRequest) - -@return CreateSnapshotResponse -*/ -func (a *SnapshotApiService) CreateSnapshot(ctx _context.Context, localVarOptionals *CreateSnapshotOpts) (CreateSnapshotResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateSnapshotResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateSnapshot" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateSnapshotRequest.IsSet() { - localVarOptionalCreateSnapshotRequest, localVarOptionalCreateSnapshotRequestok := localVarOptionals.CreateSnapshotRequest.Value().(CreateSnapshotRequest) - if !localVarOptionalCreateSnapshotRequestok { - return localVarReturnValue, nil, reportError("createSnapshotRequest should be CreateSnapshotRequest") - } - localVarPostBody = &localVarOptionalCreateSnapshotRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateSnapshotResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateSnapshotExportTaskOpts Optional parameters for the method 'CreateSnapshotExportTask' -type CreateSnapshotExportTaskOpts struct { - CreateSnapshotExportTaskRequest optional.Interface -} - -/* -CreateSnapshotExportTask Method for CreateSnapshotExportTask - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateSnapshotExportTaskOpts - Optional Parameters: - * @param "CreateSnapshotExportTaskRequest" (optional.Interface of CreateSnapshotExportTaskRequest) - -@return CreateSnapshotExportTaskResponse -*/ -func (a *SnapshotApiService) CreateSnapshotExportTask(ctx _context.Context, localVarOptionals *CreateSnapshotExportTaskOpts) (CreateSnapshotExportTaskResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateSnapshotExportTaskResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateSnapshotExportTask" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateSnapshotExportTaskRequest.IsSet() { - localVarOptionalCreateSnapshotExportTaskRequest, localVarOptionalCreateSnapshotExportTaskRequestok := localVarOptionals.CreateSnapshotExportTaskRequest.Value().(CreateSnapshotExportTaskRequest) - if !localVarOptionalCreateSnapshotExportTaskRequestok { - return localVarReturnValue, nil, reportError("createSnapshotExportTaskRequest should be CreateSnapshotExportTaskRequest") - } - localVarPostBody = &localVarOptionalCreateSnapshotExportTaskRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateSnapshotExportTaskResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteSnapshotOpts Optional parameters for the method 'DeleteSnapshot' -type DeleteSnapshotOpts struct { - DeleteSnapshotRequest optional.Interface -} - -/* -DeleteSnapshot Method for DeleteSnapshot - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteSnapshotOpts - Optional Parameters: - * @param "DeleteSnapshotRequest" (optional.Interface of DeleteSnapshotRequest) - -@return DeleteSnapshotResponse -*/ -func (a *SnapshotApiService) DeleteSnapshot(ctx _context.Context, localVarOptionals *DeleteSnapshotOpts) (DeleteSnapshotResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteSnapshotResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteSnapshot" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteSnapshotRequest.IsSet() { - localVarOptionalDeleteSnapshotRequest, localVarOptionalDeleteSnapshotRequestok := localVarOptionals.DeleteSnapshotRequest.Value().(DeleteSnapshotRequest) - if !localVarOptionalDeleteSnapshotRequestok { - return localVarReturnValue, nil, reportError("deleteSnapshotRequest should be DeleteSnapshotRequest") - } - localVarPostBody = &localVarOptionalDeleteSnapshotRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteSnapshotResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadSnapshotExportTasksOpts Optional parameters for the method 'ReadSnapshotExportTasks' -type ReadSnapshotExportTasksOpts struct { - ReadSnapshotExportTasksRequest optional.Interface -} - -/* -ReadSnapshotExportTasks Method for ReadSnapshotExportTasks - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSnapshotExportTasksOpts - Optional Parameters: - * @param "ReadSnapshotExportTasksRequest" (optional.Interface of ReadSnapshotExportTasksRequest) - -@return ReadSnapshotExportTasksResponse -*/ -func (a *SnapshotApiService) ReadSnapshotExportTasks(ctx _context.Context, localVarOptionals *ReadSnapshotExportTasksOpts) (ReadSnapshotExportTasksResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSnapshotExportTasksResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSnapshotExportTasks" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSnapshotExportTasksRequest.IsSet() { - localVarOptionalReadSnapshotExportTasksRequest, localVarOptionalReadSnapshotExportTasksRequestok := localVarOptionals.ReadSnapshotExportTasksRequest.Value().(ReadSnapshotExportTasksRequest) - if !localVarOptionalReadSnapshotExportTasksRequestok { - return localVarReturnValue, nil, reportError("readSnapshotExportTasksRequest should be ReadSnapshotExportTasksRequest") - } - localVarPostBody = &localVarOptionalReadSnapshotExportTasksRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSnapshotExportTasksResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadSnapshotsOpts Optional parameters for the method 'ReadSnapshots' -type ReadSnapshotsOpts struct { - ReadSnapshotsRequest optional.Interface -} - -/* -ReadSnapshots Method for ReadSnapshots - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSnapshotsOpts - Optional Parameters: - * @param "ReadSnapshotsRequest" (optional.Interface of ReadSnapshotsRequest) - -@return ReadSnapshotsResponse -*/ -func (a *SnapshotApiService) ReadSnapshots(ctx _context.Context, localVarOptionals *ReadSnapshotsOpts) (ReadSnapshotsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSnapshotsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSnapshots" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSnapshotsRequest.IsSet() { - localVarOptionalReadSnapshotsRequest, localVarOptionalReadSnapshotsRequestok := localVarOptionals.ReadSnapshotsRequest.Value().(ReadSnapshotsRequest) - if !localVarOptionalReadSnapshotsRequestok { - return localVarReturnValue, nil, reportError("readSnapshotsRequest should be ReadSnapshotsRequest") - } - localVarPostBody = &localVarOptionalReadSnapshotsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSnapshotsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateSnapshotOpts Optional parameters for the method 'UpdateSnapshot' -type UpdateSnapshotOpts struct { - UpdateSnapshotRequest optional.Interface -} - -/* -UpdateSnapshot Method for UpdateSnapshot - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateSnapshotOpts - Optional Parameters: - * @param "UpdateSnapshotRequest" (optional.Interface of UpdateSnapshotRequest) - -@return UpdateSnapshotResponse -*/ -func (a *SnapshotApiService) UpdateSnapshot(ctx _context.Context, localVarOptionals *UpdateSnapshotOpts) (UpdateSnapshotResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateSnapshotResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateSnapshot" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateSnapshotRequest.IsSet() { - localVarOptionalUpdateSnapshotRequest, localVarOptionalUpdateSnapshotRequestok := localVarOptionals.UpdateSnapshotRequest.Value().(UpdateSnapshotRequest) - if !localVarOptionalUpdateSnapshotRequestok { - return localVarReturnValue, nil, reportError("updateSnapshotRequest should be UpdateSnapshotRequest") - } - localVarPostBody = &localVarOptionalUpdateSnapshotRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateSnapshotResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_subnet.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_subnet.go deleted file mode 100644 index 1f1b26d5f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_subnet.go +++ /dev/null @@ -1,614 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// SubnetApiService SubnetApi service -type SubnetApiService service - -// CreateSubnetOpts Optional parameters for the method 'CreateSubnet' -type CreateSubnetOpts struct { - CreateSubnetRequest optional.Interface -} - -/* -CreateSubnet Method for CreateSubnet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateSubnetOpts - Optional Parameters: - * @param "CreateSubnetRequest" (optional.Interface of CreateSubnetRequest) - -@return CreateSubnetResponse -*/ -func (a *SubnetApiService) CreateSubnet(ctx _context.Context, localVarOptionals *CreateSubnetOpts) (CreateSubnetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateSubnetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateSubnet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateSubnetRequest.IsSet() { - localVarOptionalCreateSubnetRequest, localVarOptionalCreateSubnetRequestok := localVarOptionals.CreateSubnetRequest.Value().(CreateSubnetRequest) - if !localVarOptionalCreateSubnetRequestok { - return localVarReturnValue, nil, reportError("createSubnetRequest should be CreateSubnetRequest") - } - localVarPostBody = &localVarOptionalCreateSubnetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateSubnetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 409 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteSubnetOpts Optional parameters for the method 'DeleteSubnet' -type DeleteSubnetOpts struct { - DeleteSubnetRequest optional.Interface -} - -/* -DeleteSubnet Method for DeleteSubnet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteSubnetOpts - Optional Parameters: - * @param "DeleteSubnetRequest" (optional.Interface of DeleteSubnetRequest) - -@return DeleteSubnetResponse -*/ -func (a *SubnetApiService) DeleteSubnet(ctx _context.Context, localVarOptionals *DeleteSubnetOpts) (DeleteSubnetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteSubnetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteSubnet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteSubnetRequest.IsSet() { - localVarOptionalDeleteSubnetRequest, localVarOptionalDeleteSubnetRequestok := localVarOptionals.DeleteSubnetRequest.Value().(DeleteSubnetRequest) - if !localVarOptionalDeleteSubnetRequestok { - return localVarReturnValue, nil, reportError("deleteSubnetRequest should be DeleteSubnetRequest") - } - localVarPostBody = &localVarOptionalDeleteSubnetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteSubnetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadSubnetsOpts Optional parameters for the method 'ReadSubnets' -type ReadSubnetsOpts struct { - ReadSubnetsRequest optional.Interface -} - -/* -ReadSubnets Method for ReadSubnets - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSubnetsOpts - Optional Parameters: - * @param "ReadSubnetsRequest" (optional.Interface of ReadSubnetsRequest) - -@return ReadSubnetsResponse -*/ -func (a *SubnetApiService) ReadSubnets(ctx _context.Context, localVarOptionals *ReadSubnetsOpts) (ReadSubnetsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSubnetsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSubnets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSubnetsRequest.IsSet() { - localVarOptionalReadSubnetsRequest, localVarOptionalReadSubnetsRequestok := localVarOptionals.ReadSubnetsRequest.Value().(ReadSubnetsRequest) - if !localVarOptionalReadSubnetsRequestok { - return localVarReturnValue, nil, reportError("readSubnetsRequest should be ReadSubnetsRequest") - } - localVarPostBody = &localVarOptionalReadSubnetsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSubnetsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateSubnetOpts Optional parameters for the method 'UpdateSubnet' -type UpdateSubnetOpts struct { - UpdateSubnetRequest optional.Interface -} - -/* -UpdateSubnet Method for UpdateSubnet - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateSubnetOpts - Optional Parameters: - * @param "UpdateSubnetRequest" (optional.Interface of UpdateSubnetRequest) - -@return UpdateSubnetResponse -*/ -func (a *SubnetApiService) UpdateSubnet(ctx _context.Context, localVarOptionals *UpdateSubnetOpts) (UpdateSubnetResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateSubnetResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateSubnet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateSubnetRequest.IsSet() { - localVarOptionalUpdateSubnetRequest, localVarOptionalUpdateSubnetRequestok := localVarOptionals.UpdateSubnetRequest.Value().(UpdateSubnetRequest) - if !localVarOptionalUpdateSubnetRequestok { - return localVarReturnValue, nil, reportError("updateSubnetRequest should be UpdateSubnetRequest") - } - localVarPostBody = &localVarOptionalUpdateSubnetRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateSubnetResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_subregion.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_subregion.go deleted file mode 100644 index fa91f1b7a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_subregion.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// SubregionApiService SubregionApi service -type SubregionApiService service - -// ReadSubregionsOpts Optional parameters for the method 'ReadSubregions' -type ReadSubregionsOpts struct { - ReadSubregionsRequest optional.Interface -} - -/* -ReadSubregions Method for ReadSubregions - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadSubregionsOpts - Optional Parameters: - * @param "ReadSubregionsRequest" (optional.Interface of ReadSubregionsRequest) - -@return ReadSubregionsResponse -*/ -func (a *SubregionApiService) ReadSubregions(ctx _context.Context, localVarOptionals *ReadSubregionsOpts) (ReadSubregionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadSubregionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadSubregions" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadSubregionsRequest.IsSet() { - localVarOptionalReadSubregionsRequest, localVarOptionalReadSubregionsRequestok := localVarOptionals.ReadSubregionsRequest.Value().(ReadSubregionsRequest) - if !localVarOptionalReadSubregionsRequestok { - return localVarReturnValue, nil, reportError("readSubregionsRequest should be ReadSubregionsRequest") - } - localVarPostBody = &localVarOptionalReadSubregionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadSubregionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_tag.go deleted file mode 100644 index 8fd1f3657..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_tag.go +++ /dev/null @@ -1,460 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// TagApiService TagApi service -type TagApiService service - -// CreateTagsOpts Optional parameters for the method 'CreateTags' -type CreateTagsOpts struct { - CreateTagsRequest optional.Interface -} - -/* -CreateTags Method for CreateTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateTagsOpts - Optional Parameters: - * @param "CreateTagsRequest" (optional.Interface of CreateTagsRequest) - -@return CreateTagsResponse -*/ -func (a *TagApiService) CreateTags(ctx _context.Context, localVarOptionals *CreateTagsOpts) (CreateTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateTagsRequest.IsSet() { - localVarOptionalCreateTagsRequest, localVarOptionalCreateTagsRequestok := localVarOptionals.CreateTagsRequest.Value().(CreateTagsRequest) - if !localVarOptionalCreateTagsRequestok { - return localVarReturnValue, nil, reportError("createTagsRequest should be CreateTagsRequest") - } - localVarPostBody = &localVarOptionalCreateTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteTagsOpts Optional parameters for the method 'DeleteTags' -type DeleteTagsOpts struct { - DeleteTagsRequest optional.Interface -} - -/* -DeleteTags Method for DeleteTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteTagsOpts - Optional Parameters: - * @param "DeleteTagsRequest" (optional.Interface of DeleteTagsRequest) - -@return DeleteTagsResponse -*/ -func (a *TagApiService) DeleteTags(ctx _context.Context, localVarOptionals *DeleteTagsOpts) (DeleteTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteTagsRequest.IsSet() { - localVarOptionalDeleteTagsRequest, localVarOptionalDeleteTagsRequestok := localVarOptionals.DeleteTagsRequest.Value().(DeleteTagsRequest) - if !localVarOptionalDeleteTagsRequestok { - return localVarReturnValue, nil, reportError("deleteTagsRequest should be DeleteTagsRequest") - } - localVarPostBody = &localVarOptionalDeleteTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadTagsOpts Optional parameters for the method 'ReadTags' -type ReadTagsOpts struct { - ReadTagsRequest optional.Interface -} - -/* -ReadTags Method for ReadTags - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadTagsOpts - Optional Parameters: - * @param "ReadTagsRequest" (optional.Interface of ReadTagsRequest) - -@return ReadTagsResponse -*/ -func (a *TagApiService) ReadTags(ctx _context.Context, localVarOptionals *ReadTagsOpts) (ReadTagsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadTagsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadTags" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadTagsRequest.IsSet() { - localVarOptionalReadTagsRequest, localVarOptionalReadTagsRequestok := localVarOptionals.ReadTagsRequest.Value().(ReadTagsRequest) - if !localVarOptionalReadTagsRequestok { - return localVarReturnValue, nil, reportError("readTagsRequest should be ReadTagsRequest") - } - localVarPostBody = &localVarOptionalReadTagsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadTagsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_task.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_task.go deleted file mode 100644 index ca6da50ff..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_task.go +++ /dev/null @@ -1,141 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// TaskApiService TaskApi service -type TaskApiService service - -// DeleteExportTaskOpts Optional parameters for the method 'DeleteExportTask' -type DeleteExportTaskOpts struct { - DeleteExportTaskRequest optional.Interface -} - -/* -DeleteExportTask Method for DeleteExportTask - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteExportTaskOpts - Optional Parameters: - * @param "DeleteExportTaskRequest" (optional.Interface of DeleteExportTaskRequest) - -@return DeleteExportTaskResponse -*/ -func (a *TaskApiService) DeleteExportTask(ctx _context.Context, localVarOptionals *DeleteExportTaskOpts) (DeleteExportTaskResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteExportTaskResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteExportTask" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteExportTaskRequest.IsSet() { - localVarOptionalDeleteExportTaskRequest, localVarOptionalDeleteExportTaskRequestok := localVarOptionals.DeleteExportTaskRequest.Value().(DeleteExportTaskRequest) - if !localVarOptionalDeleteExportTaskRequestok { - return localVarReturnValue, nil, reportError("deleteExportTaskRequest should be DeleteExportTaskRequest") - } - localVarPostBody = &localVarOptionalDeleteExportTaskRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteExportTaskResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_virtual_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_virtual_gateway.go deleted file mode 100644 index 9ecb0a8dd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_virtual_gateway.go +++ /dev/null @@ -1,711 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// VirtualGatewayApiService VirtualGatewayApi service -type VirtualGatewayApiService service - -// CreateVirtualGatewayOpts Optional parameters for the method 'CreateVirtualGateway' -type CreateVirtualGatewayOpts struct { - CreateVirtualGatewayRequest optional.Interface -} - -/* -CreateVirtualGateway Method for CreateVirtualGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateVirtualGatewayOpts - Optional Parameters: - * @param "CreateVirtualGatewayRequest" (optional.Interface of CreateVirtualGatewayRequest) - -@return CreateVirtualGatewayResponse -*/ -func (a *VirtualGatewayApiService) CreateVirtualGateway(ctx _context.Context, localVarOptionals *CreateVirtualGatewayOpts) (CreateVirtualGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateVirtualGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateVirtualGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateVirtualGatewayRequest.IsSet() { - localVarOptionalCreateVirtualGatewayRequest, localVarOptionalCreateVirtualGatewayRequestok := localVarOptionals.CreateVirtualGatewayRequest.Value().(CreateVirtualGatewayRequest) - if !localVarOptionalCreateVirtualGatewayRequestok { - return localVarReturnValue, nil, reportError("createVirtualGatewayRequest should be CreateVirtualGatewayRequest") - } - localVarPostBody = &localVarOptionalCreateVirtualGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateVirtualGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteVirtualGatewayOpts Optional parameters for the method 'DeleteVirtualGateway' -type DeleteVirtualGatewayOpts struct { - DeleteVirtualGatewayRequest optional.Interface -} - -/* -DeleteVirtualGateway Method for DeleteVirtualGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteVirtualGatewayOpts - Optional Parameters: - * @param "DeleteVirtualGatewayRequest" (optional.Interface of DeleteVirtualGatewayRequest) - -@return DeleteVirtualGatewayResponse -*/ -func (a *VirtualGatewayApiService) DeleteVirtualGateway(ctx _context.Context, localVarOptionals *DeleteVirtualGatewayOpts) (DeleteVirtualGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteVirtualGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteVirtualGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteVirtualGatewayRequest.IsSet() { - localVarOptionalDeleteVirtualGatewayRequest, localVarOptionalDeleteVirtualGatewayRequestok := localVarOptionals.DeleteVirtualGatewayRequest.Value().(DeleteVirtualGatewayRequest) - if !localVarOptionalDeleteVirtualGatewayRequestok { - return localVarReturnValue, nil, reportError("deleteVirtualGatewayRequest should be DeleteVirtualGatewayRequest") - } - localVarPostBody = &localVarOptionalDeleteVirtualGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteVirtualGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkVirtualGatewayOpts Optional parameters for the method 'LinkVirtualGateway' -type LinkVirtualGatewayOpts struct { - LinkVirtualGatewayRequest optional.Interface -} - -/* -LinkVirtualGateway Method for LinkVirtualGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkVirtualGatewayOpts - Optional Parameters: - * @param "LinkVirtualGatewayRequest" (optional.Interface of LinkVirtualGatewayRequest) - -@return LinkVirtualGatewayResponse -*/ -func (a *VirtualGatewayApiService) LinkVirtualGateway(ctx _context.Context, localVarOptionals *LinkVirtualGatewayOpts) (LinkVirtualGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkVirtualGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkVirtualGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkVirtualGatewayRequest.IsSet() { - localVarOptionalLinkVirtualGatewayRequest, localVarOptionalLinkVirtualGatewayRequestok := localVarOptionals.LinkVirtualGatewayRequest.Value().(LinkVirtualGatewayRequest) - if !localVarOptionalLinkVirtualGatewayRequestok { - return localVarReturnValue, nil, reportError("linkVirtualGatewayRequest should be LinkVirtualGatewayRequest") - } - localVarPostBody = &localVarOptionalLinkVirtualGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkVirtualGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVirtualGatewaysOpts Optional parameters for the method 'ReadVirtualGateways' -type ReadVirtualGatewaysOpts struct { - ReadVirtualGatewaysRequest optional.Interface -} - -/* -ReadVirtualGateways Method for ReadVirtualGateways - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVirtualGatewaysOpts - Optional Parameters: - * @param "ReadVirtualGatewaysRequest" (optional.Interface of ReadVirtualGatewaysRequest) - -@return ReadVirtualGatewaysResponse -*/ -func (a *VirtualGatewayApiService) ReadVirtualGateways(ctx _context.Context, localVarOptionals *ReadVirtualGatewaysOpts) (ReadVirtualGatewaysResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVirtualGatewaysResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVirtualGateways" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVirtualGatewaysRequest.IsSet() { - localVarOptionalReadVirtualGatewaysRequest, localVarOptionalReadVirtualGatewaysRequestok := localVarOptionals.ReadVirtualGatewaysRequest.Value().(ReadVirtualGatewaysRequest) - if !localVarOptionalReadVirtualGatewaysRequestok { - return localVarReturnValue, nil, reportError("readVirtualGatewaysRequest should be ReadVirtualGatewaysRequest") - } - localVarPostBody = &localVarOptionalReadVirtualGatewaysRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVirtualGatewaysResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkVirtualGatewayOpts Optional parameters for the method 'UnlinkVirtualGateway' -type UnlinkVirtualGatewayOpts struct { - UnlinkVirtualGatewayRequest optional.Interface -} - -/* -UnlinkVirtualGateway Method for UnlinkVirtualGateway - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkVirtualGatewayOpts - Optional Parameters: - * @param "UnlinkVirtualGatewayRequest" (optional.Interface of UnlinkVirtualGatewayRequest) - -@return UnlinkVirtualGatewayResponse -*/ -func (a *VirtualGatewayApiService) UnlinkVirtualGateway(ctx _context.Context, localVarOptionals *UnlinkVirtualGatewayOpts) (UnlinkVirtualGatewayResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkVirtualGatewayResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkVirtualGateway" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkVirtualGatewayRequest.IsSet() { - localVarOptionalUnlinkVirtualGatewayRequest, localVarOptionalUnlinkVirtualGatewayRequestok := localVarOptionals.UnlinkVirtualGatewayRequest.Value().(UnlinkVirtualGatewayRequest) - if !localVarOptionalUnlinkVirtualGatewayRequestok { - return localVarReturnValue, nil, reportError("unlinkVirtualGatewayRequest should be UnlinkVirtualGatewayRequest") - } - localVarPostBody = &localVarOptionalUnlinkVirtualGatewayRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkVirtualGatewayResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateRoutePropagationOpts Optional parameters for the method 'UpdateRoutePropagation' -type UpdateRoutePropagationOpts struct { - UpdateRoutePropagationRequest optional.Interface -} - -/* -UpdateRoutePropagation Method for UpdateRoutePropagation - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateRoutePropagationOpts - Optional Parameters: - * @param "UpdateRoutePropagationRequest" (optional.Interface of UpdateRoutePropagationRequest) - -@return UpdateRoutePropagationResponse -*/ -func (a *VirtualGatewayApiService) UpdateRoutePropagation(ctx _context.Context, localVarOptionals *UpdateRoutePropagationOpts) (UpdateRoutePropagationResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateRoutePropagationResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateRoutePropagation" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateRoutePropagationRequest.IsSet() { - localVarOptionalUpdateRoutePropagationRequest, localVarOptionalUpdateRoutePropagationRequestok := localVarOptionals.UpdateRoutePropagationRequest.Value().(UpdateRoutePropagationRequest) - if !localVarOptionalUpdateRoutePropagationRequestok { - return localVarReturnValue, nil, reportError("updateRoutePropagationRequest should be UpdateRoutePropagationRequest") - } - localVarPostBody = &localVarOptionalUpdateRoutePropagationRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateRoutePropagationResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_vm.go deleted file mode 100644 index d09e5d6cc..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_vm.go +++ /dev/null @@ -1,1568 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// VmApiService VmApi service -type VmApiService service - -// CreateVmsOpts Optional parameters for the method 'CreateVms' -type CreateVmsOpts struct { - CreateVmsRequest optional.Interface -} - -/* -CreateVms Method for CreateVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateVmsOpts - Optional Parameters: - * @param "CreateVmsRequest" (optional.Interface of CreateVmsRequest) - -@return CreateVmsResponse -*/ -func (a *VmApiService) CreateVms(ctx _context.Context, localVarOptionals *CreateVmsOpts) (CreateVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateVmsRequest.IsSet() { - localVarOptionalCreateVmsRequest, localVarOptionalCreateVmsRequestok := localVarOptionals.CreateVmsRequest.Value().(CreateVmsRequest) - if !localVarOptionalCreateVmsRequestok { - return localVarReturnValue, nil, reportError("createVmsRequest should be CreateVmsRequest") - } - localVarPostBody = &localVarOptionalCreateVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteVmsOpts Optional parameters for the method 'DeleteVms' -type DeleteVmsOpts struct { - DeleteVmsRequest optional.Interface -} - -/* -DeleteVms Method for DeleteVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteVmsOpts - Optional Parameters: - * @param "DeleteVmsRequest" (optional.Interface of DeleteVmsRequest) - -@return DeleteVmsResponse -*/ -func (a *VmApiService) DeleteVms(ctx _context.Context, localVarOptionals *DeleteVmsOpts) (DeleteVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteVmsRequest.IsSet() { - localVarOptionalDeleteVmsRequest, localVarOptionalDeleteVmsRequestok := localVarOptionals.DeleteVmsRequest.Value().(DeleteVmsRequest) - if !localVarOptionalDeleteVmsRequestok { - return localVarReturnValue, nil, reportError("deleteVmsRequest should be DeleteVmsRequest") - } - localVarPostBody = &localVarOptionalDeleteVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadAdminPasswordOpts Optional parameters for the method 'ReadAdminPassword' -type ReadAdminPasswordOpts struct { - ReadAdminPasswordRequest optional.Interface -} - -/* -ReadAdminPassword Method for ReadAdminPassword - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadAdminPasswordOpts - Optional Parameters: - * @param "ReadAdminPasswordRequest" (optional.Interface of ReadAdminPasswordRequest) - -@return ReadAdminPasswordResponse -*/ -func (a *VmApiService) ReadAdminPassword(ctx _context.Context, localVarOptionals *ReadAdminPasswordOpts) (ReadAdminPasswordResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadAdminPasswordResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadAdminPassword" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadAdminPasswordRequest.IsSet() { - localVarOptionalReadAdminPasswordRequest, localVarOptionalReadAdminPasswordRequestok := localVarOptionals.ReadAdminPasswordRequest.Value().(ReadAdminPasswordRequest) - if !localVarOptionalReadAdminPasswordRequestok { - return localVarReturnValue, nil, reportError("readAdminPasswordRequest should be ReadAdminPasswordRequest") - } - localVarPostBody = &localVarOptionalReadAdminPasswordRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadAdminPasswordResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadConsoleOutputOpts Optional parameters for the method 'ReadConsoleOutput' -type ReadConsoleOutputOpts struct { - ReadConsoleOutputRequest optional.Interface -} - -/* -ReadConsoleOutput Method for ReadConsoleOutput - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadConsoleOutputOpts - Optional Parameters: - * @param "ReadConsoleOutputRequest" (optional.Interface of ReadConsoleOutputRequest) - -@return ReadConsoleOutputResponse -*/ -func (a *VmApiService) ReadConsoleOutput(ctx _context.Context, localVarOptionals *ReadConsoleOutputOpts) (ReadConsoleOutputResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadConsoleOutputResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadConsoleOutput" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadConsoleOutputRequest.IsSet() { - localVarOptionalReadConsoleOutputRequest, localVarOptionalReadConsoleOutputRequestok := localVarOptionals.ReadConsoleOutputRequest.Value().(ReadConsoleOutputRequest) - if !localVarOptionalReadConsoleOutputRequestok { - return localVarReturnValue, nil, reportError("readConsoleOutputRequest should be ReadConsoleOutputRequest") - } - localVarPostBody = &localVarOptionalReadConsoleOutputRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadConsoleOutputResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVmTypesOpts Optional parameters for the method 'ReadVmTypes' -type ReadVmTypesOpts struct { - ReadVmTypesRequest optional.Interface -} - -/* -ReadVmTypes Method for ReadVmTypes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVmTypesOpts - Optional Parameters: - * @param "ReadVmTypesRequest" (optional.Interface of ReadVmTypesRequest) - -@return ReadVmTypesResponse -*/ -func (a *VmApiService) ReadVmTypes(ctx _context.Context, localVarOptionals *ReadVmTypesOpts) (ReadVmTypesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVmTypesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVmTypes" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVmTypesRequest.IsSet() { - localVarOptionalReadVmTypesRequest, localVarOptionalReadVmTypesRequestok := localVarOptionals.ReadVmTypesRequest.Value().(ReadVmTypesRequest) - if !localVarOptionalReadVmTypesRequestok { - return localVarReturnValue, nil, reportError("readVmTypesRequest should be ReadVmTypesRequest") - } - localVarPostBody = &localVarOptionalReadVmTypesRequest - } - - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVmTypesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVmsOpts Optional parameters for the method 'ReadVms' -type ReadVmsOpts struct { - ReadVmsRequest optional.Interface -} - -/* -ReadVms Method for ReadVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVmsOpts - Optional Parameters: - * @param "ReadVmsRequest" (optional.Interface of ReadVmsRequest) - -@return ReadVmsResponse -*/ -func (a *VmApiService) ReadVms(ctx _context.Context, localVarOptionals *ReadVmsOpts) (ReadVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVmsRequest.IsSet() { - localVarOptionalReadVmsRequest, localVarOptionalReadVmsRequestok := localVarOptionals.ReadVmsRequest.Value().(ReadVmsRequest) - if !localVarOptionalReadVmsRequestok { - return localVarReturnValue, nil, reportError("readVmsRequest should be ReadVmsRequest") - } - localVarPostBody = &localVarOptionalReadVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVmsStateOpts Optional parameters for the method 'ReadVmsState' -type ReadVmsStateOpts struct { - ReadVmsStateRequest optional.Interface -} - -/* -ReadVmsState Method for ReadVmsState - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVmsStateOpts - Optional Parameters: - * @param "ReadVmsStateRequest" (optional.Interface of ReadVmsStateRequest) - -@return ReadVmsStateResponse -*/ -func (a *VmApiService) ReadVmsState(ctx _context.Context, localVarOptionals *ReadVmsStateOpts) (ReadVmsStateResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVmsStateResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVmsState" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVmsStateRequest.IsSet() { - localVarOptionalReadVmsStateRequest, localVarOptionalReadVmsStateRequestok := localVarOptionals.ReadVmsStateRequest.Value().(ReadVmsStateRequest) - if !localVarOptionalReadVmsStateRequestok { - return localVarReturnValue, nil, reportError("readVmsStateRequest should be ReadVmsStateRequest") - } - localVarPostBody = &localVarOptionalReadVmsStateRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVmsStateResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// RebootVmsOpts Optional parameters for the method 'RebootVms' -type RebootVmsOpts struct { - RebootVmsRequest optional.Interface -} - -/* -RebootVms Method for RebootVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *RebootVmsOpts - Optional Parameters: - * @param "RebootVmsRequest" (optional.Interface of RebootVmsRequest) - -@return RebootVmsResponse -*/ -func (a *VmApiService) RebootVms(ctx _context.Context, localVarOptionals *RebootVmsOpts) (RebootVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RebootVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/RebootVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.RebootVmsRequest.IsSet() { - localVarOptionalRebootVmsRequest, localVarOptionalRebootVmsRequestok := localVarOptionals.RebootVmsRequest.Value().(RebootVmsRequest) - if !localVarOptionalRebootVmsRequestok { - return localVarReturnValue, nil, reportError("rebootVmsRequest should be RebootVmsRequest") - } - localVarPostBody = &localVarOptionalRebootVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v RebootVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// StartVmsOpts Optional parameters for the method 'StartVms' -type StartVmsOpts struct { - StartVmsRequest optional.Interface -} - -/* -StartVms Method for StartVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *StartVmsOpts - Optional Parameters: - * @param "StartVmsRequest" (optional.Interface of StartVmsRequest) - -@return StartVmsResponse -*/ -func (a *VmApiService) StartVms(ctx _context.Context, localVarOptionals *StartVmsOpts) (StartVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue StartVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/StartVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.StartVmsRequest.IsSet() { - localVarOptionalStartVmsRequest, localVarOptionalStartVmsRequestok := localVarOptionals.StartVmsRequest.Value().(StartVmsRequest) - if !localVarOptionalStartVmsRequestok { - return localVarReturnValue, nil, reportError("startVmsRequest should be StartVmsRequest") - } - localVarPostBody = &localVarOptionalStartVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v StartVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// StopVmsOpts Optional parameters for the method 'StopVms' -type StopVmsOpts struct { - StopVmsRequest optional.Interface -} - -/* -StopVms Method for StopVms - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *StopVmsOpts - Optional Parameters: - * @param "StopVmsRequest" (optional.Interface of StopVmsRequest) - -@return StopVmsResponse -*/ -func (a *VmApiService) StopVms(ctx _context.Context, localVarOptionals *StopVmsOpts) (StopVmsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue StopVmsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/StopVms" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.StopVmsRequest.IsSet() { - localVarOptionalStopVmsRequest, localVarOptionalStopVmsRequestok := localVarOptionals.StopVmsRequest.Value().(StopVmsRequest) - if !localVarOptionalStopVmsRequestok { - return localVarReturnValue, nil, reportError("stopVmsRequest should be StopVmsRequest") - } - localVarPostBody = &localVarOptionalStopVmsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v StopVmsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UpdateVmOpts Optional parameters for the method 'UpdateVm' -type UpdateVmOpts struct { - UpdateVmRequest optional.Interface -} - -/* -UpdateVm Method for UpdateVm - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UpdateVmOpts - Optional Parameters: - * @param "UpdateVmRequest" (optional.Interface of UpdateVmRequest) - -@return UpdateVmResponse -*/ -func (a *VmApiService) UpdateVm(ctx _context.Context, localVarOptionals *UpdateVmOpts) (UpdateVmResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UpdateVmResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UpdateVm" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UpdateVmRequest.IsSet() { - localVarOptionalUpdateVmRequest, localVarOptionalUpdateVmRequestok := localVarOptionals.UpdateVmRequest.Value().(UpdateVmRequest) - if !localVarOptionalUpdateVmRequestok { - return localVarReturnValue, nil, reportError("updateVmRequest should be UpdateVmRequest") - } - localVarPostBody = &localVarOptionalUpdateVmRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UpdateVmResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_volume.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_volume.go deleted file mode 100644 index 08a45d069..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_volume.go +++ /dev/null @@ -1,748 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" - - "github.com/antihax/optional" -) - -// Linger please -var ( - _ _context.Context -) - -// VolumeApiService VolumeApi service -type VolumeApiService service - -// CreateVolumeOpts Optional parameters for the method 'CreateVolume' -type CreateVolumeOpts struct { - CreateVolumeRequest optional.Interface -} - -/* -CreateVolume Method for CreateVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateVolumeOpts - Optional Parameters: - * @param "CreateVolumeRequest" (optional.Interface of CreateVolumeRequest) - -@return CreateVolumeResponse -*/ -func (a *VolumeApiService) CreateVolume(ctx _context.Context, localVarOptionals *CreateVolumeOpts) (CreateVolumeResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateVolumeResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateVolume" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateVolumeRequest.IsSet() { - localVarOptionalCreateVolumeRequest, localVarOptionalCreateVolumeRequestok := localVarOptionals.CreateVolumeRequest.Value().(CreateVolumeRequest) - if !localVarOptionalCreateVolumeRequestok { - return localVarReturnValue, nil, reportError("createVolumeRequest should be CreateVolumeRequest") - } - localVarPostBody = &localVarOptionalCreateVolumeRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateVolumeResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteVolumeOpts Optional parameters for the method 'DeleteVolume' -type DeleteVolumeOpts struct { - DeleteVolumeRequest optional.Interface -} - -/* -DeleteVolume Method for DeleteVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteVolumeOpts - Optional Parameters: - * @param "DeleteVolumeRequest" (optional.Interface of DeleteVolumeRequest) - -@return DeleteVolumeResponse -*/ -func (a *VolumeApiService) DeleteVolume(ctx _context.Context, localVarOptionals *DeleteVolumeOpts) (DeleteVolumeResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteVolumeResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteVolume" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteVolumeRequest.IsSet() { - localVarOptionalDeleteVolumeRequest, localVarOptionalDeleteVolumeRequestok := localVarOptionals.DeleteVolumeRequest.Value().(DeleteVolumeRequest) - if !localVarOptionalDeleteVolumeRequestok { - return localVarReturnValue, nil, reportError("deleteVolumeRequest should be DeleteVolumeRequest") - } - localVarPostBody = &localVarOptionalDeleteVolumeRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteVolumeResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// LinkVolumeOpts Optional parameters for the method 'LinkVolume' -type LinkVolumeOpts struct { - LinkVolumeRequest optional.Interface -} - -/* -LinkVolume Method for LinkVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *LinkVolumeOpts - Optional Parameters: - * @param "LinkVolumeRequest" (optional.Interface of LinkVolumeRequest) - -@return LinkVolumeResponse -*/ -func (a *VolumeApiService) LinkVolume(ctx _context.Context, localVarOptionals *LinkVolumeOpts) (LinkVolumeResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue LinkVolumeResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/LinkVolume" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.LinkVolumeRequest.IsSet() { - localVarOptionalLinkVolumeRequest, localVarOptionalLinkVolumeRequestok := localVarOptionals.LinkVolumeRequest.Value().(LinkVolumeRequest) - if !localVarOptionalLinkVolumeRequestok { - return localVarReturnValue, nil, reportError("linkVolumeRequest should be LinkVolumeRequest") - } - localVarPostBody = &localVarOptionalLinkVolumeRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v LinkVolumeResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVolumesOpts Optional parameters for the method 'ReadVolumes' -type ReadVolumesOpts struct { - ReadVolumesRequest optional.Interface -} - -/* -ReadVolumes Method for ReadVolumes - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVolumesOpts - Optional Parameters: - * @param "ReadVolumesRequest" (optional.Interface of ReadVolumesRequest) - -@return ReadVolumesResponse -*/ -func (a *VolumeApiService) ReadVolumes(ctx _context.Context, localVarOptionals *ReadVolumesOpts) (ReadVolumesResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVolumesResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVolumes" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVolumesRequest.IsSet() { - localVarOptionalReadVolumesRequest, localVarOptionalReadVolumesRequestok := localVarOptionals.ReadVolumesRequest.Value().(ReadVolumesRequest) - if !localVarOptionalReadVolumesRequestok { - return localVarReturnValue, nil, reportError("readVolumesRequest should be ReadVolumesRequest") - } - localVarPostBody = &localVarOptionalReadVolumesRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVolumesResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// UnlinkVolumeOpts Optional parameters for the method 'UnlinkVolume' -type UnlinkVolumeOpts struct { - UnlinkVolumeRequest optional.Interface -} - -/* -UnlinkVolume Method for UnlinkVolume - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *UnlinkVolumeOpts - Optional Parameters: - * @param "UnlinkVolumeRequest" (optional.Interface of UnlinkVolumeRequest) - -@return UnlinkVolumeResponse -*/ -func (a *VolumeApiService) UnlinkVolume(ctx _context.Context, localVarOptionals *UnlinkVolumeOpts) (UnlinkVolumeResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue UnlinkVolumeResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/UnlinkVolume" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.UnlinkVolumeRequest.IsSet() { - localVarOptionalUnlinkVolumeRequest, localVarOptionalUnlinkVolumeRequestok := localVarOptionals.UnlinkVolumeRequest.Value().(UnlinkVolumeRequest) - if !localVarOptionalUnlinkVolumeRequestok { - return localVarReturnValue, nil, reportError("unlinkVolumeRequest should be UnlinkVolumeRequest") - } - localVarPostBody = &localVarOptionalUnlinkVolumeRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v UnlinkVolumeResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 400 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 401 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHTTPResponse, newErr - } - if localVarHTTPResponse.StatusCode == 500 { - var v ErrorResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/api_vpn_connection.go b/vendor/github.com/marinsalinas/osc-sdk-go/api_vpn_connection.go deleted file mode 100644 index e0af3c3eb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/api_vpn_connection.go +++ /dev/null @@ -1,597 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - _context "context" - "github.com/antihax/optional" - _ioutil "io/ioutil" - _nethttp "net/http" - _neturl "net/url" -) - -// Linger please -var ( - _ _context.Context -) - -// VpnConnectionApiService VpnConnectionApi service -type VpnConnectionApiService service - -// CreateVpnConnectionOpts Optional parameters for the method 'CreateVpnConnection' -type CreateVpnConnectionOpts struct { - CreateVpnConnectionRequest optional.Interface -} - -/* -CreateVpnConnection Method for CreateVpnConnection - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateVpnConnectionOpts - Optional Parameters: - * @param "CreateVpnConnectionRequest" (optional.Interface of CreateVpnConnectionRequest) - -@return CreateVpnConnectionResponse -*/ -func (a *VpnConnectionApiService) CreateVpnConnection(ctx _context.Context, localVarOptionals *CreateVpnConnectionOpts) (CreateVpnConnectionResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateVpnConnectionResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateVpnConnection" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateVpnConnectionRequest.IsSet() { - localVarOptionalCreateVpnConnectionRequest, localVarOptionalCreateVpnConnectionRequestok := localVarOptionals.CreateVpnConnectionRequest.Value().(CreateVpnConnectionRequest) - if !localVarOptionalCreateVpnConnectionRequestok { - return localVarReturnValue, nil, reportError("createVpnConnectionRequest should be CreateVpnConnectionRequest") - } - localVarPostBody = &localVarOptionalCreateVpnConnectionRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateVpnConnectionResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// CreateVpnConnectionRouteOpts Optional parameters for the method 'CreateVpnConnectionRoute' -type CreateVpnConnectionRouteOpts struct { - CreateVpnConnectionRouteRequest optional.Interface -} - -/* -CreateVpnConnectionRoute Method for CreateVpnConnectionRoute - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *CreateVpnConnectionRouteOpts - Optional Parameters: - * @param "CreateVpnConnectionRouteRequest" (optional.Interface of CreateVpnConnectionRouteRequest) - -@return CreateVpnConnectionRouteResponse -*/ -func (a *VpnConnectionApiService) CreateVpnConnectionRoute(ctx _context.Context, localVarOptionals *CreateVpnConnectionRouteOpts) (CreateVpnConnectionRouteResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue CreateVpnConnectionRouteResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/CreateVpnConnectionRoute" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.CreateVpnConnectionRouteRequest.IsSet() { - localVarOptionalCreateVpnConnectionRouteRequest, localVarOptionalCreateVpnConnectionRouteRequestok := localVarOptionals.CreateVpnConnectionRouteRequest.Value().(CreateVpnConnectionRouteRequest) - if !localVarOptionalCreateVpnConnectionRouteRequestok { - return localVarReturnValue, nil, reportError("createVpnConnectionRouteRequest should be CreateVpnConnectionRouteRequest") - } - localVarPostBody = &localVarOptionalCreateVpnConnectionRouteRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v CreateVpnConnectionRouteResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteVpnConnectionOpts Optional parameters for the method 'DeleteVpnConnection' -type DeleteVpnConnectionOpts struct { - DeleteVpnConnectionRequest optional.Interface -} - -/* -DeleteVpnConnection Method for DeleteVpnConnection - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteVpnConnectionOpts - Optional Parameters: - * @param "DeleteVpnConnectionRequest" (optional.Interface of DeleteVpnConnectionRequest) - -@return DeleteVpnConnectionResponse -*/ -func (a *VpnConnectionApiService) DeleteVpnConnection(ctx _context.Context, localVarOptionals *DeleteVpnConnectionOpts) (DeleteVpnConnectionResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteVpnConnectionResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteVpnConnection" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteVpnConnectionRequest.IsSet() { - localVarOptionalDeleteVpnConnectionRequest, localVarOptionalDeleteVpnConnectionRequestok := localVarOptionals.DeleteVpnConnectionRequest.Value().(DeleteVpnConnectionRequest) - if !localVarOptionalDeleteVpnConnectionRequestok { - return localVarReturnValue, nil, reportError("deleteVpnConnectionRequest should be DeleteVpnConnectionRequest") - } - localVarPostBody = &localVarOptionalDeleteVpnConnectionRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteVpnConnectionResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// DeleteVpnConnectionRouteOpts Optional parameters for the method 'DeleteVpnConnectionRoute' -type DeleteVpnConnectionRouteOpts struct { - DeleteVpnConnectionRouteRequest optional.Interface -} - -/* -DeleteVpnConnectionRoute Method for DeleteVpnConnectionRoute - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DeleteVpnConnectionRouteOpts - Optional Parameters: - * @param "DeleteVpnConnectionRouteRequest" (optional.Interface of DeleteVpnConnectionRouteRequest) - -@return DeleteVpnConnectionRouteResponse -*/ -func (a *VpnConnectionApiService) DeleteVpnConnectionRoute(ctx _context.Context, localVarOptionals *DeleteVpnConnectionRouteOpts) (DeleteVpnConnectionRouteResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue DeleteVpnConnectionRouteResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/DeleteVpnConnectionRoute" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.DeleteVpnConnectionRouteRequest.IsSet() { - localVarOptionalDeleteVpnConnectionRouteRequest, localVarOptionalDeleteVpnConnectionRouteRequestok := localVarOptionals.DeleteVpnConnectionRouteRequest.Value().(DeleteVpnConnectionRouteRequest) - if !localVarOptionalDeleteVpnConnectionRouteRequestok { - return localVarReturnValue, nil, reportError("deleteVpnConnectionRouteRequest should be DeleteVpnConnectionRouteRequest") - } - localVarPostBody = &localVarOptionalDeleteVpnConnectionRouteRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v DeleteVpnConnectionRouteResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -// ReadVpnConnectionsOpts Optional parameters for the method 'ReadVpnConnections' -type ReadVpnConnectionsOpts struct { - ReadVpnConnectionsRequest optional.Interface -} - -/* -ReadVpnConnections Method for ReadVpnConnections - * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *ReadVpnConnectionsOpts - Optional Parameters: - * @param "ReadVpnConnectionsRequest" (optional.Interface of ReadVpnConnectionsRequest) - -@return ReadVpnConnectionsResponse -*/ -func (a *VpnConnectionApiService) ReadVpnConnections(ctx _context.Context, localVarOptionals *ReadVpnConnectionsOpts) (ReadVpnConnectionsResponse, *_nethttp.Response, error) { - var ( - localVarHTTPMethod = _nethttp.MethodPost - localVarPostBody interface{} - localVarFormFileName string - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ReadVpnConnectionsResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/ReadVpnConnections" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := _neturl.Values{} - localVarFormParams := _neturl.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.ReadVpnConnectionsRequest.IsSet() { - localVarOptionalReadVpnConnectionsRequest, localVarOptionalReadVpnConnectionsRequestok := localVarOptionals.ReadVpnConnectionsRequest.Value().(ReadVpnConnectionsRequest) - if !localVarOptionalReadVpnConnectionsRequestok { - return localVarReturnValue, nil, reportError("readVpnConnectionsRequest should be ReadVpnConnectionsRequest") - } - localVarPostBody = &localVarOptionalReadVpnConnectionsRequest - } - - if ctx != nil { - // API Key Authentication - if auth, ok := ctx.Value(ContextAPIKeys).(map[string]APIKey); ok { - if auth, ok := auth["Authorization"]; ok { - var key string - if auth.Prefix != "" { - key = auth.Prefix + " " + auth.Key - } else { - key = auth.Key - } - localVarHeaderParams["Authorization"] = key - } - } - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(r) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 200 { - var v ReadVpnConnectionsResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/client.go b/vendor/github.com/marinsalinas/osc-sdk-go/client.go deleted file mode 100644 index 49a07951d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/client.go +++ /dev/null @@ -1,619 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "context" - "encoding/json" - "encoding/xml" - "errors" - "fmt" - "io" - "mime/multipart" - "net/http" - "net/url" - "os" - "path/filepath" - "reflect" - "regexp" - "strconv" - "strings" - "time" - "unicode/utf8" - - "golang.org/x/oauth2" -) - -var ( - jsonCheck = regexp.MustCompile(`(?i:(?:application|text)/(?:vnd\.[^;]+\+)?(?:json|plain))`) - xmlCheck = regexp.MustCompile(`(?i:(?:application|text)/xml)`) -) - -// APIClient manages communication with the 3DS OUTSCALE API API v1.1 -// In most cases there should be only one, shared, APIClient. -type APIClient struct { - cfg *Configuration - common service // Reuse a single struct instead of allocating one for each service on the heap. - - // API Services - - AccessKeyApi *AccessKeyApiService - - AccountApi *AccountApiService - - ApiLogApi *ApiLogApiService - - ClientGatewayApi *ClientGatewayApiService - - DefaultApi *DefaultApiService - - DhcpOptionApi *DhcpOptionApiService - - DirectLinkApi *DirectLinkApiService - - DirectLinkInterfaceApi *DirectLinkInterfaceApiService - - FlexibleGpuApi *FlexibleGpuApiService - - ImageApi *ImageApiService - - InternetServiceApi *InternetServiceApiService - - KeypairApi *KeypairApiService - - ListenerApi *ListenerApiService - - LoadBalancerApi *LoadBalancerApiService - - LoadBalancerPolicyApi *LoadBalancerPolicyApiService - - LocationApi *LocationApiService - - NatServiceApi *NatServiceApiService - - NetApi *NetApiService - - NetAccessPointApi *NetAccessPointApiService - - NetPeeringApi *NetPeeringApiService - - NicApi *NicApiService - - ProductTypeApi *ProductTypeApiService - - PublicIpApi *PublicIpApiService - - QuotaApi *QuotaApiService - - RegionApi *RegionApiService - - RouteApi *RouteApiService - - RouteTableApi *RouteTableApiService - - SecurityGroupApi *SecurityGroupApiService - - SecurityGroupRuleApi *SecurityGroupRuleApiService - - ServerCertificateApi *ServerCertificateApiService - - SnapshotApi *SnapshotApiService - - SubnetApi *SubnetApiService - - SubregionApi *SubregionApiService - - TagApi *TagApiService - - TaskApi *TaskApiService - - VirtualGatewayApi *VirtualGatewayApiService - - VmApi *VmApiService - - VolumeApi *VolumeApiService - - VpnConnectionApi *VpnConnectionApiService -} - -type service struct { - client *APIClient -} - -// NewAPIClient creates a new API client. Requires a userAgent string describing your application. -// optionally a custom http.Client to allow for advanced features such as caching. -func NewAPIClient(cfg *Configuration) *APIClient { - if cfg.HTTPClient == nil { - cfg.HTTPClient = http.DefaultClient - } - - c := &APIClient{} - c.cfg = cfg - c.common.client = c - - // API Services - c.AccessKeyApi = (*AccessKeyApiService)(&c.common) - c.AccountApi = (*AccountApiService)(&c.common) - c.ApiLogApi = (*ApiLogApiService)(&c.common) - c.ClientGatewayApi = (*ClientGatewayApiService)(&c.common) - c.DefaultApi = (*DefaultApiService)(&c.common) - c.DhcpOptionApi = (*DhcpOptionApiService)(&c.common) - c.DirectLinkApi = (*DirectLinkApiService)(&c.common) - c.DirectLinkInterfaceApi = (*DirectLinkInterfaceApiService)(&c.common) - c.FlexibleGpuApi = (*FlexibleGpuApiService)(&c.common) - c.ImageApi = (*ImageApiService)(&c.common) - c.InternetServiceApi = (*InternetServiceApiService)(&c.common) - c.KeypairApi = (*KeypairApiService)(&c.common) - c.ListenerApi = (*ListenerApiService)(&c.common) - c.LoadBalancerApi = (*LoadBalancerApiService)(&c.common) - c.LoadBalancerPolicyApi = (*LoadBalancerPolicyApiService)(&c.common) - c.LocationApi = (*LocationApiService)(&c.common) - c.NatServiceApi = (*NatServiceApiService)(&c.common) - c.NetApi = (*NetApiService)(&c.common) - c.NetAccessPointApi = (*NetAccessPointApiService)(&c.common) - c.NetPeeringApi = (*NetPeeringApiService)(&c.common) - c.NicApi = (*NicApiService)(&c.common) - c.ProductTypeApi = (*ProductTypeApiService)(&c.common) - c.PublicIpApi = (*PublicIpApiService)(&c.common) - c.QuotaApi = (*QuotaApiService)(&c.common) - c.RegionApi = (*RegionApiService)(&c.common) - c.RouteApi = (*RouteApiService)(&c.common) - c.RouteTableApi = (*RouteTableApiService)(&c.common) - c.SecurityGroupApi = (*SecurityGroupApiService)(&c.common) - c.SecurityGroupRuleApi = (*SecurityGroupRuleApiService)(&c.common) - c.ServerCertificateApi = (*ServerCertificateApiService)(&c.common) - c.SnapshotApi = (*SnapshotApiService)(&c.common) - c.SubnetApi = (*SubnetApiService)(&c.common) - c.SubregionApi = (*SubregionApiService)(&c.common) - c.TagApi = (*TagApiService)(&c.common) - c.TaskApi = (*TaskApiService)(&c.common) - c.VirtualGatewayApi = (*VirtualGatewayApiService)(&c.common) - c.VmApi = (*VmApiService)(&c.common) - c.VolumeApi = (*VolumeApiService)(&c.common) - c.VpnConnectionApi = (*VpnConnectionApiService)(&c.common) - - return c -} - -func atoi(in string) (int, error) { - return strconv.Atoi(in) -} - -// selectHeaderContentType select a content type from the available list. -func selectHeaderContentType(contentTypes []string) string { - if len(contentTypes) == 0 { - return "" - } - if contains(contentTypes, "application/json") { - return "application/json" - } - return contentTypes[0] // use the first content type specified in 'consumes' -} - -// selectHeaderAccept join all accept types and return -func selectHeaderAccept(accepts []string) string { - if len(accepts) == 0 { - return "" - } - - if contains(accepts, "application/json") { - return "application/json" - } - - return strings.Join(accepts, ",") -} - -// contains is a case insenstive match, finding needle in a haystack -func contains(haystack []string, needle string) bool { - for _, a := range haystack { - if strings.ToLower(a) == strings.ToLower(needle) { - return true - } - } - return false -} - -// Verify optional parameters are of the correct type. -func typeCheckParameter(obj interface{}, expected string, name string) error { - // Make sure there is an object. - if obj == nil { - return nil - } - - // Check the type is as expected. - if reflect.TypeOf(obj).String() != expected { - return fmt.Errorf("Expected %s to be of type %s but received %s.", name, expected, reflect.TypeOf(obj).String()) - } - return nil -} - -// parameterToString convert interface{} parameters to string, using a delimiter if format is provided. -func parameterToString(obj interface{}, collectionFormat string) string { - var delimiter string - - switch collectionFormat { - case "pipes": - delimiter = "|" - case "ssv": - delimiter = " " - case "tsv": - delimiter = "\t" - case "csv": - delimiter = "," - } - - if reflect.TypeOf(obj).Kind() == reflect.Slice { - return strings.Trim(strings.Replace(fmt.Sprint(obj), " ", delimiter, -1), "[]") - } else if t, ok := obj.(time.Time); ok { - return t.Format(time.RFC3339) - } - - return fmt.Sprintf("%v", obj) -} - -// helper for converting interface{} parameters to json strings -func parameterToJson(obj interface{}) (string, error) { - jsonBuf, err := json.Marshal(obj) - if err != nil { - return "", err - } - return string(jsonBuf), err -} - -// callAPI do the request. -func (c *APIClient) callAPI(request *http.Request) (*http.Response, error) { - return c.cfg.HTTPClient.Do(request) -} - -// ChangeBasePath changes base path to allow switching to mocks -func (c *APIClient) ChangeBasePath(path string) { - c.cfg.BasePath = path -} - -// Allow modification of underlying config for alternate implementations and testing -// Caution: modifying the configuration while live can cause data races and potentially unwanted behavior -func (c *APIClient) GetConfig() *Configuration { - return c.cfg -} - -// prepareRequest build the request -func (c *APIClient) prepareRequest( - ctx context.Context, - path string, method string, - postBody interface{}, - headerParams map[string]string, - queryParams url.Values, - formParams url.Values, - formFileName string, - fileName string, - fileBytes []byte) (localVarRequest *http.Request, err error) { - - var body *bytes.Buffer - - // Detect postBody type and post. - if postBody != nil { - contentType := headerParams["Content-Type"] - if contentType == "" { - contentType = detectContentType(postBody) - headerParams["Content-Type"] = contentType - } - - body, err = setBody(postBody, contentType) - if err != nil { - return nil, err - } - } - - // add form parameters and file if available. - if strings.HasPrefix(headerParams["Content-Type"], "multipart/form-data") && len(formParams) > 0 || (len(fileBytes) > 0 && fileName != "") { - if body != nil { - return nil, errors.New("Cannot specify postBody and multipart form at the same time.") - } - body = &bytes.Buffer{} - w := multipart.NewWriter(body) - - for k, v := range formParams { - for _, iv := range v { - if strings.HasPrefix(k, "@") { // file - err = addFile(w, k[1:], iv) - if err != nil { - return nil, err - } - } else { // form value - w.WriteField(k, iv) - } - } - } - if len(fileBytes) > 0 && fileName != "" { - w.Boundary() - //_, fileNm := filepath.Split(fileName) - part, err := w.CreateFormFile(formFileName, filepath.Base(fileName)) - if err != nil { - return nil, err - } - _, err = part.Write(fileBytes) - if err != nil { - return nil, err - } - } - - // Set the Boundary in the Content-Type - headerParams["Content-Type"] = w.FormDataContentType() - - // Set Content-Length - headerParams["Content-Length"] = fmt.Sprintf("%d", body.Len()) - w.Close() - } - - if strings.HasPrefix(headerParams["Content-Type"], "application/x-www-form-urlencoded") && len(formParams) > 0 { - if body != nil { - return nil, errors.New("Cannot specify postBody and x-www-form-urlencoded form at the same time.") - } - body = &bytes.Buffer{} - body.WriteString(formParams.Encode()) - // Set Content-Length - headerParams["Content-Length"] = fmt.Sprintf("%d", body.Len()) - } - - // Setup path and query parameters - url, err := url.Parse(path) - if err != nil { - return nil, err - } - - // Override request host, if applicable - if c.cfg.Host != "" { - url.Host = c.cfg.Host - } - - // Override request scheme, if applicable - if c.cfg.Scheme != "" { - url.Scheme = c.cfg.Scheme - } - - // Adding Query Param - query := url.Query() - for k, v := range queryParams { - for _, iv := range v { - query.Add(k, iv) - } - } - - // Encode the parameters. - url.RawQuery = query.Encode() - - // Generate a new request - if body != nil { - localVarRequest, err = http.NewRequest(method, url.String(), body) - } else { - localVarRequest, err = http.NewRequest(method, url.String(), nil) - } - if err != nil { - return nil, err - } - - // add header parameters, if any - if len(headerParams) > 0 { - headers := http.Header{} - for h, v := range headerParams { - headers.Set(h, v) - } - localVarRequest.Header = headers - } - - // Add the user agent to the request. - localVarRequest.Header.Add("User-Agent", c.cfg.UserAgent) - - if ctx != nil { - // add context to the request - localVarRequest = localVarRequest.WithContext(ctx) - - // Walk through any authentication. - - // OAuth2 authentication - if tok, ok := ctx.Value(ContextOAuth2).(oauth2.TokenSource); ok { - // We were able to grab an oauth2 token from the context - var latestToken *oauth2.Token - if latestToken, err = tok.Token(); err != nil { - return nil, err - } - - latestToken.SetAuthHeader(localVarRequest) - } - - // Basic HTTP Authentication - if auth, ok := ctx.Value(ContextBasicAuth).(BasicAuth); ok { - localVarRequest.SetBasicAuth(auth.UserName, auth.Password) - } - - // AccessToken Authentication - if auth, ok := ctx.Value(ContextAccessToken).(string); ok { - localVarRequest.Header.Add("Authorization", "Bearer "+auth) - } - } - - for header, value := range c.cfg.DefaultHeader { - localVarRequest.Header.Add(header, value) - } - - return localVarRequest, nil -} - -func (c *APIClient) decode(v interface{}, b []byte, contentType string) (err error) { - if s, ok := v.(*string); ok { - *s = string(b) - return nil - } - if xmlCheck.MatchString(contentType) { - if err = xml.Unmarshal(b, v); err != nil { - return err - } - return nil - } - if jsonCheck.MatchString(contentType) { - if err = json.Unmarshal(b, v); err != nil { - return err - } - return nil - } - return errors.New("undefined response type") -} - -// Add a file to the multipart request -func addFile(w *multipart.Writer, fieldName, path string) error { - file, err := os.Open(path) - if err != nil { - return err - } - defer file.Close() - - part, err := w.CreateFormFile(fieldName, filepath.Base(path)) - if err != nil { - return err - } - _, err = io.Copy(part, file) - - return err -} - -// Prevent trying to import "fmt" -func reportError(format string, a ...interface{}) error { - return fmt.Errorf(format, a...) -} - -// Set request body from an interface{} -func setBody(body interface{}, contentType string) (bodyBuf *bytes.Buffer, err error) { - if bodyBuf == nil { - bodyBuf = &bytes.Buffer{} - } - - if reader, ok := body.(io.Reader); ok { - _, err = bodyBuf.ReadFrom(reader) - } else if b, ok := body.([]byte); ok { - _, err = bodyBuf.Write(b) - } else if s, ok := body.(string); ok { - _, err = bodyBuf.WriteString(s) - } else if s, ok := body.(*string); ok { - _, err = bodyBuf.WriteString(*s) - } else if jsonCheck.MatchString(contentType) { - err = json.NewEncoder(bodyBuf).Encode(body) - } else if xmlCheck.MatchString(contentType) { - err = xml.NewEncoder(bodyBuf).Encode(body) - } - - if err != nil { - return nil, err - } - - if bodyBuf.Len() == 0 { - err = fmt.Errorf("Invalid body type %s\n", contentType) - return nil, err - } - return bodyBuf, nil -} - -// detectContentType method is used to figure out `Request.Body` content type for request header -func detectContentType(body interface{}) string { - contentType := "text/plain; charset=utf-8" - kind := reflect.TypeOf(body).Kind() - - switch kind { - case reflect.Struct, reflect.Map, reflect.Ptr: - contentType = "application/json; charset=utf-8" - case reflect.String: - contentType = "text/plain; charset=utf-8" - default: - if b, ok := body.([]byte); ok { - contentType = http.DetectContentType(b) - } else if kind == reflect.Slice { - contentType = "application/json; charset=utf-8" - } - } - - return contentType -} - -// Ripped from https://github.com/gregjones/httpcache/blob/master/httpcache.go -type cacheControl map[string]string - -func parseCacheControl(headers http.Header) cacheControl { - cc := cacheControl{} - ccHeader := headers.Get("Cache-Control") - for _, part := range strings.Split(ccHeader, ",") { - part = strings.Trim(part, " ") - if part == "" { - continue - } - if strings.ContainsRune(part, '=') { - keyval := strings.Split(part, "=") - cc[strings.Trim(keyval[0], " ")] = strings.Trim(keyval[1], ",") - } else { - cc[part] = "" - } - } - return cc -} - -// CacheExpires helper function to determine remaining time before repeating a request. -func CacheExpires(r *http.Response) time.Time { - // Figure out when the cache expires. - var expires time.Time - now, err := time.Parse(time.RFC1123, r.Header.Get("date")) - if err != nil { - return time.Now() - } - respCacheControl := parseCacheControl(r.Header) - - if maxAge, ok := respCacheControl["max-age"]; ok { - lifetime, err := time.ParseDuration(maxAge + "s") - if err != nil { - expires = now - } else { - expires = now.Add(lifetime) - } - } else { - expiresHeader := r.Header.Get("Expires") - if expiresHeader != "" { - expires, err = time.Parse(time.RFC1123, expiresHeader) - if err != nil { - expires = now - } - } - } - return expires -} - -func strlen(s string) int { - return utf8.RuneCountInString(s) -} - -// GenericOpenAPIError Provides access to the body, error and model on returned errors. -type GenericOpenAPIError struct { - body []byte - error string - model interface{} -} - -// Error returns non-empty string if there was an error. -func (e GenericOpenAPIError) Error() string { - return e.error -} - -// Body returns the raw bytes of the response -func (e GenericOpenAPIError) Body() []byte { - return e.body -} - -// Model returns the unpacked model of the error -func (e GenericOpenAPIError) Model() interface{} { - return e.model -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/configuration.go b/vendor/github.com/marinsalinas/osc-sdk-go/configuration.go deleted file mode 100644 index cd7aa00ef..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/configuration.go +++ /dev/null @@ -1,76 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "net/http" -) - -// contextKeys are used to identify the type of value in the context. -// Since these are string, it is possible to get a short description of the -// context key for logging and debugging using key.String(). - -type contextKey string - -func (c contextKey) String() string { - return "auth " + string(c) -} - -var ( - // ContextOAuth2 takes an oauth2.TokenSource as authentication for the request. - ContextOAuth2 = contextKey("token") - - // ContextBasicAuth takes BasicAuth as authentication for the request. - ContextBasicAuth = contextKey("basic") - - // ContextAccessToken takes a string oauth2 access token as authentication for the request. - ContextAccessToken = contextKey("accesstoken") - - // ContextAPIKeys takes a string apikey as authentication for the request - ContextAPIKeys = contextKey("apiKeys") -) - -// BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth -type BasicAuth struct { - UserName string `json:"userName,omitempty"` - Password string `json:"password,omitempty"` -} - -// APIKey provides API key based authentication to a request passed via context using ContextAPIKey -type APIKey struct { - Key string - Prefix string -} - -// Configuration stores the configuration of the API client -type Configuration struct { - BasePath string `json:"basePath,omitempty"` - Host string `json:"host,omitempty"` - Scheme string `json:"scheme,omitempty"` - DefaultHeader map[string]string `json:"defaultHeader,omitempty"` - UserAgent string `json:"userAgent,omitempty"` - HTTPClient *http.Client -} - -// NewConfiguration returns a new Configuration object -func NewConfiguration() *Configuration { - cfg := &Configuration{ - BasePath: "https://api.eu-west-2.outscale.com/api/v1", - DefaultHeader: make(map[string]string), - UserAgent: "OpenAPI-Generator/0.1.1/go", - } - return cfg -} - -// AddDefaultHeader adds a new HTTP header to the default header in the request -func (c *Configuration) AddDefaultHeader(key string, value string) { - c.DefaultHeader[key] = value -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/gen-config.json b/vendor/github.com/marinsalinas/osc-sdk-go/gen-config.json deleted file mode 100644 index f0a438dc3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/gen-config.json +++ /dev/null @@ -1,4 +0,0 @@ - {"packageName": "oscgo", - "packageVersion": "0.1.1", - "prependFormOrBodyParameters": true - } \ No newline at end of file diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/git_push.sh b/vendor/github.com/marinsalinas/osc-sdk-go/git_push.sh deleted file mode 100644 index eaaae3f18..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/git_push.sh +++ /dev/null @@ -1,58 +0,0 @@ -#!/bin/sh -# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ -# -# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com" - -git_user_id=$1 -git_repo_id=$2 -release_note=$3 -git_host=$4 - -if [ "$git_host" = "" ]; then - git_host="github.com" - echo "[INFO] No command line input provided. Set \$git_host to $git_host" -fi - -if [ "$git_user_id" = "" ]; then - git_user_id="marinsalinas" - echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" -fi - -if [ "$git_repo_id" = "" ]; then - git_repo_id="osc-sdk-go" - echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" -fi - -if [ "$release_note" = "" ]; then - release_note="Minor update" - echo "[INFO] No command line input provided. Set \$release_note to $release_note" -fi - -# Initialize the local directory as a Git repository -git init - -# Adds the files in the local repository and stages them for commit. -git add . - -# Commits the tracked changes and prepares them to be pushed to a remote repository. -git commit -m "$release_note" - -# Sets the new remote -git_remote=`git remote` -if [ "$git_remote" = "" ]; then # git remote not defined - - if [ "$GIT_TOKEN" = "" ]; then - echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." - git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git - else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git - fi - -fi - -git pull origin master - -# Pushes (Forces) the changes in the local repository up to the remote repository -echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" -git push origin master 2>&1 | grep -v 'To https' - diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/go.mod b/vendor/github.com/marinsalinas/osc-sdk-go/go.mod deleted file mode 100644 index 9a7a98fef..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/go.mod +++ /dev/null @@ -1,9 +0,0 @@ -module github.com/marinsalinas/osc-sdk-go - -go 1.13 - -require ( - github.com/antihax/optional v1.0.0 - github.com/aws/aws-sdk-go v1.31.10 - golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 -) diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/go.sum b/vendor/github.com/marinsalinas/osc-sdk-go/go.sum deleted file mode 100644 index e16f4b5aa..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/go.sum +++ /dev/null @@ -1,31 +0,0 @@ -cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -github.com/antihax/optional v1.0.0 h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg= -github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= -github.com/aws/aws-sdk-go v1.31.10 h1:33jOMifUSdOP9pvNEOj+PGwljzunc8bJvKKNF/JuGzo= -github.com/aws/aws-sdk-go v1.31.10/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= -github.com/golang/protobuf v1.2.0 h1:P3YflyNX/ehuJFLhxviNdFxQPkGK5cDcApsge1SqnvM= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/jmespath/go-jmespath v0.3.0 h1:OS12ieG61fsCg5+qLJ+SsW9NicxNkg3b25OyT2yCeUc= -github.com/jmespath/go-jmespath v0.3.0/go.mod h1:9QtRXoHjLGCJ5IBSaohpXITPlowMeeYCZ7fLUTSywik= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= -golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e h1:bRhVy7zSSasaqNksaRZiA5EEI+Ei4I1nO5Jh72wfHlg= -golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20200202094626-16171245cfb2 h1:CCH4IOTTfewWjGOlSp+zGcjutRKlBEZQ6wTn8ozI/nI= -golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45 h1:SVwTIAaPC2U/AvvLNZ2a7OVsmBpC8L5BlwK1whH3hm0= -golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= -golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4 h1:YUO/7uOKsKeq9UokNS62b8FYywz3ker1l1vDZRCRefw= -golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -google.golang.org/appengine v1.4.0 h1:/wp5JvzpHIxhs/dumFmF7BXTf3Z+dd4uXta4kVyO508= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_request.go deleted file mode 100644 index 9d84d0148..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AcceptNetPeeringRequest struct for AcceptNetPeeringRequest -type AcceptNetPeeringRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net peering connection you want to accept. - NetPeeringId string `json:"NetPeeringId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *AcceptNetPeeringRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AcceptNetPeeringRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *AcceptNetPeeringRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *AcceptNetPeeringRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetPeeringId returns the NetPeeringId field value -func (o *AcceptNetPeeringRequest) GetNetPeeringId() string { - if o == nil { - var ret string - return ret - } - - return o.NetPeeringId -} - -// SetNetPeeringId sets field value -func (o *AcceptNetPeeringRequest) SetNetPeeringId(v string) { - o.NetPeeringId = v -} - -type NullableAcceptNetPeeringRequest struct { - Value AcceptNetPeeringRequest - ExplicitNull bool -} - -func (v NullableAcceptNetPeeringRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAcceptNetPeeringRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_response.go deleted file mode 100644 index 812e0b0bf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_accept_net_peering_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AcceptNetPeeringResponse struct for AcceptNetPeeringResponse -type AcceptNetPeeringResponse struct { - NetPeering *NetPeering `json:"NetPeering,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetPeering returns the NetPeering field value if set, zero value otherwise. -func (o *AcceptNetPeeringResponse) GetNetPeering() NetPeering { - if o == nil || o.NetPeering == nil { - var ret NetPeering - return ret - } - return *o.NetPeering -} - -// GetNetPeeringOk returns a tuple with the NetPeering field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AcceptNetPeeringResponse) GetNetPeeringOk() (NetPeering, bool) { - if o == nil || o.NetPeering == nil { - var ret NetPeering - return ret, false - } - return *o.NetPeering, true -} - -// HasNetPeering returns a boolean if a field has been set. -func (o *AcceptNetPeeringResponse) HasNetPeering() bool { - if o != nil && o.NetPeering != nil { - return true - } - - return false -} - -// SetNetPeering gets a reference to the given NetPeering and assigns it to the NetPeering field. -func (o *AcceptNetPeeringResponse) SetNetPeering(v NetPeering) { - o.NetPeering = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *AcceptNetPeeringResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AcceptNetPeeringResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *AcceptNetPeeringResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *AcceptNetPeeringResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableAcceptNetPeeringResponse struct { - Value AcceptNetPeeringResponse - ExplicitNull bool -} - -func (v NullableAcceptNetPeeringResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAcceptNetPeeringResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_accepter_net.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_accepter_net.go deleted file mode 100644 index 98fe43cb5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_accepter_net.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AccepterNet Information about the accepter Net. -type AccepterNet struct { - // The account ID of the owner of the accepter Net. - AccountId *string `json:"AccountId,omitempty"` - // The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // The ID of the accepter Net. - NetId *string `json:"NetId,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *AccepterNet) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccepterNet) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *AccepterNet) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *AccepterNet) SetAccountId(v string) { - o.AccountId = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *AccepterNet) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccepterNet) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *AccepterNet) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *AccepterNet) SetIpRange(v string) { - o.IpRange = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *AccepterNet) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccepterNet) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *AccepterNet) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *AccepterNet) SetNetId(v string) { - o.NetId = &v -} - -type NullableAccepterNet struct { - Value AccepterNet - ExplicitNull bool -} - -func (v NullableAccepterNet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAccepterNet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key.go deleted file mode 100644 index 5fd248ac4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AccessKey Information about the access key. -type AccessKey struct { - // The ID of the access key. - AccessKeyId *string `json:"AccessKeyId,omitempty"` - // The date and time of creation of the access key. - CreationDate *string `json:"CreationDate,omitempty"` - // The date and time of the last modification of the access key. - LastModificationDate *string `json:"LastModificationDate,omitempty"` - // The state of the access key (`Active` if the key is valid for API calls, or `Inactive` if not). - State *string `json:"State,omitempty"` -} - -// GetAccessKeyId returns the AccessKeyId field value if set, zero value otherwise. -func (o *AccessKey) GetAccessKeyId() string { - if o == nil || o.AccessKeyId == nil { - var ret string - return ret - } - return *o.AccessKeyId -} - -// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKey) GetAccessKeyIdOk() (string, bool) { - if o == nil || o.AccessKeyId == nil { - var ret string - return ret, false - } - return *o.AccessKeyId, true -} - -// HasAccessKeyId returns a boolean if a field has been set. -func (o *AccessKey) HasAccessKeyId() bool { - if o != nil && o.AccessKeyId != nil { - return true - } - - return false -} - -// SetAccessKeyId gets a reference to the given string and assigns it to the AccessKeyId field. -func (o *AccessKey) SetAccessKeyId(v string) { - o.AccessKeyId = &v -} - -// GetCreationDate returns the CreationDate field value if set, zero value otherwise. -func (o *AccessKey) GetCreationDate() string { - if o == nil || o.CreationDate == nil { - var ret string - return ret - } - return *o.CreationDate -} - -// GetCreationDateOk returns a tuple with the CreationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKey) GetCreationDateOk() (string, bool) { - if o == nil || o.CreationDate == nil { - var ret string - return ret, false - } - return *o.CreationDate, true -} - -// HasCreationDate returns a boolean if a field has been set. -func (o *AccessKey) HasCreationDate() bool { - if o != nil && o.CreationDate != nil { - return true - } - - return false -} - -// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. -func (o *AccessKey) SetCreationDate(v string) { - o.CreationDate = &v -} - -// GetLastModificationDate returns the LastModificationDate field value if set, zero value otherwise. -func (o *AccessKey) GetLastModificationDate() string { - if o == nil || o.LastModificationDate == nil { - var ret string - return ret - } - return *o.LastModificationDate -} - -// GetLastModificationDateOk returns a tuple with the LastModificationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKey) GetLastModificationDateOk() (string, bool) { - if o == nil || o.LastModificationDate == nil { - var ret string - return ret, false - } - return *o.LastModificationDate, true -} - -// HasLastModificationDate returns a boolean if a field has been set. -func (o *AccessKey) HasLastModificationDate() bool { - if o != nil && o.LastModificationDate != nil { - return true - } - - return false -} - -// SetLastModificationDate gets a reference to the given string and assigns it to the LastModificationDate field. -func (o *AccessKey) SetLastModificationDate(v string) { - o.LastModificationDate = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *AccessKey) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKey) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *AccessKey) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *AccessKey) SetState(v string) { - o.State = &v -} - -type NullableAccessKey struct { - Value AccessKey - ExplicitNull bool -} - -func (v NullableAccessKey) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAccessKey) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key_secret_key.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key_secret_key.go deleted file mode 100644 index 88297e117..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_key_secret_key.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AccessKeySecretKey Information about the secret access key. -type AccessKeySecretKey struct { - // The ID of the secret access key. - AccessKeyId *string `json:"AccessKeyId,omitempty"` - // The date and time of creation of the secret access key. - CreationDate *string `json:"CreationDate,omitempty"` - // The date and time of the last modification of the secret access key. - LastModificationDate *string `json:"LastModificationDate,omitempty"` - // The secret access key that enables you to send requests. - SecretKey *string `json:"SecretKey,omitempty"` - // The state of the secret access key (`Active` if the key is valid for API calls, or `Inactive` if not). - State *string `json:"State,omitempty"` -} - -// GetAccessKeyId returns the AccessKeyId field value if set, zero value otherwise. -func (o *AccessKeySecretKey) GetAccessKeyId() string { - if o == nil || o.AccessKeyId == nil { - var ret string - return ret - } - return *o.AccessKeyId -} - -// GetAccessKeyIdOk returns a tuple with the AccessKeyId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKeySecretKey) GetAccessKeyIdOk() (string, bool) { - if o == nil || o.AccessKeyId == nil { - var ret string - return ret, false - } - return *o.AccessKeyId, true -} - -// HasAccessKeyId returns a boolean if a field has been set. -func (o *AccessKeySecretKey) HasAccessKeyId() bool { - if o != nil && o.AccessKeyId != nil { - return true - } - - return false -} - -// SetAccessKeyId gets a reference to the given string and assigns it to the AccessKeyId field. -func (o *AccessKeySecretKey) SetAccessKeyId(v string) { - o.AccessKeyId = &v -} - -// GetCreationDate returns the CreationDate field value if set, zero value otherwise. -func (o *AccessKeySecretKey) GetCreationDate() string { - if o == nil || o.CreationDate == nil { - var ret string - return ret - } - return *o.CreationDate -} - -// GetCreationDateOk returns a tuple with the CreationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKeySecretKey) GetCreationDateOk() (string, bool) { - if o == nil || o.CreationDate == nil { - var ret string - return ret, false - } - return *o.CreationDate, true -} - -// HasCreationDate returns a boolean if a field has been set. -func (o *AccessKeySecretKey) HasCreationDate() bool { - if o != nil && o.CreationDate != nil { - return true - } - - return false -} - -// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. -func (o *AccessKeySecretKey) SetCreationDate(v string) { - o.CreationDate = &v -} - -// GetLastModificationDate returns the LastModificationDate field value if set, zero value otherwise. -func (o *AccessKeySecretKey) GetLastModificationDate() string { - if o == nil || o.LastModificationDate == nil { - var ret string - return ret - } - return *o.LastModificationDate -} - -// GetLastModificationDateOk returns a tuple with the LastModificationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKeySecretKey) GetLastModificationDateOk() (string, bool) { - if o == nil || o.LastModificationDate == nil { - var ret string - return ret, false - } - return *o.LastModificationDate, true -} - -// HasLastModificationDate returns a boolean if a field has been set. -func (o *AccessKeySecretKey) HasLastModificationDate() bool { - if o != nil && o.LastModificationDate != nil { - return true - } - - return false -} - -// SetLastModificationDate gets a reference to the given string and assigns it to the LastModificationDate field. -func (o *AccessKeySecretKey) SetLastModificationDate(v string) { - o.LastModificationDate = &v -} - -// GetSecretKey returns the SecretKey field value if set, zero value otherwise. -func (o *AccessKeySecretKey) GetSecretKey() string { - if o == nil || o.SecretKey == nil { - var ret string - return ret - } - return *o.SecretKey -} - -// GetSecretKeyOk returns a tuple with the SecretKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKeySecretKey) GetSecretKeyOk() (string, bool) { - if o == nil || o.SecretKey == nil { - var ret string - return ret, false - } - return *o.SecretKey, true -} - -// HasSecretKey returns a boolean if a field has been set. -func (o *AccessKeySecretKey) HasSecretKey() bool { - if o != nil && o.SecretKey != nil { - return true - } - - return false -} - -// SetSecretKey gets a reference to the given string and assigns it to the SecretKey field. -func (o *AccessKeySecretKey) SetSecretKey(v string) { - o.SecretKey = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *AccessKeySecretKey) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessKeySecretKey) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *AccessKeySecretKey) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *AccessKeySecretKey) SetState(v string) { - o.State = &v -} - -type NullableAccessKeySecretKey struct { - Value AccessKeySecretKey - ExplicitNull bool -} - -func (v NullableAccessKeySecretKey) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAccessKeySecretKey) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_log.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_access_log.go deleted file mode 100644 index ac39aad7b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_access_log.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// AccessLog Information about access logs. -type AccessLog struct { - // If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - IsEnabled *bool `json:"IsEnabled,omitempty"` - // The name of the Object Storage Unit (OSU) bucket for the access logs. - OsuBucketName *string `json:"OsuBucketName,omitempty"` - // The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - OsuBucketPrefix *string `json:"OsuBucketPrefix,omitempty"` - // The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). - PublicationInterval *int64 `json:"PublicationInterval,omitempty"` -} - -// GetIsEnabled returns the IsEnabled field value if set, zero value otherwise. -func (o *AccessLog) GetIsEnabled() bool { - if o == nil || o.IsEnabled == nil { - var ret bool - return ret - } - return *o.IsEnabled -} - -// GetIsEnabledOk returns a tuple with the IsEnabled field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessLog) GetIsEnabledOk() (bool, bool) { - if o == nil || o.IsEnabled == nil { - var ret bool - return ret, false - } - return *o.IsEnabled, true -} - -// HasIsEnabled returns a boolean if a field has been set. -func (o *AccessLog) HasIsEnabled() bool { - if o != nil && o.IsEnabled != nil { - return true - } - - return false -} - -// SetIsEnabled gets a reference to the given bool and assigns it to the IsEnabled field. -func (o *AccessLog) SetIsEnabled(v bool) { - o.IsEnabled = &v -} - -// GetOsuBucketName returns the OsuBucketName field value if set, zero value otherwise. -func (o *AccessLog) GetOsuBucketName() string { - if o == nil || o.OsuBucketName == nil { - var ret string - return ret - } - return *o.OsuBucketName -} - -// GetOsuBucketNameOk returns a tuple with the OsuBucketName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessLog) GetOsuBucketNameOk() (string, bool) { - if o == nil || o.OsuBucketName == nil { - var ret string - return ret, false - } - return *o.OsuBucketName, true -} - -// HasOsuBucketName returns a boolean if a field has been set. -func (o *AccessLog) HasOsuBucketName() bool { - if o != nil && o.OsuBucketName != nil { - return true - } - - return false -} - -// SetOsuBucketName gets a reference to the given string and assigns it to the OsuBucketName field. -func (o *AccessLog) SetOsuBucketName(v string) { - o.OsuBucketName = &v -} - -// GetOsuBucketPrefix returns the OsuBucketPrefix field value if set, zero value otherwise. -func (o *AccessLog) GetOsuBucketPrefix() string { - if o == nil || o.OsuBucketPrefix == nil { - var ret string - return ret - } - return *o.OsuBucketPrefix -} - -// GetOsuBucketPrefixOk returns a tuple with the OsuBucketPrefix field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessLog) GetOsuBucketPrefixOk() (string, bool) { - if o == nil || o.OsuBucketPrefix == nil { - var ret string - return ret, false - } - return *o.OsuBucketPrefix, true -} - -// HasOsuBucketPrefix returns a boolean if a field has been set. -func (o *AccessLog) HasOsuBucketPrefix() bool { - if o != nil && o.OsuBucketPrefix != nil { - return true - } - - return false -} - -// SetOsuBucketPrefix gets a reference to the given string and assigns it to the OsuBucketPrefix field. -func (o *AccessLog) SetOsuBucketPrefix(v string) { - o.OsuBucketPrefix = &v -} - -// GetPublicationInterval returns the PublicationInterval field value if set, zero value otherwise. -func (o *AccessLog) GetPublicationInterval() int64 { - if o == nil || o.PublicationInterval == nil { - var ret int64 - return ret - } - return *o.PublicationInterval -} - -// GetPublicationIntervalOk returns a tuple with the PublicationInterval field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *AccessLog) GetPublicationIntervalOk() (int64, bool) { - if o == nil || o.PublicationInterval == nil { - var ret int64 - return ret, false - } - return *o.PublicationInterval, true -} - -// HasPublicationInterval returns a boolean if a field has been set. -func (o *AccessLog) HasPublicationInterval() bool { - if o != nil && o.PublicationInterval != nil { - return true - } - - return false -} - -// SetPublicationInterval gets a reference to the given int64 and assigns it to the PublicationInterval field. -func (o *AccessLog) SetPublicationInterval(v int64) { - o.PublicationInterval = &v -} - -type NullableAccessLog struct { - Value AccessLog - ExplicitNull bool -} - -func (v NullableAccessLog) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAccessLog) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_account.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_account.go deleted file mode 100644 index bd27b8097..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_account.go +++ /dev/null @@ -1,533 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Account Information about the account. -type Account struct { - // The ID of the account. - AccountId *string `json:"AccountId,omitempty"` - // The city of the account owner. - City *string `json:"City,omitempty"` - // The name of the company for the account. - CompanyName *string `json:"CompanyName,omitempty"` - // The country of the account owner. - Country *string `json:"Country,omitempty"` - // The ID of the customer. It must be 8 digits (by default, `12345678`). - CustomerId *string `json:"CustomerId,omitempty"` - // The email address for the account. - Email *string `json:"Email,omitempty"` - // The first name of the account owner. - FirstName *string `json:"FirstName,omitempty"` - // The job title of the account owner. - JobTitle *string `json:"JobTitle,omitempty"` - // The last name of the account owner. - LastName *string `json:"LastName,omitempty"` - // The mobile phone number of the account owner. - MobileNumber *string `json:"MobileNumber,omitempty"` - // The landline phone number of the account owner. - PhoneNumber *string `json:"PhoneNumber,omitempty"` - // The state/province of the account. - StateProvince *string `json:"StateProvince,omitempty"` - // The value added tax (VAT) number for the account. - VatNumber *string `json:"VatNumber,omitempty"` - // The ZIP code of the city. - ZipCode *string `json:"ZipCode,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Account) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Account) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Account) SetAccountId(v string) { - o.AccountId = &v -} - -// GetCity returns the City field value if set, zero value otherwise. -func (o *Account) GetCity() string { - if o == nil || o.City == nil { - var ret string - return ret - } - return *o.City -} - -// GetCityOk returns a tuple with the City field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetCityOk() (string, bool) { - if o == nil || o.City == nil { - var ret string - return ret, false - } - return *o.City, true -} - -// HasCity returns a boolean if a field has been set. -func (o *Account) HasCity() bool { - if o != nil && o.City != nil { - return true - } - - return false -} - -// SetCity gets a reference to the given string and assigns it to the City field. -func (o *Account) SetCity(v string) { - o.City = &v -} - -// GetCompanyName returns the CompanyName field value if set, zero value otherwise. -func (o *Account) GetCompanyName() string { - if o == nil || o.CompanyName == nil { - var ret string - return ret - } - return *o.CompanyName -} - -// GetCompanyNameOk returns a tuple with the CompanyName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetCompanyNameOk() (string, bool) { - if o == nil || o.CompanyName == nil { - var ret string - return ret, false - } - return *o.CompanyName, true -} - -// HasCompanyName returns a boolean if a field has been set. -func (o *Account) HasCompanyName() bool { - if o != nil && o.CompanyName != nil { - return true - } - - return false -} - -// SetCompanyName gets a reference to the given string and assigns it to the CompanyName field. -func (o *Account) SetCompanyName(v string) { - o.CompanyName = &v -} - -// GetCountry returns the Country field value if set, zero value otherwise. -func (o *Account) GetCountry() string { - if o == nil || o.Country == nil { - var ret string - return ret - } - return *o.Country -} - -// GetCountryOk returns a tuple with the Country field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetCountryOk() (string, bool) { - if o == nil || o.Country == nil { - var ret string - return ret, false - } - return *o.Country, true -} - -// HasCountry returns a boolean if a field has been set. -func (o *Account) HasCountry() bool { - if o != nil && o.Country != nil { - return true - } - - return false -} - -// SetCountry gets a reference to the given string and assigns it to the Country field. -func (o *Account) SetCountry(v string) { - o.Country = &v -} - -// GetCustomerId returns the CustomerId field value if set, zero value otherwise. -func (o *Account) GetCustomerId() string { - if o == nil || o.CustomerId == nil { - var ret string - return ret - } - return *o.CustomerId -} - -// GetCustomerIdOk returns a tuple with the CustomerId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetCustomerIdOk() (string, bool) { - if o == nil || o.CustomerId == nil { - var ret string - return ret, false - } - return *o.CustomerId, true -} - -// HasCustomerId returns a boolean if a field has been set. -func (o *Account) HasCustomerId() bool { - if o != nil && o.CustomerId != nil { - return true - } - - return false -} - -// SetCustomerId gets a reference to the given string and assigns it to the CustomerId field. -func (o *Account) SetCustomerId(v string) { - o.CustomerId = &v -} - -// GetEmail returns the Email field value if set, zero value otherwise. -func (o *Account) GetEmail() string { - if o == nil || o.Email == nil { - var ret string - return ret - } - return *o.Email -} - -// GetEmailOk returns a tuple with the Email field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetEmailOk() (string, bool) { - if o == nil || o.Email == nil { - var ret string - return ret, false - } - return *o.Email, true -} - -// HasEmail returns a boolean if a field has been set. -func (o *Account) HasEmail() bool { - if o != nil && o.Email != nil { - return true - } - - return false -} - -// SetEmail gets a reference to the given string and assigns it to the Email field. -func (o *Account) SetEmail(v string) { - o.Email = &v -} - -// GetFirstName returns the FirstName field value if set, zero value otherwise. -func (o *Account) GetFirstName() string { - if o == nil || o.FirstName == nil { - var ret string - return ret - } - return *o.FirstName -} - -// GetFirstNameOk returns a tuple with the FirstName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetFirstNameOk() (string, bool) { - if o == nil || o.FirstName == nil { - var ret string - return ret, false - } - return *o.FirstName, true -} - -// HasFirstName returns a boolean if a field has been set. -func (o *Account) HasFirstName() bool { - if o != nil && o.FirstName != nil { - return true - } - - return false -} - -// SetFirstName gets a reference to the given string and assigns it to the FirstName field. -func (o *Account) SetFirstName(v string) { - o.FirstName = &v -} - -// GetJobTitle returns the JobTitle field value if set, zero value otherwise. -func (o *Account) GetJobTitle() string { - if o == nil || o.JobTitle == nil { - var ret string - return ret - } - return *o.JobTitle -} - -// GetJobTitleOk returns a tuple with the JobTitle field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetJobTitleOk() (string, bool) { - if o == nil || o.JobTitle == nil { - var ret string - return ret, false - } - return *o.JobTitle, true -} - -// HasJobTitle returns a boolean if a field has been set. -func (o *Account) HasJobTitle() bool { - if o != nil && o.JobTitle != nil { - return true - } - - return false -} - -// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. -func (o *Account) SetJobTitle(v string) { - o.JobTitle = &v -} - -// GetLastName returns the LastName field value if set, zero value otherwise. -func (o *Account) GetLastName() string { - if o == nil || o.LastName == nil { - var ret string - return ret - } - return *o.LastName -} - -// GetLastNameOk returns a tuple with the LastName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetLastNameOk() (string, bool) { - if o == nil || o.LastName == nil { - var ret string - return ret, false - } - return *o.LastName, true -} - -// HasLastName returns a boolean if a field has been set. -func (o *Account) HasLastName() bool { - if o != nil && o.LastName != nil { - return true - } - - return false -} - -// SetLastName gets a reference to the given string and assigns it to the LastName field. -func (o *Account) SetLastName(v string) { - o.LastName = &v -} - -// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. -func (o *Account) GetMobileNumber() string { - if o == nil || o.MobileNumber == nil { - var ret string - return ret - } - return *o.MobileNumber -} - -// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetMobileNumberOk() (string, bool) { - if o == nil || o.MobileNumber == nil { - var ret string - return ret, false - } - return *o.MobileNumber, true -} - -// HasMobileNumber returns a boolean if a field has been set. -func (o *Account) HasMobileNumber() bool { - if o != nil && o.MobileNumber != nil { - return true - } - - return false -} - -// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. -func (o *Account) SetMobileNumber(v string) { - o.MobileNumber = &v -} - -// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. -func (o *Account) GetPhoneNumber() string { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret - } - return *o.PhoneNumber -} - -// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetPhoneNumberOk() (string, bool) { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret, false - } - return *o.PhoneNumber, true -} - -// HasPhoneNumber returns a boolean if a field has been set. -func (o *Account) HasPhoneNumber() bool { - if o != nil && o.PhoneNumber != nil { - return true - } - - return false -} - -// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. -func (o *Account) SetPhoneNumber(v string) { - o.PhoneNumber = &v -} - -// GetStateProvince returns the StateProvince field value if set, zero value otherwise. -func (o *Account) GetStateProvince() string { - if o == nil || o.StateProvince == nil { - var ret string - return ret - } - return *o.StateProvince -} - -// GetStateProvinceOk returns a tuple with the StateProvince field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetStateProvinceOk() (string, bool) { - if o == nil || o.StateProvince == nil { - var ret string - return ret, false - } - return *o.StateProvince, true -} - -// HasStateProvince returns a boolean if a field has been set. -func (o *Account) HasStateProvince() bool { - if o != nil && o.StateProvince != nil { - return true - } - - return false -} - -// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. -func (o *Account) SetStateProvince(v string) { - o.StateProvince = &v -} - -// GetVatNumber returns the VatNumber field value if set, zero value otherwise. -func (o *Account) GetVatNumber() string { - if o == nil || o.VatNumber == nil { - var ret string - return ret - } - return *o.VatNumber -} - -// GetVatNumberOk returns a tuple with the VatNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetVatNumberOk() (string, bool) { - if o == nil || o.VatNumber == nil { - var ret string - return ret, false - } - return *o.VatNumber, true -} - -// HasVatNumber returns a boolean if a field has been set. -func (o *Account) HasVatNumber() bool { - if o != nil && o.VatNumber != nil { - return true - } - - return false -} - -// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. -func (o *Account) SetVatNumber(v string) { - o.VatNumber = &v -} - -// GetZipCode returns the ZipCode field value if set, zero value otherwise. -func (o *Account) GetZipCode() string { - if o == nil || o.ZipCode == nil { - var ret string - return ret - } - return *o.ZipCode -} - -// GetZipCodeOk returns a tuple with the ZipCode field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Account) GetZipCodeOk() (string, bool) { - if o == nil || o.ZipCode == nil { - var ret string - return ret, false - } - return *o.ZipCode, true -} - -// HasZipCode returns a boolean if a field has been set. -func (o *Account) HasZipCode() bool { - if o != nil && o.ZipCode != nil { - return true - } - - return false -} - -// SetZipCode gets a reference to the given string and assigns it to the ZipCode field. -func (o *Account) SetZipCode(v string) { - o.ZipCode = &v -} - -type NullableAccount struct { - Value Account - ExplicitNull bool -} - -func (v NullableAccount) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableAccount) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_application_sticky_cookie_policy.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_application_sticky_cookie_policy.go deleted file mode 100644 index cfaa185af..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_application_sticky_cookie_policy.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ApplicationStickyCookiePolicy Information about the stickiness policy. -type ApplicationStickyCookiePolicy struct { - // The name of the application cookie used for stickiness. - CookieName *string `json:"CookieName,omitempty"` - // The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. - PolicyName *string `json:"PolicyName,omitempty"` -} - -// GetCookieName returns the CookieName field value if set, zero value otherwise. -func (o *ApplicationStickyCookiePolicy) GetCookieName() string { - if o == nil || o.CookieName == nil { - var ret string - return ret - } - return *o.CookieName -} - -// GetCookieNameOk returns a tuple with the CookieName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ApplicationStickyCookiePolicy) GetCookieNameOk() (string, bool) { - if o == nil || o.CookieName == nil { - var ret string - return ret, false - } - return *o.CookieName, true -} - -// HasCookieName returns a boolean if a field has been set. -func (o *ApplicationStickyCookiePolicy) HasCookieName() bool { - if o != nil && o.CookieName != nil { - return true - } - - return false -} - -// SetCookieName gets a reference to the given string and assigns it to the CookieName field. -func (o *ApplicationStickyCookiePolicy) SetCookieName(v string) { - o.CookieName = &v -} - -// GetPolicyName returns the PolicyName field value if set, zero value otherwise. -func (o *ApplicationStickyCookiePolicy) GetPolicyName() string { - if o == nil || o.PolicyName == nil { - var ret string - return ret - } - return *o.PolicyName -} - -// GetPolicyNameOk returns a tuple with the PolicyName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ApplicationStickyCookiePolicy) GetPolicyNameOk() (string, bool) { - if o == nil || o.PolicyName == nil { - var ret string - return ret, false - } - return *o.PolicyName, true -} - -// HasPolicyName returns a boolean if a field has been set. -func (o *ApplicationStickyCookiePolicy) HasPolicyName() bool { - if o != nil && o.PolicyName != nil { - return true - } - - return false -} - -// SetPolicyName gets a reference to the given string and assigns it to the PolicyName field. -func (o *ApplicationStickyCookiePolicy) SetPolicyName(v string) { - o.PolicyName = &v -} - -type NullableApplicationStickyCookiePolicy struct { - Value ApplicationStickyCookiePolicy - ExplicitNull bool -} - -func (v NullableApplicationStickyCookiePolicy) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableApplicationStickyCookiePolicy) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_backend_vm_health.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_backend_vm_health.go deleted file mode 100644 index d194caf35..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_backend_vm_health.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BackendVmHealth Information about the health of a back-end VM. -type BackendVmHealth struct { - // The description of the state of the back-end VM. - Description *string `json:"Description,omitempty"` - // The state of the back-end VM (`InService` \\| `OutOfService` \\| `Unknown`). - State *string `json:"State,omitempty"` - // Information about the cause of `OutOfService` VMs.
Specifically, whether the cause is Elastic Load Balancing or the VM (`ELB` \\| `Instance` \\| `N/A`). - StateReason *string `json:"StateReason,omitempty"` - // The ID of the back-end VM. - VmId *string `json:"VmId,omitempty"` -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *BackendVmHealth) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BackendVmHealth) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *BackendVmHealth) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *BackendVmHealth) SetDescription(v string) { - o.Description = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *BackendVmHealth) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BackendVmHealth) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *BackendVmHealth) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *BackendVmHealth) SetState(v string) { - o.State = &v -} - -// GetStateReason returns the StateReason field value if set, zero value otherwise. -func (o *BackendVmHealth) GetStateReason() string { - if o == nil || o.StateReason == nil { - var ret string - return ret - } - return *o.StateReason -} - -// GetStateReasonOk returns a tuple with the StateReason field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BackendVmHealth) GetStateReasonOk() (string, bool) { - if o == nil || o.StateReason == nil { - var ret string - return ret, false - } - return *o.StateReason, true -} - -// HasStateReason returns a boolean if a field has been set. -func (o *BackendVmHealth) HasStateReason() bool { - if o != nil && o.StateReason != nil { - return true - } - - return false -} - -// SetStateReason gets a reference to the given string and assigns it to the StateReason field. -func (o *BackendVmHealth) SetStateReason(v string) { - o.StateReason = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *BackendVmHealth) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BackendVmHealth) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *BackendVmHealth) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *BackendVmHealth) SetVmId(v string) { - o.VmId = &v -} - -type NullableBackendVmHealth struct { - Value BackendVmHealth - ExplicitNull bool -} - -func (v NullableBackendVmHealth) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBackendVmHealth) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_created.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_created.go deleted file mode 100644 index 35c8a3774..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_created.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BlockDeviceMappingCreated Information about the created block device mapping. -type BlockDeviceMappingCreated struct { - Bsu *BsuCreated `json:"Bsu,omitempty"` - // The name of the device. - DeviceName *string `json:"DeviceName,omitempty"` -} - -// GetBsu returns the Bsu field value if set, zero value otherwise. -func (o *BlockDeviceMappingCreated) GetBsu() BsuCreated { - if o == nil || o.Bsu == nil { - var ret BsuCreated - return ret - } - return *o.Bsu -} - -// GetBsuOk returns a tuple with the Bsu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingCreated) GetBsuOk() (BsuCreated, bool) { - if o == nil || o.Bsu == nil { - var ret BsuCreated - return ret, false - } - return *o.Bsu, true -} - -// HasBsu returns a boolean if a field has been set. -func (o *BlockDeviceMappingCreated) HasBsu() bool { - if o != nil && o.Bsu != nil { - return true - } - - return false -} - -// SetBsu gets a reference to the given BsuCreated and assigns it to the Bsu field. -func (o *BlockDeviceMappingCreated) SetBsu(v BsuCreated) { - o.Bsu = &v -} - -// GetDeviceName returns the DeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingCreated) GetDeviceName() string { - if o == nil || o.DeviceName == nil { - var ret string - return ret - } - return *o.DeviceName -} - -// GetDeviceNameOk returns a tuple with the DeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingCreated) GetDeviceNameOk() (string, bool) { - if o == nil || o.DeviceName == nil { - var ret string - return ret, false - } - return *o.DeviceName, true -} - -// HasDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingCreated) HasDeviceName() bool { - if o != nil && o.DeviceName != nil { - return true - } - - return false -} - -// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. -func (o *BlockDeviceMappingCreated) SetDeviceName(v string) { - o.DeviceName = &v -} - -type NullableBlockDeviceMappingCreated struct { - Value BlockDeviceMappingCreated - ExplicitNull bool -} - -func (v NullableBlockDeviceMappingCreated) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBlockDeviceMappingCreated) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_image.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_image.go deleted file mode 100644 index 20beea97b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_image.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BlockDeviceMappingImage One or more parameters used to automatically set up volumes when the VM is created. -type BlockDeviceMappingImage struct { - Bsu *BsuToCreate `json:"Bsu,omitempty"` - // The name of the device. - DeviceName *string `json:"DeviceName,omitempty"` - // The name of the virtual device (ephemeralN). - VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` -} - -// GetBsu returns the Bsu field value if set, zero value otherwise. -func (o *BlockDeviceMappingImage) GetBsu() BsuToCreate { - if o == nil || o.Bsu == nil { - var ret BsuToCreate - return ret - } - return *o.Bsu -} - -// GetBsuOk returns a tuple with the Bsu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingImage) GetBsuOk() (BsuToCreate, bool) { - if o == nil || o.Bsu == nil { - var ret BsuToCreate - return ret, false - } - return *o.Bsu, true -} - -// HasBsu returns a boolean if a field has been set. -func (o *BlockDeviceMappingImage) HasBsu() bool { - if o != nil && o.Bsu != nil { - return true - } - - return false -} - -// SetBsu gets a reference to the given BsuToCreate and assigns it to the Bsu field. -func (o *BlockDeviceMappingImage) SetBsu(v BsuToCreate) { - o.Bsu = &v -} - -// GetDeviceName returns the DeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingImage) GetDeviceName() string { - if o == nil || o.DeviceName == nil { - var ret string - return ret - } - return *o.DeviceName -} - -// GetDeviceNameOk returns a tuple with the DeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingImage) GetDeviceNameOk() (string, bool) { - if o == nil || o.DeviceName == nil { - var ret string - return ret, false - } - return *o.DeviceName, true -} - -// HasDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingImage) HasDeviceName() bool { - if o != nil && o.DeviceName != nil { - return true - } - - return false -} - -// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. -func (o *BlockDeviceMappingImage) SetDeviceName(v string) { - o.DeviceName = &v -} - -// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingImage) GetVirtualDeviceName() string { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret - } - return *o.VirtualDeviceName -} - -// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingImage) GetVirtualDeviceNameOk() (string, bool) { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret, false - } - return *o.VirtualDeviceName, true -} - -// HasVirtualDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingImage) HasVirtualDeviceName() bool { - if o != nil && o.VirtualDeviceName != nil { - return true - } - - return false -} - -// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. -func (o *BlockDeviceMappingImage) SetVirtualDeviceName(v string) { - o.VirtualDeviceName = &v -} - -type NullableBlockDeviceMappingImage struct { - Value BlockDeviceMappingImage - ExplicitNull bool -} - -func (v NullableBlockDeviceMappingImage) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBlockDeviceMappingImage) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_creation.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_creation.go deleted file mode 100644 index c6e744865..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_creation.go +++ /dev/null @@ -1,182 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BlockDeviceMappingVmCreation Information about the block device mapping. -type BlockDeviceMappingVmCreation struct { - Bsu *BsuToCreate `json:"Bsu,omitempty"` - // The name of the device. - DeviceName *string `json:"DeviceName,omitempty"` - // Removes the device which is included in the block device mapping of the OMI. - NoDevice *string `json:"NoDevice,omitempty"` - // The name of the virtual device (ephemeralN). - VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` -} - -// GetBsu returns the Bsu field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmCreation) GetBsu() BsuToCreate { - if o == nil || o.Bsu == nil { - var ret BsuToCreate - return ret - } - return *o.Bsu -} - -// GetBsuOk returns a tuple with the Bsu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmCreation) GetBsuOk() (BsuToCreate, bool) { - if o == nil || o.Bsu == nil { - var ret BsuToCreate - return ret, false - } - return *o.Bsu, true -} - -// HasBsu returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmCreation) HasBsu() bool { - if o != nil && o.Bsu != nil { - return true - } - - return false -} - -// SetBsu gets a reference to the given BsuToCreate and assigns it to the Bsu field. -func (o *BlockDeviceMappingVmCreation) SetBsu(v BsuToCreate) { - o.Bsu = &v -} - -// GetDeviceName returns the DeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmCreation) GetDeviceName() string { - if o == nil || o.DeviceName == nil { - var ret string - return ret - } - return *o.DeviceName -} - -// GetDeviceNameOk returns a tuple with the DeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmCreation) GetDeviceNameOk() (string, bool) { - if o == nil || o.DeviceName == nil { - var ret string - return ret, false - } - return *o.DeviceName, true -} - -// HasDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmCreation) HasDeviceName() bool { - if o != nil && o.DeviceName != nil { - return true - } - - return false -} - -// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. -func (o *BlockDeviceMappingVmCreation) SetDeviceName(v string) { - o.DeviceName = &v -} - -// GetNoDevice returns the NoDevice field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmCreation) GetNoDevice() string { - if o == nil || o.NoDevice == nil { - var ret string - return ret - } - return *o.NoDevice -} - -// GetNoDeviceOk returns a tuple with the NoDevice field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmCreation) GetNoDeviceOk() (string, bool) { - if o == nil || o.NoDevice == nil { - var ret string - return ret, false - } - return *o.NoDevice, true -} - -// HasNoDevice returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmCreation) HasNoDevice() bool { - if o != nil && o.NoDevice != nil { - return true - } - - return false -} - -// SetNoDevice gets a reference to the given string and assigns it to the NoDevice field. -func (o *BlockDeviceMappingVmCreation) SetNoDevice(v string) { - o.NoDevice = &v -} - -// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmCreation) GetVirtualDeviceName() string { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret - } - return *o.VirtualDeviceName -} - -// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmCreation) GetVirtualDeviceNameOk() (string, bool) { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret, false - } - return *o.VirtualDeviceName, true -} - -// HasVirtualDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmCreation) HasVirtualDeviceName() bool { - if o != nil && o.VirtualDeviceName != nil { - return true - } - - return false -} - -// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. -func (o *BlockDeviceMappingVmCreation) SetVirtualDeviceName(v string) { - o.VirtualDeviceName = &v -} - -type NullableBlockDeviceMappingVmCreation struct { - Value BlockDeviceMappingVmCreation - ExplicitNull bool -} - -func (v NullableBlockDeviceMappingVmCreation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBlockDeviceMappingVmCreation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_update.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_update.go deleted file mode 100644 index 3d58d96f4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_block_device_mapping_vm_update.go +++ /dev/null @@ -1,182 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BlockDeviceMappingVmUpdate Information about the block device mapping. -type BlockDeviceMappingVmUpdate struct { - Bsu *BsuToUpdateVm `json:"Bsu,omitempty"` - // The name of the device. - DeviceName *string `json:"DeviceName,omitempty"` - // Removes the device which is included in the block device mapping of the OMI. - NoDevice *string `json:"NoDevice,omitempty"` - // The name of the virtual device (ephemeralN). - VirtualDeviceName *string `json:"VirtualDeviceName,omitempty"` -} - -// GetBsu returns the Bsu field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmUpdate) GetBsu() BsuToUpdateVm { - if o == nil || o.Bsu == nil { - var ret BsuToUpdateVm - return ret - } - return *o.Bsu -} - -// GetBsuOk returns a tuple with the Bsu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmUpdate) GetBsuOk() (BsuToUpdateVm, bool) { - if o == nil || o.Bsu == nil { - var ret BsuToUpdateVm - return ret, false - } - return *o.Bsu, true -} - -// HasBsu returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmUpdate) HasBsu() bool { - if o != nil && o.Bsu != nil { - return true - } - - return false -} - -// SetBsu gets a reference to the given BsuToUpdateVm and assigns it to the Bsu field. -func (o *BlockDeviceMappingVmUpdate) SetBsu(v BsuToUpdateVm) { - o.Bsu = &v -} - -// GetDeviceName returns the DeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmUpdate) GetDeviceName() string { - if o == nil || o.DeviceName == nil { - var ret string - return ret - } - return *o.DeviceName -} - -// GetDeviceNameOk returns a tuple with the DeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmUpdate) GetDeviceNameOk() (string, bool) { - if o == nil || o.DeviceName == nil { - var ret string - return ret, false - } - return *o.DeviceName, true -} - -// HasDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmUpdate) HasDeviceName() bool { - if o != nil && o.DeviceName != nil { - return true - } - - return false -} - -// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. -func (o *BlockDeviceMappingVmUpdate) SetDeviceName(v string) { - o.DeviceName = &v -} - -// GetNoDevice returns the NoDevice field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmUpdate) GetNoDevice() string { - if o == nil || o.NoDevice == nil { - var ret string - return ret - } - return *o.NoDevice -} - -// GetNoDeviceOk returns a tuple with the NoDevice field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmUpdate) GetNoDeviceOk() (string, bool) { - if o == nil || o.NoDevice == nil { - var ret string - return ret, false - } - return *o.NoDevice, true -} - -// HasNoDevice returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmUpdate) HasNoDevice() bool { - if o != nil && o.NoDevice != nil { - return true - } - - return false -} - -// SetNoDevice gets a reference to the given string and assigns it to the NoDevice field. -func (o *BlockDeviceMappingVmUpdate) SetNoDevice(v string) { - o.NoDevice = &v -} - -// GetVirtualDeviceName returns the VirtualDeviceName field value if set, zero value otherwise. -func (o *BlockDeviceMappingVmUpdate) GetVirtualDeviceName() string { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret - } - return *o.VirtualDeviceName -} - -// GetVirtualDeviceNameOk returns a tuple with the VirtualDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BlockDeviceMappingVmUpdate) GetVirtualDeviceNameOk() (string, bool) { - if o == nil || o.VirtualDeviceName == nil { - var ret string - return ret, false - } - return *o.VirtualDeviceName, true -} - -// HasVirtualDeviceName returns a boolean if a field has been set. -func (o *BlockDeviceMappingVmUpdate) HasVirtualDeviceName() bool { - if o != nil && o.VirtualDeviceName != nil { - return true - } - - return false -} - -// SetVirtualDeviceName gets a reference to the given string and assigns it to the VirtualDeviceName field. -func (o *BlockDeviceMappingVmUpdate) SetVirtualDeviceName(v string) { - o.VirtualDeviceName = &v -} - -type NullableBlockDeviceMappingVmUpdate struct { - Value BlockDeviceMappingVmUpdate - ExplicitNull bool -} - -func (v NullableBlockDeviceMappingVmUpdate) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBlockDeviceMappingVmUpdate) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_created.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_created.go deleted file mode 100644 index 16d738d86..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_created.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BsuCreated Information about the created BSU volume. -type BsuCreated struct { - // Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The time and date of attachment of the volume to the VM. - LinkDate *string `json:"LinkDate,omitempty"` - // The state of the volume. - State *string `json:"State,omitempty"` - // The ID of the volume. - VolumeId *string `json:"VolumeId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *BsuCreated) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuCreated) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *BsuCreated) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *BsuCreated) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetLinkDate returns the LinkDate field value if set, zero value otherwise. -func (o *BsuCreated) GetLinkDate() string { - if o == nil || o.LinkDate == nil { - var ret string - return ret - } - return *o.LinkDate -} - -// GetLinkDateOk returns a tuple with the LinkDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuCreated) GetLinkDateOk() (string, bool) { - if o == nil || o.LinkDate == nil { - var ret string - return ret, false - } - return *o.LinkDate, true -} - -// HasLinkDate returns a boolean if a field has been set. -func (o *BsuCreated) HasLinkDate() bool { - if o != nil && o.LinkDate != nil { - return true - } - - return false -} - -// SetLinkDate gets a reference to the given string and assigns it to the LinkDate field. -func (o *BsuCreated) SetLinkDate(v string) { - o.LinkDate = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *BsuCreated) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuCreated) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *BsuCreated) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *BsuCreated) SetState(v string) { - o.State = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *BsuCreated) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuCreated) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *BsuCreated) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *BsuCreated) SetVolumeId(v string) { - o.VolumeId = &v -} - -type NullableBsuCreated struct { - Value BsuCreated - ExplicitNull bool -} - -func (v NullableBsuCreated) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBsuCreated) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_create.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_create.go deleted file mode 100644 index 5ce4ae3af..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_create.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BsuToCreate Information about the BSU volume to create. -type BsuToCreate struct { - // Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - Iops *int64 `json:"Iops,omitempty"` - // The ID of the snapshot used to create the volume. - SnapshotId *string `json:"SnapshotId,omitempty"` - // The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - VolumeSize *int64 `json:"VolumeSize,omitempty"` - // The type of the volume (`standard` \\| `io1` \\| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). - VolumeType *string `json:"VolumeType,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *BsuToCreate) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToCreate) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *BsuToCreate) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *BsuToCreate) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetIops returns the Iops field value if set, zero value otherwise. -func (o *BsuToCreate) GetIops() int64 { - if o == nil || o.Iops == nil { - var ret int64 - return ret - } - return *o.Iops -} - -// GetIopsOk returns a tuple with the Iops field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToCreate) GetIopsOk() (int64, bool) { - if o == nil || o.Iops == nil { - var ret int64 - return ret, false - } - return *o.Iops, true -} - -// HasIops returns a boolean if a field has been set. -func (o *BsuToCreate) HasIops() bool { - if o != nil && o.Iops != nil { - return true - } - - return false -} - -// SetIops gets a reference to the given int64 and assigns it to the Iops field. -func (o *BsuToCreate) SetIops(v int64) { - o.Iops = &v -} - -// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. -func (o *BsuToCreate) GetSnapshotId() string { - if o == nil || o.SnapshotId == nil { - var ret string - return ret - } - return *o.SnapshotId -} - -// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToCreate) GetSnapshotIdOk() (string, bool) { - if o == nil || o.SnapshotId == nil { - var ret string - return ret, false - } - return *o.SnapshotId, true -} - -// HasSnapshotId returns a boolean if a field has been set. -func (o *BsuToCreate) HasSnapshotId() bool { - if o != nil && o.SnapshotId != nil { - return true - } - - return false -} - -// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. -func (o *BsuToCreate) SetSnapshotId(v string) { - o.SnapshotId = &v -} - -// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. -func (o *BsuToCreate) GetVolumeSize() int64 { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret - } - return *o.VolumeSize -} - -// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToCreate) GetVolumeSizeOk() (int64, bool) { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret, false - } - return *o.VolumeSize, true -} - -// HasVolumeSize returns a boolean if a field has been set. -func (o *BsuToCreate) HasVolumeSize() bool { - if o != nil && o.VolumeSize != nil { - return true - } - - return false -} - -// SetVolumeSize gets a reference to the given int64 and assigns it to the VolumeSize field. -func (o *BsuToCreate) SetVolumeSize(v int64) { - o.VolumeSize = &v -} - -// GetVolumeType returns the VolumeType field value if set, zero value otherwise. -func (o *BsuToCreate) GetVolumeType() string { - if o == nil || o.VolumeType == nil { - var ret string - return ret - } - return *o.VolumeType -} - -// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToCreate) GetVolumeTypeOk() (string, bool) { - if o == nil || o.VolumeType == nil { - var ret string - return ret, false - } - return *o.VolumeType, true -} - -// HasVolumeType returns a boolean if a field has been set. -func (o *BsuToCreate) HasVolumeType() bool { - if o != nil && o.VolumeType != nil { - return true - } - - return false -} - -// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. -func (o *BsuToCreate) SetVolumeType(v string) { - o.VolumeType = &v -} - -type NullableBsuToCreate struct { - Value BsuToCreate - ExplicitNull bool -} - -func (v NullableBsuToCreate) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBsuToCreate) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_update_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_update_vm.go deleted file mode 100644 index c8ff1cf76..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_bsu_to_update_vm.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// BsuToUpdateVm Information about the BSU volume. -type BsuToUpdateVm struct { - // If `true`, the volume is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The ID of the volume. - VolumeId *string `json:"VolumeId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *BsuToUpdateVm) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToUpdateVm) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *BsuToUpdateVm) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *BsuToUpdateVm) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *BsuToUpdateVm) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *BsuToUpdateVm) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *BsuToUpdateVm) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *BsuToUpdateVm) SetVolumeId(v string) { - o.VolumeId = &v -} - -type NullableBsuToUpdateVm struct { - Value BsuToUpdateVm - ExplicitNull bool -} - -func (v NullableBsuToUpdateVm) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBsuToUpdateVm) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_request.go deleted file mode 100644 index 2c58515bb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_request.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CheckAuthenticationRequest struct for CheckAuthenticationRequest -type CheckAuthenticationRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The email address of the account. - Login *string `json:"Login,omitempty"` - // The password of the account. - Password *string `json:"Password,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CheckAuthenticationRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CheckAuthenticationRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CheckAuthenticationRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CheckAuthenticationRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLogin returns the Login field value if set, zero value otherwise. -func (o *CheckAuthenticationRequest) GetLogin() string { - if o == nil || o.Login == nil { - var ret string - return ret - } - return *o.Login -} - -// GetLoginOk returns a tuple with the Login field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CheckAuthenticationRequest) GetLoginOk() (string, bool) { - if o == nil || o.Login == nil { - var ret string - return ret, false - } - return *o.Login, true -} - -// HasLogin returns a boolean if a field has been set. -func (o *CheckAuthenticationRequest) HasLogin() bool { - if o != nil && o.Login != nil { - return true - } - - return false -} - -// SetLogin gets a reference to the given string and assigns it to the Login field. -func (o *CheckAuthenticationRequest) SetLogin(v string) { - o.Login = &v -} - -// GetPassword returns the Password field value if set, zero value otherwise. -func (o *CheckAuthenticationRequest) GetPassword() string { - if o == nil || o.Password == nil { - var ret string - return ret - } - return *o.Password -} - -// GetPasswordOk returns a tuple with the Password field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CheckAuthenticationRequest) GetPasswordOk() (string, bool) { - if o == nil || o.Password == nil { - var ret string - return ret, false - } - return *o.Password, true -} - -// HasPassword returns a boolean if a field has been set. -func (o *CheckAuthenticationRequest) HasPassword() bool { - if o != nil && o.Password != nil { - return true - } - - return false -} - -// SetPassword gets a reference to the given string and assigns it to the Password field. -func (o *CheckAuthenticationRequest) SetPassword(v string) { - o.Password = &v -} - -type NullableCheckAuthenticationRequest struct { - Value CheckAuthenticationRequest - ExplicitNull bool -} - -func (v NullableCheckAuthenticationRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCheckAuthenticationRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_response.go deleted file mode 100644 index 1bc7c0b6f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_check_authentication_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CheckAuthenticationResponse struct for CheckAuthenticationResponse -type CheckAuthenticationResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CheckAuthenticationResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CheckAuthenticationResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CheckAuthenticationResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CheckAuthenticationResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCheckAuthenticationResponse struct { - Value CheckAuthenticationResponse - ExplicitNull bool -} - -func (v NullableCheckAuthenticationResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCheckAuthenticationResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_client_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_client_gateway.go deleted file mode 100644 index 0d82cbd31..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_client_gateway.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ClientGateway Information about the client gateway. -type ClientGateway struct { - // An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. - BgpAsn *int64 `json:"BgpAsn,omitempty"` - // The ID of the client gateway. - ClientGatewayId *string `json:"ClientGatewayId,omitempty"` - // The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). - ConnectionType *string `json:"ConnectionType,omitempty"` - // The public IPv4 address of the client gateway (must be a fixed address into a NATed network). - PublicIp *string `json:"PublicIp,omitempty"` - // The state of the client gateway (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` - // One or more tags associated with the client gateway. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetBgpAsn returns the BgpAsn field value if set, zero value otherwise. -func (o *ClientGateway) GetBgpAsn() int64 { - if o == nil || o.BgpAsn == nil { - var ret int64 - return ret - } - return *o.BgpAsn -} - -// GetBgpAsnOk returns a tuple with the BgpAsn field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetBgpAsnOk() (int64, bool) { - if o == nil || o.BgpAsn == nil { - var ret int64 - return ret, false - } - return *o.BgpAsn, true -} - -// HasBgpAsn returns a boolean if a field has been set. -func (o *ClientGateway) HasBgpAsn() bool { - if o != nil && o.BgpAsn != nil { - return true - } - - return false -} - -// SetBgpAsn gets a reference to the given int64 and assigns it to the BgpAsn field. -func (o *ClientGateway) SetBgpAsn(v int64) { - o.BgpAsn = &v -} - -// GetClientGatewayId returns the ClientGatewayId field value if set, zero value otherwise. -func (o *ClientGateway) GetClientGatewayId() string { - if o == nil || o.ClientGatewayId == nil { - var ret string - return ret - } - return *o.ClientGatewayId -} - -// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetClientGatewayIdOk() (string, bool) { - if o == nil || o.ClientGatewayId == nil { - var ret string - return ret, false - } - return *o.ClientGatewayId, true -} - -// HasClientGatewayId returns a boolean if a field has been set. -func (o *ClientGateway) HasClientGatewayId() bool { - if o != nil && o.ClientGatewayId != nil { - return true - } - - return false -} - -// SetClientGatewayId gets a reference to the given string and assigns it to the ClientGatewayId field. -func (o *ClientGateway) SetClientGatewayId(v string) { - o.ClientGatewayId = &v -} - -// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. -func (o *ClientGateway) GetConnectionType() string { - if o == nil || o.ConnectionType == nil { - var ret string - return ret - } - return *o.ConnectionType -} - -// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetConnectionTypeOk() (string, bool) { - if o == nil || o.ConnectionType == nil { - var ret string - return ret, false - } - return *o.ConnectionType, true -} - -// HasConnectionType returns a boolean if a field has been set. -func (o *ClientGateway) HasConnectionType() bool { - if o != nil && o.ConnectionType != nil { - return true - } - - return false -} - -// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. -func (o *ClientGateway) SetConnectionType(v string) { - o.ConnectionType = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *ClientGateway) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *ClientGateway) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *ClientGateway) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *ClientGateway) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *ClientGateway) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *ClientGateway) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *ClientGateway) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ClientGateway) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *ClientGateway) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *ClientGateway) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableClientGateway struct { - Value ClientGateway - ExplicitNull bool -} - -func (v NullableClientGateway) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableClientGateway) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_consumption_entry.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_consumption_entry.go deleted file mode 100644 index 704a59f19..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_consumption_entry.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ConsumptionEntry Information about the resources consumed during the specified time period. -type ConsumptionEntry struct { - // The category of the resource (for example, `network`). - Category *string `json:"Category,omitempty"` - // The beginning of the time period. - FromDate *string `json:"FromDate,omitempty"` - // The API call that triggered the resource consumption (for example, `RunInstances` or `CreateVolume`). - Operation *string `json:"Operation,omitempty"` - // The service of the API call (`TinaOS-FCU`, `TinaOS-LBU`, `TinaOS-OSU` or `TinaOS-DirectLink`). - Service *string `json:"Service,omitempty"` - // A description of the consumed resource. - Title *string `json:"Title,omitempty"` - // The end of the time period. - ToDate *string `json:"ToDate,omitempty"` - // The type of resource, depending on the API call. - Type *string `json:"Type,omitempty"` - // The consumed amount for the resource. The unit depends on the resource type. For more information, see the `Title` element. - Value *string `json:"Value,omitempty"` -} - -// GetCategory returns the Category field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetCategory() string { - if o == nil || o.Category == nil { - var ret string - return ret - } - return *o.Category -} - -// GetCategoryOk returns a tuple with the Category field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetCategoryOk() (string, bool) { - if o == nil || o.Category == nil { - var ret string - return ret, false - } - return *o.Category, true -} - -// HasCategory returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasCategory() bool { - if o != nil && o.Category != nil { - return true - } - - return false -} - -// SetCategory gets a reference to the given string and assigns it to the Category field. -func (o *ConsumptionEntry) SetCategory(v string) { - o.Category = &v -} - -// GetFromDate returns the FromDate field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetFromDate() string { - if o == nil || o.FromDate == nil { - var ret string - return ret - } - return *o.FromDate -} - -// GetFromDateOk returns a tuple with the FromDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetFromDateOk() (string, bool) { - if o == nil || o.FromDate == nil { - var ret string - return ret, false - } - return *o.FromDate, true -} - -// HasFromDate returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasFromDate() bool { - if o != nil && o.FromDate != nil { - return true - } - - return false -} - -// SetFromDate gets a reference to the given string and assigns it to the FromDate field. -func (o *ConsumptionEntry) SetFromDate(v string) { - o.FromDate = &v -} - -// GetOperation returns the Operation field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetOperation() string { - if o == nil || o.Operation == nil { - var ret string - return ret - } - return *o.Operation -} - -// GetOperationOk returns a tuple with the Operation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetOperationOk() (string, bool) { - if o == nil || o.Operation == nil { - var ret string - return ret, false - } - return *o.Operation, true -} - -// HasOperation returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasOperation() bool { - if o != nil && o.Operation != nil { - return true - } - - return false -} - -// SetOperation gets a reference to the given string and assigns it to the Operation field. -func (o *ConsumptionEntry) SetOperation(v string) { - o.Operation = &v -} - -// GetService returns the Service field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetService() string { - if o == nil || o.Service == nil { - var ret string - return ret - } - return *o.Service -} - -// GetServiceOk returns a tuple with the Service field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetServiceOk() (string, bool) { - if o == nil || o.Service == nil { - var ret string - return ret, false - } - return *o.Service, true -} - -// HasService returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasService() bool { - if o != nil && o.Service != nil { - return true - } - - return false -} - -// SetService gets a reference to the given string and assigns it to the Service field. -func (o *ConsumptionEntry) SetService(v string) { - o.Service = &v -} - -// GetTitle returns the Title field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetTitle() string { - if o == nil || o.Title == nil { - var ret string - return ret - } - return *o.Title -} - -// GetTitleOk returns a tuple with the Title field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetTitleOk() (string, bool) { - if o == nil || o.Title == nil { - var ret string - return ret, false - } - return *o.Title, true -} - -// HasTitle returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasTitle() bool { - if o != nil && o.Title != nil { - return true - } - - return false -} - -// SetTitle gets a reference to the given string and assigns it to the Title field. -func (o *ConsumptionEntry) SetTitle(v string) { - o.Title = &v -} - -// GetToDate returns the ToDate field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetToDate() string { - if o == nil || o.ToDate == nil { - var ret string - return ret - } - return *o.ToDate -} - -// GetToDateOk returns a tuple with the ToDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetToDateOk() (string, bool) { - if o == nil || o.ToDate == nil { - var ret string - return ret, false - } - return *o.ToDate, true -} - -// HasToDate returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasToDate() bool { - if o != nil && o.ToDate != nil { - return true - } - - return false -} - -// SetToDate gets a reference to the given string and assigns it to the ToDate field. -func (o *ConsumptionEntry) SetToDate(v string) { - o.ToDate = &v -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetTypeOk() (string, bool) { - if o == nil || o.Type == nil { - var ret string - return ret, false - } - return *o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *ConsumptionEntry) SetType(v string) { - o.Type = &v -} - -// GetValue returns the Value field value if set, zero value otherwise. -func (o *ConsumptionEntry) GetValue() string { - if o == nil || o.Value == nil { - var ret string - return ret - } - return *o.Value -} - -// GetValueOk returns a tuple with the Value field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ConsumptionEntry) GetValueOk() (string, bool) { - if o == nil || o.Value == nil { - var ret string - return ret, false - } - return *o.Value, true -} - -// HasValue returns a boolean if a field has been set. -func (o *ConsumptionEntry) HasValue() bool { - if o != nil && o.Value != nil { - return true - } - - return false -} - -// SetValue gets a reference to the given string and assigns it to the Value field. -func (o *ConsumptionEntry) SetValue(v string) { - o.Value = &v -} - -type NullableConsumptionEntry struct { - Value ConsumptionEntry - ExplicitNull bool -} - -func (v NullableConsumptionEntry) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableConsumptionEntry) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_access_key_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_access_key_response.go deleted file mode 100644 index 534b46d90..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_access_key_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateAccessKeyResponse struct for CreateAccessKeyResponse -type CreateAccessKeyResponse struct { - AccessKey *AccessKeySecretKey `json:"AccessKey,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccessKey returns the AccessKey field value if set, zero value otherwise. -func (o *CreateAccessKeyResponse) GetAccessKey() AccessKeySecretKey { - if o == nil || o.AccessKey == nil { - var ret AccessKeySecretKey - return ret - } - return *o.AccessKey -} - -// GetAccessKeyOk returns a tuple with the AccessKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccessKeyResponse) GetAccessKeyOk() (AccessKeySecretKey, bool) { - if o == nil || o.AccessKey == nil { - var ret AccessKeySecretKey - return ret, false - } - return *o.AccessKey, true -} - -// HasAccessKey returns a boolean if a field has been set. -func (o *CreateAccessKeyResponse) HasAccessKey() bool { - if o != nil && o.AccessKey != nil { - return true - } - - return false -} - -// SetAccessKey gets a reference to the given AccessKeySecretKey and assigns it to the AccessKey field. -func (o *CreateAccessKeyResponse) SetAccessKey(v AccessKeySecretKey) { - o.AccessKey = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateAccessKeyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccessKeyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateAccessKeyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateAccessKeyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateAccessKeyResponse struct { - Value CreateAccessKeyResponse - ExplicitNull bool -} - -func (v NullableCreateAccessKeyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateAccessKeyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_request.go deleted file mode 100644 index 4d26cbaf2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_request.go +++ /dev/null @@ -1,389 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateAccountRequest struct for CreateAccountRequest -type CreateAccountRequest struct { - // The city of the account owner. - City string `json:"City"` - // The name of the company for the account. - CompanyName string `json:"CompanyName"` - // The country of the account owner. - Country string `json:"Country"` - // The ID of the customer. It must be 8 digits (by default, `12345678`). - CustomerId string `json:"CustomerId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The email address for the account. - Email string `json:"Email"` - // The first name of the account owner. - FirstName string `json:"FirstName"` - // The job title of the account owner. - JobTitle *string `json:"JobTitle,omitempty"` - // The last name of the account owner. - LastName string `json:"LastName"` - // The mobile phone number of the account owner. - MobileNumber *string `json:"MobileNumber,omitempty"` - // The landline phone number of the account owner. - PhoneNumber *string `json:"PhoneNumber,omitempty"` - // The state/province of the account. - StateProvince *string `json:"StateProvince,omitempty"` - // The value added tax (VAT) number for the account. - VatNumber *string `json:"VatNumber,omitempty"` - // The ZIP code of the city. - ZipCode string `json:"ZipCode"` -} - -// GetCity returns the City field value -func (o *CreateAccountRequest) GetCity() string { - if o == nil { - var ret string - return ret - } - - return o.City -} - -// SetCity sets field value -func (o *CreateAccountRequest) SetCity(v string) { - o.City = v -} - -// GetCompanyName returns the CompanyName field value -func (o *CreateAccountRequest) GetCompanyName() string { - if o == nil { - var ret string - return ret - } - - return o.CompanyName -} - -// SetCompanyName sets field value -func (o *CreateAccountRequest) SetCompanyName(v string) { - o.CompanyName = v -} - -// GetCountry returns the Country field value -func (o *CreateAccountRequest) GetCountry() string { - if o == nil { - var ret string - return ret - } - - return o.Country -} - -// SetCountry sets field value -func (o *CreateAccountRequest) SetCountry(v string) { - o.Country = v -} - -// GetCustomerId returns the CustomerId field value -func (o *CreateAccountRequest) GetCustomerId() string { - if o == nil { - var ret string - return ret - } - - return o.CustomerId -} - -// SetCustomerId sets field value -func (o *CreateAccountRequest) SetCustomerId(v string) { - o.CustomerId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateAccountRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetEmail returns the Email field value -func (o *CreateAccountRequest) GetEmail() string { - if o == nil { - var ret string - return ret - } - - return o.Email -} - -// SetEmail sets field value -func (o *CreateAccountRequest) SetEmail(v string) { - o.Email = v -} - -// GetFirstName returns the FirstName field value -func (o *CreateAccountRequest) GetFirstName() string { - if o == nil { - var ret string - return ret - } - - return o.FirstName -} - -// SetFirstName sets field value -func (o *CreateAccountRequest) SetFirstName(v string) { - o.FirstName = v -} - -// GetJobTitle returns the JobTitle field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetJobTitle() string { - if o == nil || o.JobTitle == nil { - var ret string - return ret - } - return *o.JobTitle -} - -// GetJobTitleOk returns a tuple with the JobTitle field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetJobTitleOk() (string, bool) { - if o == nil || o.JobTitle == nil { - var ret string - return ret, false - } - return *o.JobTitle, true -} - -// HasJobTitle returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasJobTitle() bool { - if o != nil && o.JobTitle != nil { - return true - } - - return false -} - -// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. -func (o *CreateAccountRequest) SetJobTitle(v string) { - o.JobTitle = &v -} - -// GetLastName returns the LastName field value -func (o *CreateAccountRequest) GetLastName() string { - if o == nil { - var ret string - return ret - } - - return o.LastName -} - -// SetLastName sets field value -func (o *CreateAccountRequest) SetLastName(v string) { - o.LastName = v -} - -// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetMobileNumber() string { - if o == nil || o.MobileNumber == nil { - var ret string - return ret - } - return *o.MobileNumber -} - -// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetMobileNumberOk() (string, bool) { - if o == nil || o.MobileNumber == nil { - var ret string - return ret, false - } - return *o.MobileNumber, true -} - -// HasMobileNumber returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasMobileNumber() bool { - if o != nil && o.MobileNumber != nil { - return true - } - - return false -} - -// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. -func (o *CreateAccountRequest) SetMobileNumber(v string) { - o.MobileNumber = &v -} - -// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetPhoneNumber() string { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret - } - return *o.PhoneNumber -} - -// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetPhoneNumberOk() (string, bool) { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret, false - } - return *o.PhoneNumber, true -} - -// HasPhoneNumber returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasPhoneNumber() bool { - if o != nil && o.PhoneNumber != nil { - return true - } - - return false -} - -// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. -func (o *CreateAccountRequest) SetPhoneNumber(v string) { - o.PhoneNumber = &v -} - -// GetStateProvince returns the StateProvince field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetStateProvince() string { - if o == nil || o.StateProvince == nil { - var ret string - return ret - } - return *o.StateProvince -} - -// GetStateProvinceOk returns a tuple with the StateProvince field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetStateProvinceOk() (string, bool) { - if o == nil || o.StateProvince == nil { - var ret string - return ret, false - } - return *o.StateProvince, true -} - -// HasStateProvince returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasStateProvince() bool { - if o != nil && o.StateProvince != nil { - return true - } - - return false -} - -// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. -func (o *CreateAccountRequest) SetStateProvince(v string) { - o.StateProvince = &v -} - -// GetVatNumber returns the VatNumber field value if set, zero value otherwise. -func (o *CreateAccountRequest) GetVatNumber() string { - if o == nil || o.VatNumber == nil { - var ret string - return ret - } - return *o.VatNumber -} - -// GetVatNumberOk returns a tuple with the VatNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountRequest) GetVatNumberOk() (string, bool) { - if o == nil || o.VatNumber == nil { - var ret string - return ret, false - } - return *o.VatNumber, true -} - -// HasVatNumber returns a boolean if a field has been set. -func (o *CreateAccountRequest) HasVatNumber() bool { - if o != nil && o.VatNumber != nil { - return true - } - - return false -} - -// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. -func (o *CreateAccountRequest) SetVatNumber(v string) { - o.VatNumber = &v -} - -// GetZipCode returns the ZipCode field value -func (o *CreateAccountRequest) GetZipCode() string { - if o == nil { - var ret string - return ret - } - - return o.ZipCode -} - -// SetZipCode sets field value -func (o *CreateAccountRequest) SetZipCode(v string) { - o.ZipCode = v -} - -type NullableCreateAccountRequest struct { - Value CreateAccountRequest - ExplicitNull bool -} - -func (v NullableCreateAccountRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateAccountRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_response.go deleted file mode 100644 index 0d93df612..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_account_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateAccountResponse struct for CreateAccountResponse -type CreateAccountResponse struct { - Account *Account `json:"Account,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccount returns the Account field value if set, zero value otherwise. -func (o *CreateAccountResponse) GetAccount() Account { - if o == nil || o.Account == nil { - var ret Account - return ret - } - return *o.Account -} - -// GetAccountOk returns a tuple with the Account field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountResponse) GetAccountOk() (Account, bool) { - if o == nil || o.Account == nil { - var ret Account - return ret, false - } - return *o.Account, true -} - -// HasAccount returns a boolean if a field has been set. -func (o *CreateAccountResponse) HasAccount() bool { - if o != nil && o.Account != nil { - return true - } - - return false -} - -// SetAccount gets a reference to the given Account and assigns it to the Account field. -func (o *CreateAccountResponse) SetAccount(v Account) { - o.Account = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateAccountResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateAccountResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateAccountResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateAccountResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateAccountResponse struct { - Value CreateAccountResponse - ExplicitNull bool -} - -func (v NullableCreateAccountResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateAccountResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_request.go deleted file mode 100644 index aacee2020..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_request.go +++ /dev/null @@ -1,129 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateClientGatewayRequest struct for CreateClientGatewayRequest -type CreateClientGatewayRequest struct { - // An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. The long must be within the [0;4294967295] range. By default, 65000. - BgpAsn int64 `json:"BgpAsn"` - // The communication protocol used to establish tunnel with your client gateway (only `ipsec.1` is supported). - ConnectionType string `json:"ConnectionType"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The public fixed IPv4 address of your client gateway. - PublicIp string `json:"PublicIp"` -} - -// GetBgpAsn returns the BgpAsn field value -func (o *CreateClientGatewayRequest) GetBgpAsn() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.BgpAsn -} - -// SetBgpAsn sets field value -func (o *CreateClientGatewayRequest) SetBgpAsn(v int64) { - o.BgpAsn = v -} - -// GetConnectionType returns the ConnectionType field value -func (o *CreateClientGatewayRequest) GetConnectionType() string { - if o == nil { - var ret string - return ret - } - - return o.ConnectionType -} - -// SetConnectionType sets field value -func (o *CreateClientGatewayRequest) SetConnectionType(v string) { - o.ConnectionType = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateClientGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateClientGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateClientGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateClientGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPublicIp returns the PublicIp field value -func (o *CreateClientGatewayRequest) GetPublicIp() string { - if o == nil { - var ret string - return ret - } - - return o.PublicIp -} - -// SetPublicIp sets field value -func (o *CreateClientGatewayRequest) SetPublicIp(v string) { - o.PublicIp = v -} - -type NullableCreateClientGatewayRequest struct { - Value CreateClientGatewayRequest - ExplicitNull bool -} - -func (v NullableCreateClientGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateClientGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_response.go deleted file mode 100644 index 888cf3a79..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_client_gateway_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateClientGatewayResponse struct for CreateClientGatewayResponse -type CreateClientGatewayResponse struct { - ClientGateway *ClientGateway `json:"ClientGateway,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetClientGateway returns the ClientGateway field value if set, zero value otherwise. -func (o *CreateClientGatewayResponse) GetClientGateway() ClientGateway { - if o == nil || o.ClientGateway == nil { - var ret ClientGateway - return ret - } - return *o.ClientGateway -} - -// GetClientGatewayOk returns a tuple with the ClientGateway field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateClientGatewayResponse) GetClientGatewayOk() (ClientGateway, bool) { - if o == nil || o.ClientGateway == nil { - var ret ClientGateway - return ret, false - } - return *o.ClientGateway, true -} - -// HasClientGateway returns a boolean if a field has been set. -func (o *CreateClientGatewayResponse) HasClientGateway() bool { - if o != nil && o.ClientGateway != nil { - return true - } - - return false -} - -// SetClientGateway gets a reference to the given ClientGateway and assigns it to the ClientGateway field. -func (o *CreateClientGatewayResponse) SetClientGateway(v ClientGateway) { - o.ClientGateway = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateClientGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateClientGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateClientGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateClientGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateClientGatewayResponse struct { - Value CreateClientGatewayResponse - ExplicitNull bool -} - -func (v NullableCreateClientGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateClientGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_request.go deleted file mode 100644 index 437c55f3c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_request.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDhcpOptionsRequest struct for CreateDhcpOptionsRequest -type CreateDhcpOptionsRequest struct { - // Specify a domain name (for example, MyCompany.com). You can specify only one domain name. - DomainName *string `json:"DomainName,omitempty"` - // The IP addresses of domain name servers. If no IP addresses are specified, the `OutscaleProvidedDNS` value is set by default. - DomainNameServers *[]string `json:"DomainNameServers,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The IP addresses of the Network Time Protocol (NTP) servers. - NtpServers *[]string `json:"NtpServers,omitempty"` -} - -// GetDomainName returns the DomainName field value if set, zero value otherwise. -func (o *CreateDhcpOptionsRequest) GetDomainName() string { - if o == nil || o.DomainName == nil { - var ret string - return ret - } - return *o.DomainName -} - -// GetDomainNameOk returns a tuple with the DomainName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsRequest) GetDomainNameOk() (string, bool) { - if o == nil || o.DomainName == nil { - var ret string - return ret, false - } - return *o.DomainName, true -} - -// HasDomainName returns a boolean if a field has been set. -func (o *CreateDhcpOptionsRequest) HasDomainName() bool { - if o != nil && o.DomainName != nil { - return true - } - - return false -} - -// SetDomainName gets a reference to the given string and assigns it to the DomainName field. -func (o *CreateDhcpOptionsRequest) SetDomainName(v string) { - o.DomainName = &v -} - -// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. -func (o *CreateDhcpOptionsRequest) GetDomainNameServers() []string { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret - } - return *o.DomainNameServers -} - -// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsRequest) GetDomainNameServersOk() ([]string, bool) { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret, false - } - return *o.DomainNameServers, true -} - -// HasDomainNameServers returns a boolean if a field has been set. -func (o *CreateDhcpOptionsRequest) HasDomainNameServers() bool { - if o != nil && o.DomainNameServers != nil { - return true - } - - return false -} - -// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. -func (o *CreateDhcpOptionsRequest) SetDomainNameServers(v []string) { - o.DomainNameServers = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateDhcpOptionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateDhcpOptionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateDhcpOptionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNtpServers returns the NtpServers field value if set, zero value otherwise. -func (o *CreateDhcpOptionsRequest) GetNtpServers() []string { - if o == nil || o.NtpServers == nil { - var ret []string - return ret - } - return *o.NtpServers -} - -// GetNtpServersOk returns a tuple with the NtpServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsRequest) GetNtpServersOk() ([]string, bool) { - if o == nil || o.NtpServers == nil { - var ret []string - return ret, false - } - return *o.NtpServers, true -} - -// HasNtpServers returns a boolean if a field has been set. -func (o *CreateDhcpOptionsRequest) HasNtpServers() bool { - if o != nil && o.NtpServers != nil { - return true - } - - return false -} - -// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. -func (o *CreateDhcpOptionsRequest) SetNtpServers(v []string) { - o.NtpServers = &v -} - -type NullableCreateDhcpOptionsRequest struct { - Value CreateDhcpOptionsRequest - ExplicitNull bool -} - -func (v NullableCreateDhcpOptionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDhcpOptionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_response.go deleted file mode 100644 index 1cd153e9c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_dhcp_options_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDhcpOptionsResponse struct for CreateDhcpOptionsResponse -type CreateDhcpOptionsResponse struct { - DhcpOptionsSet *DhcpOptionsSet `json:"DhcpOptionsSet,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDhcpOptionsSet returns the DhcpOptionsSet field value if set, zero value otherwise. -func (o *CreateDhcpOptionsResponse) GetDhcpOptionsSet() DhcpOptionsSet { - if o == nil || o.DhcpOptionsSet == nil { - var ret DhcpOptionsSet - return ret - } - return *o.DhcpOptionsSet -} - -// GetDhcpOptionsSetOk returns a tuple with the DhcpOptionsSet field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsResponse) GetDhcpOptionsSetOk() (DhcpOptionsSet, bool) { - if o == nil || o.DhcpOptionsSet == nil { - var ret DhcpOptionsSet - return ret, false - } - return *o.DhcpOptionsSet, true -} - -// HasDhcpOptionsSet returns a boolean if a field has been set. -func (o *CreateDhcpOptionsResponse) HasDhcpOptionsSet() bool { - if o != nil && o.DhcpOptionsSet != nil { - return true - } - - return false -} - -// SetDhcpOptionsSet gets a reference to the given DhcpOptionsSet and assigns it to the DhcpOptionsSet field. -func (o *CreateDhcpOptionsResponse) SetDhcpOptionsSet(v DhcpOptionsSet) { - o.DhcpOptionsSet = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateDhcpOptionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDhcpOptionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateDhcpOptionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateDhcpOptionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateDhcpOptionsResponse struct { - Value CreateDhcpOptionsResponse - ExplicitNull bool -} - -func (v NullableCreateDhcpOptionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDhcpOptionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_request.go deleted file mode 100644 index a38dfcee7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_request.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDirectLinkInterfaceRequest struct for CreateDirectLinkInterfaceRequest -type CreateDirectLinkInterfaceRequest struct { - // The ID of the existing DirectLink for which you want to create the DirectLink interface. - DirectLinkId string `json:"DirectLinkId"` - DirectLinkInterface DirectLinkInterface `json:"DirectLinkInterface"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDirectLinkId returns the DirectLinkId field value -func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkId() string { - if o == nil { - var ret string - return ret - } - - return o.DirectLinkId -} - -// SetDirectLinkId sets field value -func (o *CreateDirectLinkInterfaceRequest) SetDirectLinkId(v string) { - o.DirectLinkId = v -} - -// GetDirectLinkInterface returns the DirectLinkInterface field value -func (o *CreateDirectLinkInterfaceRequest) GetDirectLinkInterface() DirectLinkInterface { - if o == nil { - var ret DirectLinkInterface - return ret - } - - return o.DirectLinkInterface -} - -// SetDirectLinkInterface sets field value -func (o *CreateDirectLinkInterfaceRequest) SetDirectLinkInterface(v DirectLinkInterface) { - o.DirectLinkInterface = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateDirectLinkInterfaceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkInterfaceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateDirectLinkInterfaceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateDirectLinkInterfaceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableCreateDirectLinkInterfaceRequest struct { - Value CreateDirectLinkInterfaceRequest - ExplicitNull bool -} - -func (v NullableCreateDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDirectLinkInterfaceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_response.go deleted file mode 100644 index e8e42f8e6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_interface_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDirectLinkInterfaceResponse struct for CreateDirectLinkInterfaceResponse -type CreateDirectLinkInterfaceResponse struct { - DirectLinkInterface *DirectLinkInterfaces `json:"DirectLinkInterface,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDirectLinkInterface returns the DirectLinkInterface field value if set, zero value otherwise. -func (o *CreateDirectLinkInterfaceResponse) GetDirectLinkInterface() DirectLinkInterfaces { - if o == nil || o.DirectLinkInterface == nil { - var ret DirectLinkInterfaces - return ret - } - return *o.DirectLinkInterface -} - -// GetDirectLinkInterfaceOk returns a tuple with the DirectLinkInterface field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkInterfaceResponse) GetDirectLinkInterfaceOk() (DirectLinkInterfaces, bool) { - if o == nil || o.DirectLinkInterface == nil { - var ret DirectLinkInterfaces - return ret, false - } - return *o.DirectLinkInterface, true -} - -// HasDirectLinkInterface returns a boolean if a field has been set. -func (o *CreateDirectLinkInterfaceResponse) HasDirectLinkInterface() bool { - if o != nil && o.DirectLinkInterface != nil { - return true - } - - return false -} - -// SetDirectLinkInterface gets a reference to the given DirectLinkInterfaces and assigns it to the DirectLinkInterface field. -func (o *CreateDirectLinkInterfaceResponse) SetDirectLinkInterface(v DirectLinkInterfaces) { - o.DirectLinkInterface = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateDirectLinkInterfaceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkInterfaceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateDirectLinkInterfaceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateDirectLinkInterfaceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateDirectLinkInterfaceResponse struct { - Value CreateDirectLinkInterfaceResponse - ExplicitNull bool -} - -func (v NullableCreateDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDirectLinkInterfaceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_request.go deleted file mode 100644 index 319be8c40..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_request.go +++ /dev/null @@ -1,129 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDirectLinkRequest struct for CreateDirectLinkRequest -type CreateDirectLinkRequest struct { - // The bandwidth of the DirectLink (`1Gbps` \\| `10Gbps`). - Bandwidth string `json:"Bandwidth"` - // The name of the DirectLink. - DirectLinkName string `json:"DirectLinkName"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The code of the requested location for the DirectLink, returned by the [ReadLocations](#readlocations) method. - Location string `json:"Location"` -} - -// GetBandwidth returns the Bandwidth field value -func (o *CreateDirectLinkRequest) GetBandwidth() string { - if o == nil { - var ret string - return ret - } - - return o.Bandwidth -} - -// SetBandwidth sets field value -func (o *CreateDirectLinkRequest) SetBandwidth(v string) { - o.Bandwidth = v -} - -// GetDirectLinkName returns the DirectLinkName field value -func (o *CreateDirectLinkRequest) GetDirectLinkName() string { - if o == nil { - var ret string - return ret - } - - return o.DirectLinkName -} - -// SetDirectLinkName sets field value -func (o *CreateDirectLinkRequest) SetDirectLinkName(v string) { - o.DirectLinkName = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateDirectLinkRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateDirectLinkRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateDirectLinkRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLocation returns the Location field value -func (o *CreateDirectLinkRequest) GetLocation() string { - if o == nil { - var ret string - return ret - } - - return o.Location -} - -// SetLocation sets field value -func (o *CreateDirectLinkRequest) SetLocation(v string) { - o.Location = v -} - -type NullableCreateDirectLinkRequest struct { - Value CreateDirectLinkRequest - ExplicitNull bool -} - -func (v NullableCreateDirectLinkRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDirectLinkRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_response.go deleted file mode 100644 index 009189af1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_direct_link_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateDirectLinkResponse struct for CreateDirectLinkResponse -type CreateDirectLinkResponse struct { - DirectLink *DirectLink `json:"DirectLink,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDirectLink returns the DirectLink field value if set, zero value otherwise. -func (o *CreateDirectLinkResponse) GetDirectLink() DirectLink { - if o == nil || o.DirectLink == nil { - var ret DirectLink - return ret - } - return *o.DirectLink -} - -// GetDirectLinkOk returns a tuple with the DirectLink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkResponse) GetDirectLinkOk() (DirectLink, bool) { - if o == nil || o.DirectLink == nil { - var ret DirectLink - return ret, false - } - return *o.DirectLink, true -} - -// HasDirectLink returns a boolean if a field has been set. -func (o *CreateDirectLinkResponse) HasDirectLink() bool { - if o != nil && o.DirectLink != nil { - return true - } - - return false -} - -// SetDirectLink gets a reference to the given DirectLink and assigns it to the DirectLink field. -func (o *CreateDirectLinkResponse) SetDirectLink(v DirectLink) { - o.DirectLink = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateDirectLinkResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateDirectLinkResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateDirectLinkResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateDirectLinkResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateDirectLinkResponse struct { - Value CreateDirectLinkResponse - ExplicitNull bool -} - -func (v NullableCreateDirectLinkResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateDirectLinkResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_request.go deleted file mode 100644 index c87ef512c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_request.go +++ /dev/null @@ -1,182 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateFlexibleGpuRequest struct for CreateFlexibleGpuRequest -type CreateFlexibleGpuRequest struct { - // If `true`, the fGPU is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The processor generation that the fGPU must be compatible with. If not specified, the oldest possible processor generation is selected (as provided by [ReadFlexibleGpuCatalog](#readflexiblegpucatalog) for the specified model of fGPU). - Generation *string `json:"Generation,omitempty"` - // The model of fGPU you want to allocate. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - ModelName string `json:"ModelName"` - // The Subregion in which you want to create the fGPU. - SubregionName string `json:"SubregionName"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *CreateFlexibleGpuRequest) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateFlexibleGpuRequest) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *CreateFlexibleGpuRequest) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *CreateFlexibleGpuRequest) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateFlexibleGpuRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateFlexibleGpuRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateFlexibleGpuRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateFlexibleGpuRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetGeneration returns the Generation field value if set, zero value otherwise. -func (o *CreateFlexibleGpuRequest) GetGeneration() string { - if o == nil || o.Generation == nil { - var ret string - return ret - } - return *o.Generation -} - -// GetGenerationOk returns a tuple with the Generation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateFlexibleGpuRequest) GetGenerationOk() (string, bool) { - if o == nil || o.Generation == nil { - var ret string - return ret, false - } - return *o.Generation, true -} - -// HasGeneration returns a boolean if a field has been set. -func (o *CreateFlexibleGpuRequest) HasGeneration() bool { - if o != nil && o.Generation != nil { - return true - } - - return false -} - -// SetGeneration gets a reference to the given string and assigns it to the Generation field. -func (o *CreateFlexibleGpuRequest) SetGeneration(v string) { - o.Generation = &v -} - -// GetModelName returns the ModelName field value -func (o *CreateFlexibleGpuRequest) GetModelName() string { - if o == nil { - var ret string - return ret - } - - return o.ModelName -} - -// SetModelName sets field value -func (o *CreateFlexibleGpuRequest) SetModelName(v string) { - o.ModelName = v -} - -// GetSubregionName returns the SubregionName field value -func (o *CreateFlexibleGpuRequest) GetSubregionName() string { - if o == nil { - var ret string - return ret - } - - return o.SubregionName -} - -// SetSubregionName sets field value -func (o *CreateFlexibleGpuRequest) SetSubregionName(v string) { - o.SubregionName = v -} - -type NullableCreateFlexibleGpuRequest struct { - Value CreateFlexibleGpuRequest - ExplicitNull bool -} - -func (v NullableCreateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateFlexibleGpuRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_response.go deleted file mode 100644 index 8461a0f53..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_flexible_gpu_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateFlexibleGpuResponse struct for CreateFlexibleGpuResponse -type CreateFlexibleGpuResponse struct { - FlexibleGpu *FlexibleGpu `json:"FlexibleGpu,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetFlexibleGpu returns the FlexibleGpu field value if set, zero value otherwise. -func (o *CreateFlexibleGpuResponse) GetFlexibleGpu() FlexibleGpu { - if o == nil || o.FlexibleGpu == nil { - var ret FlexibleGpu - return ret - } - return *o.FlexibleGpu -} - -// GetFlexibleGpuOk returns a tuple with the FlexibleGpu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateFlexibleGpuResponse) GetFlexibleGpuOk() (FlexibleGpu, bool) { - if o == nil || o.FlexibleGpu == nil { - var ret FlexibleGpu - return ret, false - } - return *o.FlexibleGpu, true -} - -// HasFlexibleGpu returns a boolean if a field has been set. -func (o *CreateFlexibleGpuResponse) HasFlexibleGpu() bool { - if o != nil && o.FlexibleGpu != nil { - return true - } - - return false -} - -// SetFlexibleGpu gets a reference to the given FlexibleGpu and assigns it to the FlexibleGpu field. -func (o *CreateFlexibleGpuResponse) SetFlexibleGpu(v FlexibleGpu) { - o.FlexibleGpu = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateFlexibleGpuResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateFlexibleGpuResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateFlexibleGpuResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateFlexibleGpuResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateFlexibleGpuResponse struct { - Value CreateFlexibleGpuResponse - ExplicitNull bool -} - -func (v NullableCreateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateFlexibleGpuResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_request.go deleted file mode 100644 index 835d65afd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_request.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateImageExportTaskRequest struct for CreateImageExportTaskRequest -type CreateImageExportTaskRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the OMI to export. - ImageId string `json:"ImageId"` - OsuExport OsuExport `json:"OsuExport"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateImageExportTaskRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageExportTaskRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateImageExportTaskRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateImageExportTaskRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetImageId returns the ImageId field value -func (o *CreateImageExportTaskRequest) GetImageId() string { - if o == nil { - var ret string - return ret - } - - return o.ImageId -} - -// SetImageId sets field value -func (o *CreateImageExportTaskRequest) SetImageId(v string) { - o.ImageId = v -} - -// GetOsuExport returns the OsuExport field value -func (o *CreateImageExportTaskRequest) GetOsuExport() OsuExport { - if o == nil { - var ret OsuExport - return ret - } - - return o.OsuExport -} - -// SetOsuExport sets field value -func (o *CreateImageExportTaskRequest) SetOsuExport(v OsuExport) { - o.OsuExport = v -} - -type NullableCreateImageExportTaskRequest struct { - Value CreateImageExportTaskRequest - ExplicitNull bool -} - -func (v NullableCreateImageExportTaskRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateImageExportTaskRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_response.go deleted file mode 100644 index e85eb7a55..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_export_task_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateImageExportTaskResponse struct for CreateImageExportTaskResponse -type CreateImageExportTaskResponse struct { - ImageExportTask *ImageExportTask `json:"ImageExportTask,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetImageExportTask returns the ImageExportTask field value if set, zero value otherwise. -func (o *CreateImageExportTaskResponse) GetImageExportTask() ImageExportTask { - if o == nil || o.ImageExportTask == nil { - var ret ImageExportTask - return ret - } - return *o.ImageExportTask -} - -// GetImageExportTaskOk returns a tuple with the ImageExportTask field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageExportTaskResponse) GetImageExportTaskOk() (ImageExportTask, bool) { - if o == nil || o.ImageExportTask == nil { - var ret ImageExportTask - return ret, false - } - return *o.ImageExportTask, true -} - -// HasImageExportTask returns a boolean if a field has been set. -func (o *CreateImageExportTaskResponse) HasImageExportTask() bool { - if o != nil && o.ImageExportTask != nil { - return true - } - - return false -} - -// SetImageExportTask gets a reference to the given ImageExportTask and assigns it to the ImageExportTask field. -func (o *CreateImageExportTaskResponse) SetImageExportTask(v ImageExportTask) { - o.ImageExportTask = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateImageExportTaskResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageExportTaskResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateImageExportTaskResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateImageExportTaskResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateImageExportTaskResponse struct { - Value CreateImageExportTaskResponse - ExplicitNull bool -} - -func (v NullableCreateImageExportTaskResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateImageExportTaskResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_request.go deleted file mode 100644 index 588cb88de..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_request.go +++ /dev/null @@ -1,428 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateImageRequest struct for CreateImageRequest -type CreateImageRequest struct { - // The architecture of the OMI (by default, `i386`). - Architecture *string `json:"Architecture,omitempty"` - // One or more block device mappings. - BlockDeviceMappings *[]BlockDeviceMappingImage `json:"BlockDeviceMappings,omitempty"` - // A description for the new OMI. - Description *string `json:"Description,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The pre-signed URL of the OMI manifest file, or the full path to the OMI stored in an OSU bucket. If you specify this parameter, a copy of the OMI is created in your account. - FileLocation *string `json:"FileLocation,omitempty"` - // A unique name for the new OMI.
Constraints: 3-128 alphanumeric characters, underscores (_), spaces ( ), parentheses (()), slashes (/), periods (.), or dashes (-). - ImageName *string `json:"ImageName,omitempty"` - // If `false`, the VM shuts down before creating the OMI and then reboots. If `true`, the VM does not. - NoReboot *bool `json:"NoReboot,omitempty"` - // The name of the root device. - RootDeviceName *string `json:"RootDeviceName,omitempty"` - // The ID of the OMI you want to copy. - SourceImageId *string `json:"SourceImageId,omitempty"` - // The name of the source Region, which must be the same as the Region of your account. - SourceRegionName *string `json:"SourceRegionName,omitempty"` - // The ID of the VM from which you want to create the OMI. - VmId *string `json:"VmId,omitempty"` -} - -// GetArchitecture returns the Architecture field value if set, zero value otherwise. -func (o *CreateImageRequest) GetArchitecture() string { - if o == nil || o.Architecture == nil { - var ret string - return ret - } - return *o.Architecture -} - -// GetArchitectureOk returns a tuple with the Architecture field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetArchitectureOk() (string, bool) { - if o == nil || o.Architecture == nil { - var ret string - return ret, false - } - return *o.Architecture, true -} - -// HasArchitecture returns a boolean if a field has been set. -func (o *CreateImageRequest) HasArchitecture() bool { - if o != nil && o.Architecture != nil { - return true - } - - return false -} - -// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. -func (o *CreateImageRequest) SetArchitecture(v string) { - o.Architecture = &v -} - -// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. -func (o *CreateImageRequest) GetBlockDeviceMappings() []BlockDeviceMappingImage { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingImage - return ret - } - return *o.BlockDeviceMappings -} - -// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetBlockDeviceMappingsOk() ([]BlockDeviceMappingImage, bool) { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingImage - return ret, false - } - return *o.BlockDeviceMappings, true -} - -// HasBlockDeviceMappings returns a boolean if a field has been set. -func (o *CreateImageRequest) HasBlockDeviceMappings() bool { - if o != nil && o.BlockDeviceMappings != nil { - return true - } - - return false -} - -// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingImage and assigns it to the BlockDeviceMappings field. -func (o *CreateImageRequest) SetBlockDeviceMappings(v []BlockDeviceMappingImage) { - o.BlockDeviceMappings = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *CreateImageRequest) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *CreateImageRequest) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *CreateImageRequest) SetDescription(v string) { - o.Description = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateImageRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateImageRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateImageRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFileLocation returns the FileLocation field value if set, zero value otherwise. -func (o *CreateImageRequest) GetFileLocation() string { - if o == nil || o.FileLocation == nil { - var ret string - return ret - } - return *o.FileLocation -} - -// GetFileLocationOk returns a tuple with the FileLocation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetFileLocationOk() (string, bool) { - if o == nil || o.FileLocation == nil { - var ret string - return ret, false - } - return *o.FileLocation, true -} - -// HasFileLocation returns a boolean if a field has been set. -func (o *CreateImageRequest) HasFileLocation() bool { - if o != nil && o.FileLocation != nil { - return true - } - - return false -} - -// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. -func (o *CreateImageRequest) SetFileLocation(v string) { - o.FileLocation = &v -} - -// GetImageName returns the ImageName field value if set, zero value otherwise. -func (o *CreateImageRequest) GetImageName() string { - if o == nil || o.ImageName == nil { - var ret string - return ret - } - return *o.ImageName -} - -// GetImageNameOk returns a tuple with the ImageName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetImageNameOk() (string, bool) { - if o == nil || o.ImageName == nil { - var ret string - return ret, false - } - return *o.ImageName, true -} - -// HasImageName returns a boolean if a field has been set. -func (o *CreateImageRequest) HasImageName() bool { - if o != nil && o.ImageName != nil { - return true - } - - return false -} - -// SetImageName gets a reference to the given string and assigns it to the ImageName field. -func (o *CreateImageRequest) SetImageName(v string) { - o.ImageName = &v -} - -// GetNoReboot returns the NoReboot field value if set, zero value otherwise. -func (o *CreateImageRequest) GetNoReboot() bool { - if o == nil || o.NoReboot == nil { - var ret bool - return ret - } - return *o.NoReboot -} - -// GetNoRebootOk returns a tuple with the NoReboot field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetNoRebootOk() (bool, bool) { - if o == nil || o.NoReboot == nil { - var ret bool - return ret, false - } - return *o.NoReboot, true -} - -// HasNoReboot returns a boolean if a field has been set. -func (o *CreateImageRequest) HasNoReboot() bool { - if o != nil && o.NoReboot != nil { - return true - } - - return false -} - -// SetNoReboot gets a reference to the given bool and assigns it to the NoReboot field. -func (o *CreateImageRequest) SetNoReboot(v bool) { - o.NoReboot = &v -} - -// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. -func (o *CreateImageRequest) GetRootDeviceName() string { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret - } - return *o.RootDeviceName -} - -// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetRootDeviceNameOk() (string, bool) { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret, false - } - return *o.RootDeviceName, true -} - -// HasRootDeviceName returns a boolean if a field has been set. -func (o *CreateImageRequest) HasRootDeviceName() bool { - if o != nil && o.RootDeviceName != nil { - return true - } - - return false -} - -// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. -func (o *CreateImageRequest) SetRootDeviceName(v string) { - o.RootDeviceName = &v -} - -// GetSourceImageId returns the SourceImageId field value if set, zero value otherwise. -func (o *CreateImageRequest) GetSourceImageId() string { - if o == nil || o.SourceImageId == nil { - var ret string - return ret - } - return *o.SourceImageId -} - -// GetSourceImageIdOk returns a tuple with the SourceImageId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetSourceImageIdOk() (string, bool) { - if o == nil || o.SourceImageId == nil { - var ret string - return ret, false - } - return *o.SourceImageId, true -} - -// HasSourceImageId returns a boolean if a field has been set. -func (o *CreateImageRequest) HasSourceImageId() bool { - if o != nil && o.SourceImageId != nil { - return true - } - - return false -} - -// SetSourceImageId gets a reference to the given string and assigns it to the SourceImageId field. -func (o *CreateImageRequest) SetSourceImageId(v string) { - o.SourceImageId = &v -} - -// GetSourceRegionName returns the SourceRegionName field value if set, zero value otherwise. -func (o *CreateImageRequest) GetSourceRegionName() string { - if o == nil || o.SourceRegionName == nil { - var ret string - return ret - } - return *o.SourceRegionName -} - -// GetSourceRegionNameOk returns a tuple with the SourceRegionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetSourceRegionNameOk() (string, bool) { - if o == nil || o.SourceRegionName == nil { - var ret string - return ret, false - } - return *o.SourceRegionName, true -} - -// HasSourceRegionName returns a boolean if a field has been set. -func (o *CreateImageRequest) HasSourceRegionName() bool { - if o != nil && o.SourceRegionName != nil { - return true - } - - return false -} - -// SetSourceRegionName gets a reference to the given string and assigns it to the SourceRegionName field. -func (o *CreateImageRequest) SetSourceRegionName(v string) { - o.SourceRegionName = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *CreateImageRequest) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageRequest) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *CreateImageRequest) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *CreateImageRequest) SetVmId(v string) { - o.VmId = &v -} - -type NullableCreateImageRequest struct { - Value CreateImageRequest - ExplicitNull bool -} - -func (v NullableCreateImageRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateImageRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_response.go deleted file mode 100644 index cd801e2e2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_image_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateImageResponse struct for CreateImageResponse -type CreateImageResponse struct { - Image *Image `json:"Image,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetImage returns the Image field value if set, zero value otherwise. -func (o *CreateImageResponse) GetImage() Image { - if o == nil || o.Image == nil { - var ret Image - return ret - } - return *o.Image -} - -// GetImageOk returns a tuple with the Image field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageResponse) GetImageOk() (Image, bool) { - if o == nil || o.Image == nil { - var ret Image - return ret, false - } - return *o.Image, true -} - -// HasImage returns a boolean if a field has been set. -func (o *CreateImageResponse) HasImage() bool { - if o != nil && o.Image != nil { - return true - } - - return false -} - -// SetImage gets a reference to the given Image and assigns it to the Image field. -func (o *CreateImageResponse) SetImage(v Image) { - o.Image = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateImageResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateImageResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateImageResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateImageResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateImageResponse struct { - Value CreateImageResponse - ExplicitNull bool -} - -func (v NullableCreateImageResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateImageResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_request.go deleted file mode 100644 index 77898c9be..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateInternetServiceRequest struct for CreateInternetServiceRequest -type CreateInternetServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateInternetServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateInternetServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateInternetServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateInternetServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableCreateInternetServiceRequest struct { - Value CreateInternetServiceRequest - ExplicitNull bool -} - -func (v NullableCreateInternetServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateInternetServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_response.go deleted file mode 100644 index 33e65114c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_internet_service_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateInternetServiceResponse struct for CreateInternetServiceResponse -type CreateInternetServiceResponse struct { - InternetService *InternetService `json:"InternetService,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetInternetService returns the InternetService field value if set, zero value otherwise. -func (o *CreateInternetServiceResponse) GetInternetService() InternetService { - if o == nil || o.InternetService == nil { - var ret InternetService - return ret - } - return *o.InternetService -} - -// GetInternetServiceOk returns a tuple with the InternetService field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateInternetServiceResponse) GetInternetServiceOk() (InternetService, bool) { - if o == nil || o.InternetService == nil { - var ret InternetService - return ret, false - } - return *o.InternetService, true -} - -// HasInternetService returns a boolean if a field has been set. -func (o *CreateInternetServiceResponse) HasInternetService() bool { - if o != nil && o.InternetService != nil { - return true - } - - return false -} - -// SetInternetService gets a reference to the given InternetService and assigns it to the InternetService field. -func (o *CreateInternetServiceResponse) SetInternetService(v InternetService) { - o.InternetService = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateInternetServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateInternetServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateInternetServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateInternetServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateInternetServiceResponse struct { - Value CreateInternetServiceResponse - ExplicitNull bool -} - -func (v NullableCreateInternetServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateInternetServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_request.go deleted file mode 100644 index 1f48cf94e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateKeypairRequest struct for CreateKeypairRequest -type CreateKeypairRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // A unique name for the keypair, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). - KeypairName string `json:"KeypairName"` - // The public key. It must be base64-encoded. - PublicKey *string `json:"PublicKey,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateKeypairRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateKeypairRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateKeypairRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateKeypairRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetKeypairName returns the KeypairName field value -func (o *CreateKeypairRequest) GetKeypairName() string { - if o == nil { - var ret string - return ret - } - - return o.KeypairName -} - -// SetKeypairName sets field value -func (o *CreateKeypairRequest) SetKeypairName(v string) { - o.KeypairName = v -} - -// GetPublicKey returns the PublicKey field value if set, zero value otherwise. -func (o *CreateKeypairRequest) GetPublicKey() string { - if o == nil || o.PublicKey == nil { - var ret string - return ret - } - return *o.PublicKey -} - -// GetPublicKeyOk returns a tuple with the PublicKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateKeypairRequest) GetPublicKeyOk() (string, bool) { - if o == nil || o.PublicKey == nil { - var ret string - return ret, false - } - return *o.PublicKey, true -} - -// HasPublicKey returns a boolean if a field has been set. -func (o *CreateKeypairRequest) HasPublicKey() bool { - if o != nil && o.PublicKey != nil { - return true - } - - return false -} - -// SetPublicKey gets a reference to the given string and assigns it to the PublicKey field. -func (o *CreateKeypairRequest) SetPublicKey(v string) { - o.PublicKey = &v -} - -type NullableCreateKeypairRequest struct { - Value CreateKeypairRequest - ExplicitNull bool -} - -func (v NullableCreateKeypairRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateKeypairRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_response.go deleted file mode 100644 index 600aa6dd3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_keypair_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateKeypairResponse struct for CreateKeypairResponse -type CreateKeypairResponse struct { - Keypair *KeypairCreated `json:"Keypair,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetKeypair returns the Keypair field value if set, zero value otherwise. -func (o *CreateKeypairResponse) GetKeypair() KeypairCreated { - if o == nil || o.Keypair == nil { - var ret KeypairCreated - return ret - } - return *o.Keypair -} - -// GetKeypairOk returns a tuple with the Keypair field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateKeypairResponse) GetKeypairOk() (KeypairCreated, bool) { - if o == nil || o.Keypair == nil { - var ret KeypairCreated - return ret, false - } - return *o.Keypair, true -} - -// HasKeypair returns a boolean if a field has been set. -func (o *CreateKeypairResponse) HasKeypair() bool { - if o != nil && o.Keypair != nil { - return true - } - - return false -} - -// SetKeypair gets a reference to the given KeypairCreated and assigns it to the Keypair field. -func (o *CreateKeypairResponse) SetKeypair(v KeypairCreated) { - o.Keypair = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateKeypairResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateKeypairResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateKeypairResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateKeypairResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateKeypairResponse struct { - Value CreateKeypairResponse - ExplicitNull bool -} - -func (v NullableCreateKeypairResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateKeypairResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_request.go deleted file mode 100644 index 0ff44669e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_request.go +++ /dev/null @@ -1,127 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateListenerRuleRequest struct for CreateListenerRuleRequest -type CreateListenerRuleRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Listener LoadBalancerLight `json:"Listener"` - ListenerRule ListenerRuleForCreation `json:"ListenerRule"` - // The IDs of the backend VMs. - VmIds []string `json:"VmIds"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateListenerRuleRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateListenerRuleRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateListenerRuleRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateListenerRuleRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetListener returns the Listener field value -func (o *CreateListenerRuleRequest) GetListener() LoadBalancerLight { - if o == nil { - var ret LoadBalancerLight - return ret - } - - return o.Listener -} - -// SetListener sets field value -func (o *CreateListenerRuleRequest) SetListener(v LoadBalancerLight) { - o.Listener = v -} - -// GetListenerRule returns the ListenerRule field value -func (o *CreateListenerRuleRequest) GetListenerRule() ListenerRuleForCreation { - if o == nil { - var ret ListenerRuleForCreation - return ret - } - - return o.ListenerRule -} - -// SetListenerRule sets field value -func (o *CreateListenerRuleRequest) SetListenerRule(v ListenerRuleForCreation) { - o.ListenerRule = v -} - -// GetVmIds returns the VmIds field value -func (o *CreateListenerRuleRequest) GetVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.VmIds -} - -// SetVmIds sets field value -func (o *CreateListenerRuleRequest) SetVmIds(v []string) { - o.VmIds = v -} - -type NullableCreateListenerRuleRequest struct { - Value CreateListenerRuleRequest - ExplicitNull bool -} - -func (v NullableCreateListenerRuleRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateListenerRuleRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_response.go deleted file mode 100644 index 347b9e266..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_listener_rule_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateListenerRuleResponse struct for CreateListenerRuleResponse -type CreateListenerRuleResponse struct { - ListenerRule *ListenerRule `json:"ListenerRule,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetListenerRule returns the ListenerRule field value if set, zero value otherwise. -func (o *CreateListenerRuleResponse) GetListenerRule() ListenerRule { - if o == nil || o.ListenerRule == nil { - var ret ListenerRule - return ret - } - return *o.ListenerRule -} - -// GetListenerRuleOk returns a tuple with the ListenerRule field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateListenerRuleResponse) GetListenerRuleOk() (ListenerRule, bool) { - if o == nil || o.ListenerRule == nil { - var ret ListenerRule - return ret, false - } - return *o.ListenerRule, true -} - -// HasListenerRule returns a boolean if a field has been set. -func (o *CreateListenerRuleResponse) HasListenerRule() bool { - if o != nil && o.ListenerRule != nil { - return true - } - - return false -} - -// SetListenerRule gets a reference to the given ListenerRule and assigns it to the ListenerRule field. -func (o *CreateListenerRuleResponse) SetListenerRule(v ListenerRule) { - o.ListenerRule = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateListenerRuleResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateListenerRuleResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateListenerRuleResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateListenerRuleResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateListenerRuleResponse struct { - Value CreateListenerRuleResponse - ExplicitNull bool -} - -func (v NullableCreateListenerRuleResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateListenerRuleResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_request.go deleted file mode 100644 index 465f1d2b7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerListenersRequest struct for CreateLoadBalancerListenersRequest -type CreateLoadBalancerListenersRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more listeners for the load balancer. - Listeners []ListenerForCreation `json:"Listeners"` - // The name of the load balancer for which you want to create listeners. - LoadBalancerName string `json:"LoadBalancerName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateLoadBalancerListenersRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerListenersRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateLoadBalancerListenersRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateLoadBalancerListenersRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetListeners returns the Listeners field value -func (o *CreateLoadBalancerListenersRequest) GetListeners() []ListenerForCreation { - if o == nil { - var ret []ListenerForCreation - return ret - } - - return o.Listeners -} - -// SetListeners sets field value -func (o *CreateLoadBalancerListenersRequest) SetListeners(v []ListenerForCreation) { - o.Listeners = v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *CreateLoadBalancerListenersRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *CreateLoadBalancerListenersRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -type NullableCreateLoadBalancerListenersRequest struct { - Value CreateLoadBalancerListenersRequest - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerListenersRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_response.go deleted file mode 100644 index 1b0ea5a06..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_listeners_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerListenersResponse struct for CreateLoadBalancerListenersResponse -type CreateLoadBalancerListenersResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *CreateLoadBalancerListenersResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerListenersResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *CreateLoadBalancerListenersResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *CreateLoadBalancerListenersResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateLoadBalancerListenersResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerListenersResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateLoadBalancerListenersResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateLoadBalancerListenersResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateLoadBalancerListenersResponse struct { - Value CreateLoadBalancerListenersResponse - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerListenersResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_request.go deleted file mode 100644 index 5b6a811f1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_request.go +++ /dev/null @@ -1,164 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerPolicyRequest struct for CreateLoadBalancerPolicyRequest -type CreateLoadBalancerPolicyRequest struct { - // The name of the application cookie used for stickiness. This parameter is required if you create a stickiness policy based on an application-generated cookie. - CookieName *string `json:"CookieName,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer for which you want to create a policy. - LoadBalancerName string `json:"LoadBalancerName"` - // The name of the policy. This name must be unique and consist of alphanumeric characters and dashes (-). - PolicyName string `json:"PolicyName"` - // The type of stickiness policy you want to create: `app` or `load_balancer`. - PolicyType string `json:"PolicyType"` -} - -// GetCookieName returns the CookieName field value if set, zero value otherwise. -func (o *CreateLoadBalancerPolicyRequest) GetCookieName() string { - if o == nil || o.CookieName == nil { - var ret string - return ret - } - return *o.CookieName -} - -// GetCookieNameOk returns a tuple with the CookieName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerPolicyRequest) GetCookieNameOk() (string, bool) { - if o == nil || o.CookieName == nil { - var ret string - return ret, false - } - return *o.CookieName, true -} - -// HasCookieName returns a boolean if a field has been set. -func (o *CreateLoadBalancerPolicyRequest) HasCookieName() bool { - if o != nil && o.CookieName != nil { - return true - } - - return false -} - -// SetCookieName gets a reference to the given string and assigns it to the CookieName field. -func (o *CreateLoadBalancerPolicyRequest) SetCookieName(v string) { - o.CookieName = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateLoadBalancerPolicyRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerPolicyRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateLoadBalancerPolicyRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateLoadBalancerPolicyRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *CreateLoadBalancerPolicyRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *CreateLoadBalancerPolicyRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetPolicyName returns the PolicyName field value -func (o *CreateLoadBalancerPolicyRequest) GetPolicyName() string { - if o == nil { - var ret string - return ret - } - - return o.PolicyName -} - -// SetPolicyName sets field value -func (o *CreateLoadBalancerPolicyRequest) SetPolicyName(v string) { - o.PolicyName = v -} - -// GetPolicyType returns the PolicyType field value -func (o *CreateLoadBalancerPolicyRequest) GetPolicyType() string { - if o == nil { - var ret string - return ret - } - - return o.PolicyType -} - -// SetPolicyType sets field value -func (o *CreateLoadBalancerPolicyRequest) SetPolicyType(v string) { - o.PolicyType = v -} - -type NullableCreateLoadBalancerPolicyRequest struct { - Value CreateLoadBalancerPolicyRequest - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerPolicyRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_response.go deleted file mode 100644 index fcfdcce89..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_policy_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerPolicyResponse struct for CreateLoadBalancerPolicyResponse -type CreateLoadBalancerPolicyResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *CreateLoadBalancerPolicyResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerPolicyResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *CreateLoadBalancerPolicyResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *CreateLoadBalancerPolicyResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateLoadBalancerPolicyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerPolicyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateLoadBalancerPolicyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateLoadBalancerPolicyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateLoadBalancerPolicyResponse struct { - Value CreateLoadBalancerPolicyResponse - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerPolicyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_request.go deleted file mode 100644 index 0730a13c1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_request.go +++ /dev/null @@ -1,287 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerRequest struct for CreateLoadBalancerRequest -type CreateLoadBalancerRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more listeners to create. - Listeners []ListenerForCreation `json:"Listeners"` - // The unique name of the load balancer (32 alphanumeric or hyphen characters maximum, but cannot start or end with a hyphen). - LoadBalancerName string `json:"LoadBalancerName"` - // The type of load balancer: `internet-facing` or `internal`. Use this parameter only for load balancers in a Net. - LoadBalancerType *string `json:"LoadBalancerType,omitempty"` - // One or more IDs of security groups you want to assign to the load balancer.
In a Net, this attribute is required. In the public Cloud, it is optional and default security groups can be applied. - SecurityGroups *[]string `json:"SecurityGroups,omitempty"` - // One or more IDs of Subnets in your Net that you want to attach to the load balancer. - Subnets *[]string `json:"Subnets,omitempty"` - // One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `LoadBalancerType` parameter. - SubregionNames *[]string `json:"SubregionNames,omitempty"` - // One or more tags assigned to the load balancer. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateLoadBalancerRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetListeners returns the Listeners field value -func (o *CreateLoadBalancerRequest) GetListeners() []ListenerForCreation { - if o == nil { - var ret []ListenerForCreation - return ret - } - - return o.Listeners -} - -// SetListeners sets field value -func (o *CreateLoadBalancerRequest) SetListeners(v []ListenerForCreation) { - o.Listeners = v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *CreateLoadBalancerRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *CreateLoadBalancerRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetLoadBalancerType returns the LoadBalancerType field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetLoadBalancerType() string { - if o == nil || o.LoadBalancerType == nil { - var ret string - return ret - } - return *o.LoadBalancerType -} - -// GetLoadBalancerTypeOk returns a tuple with the LoadBalancerType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetLoadBalancerTypeOk() (string, bool) { - if o == nil || o.LoadBalancerType == nil { - var ret string - return ret, false - } - return *o.LoadBalancerType, true -} - -// HasLoadBalancerType returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasLoadBalancerType() bool { - if o != nil && o.LoadBalancerType != nil { - return true - } - - return false -} - -// SetLoadBalancerType gets a reference to the given string and assigns it to the LoadBalancerType field. -func (o *CreateLoadBalancerRequest) SetLoadBalancerType(v string) { - o.LoadBalancerType = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetSecurityGroups() []string { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetSecurityGroupsOk() ([]string, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. -func (o *CreateLoadBalancerRequest) SetSecurityGroups(v []string) { - o.SecurityGroups = &v -} - -// GetSubnets returns the Subnets field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetSubnets() []string { - if o == nil || o.Subnets == nil { - var ret []string - return ret - } - return *o.Subnets -} - -// GetSubnetsOk returns a tuple with the Subnets field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetSubnetsOk() ([]string, bool) { - if o == nil || o.Subnets == nil { - var ret []string - return ret, false - } - return *o.Subnets, true -} - -// HasSubnets returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasSubnets() bool { - if o != nil && o.Subnets != nil { - return true - } - - return false -} - -// SetSubnets gets a reference to the given []string and assigns it to the Subnets field. -func (o *CreateLoadBalancerRequest) SetSubnets(v []string) { - o.Subnets = &v -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *CreateLoadBalancerRequest) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *CreateLoadBalancerRequest) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerRequest) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *CreateLoadBalancerRequest) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *CreateLoadBalancerRequest) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableCreateLoadBalancerRequest struct { - Value CreateLoadBalancerRequest - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_response.go deleted file mode 100644 index 6f07d8a29..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerResponse struct for CreateLoadBalancerResponse -type CreateLoadBalancerResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *CreateLoadBalancerResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *CreateLoadBalancerResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *CreateLoadBalancerResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateLoadBalancerResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateLoadBalancerResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateLoadBalancerResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateLoadBalancerResponse struct { - Value CreateLoadBalancerResponse - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_request.go deleted file mode 100644 index d70d01c83..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerTagsRequest struct for CreateLoadBalancerTagsRequest -type CreateLoadBalancerTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more load balancer names. - LoadBalancerNames []string `json:"LoadBalancerNames"` - // One or more tags to add to the specified load balancers. - Tags []ResourceTag `json:"Tags"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateLoadBalancerTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateLoadBalancerTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateLoadBalancerTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerNames returns the LoadBalancerNames field value -func (o *CreateLoadBalancerTagsRequest) GetLoadBalancerNames() []string { - if o == nil { - var ret []string - return ret - } - - return o.LoadBalancerNames -} - -// SetLoadBalancerNames sets field value -func (o *CreateLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { - o.LoadBalancerNames = v -} - -// GetTags returns the Tags field value -func (o *CreateLoadBalancerTagsRequest) GetTags() []ResourceTag { - if o == nil { - var ret []ResourceTag - return ret - } - - return o.Tags -} - -// SetTags sets field value -func (o *CreateLoadBalancerTagsRequest) SetTags(v []ResourceTag) { - o.Tags = v -} - -type NullableCreateLoadBalancerTagsRequest struct { - Value CreateLoadBalancerTagsRequest - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_response.go deleted file mode 100644 index a31486ccd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_load_balancer_tags_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateLoadBalancerTagsResponse struct for CreateLoadBalancerTagsResponse -type CreateLoadBalancerTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateLoadBalancerTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateLoadBalancerTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateLoadBalancerTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateLoadBalancerTagsResponse struct { - Value CreateLoadBalancerTagsResponse - ExplicitNull bool -} - -func (v NullableCreateLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_request.go deleted file mode 100644 index 69292adc0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNatServiceRequest struct for CreateNatServiceRequest -type CreateNatServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The allocation ID of the EIP to associate with the NAT service.
If the EIP is already associated with another resource, you must first disassociate it. - PublicIpId string `json:"PublicIpId"` - // The ID of the Subnet in which you want to create the NAT service. - SubnetId string `json:"SubnetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateNatServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNatServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateNatServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateNatServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPublicIpId returns the PublicIpId field value -func (o *CreateNatServiceRequest) GetPublicIpId() string { - if o == nil { - var ret string - return ret - } - - return o.PublicIpId -} - -// SetPublicIpId sets field value -func (o *CreateNatServiceRequest) SetPublicIpId(v string) { - o.PublicIpId = v -} - -// GetSubnetId returns the SubnetId field value -func (o *CreateNatServiceRequest) GetSubnetId() string { - if o == nil { - var ret string - return ret - } - - return o.SubnetId -} - -// SetSubnetId sets field value -func (o *CreateNatServiceRequest) SetSubnetId(v string) { - o.SubnetId = v -} - -type NullableCreateNatServiceRequest struct { - Value CreateNatServiceRequest - ExplicitNull bool -} - -func (v NullableCreateNatServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNatServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_response.go deleted file mode 100644 index 0d47ec3e2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nat_service_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNatServiceResponse struct for CreateNatServiceResponse -type CreateNatServiceResponse struct { - NatService *NatService `json:"NatService,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNatService returns the NatService field value if set, zero value otherwise. -func (o *CreateNatServiceResponse) GetNatService() NatService { - if o == nil || o.NatService == nil { - var ret NatService - return ret - } - return *o.NatService -} - -// GetNatServiceOk returns a tuple with the NatService field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNatServiceResponse) GetNatServiceOk() (NatService, bool) { - if o == nil || o.NatService == nil { - var ret NatService - return ret, false - } - return *o.NatService, true -} - -// HasNatService returns a boolean if a field has been set. -func (o *CreateNatServiceResponse) HasNatService() bool { - if o != nil && o.NatService != nil { - return true - } - - return false -} - -// SetNatService gets a reference to the given NatService and assigns it to the NatService field. -func (o *CreateNatServiceResponse) SetNatService(v NatService) { - o.NatService = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateNatServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNatServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateNatServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateNatServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateNatServiceResponse struct { - Value CreateNatServiceResponse - ExplicitNull bool -} - -func (v NullableCreateNatServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNatServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_request.go deleted file mode 100644 index f52948313..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_request.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetAccessPointRequest struct for CreateNetAccessPointRequest -type CreateNetAccessPointRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net. - NetId string `json:"NetId"` - // One or more IDs of route tables to use for the connection. - RouteTableIds *[]string `json:"RouteTableIds,omitempty"` - // The prefix list name corresponding to the service (for example, `com.outscale.eu-west-2.osu` for OSU). - ServiceName string `json:"ServiceName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateNetAccessPointRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetAccessPointRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateNetAccessPointRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateNetAccessPointRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *CreateNetAccessPointRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *CreateNetAccessPointRequest) SetNetId(v string) { - o.NetId = v -} - -// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. -func (o *CreateNetAccessPointRequest) GetRouteTableIds() []string { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret - } - return *o.RouteTableIds -} - -// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetAccessPointRequest) GetRouteTableIdsOk() ([]string, bool) { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret, false - } - return *o.RouteTableIds, true -} - -// HasRouteTableIds returns a boolean if a field has been set. -func (o *CreateNetAccessPointRequest) HasRouteTableIds() bool { - if o != nil && o.RouteTableIds != nil { - return true - } - - return false -} - -// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. -func (o *CreateNetAccessPointRequest) SetRouteTableIds(v []string) { - o.RouteTableIds = &v -} - -// GetServiceName returns the ServiceName field value -func (o *CreateNetAccessPointRequest) GetServiceName() string { - if o == nil { - var ret string - return ret - } - - return o.ServiceName -} - -// SetServiceName sets field value -func (o *CreateNetAccessPointRequest) SetServiceName(v string) { - o.ServiceName = v -} - -type NullableCreateNetAccessPointRequest struct { - Value CreateNetAccessPointRequest - ExplicitNull bool -} - -func (v NullableCreateNetAccessPointRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetAccessPointRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_response.go deleted file mode 100644 index de67bd6e8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_access_point_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetAccessPointResponse struct for CreateNetAccessPointResponse -type CreateNetAccessPointResponse struct { - NetAccessPoint *NetAccessPoint `json:"NetAccessPoint,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetAccessPoint returns the NetAccessPoint field value if set, zero value otherwise. -func (o *CreateNetAccessPointResponse) GetNetAccessPoint() NetAccessPoint { - if o == nil || o.NetAccessPoint == nil { - var ret NetAccessPoint - return ret - } - return *o.NetAccessPoint -} - -// GetNetAccessPointOk returns a tuple with the NetAccessPoint field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetAccessPointResponse) GetNetAccessPointOk() (NetAccessPoint, bool) { - if o == nil || o.NetAccessPoint == nil { - var ret NetAccessPoint - return ret, false - } - return *o.NetAccessPoint, true -} - -// HasNetAccessPoint returns a boolean if a field has been set. -func (o *CreateNetAccessPointResponse) HasNetAccessPoint() bool { - if o != nil && o.NetAccessPoint != nil { - return true - } - - return false -} - -// SetNetAccessPoint gets a reference to the given NetAccessPoint and assigns it to the NetAccessPoint field. -func (o *CreateNetAccessPointResponse) SetNetAccessPoint(v NetAccessPoint) { - o.NetAccessPoint = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateNetAccessPointResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetAccessPointResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateNetAccessPointResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateNetAccessPointResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateNetAccessPointResponse struct { - Value CreateNetAccessPointResponse - ExplicitNull bool -} - -func (v NullableCreateNetAccessPointResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetAccessPointResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_request.go deleted file mode 100644 index 5bbfe1cbe..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetPeeringRequest struct for CreateNetPeeringRequest -type CreateNetPeeringRequest struct { - // The ID of the Net you want to connect with. - AccepterNetId string `json:"AccepterNetId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net you send the peering request from. - SourceNetId string `json:"SourceNetId"` -} - -// GetAccepterNetId returns the AccepterNetId field value -func (o *CreateNetPeeringRequest) GetAccepterNetId() string { - if o == nil { - var ret string - return ret - } - - return o.AccepterNetId -} - -// SetAccepterNetId sets field value -func (o *CreateNetPeeringRequest) SetAccepterNetId(v string) { - o.AccepterNetId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateNetPeeringRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetPeeringRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateNetPeeringRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateNetPeeringRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetSourceNetId returns the SourceNetId field value -func (o *CreateNetPeeringRequest) GetSourceNetId() string { - if o == nil { - var ret string - return ret - } - - return o.SourceNetId -} - -// SetSourceNetId sets field value -func (o *CreateNetPeeringRequest) SetSourceNetId(v string) { - o.SourceNetId = v -} - -type NullableCreateNetPeeringRequest struct { - Value CreateNetPeeringRequest - ExplicitNull bool -} - -func (v NullableCreateNetPeeringRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetPeeringRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_response.go deleted file mode 100644 index 48e7bf8fb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_peering_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetPeeringResponse struct for CreateNetPeeringResponse -type CreateNetPeeringResponse struct { - NetPeering *NetPeering `json:"NetPeering,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetPeering returns the NetPeering field value if set, zero value otherwise. -func (o *CreateNetPeeringResponse) GetNetPeering() NetPeering { - if o == nil || o.NetPeering == nil { - var ret NetPeering - return ret - } - return *o.NetPeering -} - -// GetNetPeeringOk returns a tuple with the NetPeering field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetPeeringResponse) GetNetPeeringOk() (NetPeering, bool) { - if o == nil || o.NetPeering == nil { - var ret NetPeering - return ret, false - } - return *o.NetPeering, true -} - -// HasNetPeering returns a boolean if a field has been set. -func (o *CreateNetPeeringResponse) HasNetPeering() bool { - if o != nil && o.NetPeering != nil { - return true - } - - return false -} - -// SetNetPeering gets a reference to the given NetPeering and assigns it to the NetPeering field. -func (o *CreateNetPeeringResponse) SetNetPeering(v NetPeering) { - o.NetPeering = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateNetPeeringResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetPeeringResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateNetPeeringResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateNetPeeringResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateNetPeeringResponse struct { - Value CreateNetPeeringResponse - ExplicitNull bool -} - -func (v NullableCreateNetPeeringResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetPeeringResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_request.go deleted file mode 100644 index 5d369c444..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetRequest struct for CreateNetRequest -type CreateNetRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). - IpRange string `json:"IpRange"` - // The tenancy options for the VMs (`default` if a VM created in a Net can be launched with any tenancy, `dedicated` if it can be launched with dedicated tenancy VMs running on single-tenant hardware). - Tenancy *string `json:"Tenancy,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateNetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateNetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateNetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetIpRange returns the IpRange field value -func (o *CreateNetRequest) GetIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.IpRange -} - -// SetIpRange sets field value -func (o *CreateNetRequest) SetIpRange(v string) { - o.IpRange = v -} - -// GetTenancy returns the Tenancy field value if set, zero value otherwise. -func (o *CreateNetRequest) GetTenancy() string { - if o == nil || o.Tenancy == nil { - var ret string - return ret - } - return *o.Tenancy -} - -// GetTenancyOk returns a tuple with the Tenancy field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetRequest) GetTenancyOk() (string, bool) { - if o == nil || o.Tenancy == nil { - var ret string - return ret, false - } - return *o.Tenancy, true -} - -// HasTenancy returns a boolean if a field has been set. -func (o *CreateNetRequest) HasTenancy() bool { - if o != nil && o.Tenancy != nil { - return true - } - - return false -} - -// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. -func (o *CreateNetRequest) SetTenancy(v string) { - o.Tenancy = &v -} - -type NullableCreateNetRequest struct { - Value CreateNetRequest - ExplicitNull bool -} - -func (v NullableCreateNetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_response.go deleted file mode 100644 index 3791eb6b5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_net_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNetResponse struct for CreateNetResponse -type CreateNetResponse struct { - Net *Net `json:"Net,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNet returns the Net field value if set, zero value otherwise. -func (o *CreateNetResponse) GetNet() Net { - if o == nil || o.Net == nil { - var ret Net - return ret - } - return *o.Net -} - -// GetNetOk returns a tuple with the Net field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetResponse) GetNetOk() (Net, bool) { - if o == nil || o.Net == nil { - var ret Net - return ret, false - } - return *o.Net, true -} - -// HasNet returns a boolean if a field has been set. -func (o *CreateNetResponse) HasNet() bool { - if o != nil && o.Net != nil { - return true - } - - return false -} - -// SetNet gets a reference to the given Net and assigns it to the Net field. -func (o *CreateNetResponse) SetNet(v Net) { - o.Net = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateNetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateNetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateNetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateNetResponse struct { - Value CreateNetResponse - ExplicitNull bool -} - -func (v NullableCreateNetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_request.go deleted file mode 100644 index 61024dc11..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_request.go +++ /dev/null @@ -1,200 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNicRequest struct for CreateNicRequest -type CreateNicRequest struct { - // A description for the NIC. - Description *string `json:"Description,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The primary private IP address for the NIC.

This IP address must be within the IP address range of the Subnet that you specify with the `SubnetId` attribute.
If you do not specify this attribute, a random private IP address is selected within the IP address range of the Subnet. - PrivateIps *[]PrivateIpLight `json:"PrivateIps,omitempty"` - // One or more IDs of security groups for the NIC. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` - // The ID of the Subnet in which you want to create the NIC. - SubnetId string `json:"SubnetId"` -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *CreateNicRequest) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicRequest) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *CreateNicRequest) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *CreateNicRequest) SetDescription(v string) { - o.Description = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateNicRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateNicRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateNicRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *CreateNicRequest) GetPrivateIps() []PrivateIpLight { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLight - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicRequest) GetPrivateIpsOk() ([]PrivateIpLight, bool) { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLight - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *CreateNicRequest) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []PrivateIpLight and assigns it to the PrivateIps field. -func (o *CreateNicRequest) SetPrivateIps(v []PrivateIpLight) { - o.PrivateIps = &v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *CreateNicRequest) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicRequest) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *CreateNicRequest) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *CreateNicRequest) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -// GetSubnetId returns the SubnetId field value -func (o *CreateNicRequest) GetSubnetId() string { - if o == nil { - var ret string - return ret - } - - return o.SubnetId -} - -// SetSubnetId sets field value -func (o *CreateNicRequest) SetSubnetId(v string) { - o.SubnetId = v -} - -type NullableCreateNicRequest struct { - Value CreateNicRequest - ExplicitNull bool -} - -func (v NullableCreateNicRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNicRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_response.go deleted file mode 100644 index f050826e1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_nic_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateNicResponse struct for CreateNicResponse -type CreateNicResponse struct { - Nic *Nic `json:"Nic,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNic returns the Nic field value if set, zero value otherwise. -func (o *CreateNicResponse) GetNic() Nic { - if o == nil || o.Nic == nil { - var ret Nic - return ret - } - return *o.Nic -} - -// GetNicOk returns a tuple with the Nic field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicResponse) GetNicOk() (Nic, bool) { - if o == nil || o.Nic == nil { - var ret Nic - return ret, false - } - return *o.Nic, true -} - -// HasNic returns a boolean if a field has been set. -func (o *CreateNicResponse) HasNic() bool { - if o != nil && o.Nic != nil { - return true - } - - return false -} - -// SetNic gets a reference to the given Nic and assigns it to the Nic field. -func (o *CreateNicResponse) SetNic(v Nic) { - o.Nic = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateNicResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateNicResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateNicResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateNicResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateNicResponse struct { - Value CreateNicResponse - ExplicitNull bool -} - -func (v NullableCreateNicResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateNicResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_request.go deleted file mode 100644 index 64e93e721..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreatePublicIpRequest struct for CreatePublicIpRequest -type CreatePublicIpRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreatePublicIpRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreatePublicIpRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreatePublicIpRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreatePublicIpRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableCreatePublicIpRequest struct { - Value CreatePublicIpRequest - ExplicitNull bool -} - -func (v NullableCreatePublicIpRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreatePublicIpRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_response.go deleted file mode 100644 index 79911ebe6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_public_ip_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreatePublicIpResponse struct for CreatePublicIpResponse -type CreatePublicIpResponse struct { - PublicIp *PublicIp `json:"PublicIp,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *CreatePublicIpResponse) GetPublicIp() PublicIp { - if o == nil || o.PublicIp == nil { - var ret PublicIp - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreatePublicIpResponse) GetPublicIpOk() (PublicIp, bool) { - if o == nil || o.PublicIp == nil { - var ret PublicIp - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *CreatePublicIpResponse) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given PublicIp and assigns it to the PublicIp field. -func (o *CreatePublicIpResponse) SetPublicIp(v PublicIp) { - o.PublicIp = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreatePublicIpResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreatePublicIpResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreatePublicIpResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreatePublicIpResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreatePublicIpResponse struct { - Value CreatePublicIpResponse - ExplicitNull bool -} - -func (v NullableCreatePublicIpResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreatePublicIpResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_request.go deleted file mode 100644 index c83c44a79..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_request.go +++ /dev/null @@ -1,287 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateRouteRequest struct for CreateRouteRequest -type CreateRouteRequest struct { - // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - DestinationIpRange string `json:"DestinationIpRange"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of an Internet service or virtual gateway attached to your Net. - GatewayId *string `json:"GatewayId,omitempty"` - // The ID of a NAT service. - NatServiceId *string `json:"NatServiceId,omitempty"` - // The ID of a Net peering connection. - NetPeeringId *string `json:"NetPeeringId,omitempty"` - // The ID of a NIC. - NicId *string `json:"NicId,omitempty"` - // The ID of the route table for which you want to create a route. - RouteTableId string `json:"RouteTableId"` - // The ID of a NAT VM in your Net (attached to exactly one NIC). - VmId *string `json:"VmId,omitempty"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value -func (o *CreateRouteRequest) GetDestinationIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.DestinationIpRange -} - -// SetDestinationIpRange sets field value -func (o *CreateRouteRequest) SetDestinationIpRange(v string) { - o.DestinationIpRange = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateRouteRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetGatewayId returns the GatewayId field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetGatewayId() string { - if o == nil || o.GatewayId == nil { - var ret string - return ret - } - return *o.GatewayId -} - -// GetGatewayIdOk returns a tuple with the GatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetGatewayIdOk() (string, bool) { - if o == nil || o.GatewayId == nil { - var ret string - return ret, false - } - return *o.GatewayId, true -} - -// HasGatewayId returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasGatewayId() bool { - if o != nil && o.GatewayId != nil { - return true - } - - return false -} - -// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. -func (o *CreateRouteRequest) SetGatewayId(v string) { - o.GatewayId = &v -} - -// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetNatServiceId() string { - if o == nil || o.NatServiceId == nil { - var ret string - return ret - } - return *o.NatServiceId -} - -// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetNatServiceIdOk() (string, bool) { - if o == nil || o.NatServiceId == nil { - var ret string - return ret, false - } - return *o.NatServiceId, true -} - -// HasNatServiceId returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasNatServiceId() bool { - if o != nil && o.NatServiceId != nil { - return true - } - - return false -} - -// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. -func (o *CreateRouteRequest) SetNatServiceId(v string) { - o.NatServiceId = &v -} - -// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetNetPeeringId() string { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret - } - return *o.NetPeeringId -} - -// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetNetPeeringIdOk() (string, bool) { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret, false - } - return *o.NetPeeringId, true -} - -// HasNetPeeringId returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasNetPeeringId() bool { - if o != nil && o.NetPeeringId != nil { - return true - } - - return false -} - -// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. -func (o *CreateRouteRequest) SetNetPeeringId(v string) { - o.NetPeeringId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *CreateRouteRequest) SetNicId(v string) { - o.NicId = &v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *CreateRouteRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *CreateRouteRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *CreateRouteRequest) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteRequest) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *CreateRouteRequest) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *CreateRouteRequest) SetVmId(v string) { - o.VmId = &v -} - -type NullableCreateRouteRequest struct { - Value CreateRouteRequest - ExplicitNull bool -} - -func (v NullableCreateRouteRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateRouteRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_response.go deleted file mode 100644 index fc2989317..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateRouteResponse struct for CreateRouteResponse -type CreateRouteResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - RouteTable *RouteTable `json:"RouteTable,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateRouteResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateRouteResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateRouteResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTable returns the RouteTable field value if set, zero value otherwise. -func (o *CreateRouteResponse) GetRouteTable() RouteTable { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret - } - return *o.RouteTable -} - -// GetRouteTableOk returns a tuple with the RouteTable field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteResponse) GetRouteTableOk() (RouteTable, bool) { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret, false - } - return *o.RouteTable, true -} - -// HasRouteTable returns a boolean if a field has been set. -func (o *CreateRouteResponse) HasRouteTable() bool { - if o != nil && o.RouteTable != nil { - return true - } - - return false -} - -// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. -func (o *CreateRouteResponse) SetRouteTable(v RouteTable) { - o.RouteTable = &v -} - -type NullableCreateRouteResponse struct { - Value CreateRouteResponse - ExplicitNull bool -} - -func (v NullableCreateRouteResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateRouteResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_request.go deleted file mode 100644 index c43a74c38..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateRouteTableRequest struct for CreateRouteTableRequest -type CreateRouteTableRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net for which you want to create a route table. - NetId string `json:"NetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateRouteTableRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteTableRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateRouteTableRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateRouteTableRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *CreateRouteTableRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *CreateRouteTableRequest) SetNetId(v string) { - o.NetId = v -} - -type NullableCreateRouteTableRequest struct { - Value CreateRouteTableRequest - ExplicitNull bool -} - -func (v NullableCreateRouteTableRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateRouteTableRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_response.go deleted file mode 100644 index 4498bc377..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_route_table_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateRouteTableResponse struct for CreateRouteTableResponse -type CreateRouteTableResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - RouteTable *RouteTable `json:"RouteTable,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateRouteTableResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteTableResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateRouteTableResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateRouteTableResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTable returns the RouteTable field value if set, zero value otherwise. -func (o *CreateRouteTableResponse) GetRouteTable() RouteTable { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret - } - return *o.RouteTable -} - -// GetRouteTableOk returns a tuple with the RouteTable field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateRouteTableResponse) GetRouteTableOk() (RouteTable, bool) { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret, false - } - return *o.RouteTable, true -} - -// HasRouteTable returns a boolean if a field has been set. -func (o *CreateRouteTableResponse) HasRouteTable() bool { - if o != nil && o.RouteTable != nil { - return true - } - - return false -} - -// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. -func (o *CreateRouteTableResponse) SetRouteTable(v RouteTable) { - o.RouteTable = &v -} - -type NullableCreateRouteTableResponse struct { - Value CreateRouteTableResponse - ExplicitNull bool -} - -func (v NullableCreateRouteTableResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateRouteTableResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_request.go deleted file mode 100644 index e07a6f79e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_request.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSecurityGroupRequest struct for CreateSecurityGroupRequest -type CreateSecurityGroupRequest struct { - // A description for the security group, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). - Description string `json:"Description"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net for the security group. - NetId *string `json:"NetId,omitempty"` - // (Public Cloud only) The name of the security group.
This name must not start with `sg-`.
This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed. - SecurityGroupName string `json:"SecurityGroupName"` -} - -// GetDescription returns the Description field value -func (o *CreateSecurityGroupRequest) GetDescription() string { - if o == nil { - var ret string - return ret - } - - return o.Description -} - -// SetDescription sets field value -func (o *CreateSecurityGroupRequest) SetDescription(v string) { - o.Description = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateSecurityGroupRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateSecurityGroupRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateSecurityGroupRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *CreateSecurityGroupRequest) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRequest) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *CreateSecurityGroupRequest) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *CreateSecurityGroupRequest) SetNetId(v string) { - o.NetId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value -func (o *CreateSecurityGroupRequest) GetSecurityGroupName() string { - if o == nil { - var ret string - return ret - } - - return o.SecurityGroupName -} - -// SetSecurityGroupName sets field value -func (o *CreateSecurityGroupRequest) SetSecurityGroupName(v string) { - o.SecurityGroupName = v -} - -type NullableCreateSecurityGroupRequest struct { - Value CreateSecurityGroupRequest - ExplicitNull bool -} - -func (v NullableCreateSecurityGroupRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSecurityGroupRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_response.go deleted file mode 100644 index f1acb3dc8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSecurityGroupResponse struct for CreateSecurityGroupResponse -type CreateSecurityGroupResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateSecurityGroupResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateSecurityGroupResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateSecurityGroupResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. -func (o *CreateSecurityGroupResponse) GetSecurityGroup() SecurityGroup { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret - } - return *o.SecurityGroup -} - -// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupResponse) GetSecurityGroupOk() (SecurityGroup, bool) { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret, false - } - return *o.SecurityGroup, true -} - -// HasSecurityGroup returns a boolean if a field has been set. -func (o *CreateSecurityGroupResponse) HasSecurityGroup() bool { - if o != nil && o.SecurityGroup != nil { - return true - } - - return false -} - -// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. -func (o *CreateSecurityGroupResponse) SetSecurityGroup(v SecurityGroup) { - o.SecurityGroup = &v -} - -type NullableCreateSecurityGroupResponse struct { - Value CreateSecurityGroupResponse - ExplicitNull bool -} - -func (v NullableCreateSecurityGroupResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSecurityGroupResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_request.go deleted file mode 100644 index eef919f1d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_request.go +++ /dev/null @@ -1,357 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSecurityGroupRuleRequest struct for CreateSecurityGroupRuleRequest -type CreateSecurityGroupRuleRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. - Flow string `json:"Flow"` - // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - FromPortRange *int64 `json:"FromPortRange,omitempty"` - // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - IpProtocol *string `json:"IpProtocol,omitempty"` - // The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // Information about the security group rule to create. - Rules *[]SecurityGroupRule `json:"Rules,omitempty"` - // The account ID of the owner of the security group for which you want to create a rule. - SecurityGroupAccountIdToLink *string `json:"SecurityGroupAccountIdToLink,omitempty"` - // The ID of the security group for which you want to create a rule. - SecurityGroupId string `json:"SecurityGroupId"` - // The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. - SecurityGroupNameToLink *string `json:"SecurityGroupNameToLink,omitempty"` - // The end of the port range for the TCP and UDP protocols, or an ICMP type number. - ToPortRange *int64 `json:"ToPortRange,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateSecurityGroupRuleRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlow returns the Flow field value -func (o *CreateSecurityGroupRuleRequest) GetFlow() string { - if o == nil { - var ret string - return ret - } - - return o.Flow -} - -// SetFlow sets field value -func (o *CreateSecurityGroupRuleRequest) SetFlow(v string) { - o.Flow = v -} - -// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetFromPortRange() int64 { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret - } - return *o.FromPortRange -} - -// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetFromPortRangeOk() (int64, bool) { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret, false - } - return *o.FromPortRange, true -} - -// HasFromPortRange returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasFromPortRange() bool { - if o != nil && o.FromPortRange != nil { - return true - } - - return false -} - -// SetFromPortRange gets a reference to the given int64 and assigns it to the FromPortRange field. -func (o *CreateSecurityGroupRuleRequest) SetFromPortRange(v int64) { - o.FromPortRange = &v -} - -// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetIpProtocol() string { - if o == nil || o.IpProtocol == nil { - var ret string - return ret - } - return *o.IpProtocol -} - -// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetIpProtocolOk() (string, bool) { - if o == nil || o.IpProtocol == nil { - var ret string - return ret, false - } - return *o.IpProtocol, true -} - -// HasIpProtocol returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasIpProtocol() bool { - if o != nil && o.IpProtocol != nil { - return true - } - - return false -} - -// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. -func (o *CreateSecurityGroupRuleRequest) SetIpProtocol(v string) { - o.IpProtocol = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *CreateSecurityGroupRuleRequest) SetIpRange(v string) { - o.IpRange = &v -} - -// GetRules returns the Rules field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetRules() []SecurityGroupRule { - if o == nil || o.Rules == nil { - var ret []SecurityGroupRule - return ret - } - return *o.Rules -} - -// GetRulesOk returns a tuple with the Rules field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetRulesOk() ([]SecurityGroupRule, bool) { - if o == nil || o.Rules == nil { - var ret []SecurityGroupRule - return ret, false - } - return *o.Rules, true -} - -// HasRules returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasRules() bool { - if o != nil && o.Rules != nil { - return true - } - - return false -} - -// SetRules gets a reference to the given []SecurityGroupRule and assigns it to the Rules field. -func (o *CreateSecurityGroupRuleRequest) SetRules(v []SecurityGroupRule) { - o.Rules = &v -} - -// GetSecurityGroupAccountIdToLink returns the SecurityGroupAccountIdToLink field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupAccountIdToLink() string { - if o == nil || o.SecurityGroupAccountIdToLink == nil { - var ret string - return ret - } - return *o.SecurityGroupAccountIdToLink -} - -// GetSecurityGroupAccountIdToLinkOk returns a tuple with the SecurityGroupAccountIdToLink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupAccountIdToLinkOk() (string, bool) { - if o == nil || o.SecurityGroupAccountIdToLink == nil { - var ret string - return ret, false - } - return *o.SecurityGroupAccountIdToLink, true -} - -// HasSecurityGroupAccountIdToLink returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasSecurityGroupAccountIdToLink() bool { - if o != nil && o.SecurityGroupAccountIdToLink != nil { - return true - } - - return false -} - -// SetSecurityGroupAccountIdToLink gets a reference to the given string and assigns it to the SecurityGroupAccountIdToLink field. -func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupAccountIdToLink(v string) { - o.SecurityGroupAccountIdToLink = &v -} - -// GetSecurityGroupId returns the SecurityGroupId field value -func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupId() string { - if o == nil { - var ret string - return ret - } - - return o.SecurityGroupId -} - -// SetSecurityGroupId sets field value -func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupId(v string) { - o.SecurityGroupId = v -} - -// GetSecurityGroupNameToLink returns the SecurityGroupNameToLink field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupNameToLink() string { - if o == nil || o.SecurityGroupNameToLink == nil { - var ret string - return ret - } - return *o.SecurityGroupNameToLink -} - -// GetSecurityGroupNameToLinkOk returns a tuple with the SecurityGroupNameToLink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetSecurityGroupNameToLinkOk() (string, bool) { - if o == nil || o.SecurityGroupNameToLink == nil { - var ret string - return ret, false - } - return *o.SecurityGroupNameToLink, true -} - -// HasSecurityGroupNameToLink returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasSecurityGroupNameToLink() bool { - if o != nil && o.SecurityGroupNameToLink != nil { - return true - } - - return false -} - -// SetSecurityGroupNameToLink gets a reference to the given string and assigns it to the SecurityGroupNameToLink field. -func (o *CreateSecurityGroupRuleRequest) SetSecurityGroupNameToLink(v string) { - o.SecurityGroupNameToLink = &v -} - -// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleRequest) GetToPortRange() int64 { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret - } - return *o.ToPortRange -} - -// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleRequest) GetToPortRangeOk() (int64, bool) { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret, false - } - return *o.ToPortRange, true -} - -// HasToPortRange returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleRequest) HasToPortRange() bool { - if o != nil && o.ToPortRange != nil { - return true - } - - return false -} - -// SetToPortRange gets a reference to the given int64 and assigns it to the ToPortRange field. -func (o *CreateSecurityGroupRuleRequest) SetToPortRange(v int64) { - o.ToPortRange = &v -} - -type NullableCreateSecurityGroupRuleRequest struct { - Value CreateSecurityGroupRuleRequest - ExplicitNull bool -} - -func (v NullableCreateSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSecurityGroupRuleRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_response.go deleted file mode 100644 index 4442640ec..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_security_group_rule_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSecurityGroupRuleResponse struct for CreateSecurityGroupRuleResponse -type CreateSecurityGroupRuleResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateSecurityGroupRuleResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. -func (o *CreateSecurityGroupRuleResponse) GetSecurityGroup() SecurityGroup { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret - } - return *o.SecurityGroup -} - -// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSecurityGroupRuleResponse) GetSecurityGroupOk() (SecurityGroup, bool) { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret, false - } - return *o.SecurityGroup, true -} - -// HasSecurityGroup returns a boolean if a field has been set. -func (o *CreateSecurityGroupRuleResponse) HasSecurityGroup() bool { - if o != nil && o.SecurityGroup != nil { - return true - } - - return false -} - -// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. -func (o *CreateSecurityGroupRuleResponse) SetSecurityGroup(v SecurityGroup) { - o.SecurityGroup = &v -} - -type NullableCreateSecurityGroupRuleResponse struct { - Value CreateSecurityGroupRuleResponse - ExplicitNull bool -} - -func (v NullableCreateSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSecurityGroupRuleResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_request.go deleted file mode 100644 index 5363fec01..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_request.go +++ /dev/null @@ -1,199 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateServerCertificateRequest struct for CreateServerCertificateRequest -type CreateServerCertificateRequest struct { - // The PEM-encoded X509 certificate. - Body string `json:"Body"` - // The PEM-encoded intermediate certification authorities. - Chain *string `json:"Chain,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // A unique name for the certificate. Constraints: 1-128 alphanumeric characters, pluses (+), equals (=), commas (,), periods (.), at signs (@), minuses (-), or underscores (_). - Name string `json:"Name"` - // The path to the server certificate, set to a slash (/) if not specified. - Path *string `json:"Path,omitempty"` - // The PEM-encoded private key matching the certificate. - PrivateKey string `json:"PrivateKey"` -} - -// GetBody returns the Body field value -func (o *CreateServerCertificateRequest) GetBody() string { - if o == nil { - var ret string - return ret - } - - return o.Body -} - -// SetBody sets field value -func (o *CreateServerCertificateRequest) SetBody(v string) { - o.Body = v -} - -// GetChain returns the Chain field value if set, zero value otherwise. -func (o *CreateServerCertificateRequest) GetChain() string { - if o == nil || o.Chain == nil { - var ret string - return ret - } - return *o.Chain -} - -// GetChainOk returns a tuple with the Chain field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateServerCertificateRequest) GetChainOk() (string, bool) { - if o == nil || o.Chain == nil { - var ret string - return ret, false - } - return *o.Chain, true -} - -// HasChain returns a boolean if a field has been set. -func (o *CreateServerCertificateRequest) HasChain() bool { - if o != nil && o.Chain != nil { - return true - } - - return false -} - -// SetChain gets a reference to the given string and assigns it to the Chain field. -func (o *CreateServerCertificateRequest) SetChain(v string) { - o.Chain = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateServerCertificateRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateServerCertificateRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateServerCertificateRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateServerCertificateRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetName returns the Name field value -func (o *CreateServerCertificateRequest) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// SetName sets field value -func (o *CreateServerCertificateRequest) SetName(v string) { - o.Name = v -} - -// GetPath returns the Path field value if set, zero value otherwise. -func (o *CreateServerCertificateRequest) GetPath() string { - if o == nil || o.Path == nil { - var ret string - return ret - } - return *o.Path -} - -// GetPathOk returns a tuple with the Path field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateServerCertificateRequest) GetPathOk() (string, bool) { - if o == nil || o.Path == nil { - var ret string - return ret, false - } - return *o.Path, true -} - -// HasPath returns a boolean if a field has been set. -func (o *CreateServerCertificateRequest) HasPath() bool { - if o != nil && o.Path != nil { - return true - } - - return false -} - -// SetPath gets a reference to the given string and assigns it to the Path field. -func (o *CreateServerCertificateRequest) SetPath(v string) { - o.Path = &v -} - -// GetPrivateKey returns the PrivateKey field value -func (o *CreateServerCertificateRequest) GetPrivateKey() string { - if o == nil { - var ret string - return ret - } - - return o.PrivateKey -} - -// SetPrivateKey sets field value -func (o *CreateServerCertificateRequest) SetPrivateKey(v string) { - o.PrivateKey = v -} - -type NullableCreateServerCertificateRequest struct { - Value CreateServerCertificateRequest - ExplicitNull bool -} - -func (v NullableCreateServerCertificateRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateServerCertificateRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_response.go deleted file mode 100644 index 95bce4e69..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_server_certificate_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateServerCertificateResponse struct for CreateServerCertificateResponse -type CreateServerCertificateResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - ServerCertificate *ServerCertificate `json:"ServerCertificate,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateServerCertificateResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateServerCertificateResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateServerCertificateResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateServerCertificateResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetServerCertificate returns the ServerCertificate field value if set, zero value otherwise. -func (o *CreateServerCertificateResponse) GetServerCertificate() ServerCertificate { - if o == nil || o.ServerCertificate == nil { - var ret ServerCertificate - return ret - } - return *o.ServerCertificate -} - -// GetServerCertificateOk returns a tuple with the ServerCertificate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateServerCertificateResponse) GetServerCertificateOk() (ServerCertificate, bool) { - if o == nil || o.ServerCertificate == nil { - var ret ServerCertificate - return ret, false - } - return *o.ServerCertificate, true -} - -// HasServerCertificate returns a boolean if a field has been set. -func (o *CreateServerCertificateResponse) HasServerCertificate() bool { - if o != nil && o.ServerCertificate != nil { - return true - } - - return false -} - -// SetServerCertificate gets a reference to the given ServerCertificate and assigns it to the ServerCertificate field. -func (o *CreateServerCertificateResponse) SetServerCertificate(v ServerCertificate) { - o.ServerCertificate = &v -} - -type NullableCreateServerCertificateResponse struct { - Value CreateServerCertificateResponse - ExplicitNull bool -} - -func (v NullableCreateServerCertificateResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateServerCertificateResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_request.go deleted file mode 100644 index 71defb310..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_request.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSnapshotExportTaskRequest struct for CreateSnapshotExportTaskRequest -type CreateSnapshotExportTaskRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - OsuExport OsuExport `json:"OsuExport"` - // The ID of the snapshot to export. - SnapshotId string `json:"SnapshotId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateSnapshotExportTaskRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotExportTaskRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateSnapshotExportTaskRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateSnapshotExportTaskRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetOsuExport returns the OsuExport field value -func (o *CreateSnapshotExportTaskRequest) GetOsuExport() OsuExport { - if o == nil { - var ret OsuExport - return ret - } - - return o.OsuExport -} - -// SetOsuExport sets field value -func (o *CreateSnapshotExportTaskRequest) SetOsuExport(v OsuExport) { - o.OsuExport = v -} - -// GetSnapshotId returns the SnapshotId field value -func (o *CreateSnapshotExportTaskRequest) GetSnapshotId() string { - if o == nil { - var ret string - return ret - } - - return o.SnapshotId -} - -// SetSnapshotId sets field value -func (o *CreateSnapshotExportTaskRequest) SetSnapshotId(v string) { - o.SnapshotId = v -} - -type NullableCreateSnapshotExportTaskRequest struct { - Value CreateSnapshotExportTaskRequest - ExplicitNull bool -} - -func (v NullableCreateSnapshotExportTaskRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSnapshotExportTaskRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_response.go deleted file mode 100644 index 7454c3d4d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_export_task_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSnapshotExportTaskResponse struct for CreateSnapshotExportTaskResponse -type CreateSnapshotExportTaskResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - SnapshotExportTask *SnapshotExportTask `json:"SnapshotExportTask,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateSnapshotExportTaskResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotExportTaskResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateSnapshotExportTaskResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateSnapshotExportTaskResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSnapshotExportTask returns the SnapshotExportTask field value if set, zero value otherwise. -func (o *CreateSnapshotExportTaskResponse) GetSnapshotExportTask() SnapshotExportTask { - if o == nil || o.SnapshotExportTask == nil { - var ret SnapshotExportTask - return ret - } - return *o.SnapshotExportTask -} - -// GetSnapshotExportTaskOk returns a tuple with the SnapshotExportTask field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotExportTaskResponse) GetSnapshotExportTaskOk() (SnapshotExportTask, bool) { - if o == nil || o.SnapshotExportTask == nil { - var ret SnapshotExportTask - return ret, false - } - return *o.SnapshotExportTask, true -} - -// HasSnapshotExportTask returns a boolean if a field has been set. -func (o *CreateSnapshotExportTaskResponse) HasSnapshotExportTask() bool { - if o != nil && o.SnapshotExportTask != nil { - return true - } - - return false -} - -// SetSnapshotExportTask gets a reference to the given SnapshotExportTask and assigns it to the SnapshotExportTask field. -func (o *CreateSnapshotExportTaskResponse) SetSnapshotExportTask(v SnapshotExportTask) { - o.SnapshotExportTask = &v -} - -type NullableCreateSnapshotExportTaskResponse struct { - Value CreateSnapshotExportTaskResponse - ExplicitNull bool -} - -func (v NullableCreateSnapshotExportTaskResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSnapshotExportTaskResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_request.go deleted file mode 100644 index 82bcbee26..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_request.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSnapshotRequest struct for CreateSnapshotRequest -type CreateSnapshotRequest struct { - // A description for the snapshot. - Description *string `json:"Description,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The pre-signed URL of the snapshot you want to import from the OSU bucket. - FileLocation *string `json:"FileLocation,omitempty"` - // The size of the snapshot created in your account, in bytes. This size must be exactly the same as the source snapshot one. - SnapshotSize *int64 `json:"SnapshotSize,omitempty"` - // The name of the source Region, which must be the same as the Region of your account. - SourceRegionName *string `json:"SourceRegionName,omitempty"` - // The ID of the snapshot you want to copy. - SourceSnapshotId *string `json:"SourceSnapshotId,omitempty"` - // The ID of the volume you want to create a snapshot of. - VolumeId *string `json:"VolumeId,omitempty"` -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *CreateSnapshotRequest) SetDescription(v string) { - o.Description = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateSnapshotRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFileLocation returns the FileLocation field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetFileLocation() string { - if o == nil || o.FileLocation == nil { - var ret string - return ret - } - return *o.FileLocation -} - -// GetFileLocationOk returns a tuple with the FileLocation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetFileLocationOk() (string, bool) { - if o == nil || o.FileLocation == nil { - var ret string - return ret, false - } - return *o.FileLocation, true -} - -// HasFileLocation returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasFileLocation() bool { - if o != nil && o.FileLocation != nil { - return true - } - - return false -} - -// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. -func (o *CreateSnapshotRequest) SetFileLocation(v string) { - o.FileLocation = &v -} - -// GetSnapshotSize returns the SnapshotSize field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetSnapshotSize() int64 { - if o == nil || o.SnapshotSize == nil { - var ret int64 - return ret - } - return *o.SnapshotSize -} - -// GetSnapshotSizeOk returns a tuple with the SnapshotSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetSnapshotSizeOk() (int64, bool) { - if o == nil || o.SnapshotSize == nil { - var ret int64 - return ret, false - } - return *o.SnapshotSize, true -} - -// HasSnapshotSize returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasSnapshotSize() bool { - if o != nil && o.SnapshotSize != nil { - return true - } - - return false -} - -// SetSnapshotSize gets a reference to the given int64 and assigns it to the SnapshotSize field. -func (o *CreateSnapshotRequest) SetSnapshotSize(v int64) { - o.SnapshotSize = &v -} - -// GetSourceRegionName returns the SourceRegionName field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetSourceRegionName() string { - if o == nil || o.SourceRegionName == nil { - var ret string - return ret - } - return *o.SourceRegionName -} - -// GetSourceRegionNameOk returns a tuple with the SourceRegionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetSourceRegionNameOk() (string, bool) { - if o == nil || o.SourceRegionName == nil { - var ret string - return ret, false - } - return *o.SourceRegionName, true -} - -// HasSourceRegionName returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasSourceRegionName() bool { - if o != nil && o.SourceRegionName != nil { - return true - } - - return false -} - -// SetSourceRegionName gets a reference to the given string and assigns it to the SourceRegionName field. -func (o *CreateSnapshotRequest) SetSourceRegionName(v string) { - o.SourceRegionName = &v -} - -// GetSourceSnapshotId returns the SourceSnapshotId field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetSourceSnapshotId() string { - if o == nil || o.SourceSnapshotId == nil { - var ret string - return ret - } - return *o.SourceSnapshotId -} - -// GetSourceSnapshotIdOk returns a tuple with the SourceSnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetSourceSnapshotIdOk() (string, bool) { - if o == nil || o.SourceSnapshotId == nil { - var ret string - return ret, false - } - return *o.SourceSnapshotId, true -} - -// HasSourceSnapshotId returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasSourceSnapshotId() bool { - if o != nil && o.SourceSnapshotId != nil { - return true - } - - return false -} - -// SetSourceSnapshotId gets a reference to the given string and assigns it to the SourceSnapshotId field. -func (o *CreateSnapshotRequest) SetSourceSnapshotId(v string) { - o.SourceSnapshotId = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *CreateSnapshotRequest) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotRequest) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *CreateSnapshotRequest) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *CreateSnapshotRequest) SetVolumeId(v string) { - o.VolumeId = &v -} - -type NullableCreateSnapshotRequest struct { - Value CreateSnapshotRequest - ExplicitNull bool -} - -func (v NullableCreateSnapshotRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSnapshotRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_response.go deleted file mode 100644 index 61469b010..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_snapshot_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSnapshotResponse struct for CreateSnapshotResponse -type CreateSnapshotResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Snapshot *Snapshot `json:"Snapshot,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateSnapshotResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateSnapshotResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateSnapshotResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSnapshot returns the Snapshot field value if set, zero value otherwise. -func (o *CreateSnapshotResponse) GetSnapshot() Snapshot { - if o == nil || o.Snapshot == nil { - var ret Snapshot - return ret - } - return *o.Snapshot -} - -// GetSnapshotOk returns a tuple with the Snapshot field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSnapshotResponse) GetSnapshotOk() (Snapshot, bool) { - if o == nil || o.Snapshot == nil { - var ret Snapshot - return ret, false - } - return *o.Snapshot, true -} - -// HasSnapshot returns a boolean if a field has been set. -func (o *CreateSnapshotResponse) HasSnapshot() bool { - if o != nil && o.Snapshot != nil { - return true - } - - return false -} - -// SetSnapshot gets a reference to the given Snapshot and assigns it to the Snapshot field. -func (o *CreateSnapshotResponse) SetSnapshot(v Snapshot) { - o.Snapshot = &v -} - -type NullableCreateSnapshotResponse struct { - Value CreateSnapshotResponse - ExplicitNull bool -} - -func (v NullableCreateSnapshotResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSnapshotResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_request.go deleted file mode 100644 index 1025ab163..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_request.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSubnetRequest struct for CreateSubnetRequest -type CreateSubnetRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). - IpRange string `json:"IpRange"` - // The ID of the Net for which you want to create a Subnet. - NetId string `json:"NetId"` - // The name of the Subregion in which you want to create the Subnet. - SubregionName *string `json:"SubregionName,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateSubnetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSubnetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateSubnetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateSubnetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetIpRange returns the IpRange field value -func (o *CreateSubnetRequest) GetIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.IpRange -} - -// SetIpRange sets field value -func (o *CreateSubnetRequest) SetIpRange(v string) { - o.IpRange = v -} - -// GetNetId returns the NetId field value -func (o *CreateSubnetRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *CreateSubnetRequest) SetNetId(v string) { - o.NetId = v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *CreateSubnetRequest) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSubnetRequest) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *CreateSubnetRequest) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *CreateSubnetRequest) SetSubregionName(v string) { - o.SubregionName = &v -} - -type NullableCreateSubnetRequest struct { - Value CreateSubnetRequest - ExplicitNull bool -} - -func (v NullableCreateSubnetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSubnetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_response.go deleted file mode 100644 index ad1c9d38b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_subnet_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateSubnetResponse struct for CreateSubnetResponse -type CreateSubnetResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Subnet *Subnet `json:"Subnet,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateSubnetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSubnetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateSubnetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateSubnetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSubnet returns the Subnet field value if set, zero value otherwise. -func (o *CreateSubnetResponse) GetSubnet() Subnet { - if o == nil || o.Subnet == nil { - var ret Subnet - return ret - } - return *o.Subnet -} - -// GetSubnetOk returns a tuple with the Subnet field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateSubnetResponse) GetSubnetOk() (Subnet, bool) { - if o == nil || o.Subnet == nil { - var ret Subnet - return ret, false - } - return *o.Subnet, true -} - -// HasSubnet returns a boolean if a field has been set. -func (o *CreateSubnetResponse) HasSubnet() bool { - if o != nil && o.Subnet != nil { - return true - } - - return false -} - -// SetSubnet gets a reference to the given Subnet and assigns it to the Subnet field. -func (o *CreateSubnetResponse) SetSubnet(v Subnet) { - o.Subnet = &v -} - -type NullableCreateSubnetResponse struct { - Value CreateSubnetResponse - ExplicitNull bool -} - -func (v NullableCreateSubnetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateSubnetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_request.go deleted file mode 100644 index 1384f1c5b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateTagsRequest struct for CreateTagsRequest -type CreateTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more resource IDs. - ResourceIds []string `json:"ResourceIds"` - // One or more tags to add to the specified resources. - Tags []ResourceTag `json:"Tags"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetResourceIds returns the ResourceIds field value -func (o *CreateTagsRequest) GetResourceIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.ResourceIds -} - -// SetResourceIds sets field value -func (o *CreateTagsRequest) SetResourceIds(v []string) { - o.ResourceIds = v -} - -// GetTags returns the Tags field value -func (o *CreateTagsRequest) GetTags() []ResourceTag { - if o == nil { - var ret []ResourceTag - return ret - } - - return o.Tags -} - -// SetTags sets field value -func (o *CreateTagsRequest) SetTags(v []ResourceTag) { - o.Tags = v -} - -type NullableCreateTagsRequest struct { - Value CreateTagsRequest - ExplicitNull bool -} - -func (v NullableCreateTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_response.go deleted file mode 100644 index ab8875453..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_tags_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateTagsResponse struct for CreateTagsResponse -type CreateTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateTagsResponse struct { - Value CreateTagsResponse - ExplicitNull bool -} - -func (v NullableCreateTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_request.go deleted file mode 100644 index e45fdb843..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVirtualGatewayRequest struct for CreateVirtualGatewayRequest -type CreateVirtualGatewayRequest struct { - // The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). - ConnectionType string `json:"ConnectionType"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetConnectionType returns the ConnectionType field value -func (o *CreateVirtualGatewayRequest) GetConnectionType() string { - if o == nil { - var ret string - return ret - } - - return o.ConnectionType -} - -// SetConnectionType sets field value -func (o *CreateVirtualGatewayRequest) SetConnectionType(v string) { - o.ConnectionType = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateVirtualGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVirtualGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateVirtualGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateVirtualGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableCreateVirtualGatewayRequest struct { - Value CreateVirtualGatewayRequest - ExplicitNull bool -} - -func (v NullableCreateVirtualGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVirtualGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_response.go deleted file mode 100644 index 637b4f844..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_virtual_gateway_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVirtualGatewayResponse struct for CreateVirtualGatewayResponse -type CreateVirtualGatewayResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - VirtualGateway *VirtualGateway `json:"VirtualGateway,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateVirtualGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVirtualGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateVirtualGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateVirtualGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVirtualGateway returns the VirtualGateway field value if set, zero value otherwise. -func (o *CreateVirtualGatewayResponse) GetVirtualGateway() VirtualGateway { - if o == nil || o.VirtualGateway == nil { - var ret VirtualGateway - return ret - } - return *o.VirtualGateway -} - -// GetVirtualGatewayOk returns a tuple with the VirtualGateway field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVirtualGatewayResponse) GetVirtualGatewayOk() (VirtualGateway, bool) { - if o == nil || o.VirtualGateway == nil { - var ret VirtualGateway - return ret, false - } - return *o.VirtualGateway, true -} - -// HasVirtualGateway returns a boolean if a field has been set. -func (o *CreateVirtualGatewayResponse) HasVirtualGateway() bool { - if o != nil && o.VirtualGateway != nil { - return true - } - - return false -} - -// SetVirtualGateway gets a reference to the given VirtualGateway and assigns it to the VirtualGateway field. -func (o *CreateVirtualGatewayResponse) SetVirtualGateway(v VirtualGateway) { - o.VirtualGateway = &v -} - -type NullableCreateVirtualGatewayResponse struct { - Value CreateVirtualGatewayResponse - ExplicitNull bool -} - -func (v NullableCreateVirtualGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVirtualGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_request.go deleted file mode 100644 index cc0e2a509..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_request.go +++ /dev/null @@ -1,724 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVmsRequest struct for CreateVmsRequest -type CreateVmsRequest struct { - // One or more block device mappings. - BlockDeviceMappings *[]BlockDeviceMappingVmCreation `json:"BlockDeviceMappings,omitempty"` - // By default or if `true`, the VM is started on creation. If `false`, the VM is stopped on creation. - BootOnCreation *bool `json:"BootOnCreation,omitempty"` - // If `true`, the VM is created with optimized BSU I/O. - BsuOptimized *bool `json:"BsuOptimized,omitempty"` - // A unique identifier which enables you to manage the idempotency. - ClientToken *string `json:"ClientToken,omitempty"` - // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - DeletionProtection *bool `json:"DeletionProtection,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the OMI used to create the VM. You can find the list of OMIs by calling the [ReadImages](#readimages) method. - ImageId string `json:"ImageId"` - // The name of the keypair. - KeypairName *string `json:"KeypairName,omitempty"` - // The maximum number of VMs you want to create. If all the VMs cannot be created, the largest possible number of VMs above MinVmsCount is created. - MaxVmsCount *int64 `json:"MaxVmsCount,omitempty"` - // The minimum number of VMs you want to create. If this number of VMs cannot be created, no VMs are created. - MinVmsCount *int64 `json:"MinVmsCount,omitempty"` - // One or more NICs. If you specify this parameter, you must define one NIC as the primary network interface of the VM with `0` as its device number. - Nics *[]NicForVmCreation `json:"Nics,omitempty"` - // The performance of the VM (`standard` \\| `high` \\| `highest`). - Performance *string `json:"Performance,omitempty"` - Placement *Placement `json:"Placement,omitempty"` - // One or more private IP addresses of the VM. - PrivateIps *[]string `json:"PrivateIps,omitempty"` - // One or more IDs of security group for the VMs. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` - // One or more names of security groups for the VMs. - SecurityGroups *[]string `json:"SecurityGroups,omitempty"` - // The ID of the Subnet in which you want to create the VM. - SubnetId *string `json:"SubnetId,omitempty"` - // Data or script used to add a specific configuration to the VM. It must be base64-encoded. - UserData *string `json:"UserData,omitempty"` - // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. - VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` - // The type of VM (`tinav2.c1r2` by default).
For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - VmType *string `json:"VmType,omitempty"` -} - -// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetBlockDeviceMappings() []BlockDeviceMappingVmCreation { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingVmCreation - return ret - } - return *o.BlockDeviceMappings -} - -// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetBlockDeviceMappingsOk() ([]BlockDeviceMappingVmCreation, bool) { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingVmCreation - return ret, false - } - return *o.BlockDeviceMappings, true -} - -// HasBlockDeviceMappings returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasBlockDeviceMappings() bool { - if o != nil && o.BlockDeviceMappings != nil { - return true - } - - return false -} - -// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingVmCreation and assigns it to the BlockDeviceMappings field. -func (o *CreateVmsRequest) SetBlockDeviceMappings(v []BlockDeviceMappingVmCreation) { - o.BlockDeviceMappings = &v -} - -// GetBootOnCreation returns the BootOnCreation field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetBootOnCreation() bool { - if o == nil || o.BootOnCreation == nil { - var ret bool - return ret - } - return *o.BootOnCreation -} - -// GetBootOnCreationOk returns a tuple with the BootOnCreation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetBootOnCreationOk() (bool, bool) { - if o == nil || o.BootOnCreation == nil { - var ret bool - return ret, false - } - return *o.BootOnCreation, true -} - -// HasBootOnCreation returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasBootOnCreation() bool { - if o != nil && o.BootOnCreation != nil { - return true - } - - return false -} - -// SetBootOnCreation gets a reference to the given bool and assigns it to the BootOnCreation field. -func (o *CreateVmsRequest) SetBootOnCreation(v bool) { - o.BootOnCreation = &v -} - -// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetBsuOptimized() bool { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret - } - return *o.BsuOptimized -} - -// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetBsuOptimizedOk() (bool, bool) { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret, false - } - return *o.BsuOptimized, true -} - -// HasBsuOptimized returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasBsuOptimized() bool { - if o != nil && o.BsuOptimized != nil { - return true - } - - return false -} - -// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. -func (o *CreateVmsRequest) SetBsuOptimized(v bool) { - o.BsuOptimized = &v -} - -// GetClientToken returns the ClientToken field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetClientToken() string { - if o == nil || o.ClientToken == nil { - var ret string - return ret - } - return *o.ClientToken -} - -// GetClientTokenOk returns a tuple with the ClientToken field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetClientTokenOk() (string, bool) { - if o == nil || o.ClientToken == nil { - var ret string - return ret, false - } - return *o.ClientToken, true -} - -// HasClientToken returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasClientToken() bool { - if o != nil && o.ClientToken != nil { - return true - } - - return false -} - -// SetClientToken gets a reference to the given string and assigns it to the ClientToken field. -func (o *CreateVmsRequest) SetClientToken(v string) { - o.ClientToken = &v -} - -// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetDeletionProtection() bool { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret - } - return *o.DeletionProtection -} - -// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetDeletionProtectionOk() (bool, bool) { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret, false - } - return *o.DeletionProtection, true -} - -// HasDeletionProtection returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasDeletionProtection() bool { - if o != nil && o.DeletionProtection != nil { - return true - } - - return false -} - -// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. -func (o *CreateVmsRequest) SetDeletionProtection(v bool) { - o.DeletionProtection = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetImageId returns the ImageId field value -func (o *CreateVmsRequest) GetImageId() string { - if o == nil { - var ret string - return ret - } - - return o.ImageId -} - -// SetImageId sets field value -func (o *CreateVmsRequest) SetImageId(v string) { - o.ImageId = v -} - -// GetKeypairName returns the KeypairName field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetKeypairName() string { - if o == nil || o.KeypairName == nil { - var ret string - return ret - } - return *o.KeypairName -} - -// GetKeypairNameOk returns a tuple with the KeypairName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetKeypairNameOk() (string, bool) { - if o == nil || o.KeypairName == nil { - var ret string - return ret, false - } - return *o.KeypairName, true -} - -// HasKeypairName returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasKeypairName() bool { - if o != nil && o.KeypairName != nil { - return true - } - - return false -} - -// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. -func (o *CreateVmsRequest) SetKeypairName(v string) { - o.KeypairName = &v -} - -// GetMaxVmsCount returns the MaxVmsCount field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetMaxVmsCount() int64 { - if o == nil || o.MaxVmsCount == nil { - var ret int64 - return ret - } - return *o.MaxVmsCount -} - -// GetMaxVmsCountOk returns a tuple with the MaxVmsCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetMaxVmsCountOk() (int64, bool) { - if o == nil || o.MaxVmsCount == nil { - var ret int64 - return ret, false - } - return *o.MaxVmsCount, true -} - -// HasMaxVmsCount returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasMaxVmsCount() bool { - if o != nil && o.MaxVmsCount != nil { - return true - } - - return false -} - -// SetMaxVmsCount gets a reference to the given int64 and assigns it to the MaxVmsCount field. -func (o *CreateVmsRequest) SetMaxVmsCount(v int64) { - o.MaxVmsCount = &v -} - -// GetMinVmsCount returns the MinVmsCount field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetMinVmsCount() int64 { - if o == nil || o.MinVmsCount == nil { - var ret int64 - return ret - } - return *o.MinVmsCount -} - -// GetMinVmsCountOk returns a tuple with the MinVmsCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetMinVmsCountOk() (int64, bool) { - if o == nil || o.MinVmsCount == nil { - var ret int64 - return ret, false - } - return *o.MinVmsCount, true -} - -// HasMinVmsCount returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasMinVmsCount() bool { - if o != nil && o.MinVmsCount != nil { - return true - } - - return false -} - -// SetMinVmsCount gets a reference to the given int64 and assigns it to the MinVmsCount field. -func (o *CreateVmsRequest) SetMinVmsCount(v int64) { - o.MinVmsCount = &v -} - -// GetNics returns the Nics field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetNics() []NicForVmCreation { - if o == nil || o.Nics == nil { - var ret []NicForVmCreation - return ret - } - return *o.Nics -} - -// GetNicsOk returns a tuple with the Nics field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetNicsOk() ([]NicForVmCreation, bool) { - if o == nil || o.Nics == nil { - var ret []NicForVmCreation - return ret, false - } - return *o.Nics, true -} - -// HasNics returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasNics() bool { - if o != nil && o.Nics != nil { - return true - } - - return false -} - -// SetNics gets a reference to the given []NicForVmCreation and assigns it to the Nics field. -func (o *CreateVmsRequest) SetNics(v []NicForVmCreation) { - o.Nics = &v -} - -// GetPerformance returns the Performance field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetPerformance() string { - if o == nil || o.Performance == nil { - var ret string - return ret - } - return *o.Performance -} - -// GetPerformanceOk returns a tuple with the Performance field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetPerformanceOk() (string, bool) { - if o == nil || o.Performance == nil { - var ret string - return ret, false - } - return *o.Performance, true -} - -// HasPerformance returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasPerformance() bool { - if o != nil && o.Performance != nil { - return true - } - - return false -} - -// SetPerformance gets a reference to the given string and assigns it to the Performance field. -func (o *CreateVmsRequest) SetPerformance(v string) { - o.Performance = &v -} - -// GetPlacement returns the Placement field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetPlacement() Placement { - if o == nil || o.Placement == nil { - var ret Placement - return ret - } - return *o.Placement -} - -// GetPlacementOk returns a tuple with the Placement field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetPlacementOk() (Placement, bool) { - if o == nil || o.Placement == nil { - var ret Placement - return ret, false - } - return *o.Placement, true -} - -// HasPlacement returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasPlacement() bool { - if o != nil && o.Placement != nil { - return true - } - - return false -} - -// SetPlacement gets a reference to the given Placement and assigns it to the Placement field. -func (o *CreateVmsRequest) SetPlacement(v Placement) { - o.Placement = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetPrivateIps() []string { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetPrivateIpsOk() ([]string, bool) { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. -func (o *CreateVmsRequest) SetPrivateIps(v []string) { - o.PrivateIps = &v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *CreateVmsRequest) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetSecurityGroups() []string { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetSecurityGroupsOk() ([]string, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. -func (o *CreateVmsRequest) SetSecurityGroups(v []string) { - o.SecurityGroups = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *CreateVmsRequest) SetSubnetId(v string) { - o.SubnetId = &v -} - -// GetUserData returns the UserData field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetUserData() string { - if o == nil || o.UserData == nil { - var ret string - return ret - } - return *o.UserData -} - -// GetUserDataOk returns a tuple with the UserData field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetUserDataOk() (string, bool) { - if o == nil || o.UserData == nil { - var ret string - return ret, false - } - return *o.UserData, true -} - -// HasUserData returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasUserData() bool { - if o != nil && o.UserData != nil { - return true - } - - return false -} - -// SetUserData gets a reference to the given string and assigns it to the UserData field. -func (o *CreateVmsRequest) SetUserData(v string) { - o.UserData = &v -} - -// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetVmInitiatedShutdownBehavior() string { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret - } - return *o.VmInitiatedShutdownBehavior -} - -// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetVmInitiatedShutdownBehaviorOk() (string, bool) { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret, false - } - return *o.VmInitiatedShutdownBehavior, true -} - -// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasVmInitiatedShutdownBehavior() bool { - if o != nil && o.VmInitiatedShutdownBehavior != nil { - return true - } - - return false -} - -// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. -func (o *CreateVmsRequest) SetVmInitiatedShutdownBehavior(v string) { - o.VmInitiatedShutdownBehavior = &v -} - -// GetVmType returns the VmType field value if set, zero value otherwise. -func (o *CreateVmsRequest) GetVmType() string { - if o == nil || o.VmType == nil { - var ret string - return ret - } - return *o.VmType -} - -// GetVmTypeOk returns a tuple with the VmType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsRequest) GetVmTypeOk() (string, bool) { - if o == nil || o.VmType == nil { - var ret string - return ret, false - } - return *o.VmType, true -} - -// HasVmType returns a boolean if a field has been set. -func (o *CreateVmsRequest) HasVmType() bool { - if o != nil && o.VmType != nil { - return true - } - - return false -} - -// SetVmType gets a reference to the given string and assigns it to the VmType field. -func (o *CreateVmsRequest) SetVmType(v string) { - o.VmType = &v -} - -type NullableCreateVmsRequest struct { - Value CreateVmsRequest - ExplicitNull bool -} - -func (v NullableCreateVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_response.go deleted file mode 100644 index 12f0b96d0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vms_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVmsResponse struct for CreateVmsResponse -type CreateVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more created VMs. - Vms *[]Vm `json:"Vms,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVms returns the Vms field value if set, zero value otherwise. -func (o *CreateVmsResponse) GetVms() []Vm { - if o == nil || o.Vms == nil { - var ret []Vm - return ret - } - return *o.Vms -} - -// GetVmsOk returns a tuple with the Vms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVmsResponse) GetVmsOk() ([]Vm, bool) { - if o == nil || o.Vms == nil { - var ret []Vm - return ret, false - } - return *o.Vms, true -} - -// HasVms returns a boolean if a field has been set. -func (o *CreateVmsResponse) HasVms() bool { - if o != nil && o.Vms != nil { - return true - } - - return false -} - -// SetVms gets a reference to the given []Vm and assigns it to the Vms field. -func (o *CreateVmsResponse) SetVms(v []Vm) { - o.Vms = &v -} - -type NullableCreateVmsResponse struct { - Value CreateVmsResponse - ExplicitNull bool -} - -func (v NullableCreateVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_request.go deleted file mode 100644 index aa5da4e7b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_request.go +++ /dev/null @@ -1,235 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVolumeRequest struct for CreateVolumeRequest -type CreateVolumeRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - Iops *int64 `json:"Iops,omitempty"` - // The size of the volume, in gibibytes (GiB). The maximum allowed size for a volume is 14,901 GiB. This parameter is required if the volume is not created from a snapshot (`SnapshotId` unspecified). - Size *int64 `json:"Size,omitempty"` - // The ID of the snapshot from which you want to create the volume. - SnapshotId *string `json:"SnapshotId,omitempty"` - // The Subregion in which you want to create the volume. - SubregionName string `json:"SubregionName"` - // The type of volume you want to create (`io1` \\| `gp2` \\| `standard`). If not specified, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). - VolumeType *string `json:"VolumeType,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateVolumeRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateVolumeRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateVolumeRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetIops returns the Iops field value if set, zero value otherwise. -func (o *CreateVolumeRequest) GetIops() int64 { - if o == nil || o.Iops == nil { - var ret int64 - return ret - } - return *o.Iops -} - -// GetIopsOk returns a tuple with the Iops field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeRequest) GetIopsOk() (int64, bool) { - if o == nil || o.Iops == nil { - var ret int64 - return ret, false - } - return *o.Iops, true -} - -// HasIops returns a boolean if a field has been set. -func (o *CreateVolumeRequest) HasIops() bool { - if o != nil && o.Iops != nil { - return true - } - - return false -} - -// SetIops gets a reference to the given int64 and assigns it to the Iops field. -func (o *CreateVolumeRequest) SetIops(v int64) { - o.Iops = &v -} - -// GetSize returns the Size field value if set, zero value otherwise. -func (o *CreateVolumeRequest) GetSize() int64 { - if o == nil || o.Size == nil { - var ret int64 - return ret - } - return *o.Size -} - -// GetSizeOk returns a tuple with the Size field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeRequest) GetSizeOk() (int64, bool) { - if o == nil || o.Size == nil { - var ret int64 - return ret, false - } - return *o.Size, true -} - -// HasSize returns a boolean if a field has been set. -func (o *CreateVolumeRequest) HasSize() bool { - if o != nil && o.Size != nil { - return true - } - - return false -} - -// SetSize gets a reference to the given int64 and assigns it to the Size field. -func (o *CreateVolumeRequest) SetSize(v int64) { - o.Size = &v -} - -// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. -func (o *CreateVolumeRequest) GetSnapshotId() string { - if o == nil || o.SnapshotId == nil { - var ret string - return ret - } - return *o.SnapshotId -} - -// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeRequest) GetSnapshotIdOk() (string, bool) { - if o == nil || o.SnapshotId == nil { - var ret string - return ret, false - } - return *o.SnapshotId, true -} - -// HasSnapshotId returns a boolean if a field has been set. -func (o *CreateVolumeRequest) HasSnapshotId() bool { - if o != nil && o.SnapshotId != nil { - return true - } - - return false -} - -// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. -func (o *CreateVolumeRequest) SetSnapshotId(v string) { - o.SnapshotId = &v -} - -// GetSubregionName returns the SubregionName field value -func (o *CreateVolumeRequest) GetSubregionName() string { - if o == nil { - var ret string - return ret - } - - return o.SubregionName -} - -// SetSubregionName sets field value -func (o *CreateVolumeRequest) SetSubregionName(v string) { - o.SubregionName = v -} - -// GetVolumeType returns the VolumeType field value if set, zero value otherwise. -func (o *CreateVolumeRequest) GetVolumeType() string { - if o == nil || o.VolumeType == nil { - var ret string - return ret - } - return *o.VolumeType -} - -// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeRequest) GetVolumeTypeOk() (string, bool) { - if o == nil || o.VolumeType == nil { - var ret string - return ret, false - } - return *o.VolumeType, true -} - -// HasVolumeType returns a boolean if a field has been set. -func (o *CreateVolumeRequest) HasVolumeType() bool { - if o != nil && o.VolumeType != nil { - return true - } - - return false -} - -// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. -func (o *CreateVolumeRequest) SetVolumeType(v string) { - o.VolumeType = &v -} - -type NullableCreateVolumeRequest struct { - Value CreateVolumeRequest - ExplicitNull bool -} - -func (v NullableCreateVolumeRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVolumeRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_response.go deleted file mode 100644 index a6300f50f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_volume_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVolumeResponse struct for CreateVolumeResponse -type CreateVolumeResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Volume *Volume `json:"Volume,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateVolumeResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateVolumeResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateVolumeResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVolume returns the Volume field value if set, zero value otherwise. -func (o *CreateVolumeResponse) GetVolume() Volume { - if o == nil || o.Volume == nil { - var ret Volume - return ret - } - return *o.Volume -} - -// GetVolumeOk returns a tuple with the Volume field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVolumeResponse) GetVolumeOk() (Volume, bool) { - if o == nil || o.Volume == nil { - var ret Volume - return ret, false - } - return *o.Volume, true -} - -// HasVolume returns a boolean if a field has been set. -func (o *CreateVolumeResponse) HasVolume() bool { - if o != nil && o.Volume != nil { - return true - } - - return false -} - -// SetVolume gets a reference to the given Volume and assigns it to the Volume field. -func (o *CreateVolumeResponse) SetVolume(v Volume) { - o.Volume = &v -} - -type NullableCreateVolumeResponse struct { - Value CreateVolumeResponse - ExplicitNull bool -} - -func (v NullableCreateVolumeResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVolumeResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_request.go deleted file mode 100644 index 88badaf5e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_request.go +++ /dev/null @@ -1,164 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVpnConnectionRequest struct for CreateVpnConnectionRequest -type CreateVpnConnectionRequest struct { - // The ID of the client gateway. - ClientGatewayId string `json:"ClientGatewayId"` - // The type of VPN connection (only `ipsec.1` is supported). - ConnectionType string `json:"ConnectionType"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` - // The ID of the virtual gateway. - VirtualGatewayId string `json:"VirtualGatewayId"` -} - -// GetClientGatewayId returns the ClientGatewayId field value -func (o *CreateVpnConnectionRequest) GetClientGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.ClientGatewayId -} - -// SetClientGatewayId sets field value -func (o *CreateVpnConnectionRequest) SetClientGatewayId(v string) { - o.ClientGatewayId = v -} - -// GetConnectionType returns the ConnectionType field value -func (o *CreateVpnConnectionRequest) GetConnectionType() string { - if o == nil { - var ret string - return ret - } - - return o.ConnectionType -} - -// SetConnectionType sets field value -func (o *CreateVpnConnectionRequest) SetConnectionType(v string) { - o.ConnectionType = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateVpnConnectionRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateVpnConnectionRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateVpnConnectionRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. -func (o *CreateVpnConnectionRequest) GetStaticRoutesOnly() bool { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret - } - return *o.StaticRoutesOnly -} - -// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionRequest) GetStaticRoutesOnlyOk() (bool, bool) { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret, false - } - return *o.StaticRoutesOnly, true -} - -// HasStaticRoutesOnly returns a boolean if a field has been set. -func (o *CreateVpnConnectionRequest) HasStaticRoutesOnly() bool { - if o != nil && o.StaticRoutesOnly != nil { - return true - } - - return false -} - -// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. -func (o *CreateVpnConnectionRequest) SetStaticRoutesOnly(v bool) { - o.StaticRoutesOnly = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *CreateVpnConnectionRequest) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *CreateVpnConnectionRequest) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -type NullableCreateVpnConnectionRequest struct { - Value CreateVpnConnectionRequest - ExplicitNull bool -} - -func (v NullableCreateVpnConnectionRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVpnConnectionRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_response.go deleted file mode 100644 index c11304ad9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVpnConnectionResponse struct for CreateVpnConnectionResponse -type CreateVpnConnectionResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - VpnConnection *VpnConnection `json:"VpnConnection,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateVpnConnectionResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateVpnConnectionResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateVpnConnectionResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVpnConnection returns the VpnConnection field value if set, zero value otherwise. -func (o *CreateVpnConnectionResponse) GetVpnConnection() VpnConnection { - if o == nil || o.VpnConnection == nil { - var ret VpnConnection - return ret - } - return *o.VpnConnection -} - -// GetVpnConnectionOk returns a tuple with the VpnConnection field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionResponse) GetVpnConnectionOk() (VpnConnection, bool) { - if o == nil || o.VpnConnection == nil { - var ret VpnConnection - return ret, false - } - return *o.VpnConnection, true -} - -// HasVpnConnection returns a boolean if a field has been set. -func (o *CreateVpnConnectionResponse) HasVpnConnection() bool { - if o != nil && o.VpnConnection != nil { - return true - } - - return false -} - -// SetVpnConnection gets a reference to the given VpnConnection and assigns it to the VpnConnection field. -func (o *CreateVpnConnectionResponse) SetVpnConnection(v VpnConnection) { - o.VpnConnection = &v -} - -type NullableCreateVpnConnectionResponse struct { - Value CreateVpnConnectionResponse - ExplicitNull bool -} - -func (v NullableCreateVpnConnectionResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVpnConnectionResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_request.go deleted file mode 100644 index eb1a1484d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVpnConnectionRouteRequest struct for CreateVpnConnectionRouteRequest -type CreateVpnConnectionRouteRequest struct { - // The network prefix of the route, in CIDR notation (for example, 10.12.0.0/16). - DestinationIpRange string `json:"DestinationIpRange"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the target VPN connection of the static route. - VpnConnectionId string `json:"VpnConnectionId"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value -func (o *CreateVpnConnectionRouteRequest) GetDestinationIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.DestinationIpRange -} - -// SetDestinationIpRange sets field value -func (o *CreateVpnConnectionRouteRequest) SetDestinationIpRange(v string) { - o.DestinationIpRange = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *CreateVpnConnectionRouteRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionRouteRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *CreateVpnConnectionRouteRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *CreateVpnConnectionRouteRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVpnConnectionId returns the VpnConnectionId field value -func (o *CreateVpnConnectionRouteRequest) GetVpnConnectionId() string { - if o == nil { - var ret string - return ret - } - - return o.VpnConnectionId -} - -// SetVpnConnectionId sets field value -func (o *CreateVpnConnectionRouteRequest) SetVpnConnectionId(v string) { - o.VpnConnectionId = v -} - -type NullableCreateVpnConnectionRouteRequest struct { - Value CreateVpnConnectionRouteRequest - ExplicitNull bool -} - -func (v NullableCreateVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVpnConnectionRouteRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_response.go deleted file mode 100644 index 27f188bd5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_create_vpn_connection_route_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// CreateVpnConnectionRouteResponse struct for CreateVpnConnectionRouteResponse -type CreateVpnConnectionRouteResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *CreateVpnConnectionRouteResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *CreateVpnConnectionRouteResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *CreateVpnConnectionRouteResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *CreateVpnConnectionRouteResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableCreateVpnConnectionRouteResponse struct { - Value CreateVpnConnectionRouteResponse - ExplicitNull bool -} - -func (v NullableCreateVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableCreateVpnConnectionRouteResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_request.go deleted file mode 100644 index 6fe3358c5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteAccessKeyRequest struct for DeleteAccessKeyRequest -type DeleteAccessKeyRequest struct { - // The ID of the access key you want to delete. - AccessKeyId string `json:"AccessKeyId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetAccessKeyId returns the AccessKeyId field value -func (o *DeleteAccessKeyRequest) GetAccessKeyId() string { - if o == nil { - var ret string - return ret - } - - return o.AccessKeyId -} - -// SetAccessKeyId sets field value -func (o *DeleteAccessKeyRequest) SetAccessKeyId(v string) { - o.AccessKeyId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteAccessKeyRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteAccessKeyRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteAccessKeyRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteAccessKeyRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableDeleteAccessKeyRequest struct { - Value DeleteAccessKeyRequest - ExplicitNull bool -} - -func (v NullableDeleteAccessKeyRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteAccessKeyRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_response.go deleted file mode 100644 index e2be19ed9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_access_key_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteAccessKeyResponse struct for DeleteAccessKeyResponse -type DeleteAccessKeyResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteAccessKeyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteAccessKeyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteAccessKeyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteAccessKeyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteAccessKeyResponse struct { - Value DeleteAccessKeyResponse - ExplicitNull bool -} - -func (v NullableDeleteAccessKeyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteAccessKeyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_request.go deleted file mode 100644 index 5fff3ea8a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteClientGatewayRequest struct for DeleteClientGatewayRequest -type DeleteClientGatewayRequest struct { - // The ID of the client gateway you want to delete. - ClientGatewayId string `json:"ClientGatewayId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetClientGatewayId returns the ClientGatewayId field value -func (o *DeleteClientGatewayRequest) GetClientGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.ClientGatewayId -} - -// SetClientGatewayId sets field value -func (o *DeleteClientGatewayRequest) SetClientGatewayId(v string) { - o.ClientGatewayId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteClientGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteClientGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteClientGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteClientGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableDeleteClientGatewayRequest struct { - Value DeleteClientGatewayRequest - ExplicitNull bool -} - -func (v NullableDeleteClientGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteClientGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_response.go deleted file mode 100644 index fa56b1ab7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_client_gateway_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteClientGatewayResponse struct for DeleteClientGatewayResponse -type DeleteClientGatewayResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteClientGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteClientGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteClientGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteClientGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteClientGatewayResponse struct { - Value DeleteClientGatewayResponse - ExplicitNull bool -} - -func (v NullableDeleteClientGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteClientGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_request.go deleted file mode 100644 index e53f3d1e8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDhcpOptionsRequest struct for DeleteDhcpOptionsRequest -type DeleteDhcpOptionsRequest struct { - // The ID of the DHCP options set you want to delete. - DhcpOptionsSetId string `json:"DhcpOptionsSetId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value -func (o *DeleteDhcpOptionsRequest) GetDhcpOptionsSetId() string { - if o == nil { - var ret string - return ret - } - - return o.DhcpOptionsSetId -} - -// SetDhcpOptionsSetId sets field value -func (o *DeleteDhcpOptionsRequest) SetDhcpOptionsSetId(v string) { - o.DhcpOptionsSetId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteDhcpOptionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDhcpOptionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteDhcpOptionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteDhcpOptionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableDeleteDhcpOptionsRequest struct { - Value DeleteDhcpOptionsRequest - ExplicitNull bool -} - -func (v NullableDeleteDhcpOptionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDhcpOptionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_response.go deleted file mode 100644 index a66201d07..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_dhcp_options_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDhcpOptionsResponse struct for DeleteDhcpOptionsResponse -type DeleteDhcpOptionsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteDhcpOptionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDhcpOptionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteDhcpOptionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteDhcpOptionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteDhcpOptionsResponse struct { - Value DeleteDhcpOptionsResponse - ExplicitNull bool -} - -func (v NullableDeleteDhcpOptionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDhcpOptionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_request.go deleted file mode 100644 index 93dfed2f5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDirectLinkInterfaceRequest struct for DeleteDirectLinkInterfaceRequest -type DeleteDirectLinkInterfaceRequest struct { - // The ID of the DirectLink interface you want to delete. - DirectLinkInterfaceId string `json:"DirectLinkInterfaceId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDirectLinkInterfaceId returns the DirectLinkInterfaceId field value -func (o *DeleteDirectLinkInterfaceRequest) GetDirectLinkInterfaceId() string { - if o == nil { - var ret string - return ret - } - - return o.DirectLinkInterfaceId -} - -// SetDirectLinkInterfaceId sets field value -func (o *DeleteDirectLinkInterfaceRequest) SetDirectLinkInterfaceId(v string) { - o.DirectLinkInterfaceId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteDirectLinkInterfaceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDirectLinkInterfaceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteDirectLinkInterfaceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteDirectLinkInterfaceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableDeleteDirectLinkInterfaceRequest struct { - Value DeleteDirectLinkInterfaceRequest - ExplicitNull bool -} - -func (v NullableDeleteDirectLinkInterfaceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDirectLinkInterfaceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_response.go deleted file mode 100644 index d719e3adc..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_interface_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDirectLinkInterfaceResponse struct for DeleteDirectLinkInterfaceResponse -type DeleteDirectLinkInterfaceResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteDirectLinkInterfaceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDirectLinkInterfaceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteDirectLinkInterfaceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteDirectLinkInterfaceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteDirectLinkInterfaceResponse struct { - Value DeleteDirectLinkInterfaceResponse - ExplicitNull bool -} - -func (v NullableDeleteDirectLinkInterfaceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDirectLinkInterfaceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_request.go deleted file mode 100644 index d5f4021a5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDirectLinkRequest struct for DeleteDirectLinkRequest -type DeleteDirectLinkRequest struct { - // The ID of the DirectLink you want to delete. - DirectLinkId string `json:"DirectLinkId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDirectLinkId returns the DirectLinkId field value -func (o *DeleteDirectLinkRequest) GetDirectLinkId() string { - if o == nil { - var ret string - return ret - } - - return o.DirectLinkId -} - -// SetDirectLinkId sets field value -func (o *DeleteDirectLinkRequest) SetDirectLinkId(v string) { - o.DirectLinkId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteDirectLinkRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDirectLinkRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteDirectLinkRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteDirectLinkRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableDeleteDirectLinkRequest struct { - Value DeleteDirectLinkRequest - ExplicitNull bool -} - -func (v NullableDeleteDirectLinkRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDirectLinkRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_response.go deleted file mode 100644 index 9f99eb2c9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_direct_link_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteDirectLinkResponse struct for DeleteDirectLinkResponse -type DeleteDirectLinkResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteDirectLinkResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteDirectLinkResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteDirectLinkResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteDirectLinkResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteDirectLinkResponse struct { - Value DeleteDirectLinkResponse - ExplicitNull bool -} - -func (v NullableDeleteDirectLinkResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteDirectLinkResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_request.go deleted file mode 100644 index b27b196b8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteExportTaskRequest struct for DeleteExportTaskRequest -type DeleteExportTaskRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the export task to delete. - ExportTaskId string `json:"ExportTaskId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteExportTaskRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteExportTaskRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteExportTaskRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteExportTaskRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetExportTaskId returns the ExportTaskId field value -func (o *DeleteExportTaskRequest) GetExportTaskId() string { - if o == nil { - var ret string - return ret - } - - return o.ExportTaskId -} - -// SetExportTaskId sets field value -func (o *DeleteExportTaskRequest) SetExportTaskId(v string) { - o.ExportTaskId = v -} - -type NullableDeleteExportTaskRequest struct { - Value DeleteExportTaskRequest - ExplicitNull bool -} - -func (v NullableDeleteExportTaskRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteExportTaskRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_response.go deleted file mode 100644 index 5e17a087a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_export_task_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteExportTaskResponse struct for DeleteExportTaskResponse -type DeleteExportTaskResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteExportTaskResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteExportTaskResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteExportTaskResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteExportTaskResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteExportTaskResponse struct { - Value DeleteExportTaskResponse - ExplicitNull bool -} - -func (v NullableDeleteExportTaskResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteExportTaskResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_request.go deleted file mode 100644 index 083da246c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteFlexibleGpuRequest struct for DeleteFlexibleGpuRequest -type DeleteFlexibleGpuRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the fGPU you want to delete. - FlexibleGpuId string `json:"FlexibleGpuId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteFlexibleGpuRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteFlexibleGpuRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteFlexibleGpuRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteFlexibleGpuRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlexibleGpuId returns the FlexibleGpuId field value -func (o *DeleteFlexibleGpuRequest) GetFlexibleGpuId() string { - if o == nil { - var ret string - return ret - } - - return o.FlexibleGpuId -} - -// SetFlexibleGpuId sets field value -func (o *DeleteFlexibleGpuRequest) SetFlexibleGpuId(v string) { - o.FlexibleGpuId = v -} - -type NullableDeleteFlexibleGpuRequest struct { - Value DeleteFlexibleGpuRequest - ExplicitNull bool -} - -func (v NullableDeleteFlexibleGpuRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteFlexibleGpuRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_response.go deleted file mode 100644 index e52c9d93c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_flexible_gpu_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteFlexibleGpuResponse struct for DeleteFlexibleGpuResponse -type DeleteFlexibleGpuResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteFlexibleGpuResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteFlexibleGpuResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteFlexibleGpuResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteFlexibleGpuResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteFlexibleGpuResponse struct { - Value DeleteFlexibleGpuResponse - ExplicitNull bool -} - -func (v NullableDeleteFlexibleGpuResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteFlexibleGpuResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_request.go deleted file mode 100644 index a1a8c67f8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteImageRequest struct for DeleteImageRequest -type DeleteImageRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the OMI you want to delete. - ImageId string `json:"ImageId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteImageRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteImageRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteImageRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteImageRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetImageId returns the ImageId field value -func (o *DeleteImageRequest) GetImageId() string { - if o == nil { - var ret string - return ret - } - - return o.ImageId -} - -// SetImageId sets field value -func (o *DeleteImageRequest) SetImageId(v string) { - o.ImageId = v -} - -type NullableDeleteImageRequest struct { - Value DeleteImageRequest - ExplicitNull bool -} - -func (v NullableDeleteImageRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteImageRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_response.go deleted file mode 100644 index dcea8c022..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_image_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteImageResponse struct for DeleteImageResponse -type DeleteImageResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteImageResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteImageResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteImageResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteImageResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteImageResponse struct { - Value DeleteImageResponse - ExplicitNull bool -} - -func (v NullableDeleteImageResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteImageResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_request.go deleted file mode 100644 index dceeb1a60..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteInternetServiceRequest struct for DeleteInternetServiceRequest -type DeleteInternetServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Internet service you want to delete. - InternetServiceId string `json:"InternetServiceId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteInternetServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteInternetServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteInternetServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteInternetServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetInternetServiceId returns the InternetServiceId field value -func (o *DeleteInternetServiceRequest) GetInternetServiceId() string { - if o == nil { - var ret string - return ret - } - - return o.InternetServiceId -} - -// SetInternetServiceId sets field value -func (o *DeleteInternetServiceRequest) SetInternetServiceId(v string) { - o.InternetServiceId = v -} - -type NullableDeleteInternetServiceRequest struct { - Value DeleteInternetServiceRequest - ExplicitNull bool -} - -func (v NullableDeleteInternetServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteInternetServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_response.go deleted file mode 100644 index ffb5183bd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_internet_service_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteInternetServiceResponse struct for DeleteInternetServiceResponse -type DeleteInternetServiceResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteInternetServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteInternetServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteInternetServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteInternetServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteInternetServiceResponse struct { - Value DeleteInternetServiceResponse - ExplicitNull bool -} - -func (v NullableDeleteInternetServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteInternetServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_request.go deleted file mode 100644 index 76e8ca703..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteKeypairRequest struct for DeleteKeypairRequest -type DeleteKeypairRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the keypair you want to delete. - KeypairName string `json:"KeypairName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteKeypairRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteKeypairRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteKeypairRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteKeypairRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetKeypairName returns the KeypairName field value -func (o *DeleteKeypairRequest) GetKeypairName() string { - if o == nil { - var ret string - return ret - } - - return o.KeypairName -} - -// SetKeypairName sets field value -func (o *DeleteKeypairRequest) SetKeypairName(v string) { - o.KeypairName = v -} - -type NullableDeleteKeypairRequest struct { - Value DeleteKeypairRequest - ExplicitNull bool -} - -func (v NullableDeleteKeypairRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteKeypairRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_response.go deleted file mode 100644 index 205bd6c55..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_keypair_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteKeypairResponse struct for DeleteKeypairResponse -type DeleteKeypairResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteKeypairResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteKeypairResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteKeypairResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteKeypairResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteKeypairResponse struct { - Value DeleteKeypairResponse - ExplicitNull bool -} - -func (v NullableDeleteKeypairResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteKeypairResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_request.go deleted file mode 100644 index 06f8fa341..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteListenerRuleRequest struct for DeleteListenerRuleRequest -type DeleteListenerRuleRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the rule you want to delete. - ListenerRuleName string `json:"ListenerRuleName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteListenerRuleRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteListenerRuleRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteListenerRuleRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteListenerRuleRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetListenerRuleName returns the ListenerRuleName field value -func (o *DeleteListenerRuleRequest) GetListenerRuleName() string { - if o == nil { - var ret string - return ret - } - - return o.ListenerRuleName -} - -// SetListenerRuleName sets field value -func (o *DeleteListenerRuleRequest) SetListenerRuleName(v string) { - o.ListenerRuleName = v -} - -type NullableDeleteListenerRuleRequest struct { - Value DeleteListenerRuleRequest - ExplicitNull bool -} - -func (v NullableDeleteListenerRuleRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteListenerRuleRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_response.go deleted file mode 100644 index 08c43cdaf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_listener_rule_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteListenerRuleResponse struct for DeleteListenerRuleResponse -type DeleteListenerRuleResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteListenerRuleResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteListenerRuleResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteListenerRuleResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteListenerRuleResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteListenerRuleResponse struct { - Value DeleteListenerRuleResponse - ExplicitNull bool -} - -func (v NullableDeleteListenerRuleResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteListenerRuleResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_request.go deleted file mode 100644 index 40a989445..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerListenersRequest struct for DeleteLoadBalancerListenersRequest -type DeleteLoadBalancerListenersRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer for which you want to delete listeners. - LoadBalancerName string `json:"LoadBalancerName"` - // One or more port numbers of the listeners you want to delete. - LoadBalancerPorts []int64 `json:"LoadBalancerPorts"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteLoadBalancerListenersRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerListenersRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteLoadBalancerListenersRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteLoadBalancerListenersRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *DeleteLoadBalancerListenersRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetLoadBalancerPorts returns the LoadBalancerPorts field value -func (o *DeleteLoadBalancerListenersRequest) GetLoadBalancerPorts() []int64 { - if o == nil { - var ret []int64 - return ret - } - - return o.LoadBalancerPorts -} - -// SetLoadBalancerPorts sets field value -func (o *DeleteLoadBalancerListenersRequest) SetLoadBalancerPorts(v []int64) { - o.LoadBalancerPorts = v -} - -type NullableDeleteLoadBalancerListenersRequest struct { - Value DeleteLoadBalancerListenersRequest - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerListenersRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerListenersRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_response.go deleted file mode 100644 index 0ba328413..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_listeners_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerListenersResponse struct for DeleteLoadBalancerListenersResponse -type DeleteLoadBalancerListenersResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *DeleteLoadBalancerListenersResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerListenersResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *DeleteLoadBalancerListenersResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *DeleteLoadBalancerListenersResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteLoadBalancerListenersResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerListenersResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteLoadBalancerListenersResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteLoadBalancerListenersResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteLoadBalancerListenersResponse struct { - Value DeleteLoadBalancerListenersResponse - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerListenersResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerListenersResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_request.go deleted file mode 100644 index 5b9acdca6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerPolicyRequest struct for DeleteLoadBalancerPolicyRequest -type DeleteLoadBalancerPolicyRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer for which you want to delete a policy. - LoadBalancerName string `json:"LoadBalancerName"` - // The name of the policy you want to delete. - PolicyName string `json:"PolicyName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteLoadBalancerPolicyRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerPolicyRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteLoadBalancerPolicyRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteLoadBalancerPolicyRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *DeleteLoadBalancerPolicyRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *DeleteLoadBalancerPolicyRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetPolicyName returns the PolicyName field value -func (o *DeleteLoadBalancerPolicyRequest) GetPolicyName() string { - if o == nil { - var ret string - return ret - } - - return o.PolicyName -} - -// SetPolicyName sets field value -func (o *DeleteLoadBalancerPolicyRequest) SetPolicyName(v string) { - o.PolicyName = v -} - -type NullableDeleteLoadBalancerPolicyRequest struct { - Value DeleteLoadBalancerPolicyRequest - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerPolicyRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerPolicyRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_response.go deleted file mode 100644 index 4c2ac74a3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_policy_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerPolicyResponse struct for DeleteLoadBalancerPolicyResponse -type DeleteLoadBalancerPolicyResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *DeleteLoadBalancerPolicyResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerPolicyResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *DeleteLoadBalancerPolicyResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *DeleteLoadBalancerPolicyResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteLoadBalancerPolicyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerPolicyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteLoadBalancerPolicyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteLoadBalancerPolicyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteLoadBalancerPolicyResponse struct { - Value DeleteLoadBalancerPolicyResponse - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerPolicyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerPolicyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_request.go deleted file mode 100644 index c015f0f2a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerRequest struct for DeleteLoadBalancerRequest -type DeleteLoadBalancerRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer you want to delete. - LoadBalancerName string `json:"LoadBalancerName"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteLoadBalancerRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteLoadBalancerRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteLoadBalancerRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *DeleteLoadBalancerRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *DeleteLoadBalancerRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -type NullableDeleteLoadBalancerRequest struct { - Value DeleteLoadBalancerRequest - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_response.go deleted file mode 100644 index 8cf33cd4b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerResponse struct for DeleteLoadBalancerResponse -type DeleteLoadBalancerResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteLoadBalancerResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteLoadBalancerResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteLoadBalancerResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteLoadBalancerResponse struct { - Value DeleteLoadBalancerResponse - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_request.go deleted file mode 100644 index e0e1b3939..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerTagsRequest struct for DeleteLoadBalancerTagsRequest -type DeleteLoadBalancerTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more load balancer names. - LoadBalancerNames []string `json:"LoadBalancerNames"` - // One or more tags to delete from the load balancers. - Tags []ResourceLoadBalancerTag `json:"Tags"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteLoadBalancerTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteLoadBalancerTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteLoadBalancerTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerNames returns the LoadBalancerNames field value -func (o *DeleteLoadBalancerTagsRequest) GetLoadBalancerNames() []string { - if o == nil { - var ret []string - return ret - } - - return o.LoadBalancerNames -} - -// SetLoadBalancerNames sets field value -func (o *DeleteLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { - o.LoadBalancerNames = v -} - -// GetTags returns the Tags field value -func (o *DeleteLoadBalancerTagsRequest) GetTags() []ResourceLoadBalancerTag { - if o == nil { - var ret []ResourceLoadBalancerTag - return ret - } - - return o.Tags -} - -// SetTags sets field value -func (o *DeleteLoadBalancerTagsRequest) SetTags(v []ResourceLoadBalancerTag) { - o.Tags = v -} - -type NullableDeleteLoadBalancerTagsRequest struct { - Value DeleteLoadBalancerTagsRequest - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_response.go deleted file mode 100644 index baa028174..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_load_balancer_tags_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteLoadBalancerTagsResponse struct for DeleteLoadBalancerTagsResponse -type DeleteLoadBalancerTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteLoadBalancerTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteLoadBalancerTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteLoadBalancerTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteLoadBalancerTagsResponse struct { - Value DeleteLoadBalancerTagsResponse - ExplicitNull bool -} - -func (v NullableDeleteLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_request.go deleted file mode 100644 index 51551b5b4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNatServiceRequest struct for DeleteNatServiceRequest -type DeleteNatServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the NAT service you want to delete. - NatServiceId string `json:"NatServiceId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteNatServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNatServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteNatServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteNatServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNatServiceId returns the NatServiceId field value -func (o *DeleteNatServiceRequest) GetNatServiceId() string { - if o == nil { - var ret string - return ret - } - - return o.NatServiceId -} - -// SetNatServiceId sets field value -func (o *DeleteNatServiceRequest) SetNatServiceId(v string) { - o.NatServiceId = v -} - -type NullableDeleteNatServiceRequest struct { - Value DeleteNatServiceRequest - ExplicitNull bool -} - -func (v NullableDeleteNatServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNatServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_response.go deleted file mode 100644 index 16f666a27..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nat_service_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNatServiceResponse struct for DeleteNatServiceResponse -type DeleteNatServiceResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteNatServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNatServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteNatServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteNatServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteNatServiceResponse struct { - Value DeleteNatServiceResponse - ExplicitNull bool -} - -func (v NullableDeleteNatServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNatServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_request.go deleted file mode 100644 index 27361e849..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetAccessPointRequest struct for DeleteNetAccessPointRequest -type DeleteNetAccessPointRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net access point. - NetAccessPointId string `json:"NetAccessPointId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteNetAccessPointRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetAccessPointRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteNetAccessPointRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteNetAccessPointRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetAccessPointId returns the NetAccessPointId field value -func (o *DeleteNetAccessPointRequest) GetNetAccessPointId() string { - if o == nil { - var ret string - return ret - } - - return o.NetAccessPointId -} - -// SetNetAccessPointId sets field value -func (o *DeleteNetAccessPointRequest) SetNetAccessPointId(v string) { - o.NetAccessPointId = v -} - -type NullableDeleteNetAccessPointRequest struct { - Value DeleteNetAccessPointRequest - ExplicitNull bool -} - -func (v NullableDeleteNetAccessPointRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetAccessPointRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_response.go deleted file mode 100644 index f393701fc..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_access_point_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetAccessPointResponse struct for DeleteNetAccessPointResponse -type DeleteNetAccessPointResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteNetAccessPointResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetAccessPointResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteNetAccessPointResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteNetAccessPointResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteNetAccessPointResponse struct { - Value DeleteNetAccessPointResponse - ExplicitNull bool -} - -func (v NullableDeleteNetAccessPointResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetAccessPointResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_request.go deleted file mode 100644 index 113b012ae..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetPeeringRequest struct for DeleteNetPeeringRequest -type DeleteNetPeeringRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net peering connection you want to delete. - NetPeeringId string `json:"NetPeeringId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteNetPeeringRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetPeeringRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteNetPeeringRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteNetPeeringRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetPeeringId returns the NetPeeringId field value -func (o *DeleteNetPeeringRequest) GetNetPeeringId() string { - if o == nil { - var ret string - return ret - } - - return o.NetPeeringId -} - -// SetNetPeeringId sets field value -func (o *DeleteNetPeeringRequest) SetNetPeeringId(v string) { - o.NetPeeringId = v -} - -type NullableDeleteNetPeeringRequest struct { - Value DeleteNetPeeringRequest - ExplicitNull bool -} - -func (v NullableDeleteNetPeeringRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetPeeringRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_response.go deleted file mode 100644 index 1a4c59689..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_peering_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetPeeringResponse struct for DeleteNetPeeringResponse -type DeleteNetPeeringResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteNetPeeringResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetPeeringResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteNetPeeringResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteNetPeeringResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteNetPeeringResponse struct { - Value DeleteNetPeeringResponse - ExplicitNull bool -} - -func (v NullableDeleteNetPeeringResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetPeeringResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_request.go deleted file mode 100644 index db9bebf87..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetRequest struct for DeleteNetRequest -type DeleteNetRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net you want to delete. - NetId string `json:"NetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteNetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteNetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteNetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *DeleteNetRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *DeleteNetRequest) SetNetId(v string) { - o.NetId = v -} - -type NullableDeleteNetRequest struct { - Value DeleteNetRequest - ExplicitNull bool -} - -func (v NullableDeleteNetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_response.go deleted file mode 100644 index f27f49333..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_net_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNetResponse struct for DeleteNetResponse -type DeleteNetResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteNetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteNetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteNetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteNetResponse struct { - Value DeleteNetResponse - ExplicitNull bool -} - -func (v NullableDeleteNetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_request.go deleted file mode 100644 index f5917558f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNicRequest struct for DeleteNicRequest -type DeleteNicRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the NIC you want to delete. - NicId string `json:"NicId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteNicRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNicRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteNicRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteNicRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNicId returns the NicId field value -func (o *DeleteNicRequest) GetNicId() string { - if o == nil { - var ret string - return ret - } - - return o.NicId -} - -// SetNicId sets field value -func (o *DeleteNicRequest) SetNicId(v string) { - o.NicId = v -} - -type NullableDeleteNicRequest struct { - Value DeleteNicRequest - ExplicitNull bool -} - -func (v NullableDeleteNicRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNicRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_response.go deleted file mode 100644 index 7fca98eaa..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_nic_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteNicResponse struct for DeleteNicResponse -type DeleteNicResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteNicResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteNicResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteNicResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteNicResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteNicResponse struct { - Value DeleteNicResponse - ExplicitNull bool -} - -func (v NullableDeleteNicResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteNicResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_request.go deleted file mode 100644 index bc58261de..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_request.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeletePublicIpRequest struct for DeletePublicIpRequest -type DeletePublicIpRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The EIP. In the public Cloud, this parameter is required. - PublicIp *string `json:"PublicIp,omitempty"` - // The ID representing the association of the EIP with the VM or the NIC. In a Net, this parameter is required. - PublicIpId *string `json:"PublicIpId,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeletePublicIpRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeletePublicIpRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeletePublicIpRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeletePublicIpRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *DeletePublicIpRequest) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeletePublicIpRequest) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *DeletePublicIpRequest) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *DeletePublicIpRequest) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. -func (o *DeletePublicIpRequest) GetPublicIpId() string { - if o == nil || o.PublicIpId == nil { - var ret string - return ret - } - return *o.PublicIpId -} - -// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeletePublicIpRequest) GetPublicIpIdOk() (string, bool) { - if o == nil || o.PublicIpId == nil { - var ret string - return ret, false - } - return *o.PublicIpId, true -} - -// HasPublicIpId returns a boolean if a field has been set. -func (o *DeletePublicIpRequest) HasPublicIpId() bool { - if o != nil && o.PublicIpId != nil { - return true - } - - return false -} - -// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. -func (o *DeletePublicIpRequest) SetPublicIpId(v string) { - o.PublicIpId = &v -} - -type NullableDeletePublicIpRequest struct { - Value DeletePublicIpRequest - ExplicitNull bool -} - -func (v NullableDeletePublicIpRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeletePublicIpRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_response.go deleted file mode 100644 index be46aeab7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_public_ip_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeletePublicIpResponse struct for DeletePublicIpResponse -type DeletePublicIpResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeletePublicIpResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeletePublicIpResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeletePublicIpResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeletePublicIpResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeletePublicIpResponse struct { - Value DeletePublicIpResponse - ExplicitNull bool -} - -func (v NullableDeletePublicIpResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeletePublicIpResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_request.go deleted file mode 100644 index f4945b6ad..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteRouteRequest struct for DeleteRouteRequest -type DeleteRouteRequest struct { - // The exact IP range for the route. - DestinationIpRange string `json:"DestinationIpRange"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the route table from which you want to delete a route. - RouteTableId string `json:"RouteTableId"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value -func (o *DeleteRouteRequest) GetDestinationIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.DestinationIpRange -} - -// SetDestinationIpRange sets field value -func (o *DeleteRouteRequest) SetDestinationIpRange(v string) { - o.DestinationIpRange = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteRouteRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteRouteRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteRouteRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteRouteRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *DeleteRouteRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *DeleteRouteRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -type NullableDeleteRouteRequest struct { - Value DeleteRouteRequest - ExplicitNull bool -} - -func (v NullableDeleteRouteRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteRouteRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_response.go deleted file mode 100644 index ad30ff7ae..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteRouteResponse struct for DeleteRouteResponse -type DeleteRouteResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - RouteTable *RouteTable `json:"RouteTable,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteRouteResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteRouteResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteRouteResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteRouteResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTable returns the RouteTable field value if set, zero value otherwise. -func (o *DeleteRouteResponse) GetRouteTable() RouteTable { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret - } - return *o.RouteTable -} - -// GetRouteTableOk returns a tuple with the RouteTable field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteRouteResponse) GetRouteTableOk() (RouteTable, bool) { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret, false - } - return *o.RouteTable, true -} - -// HasRouteTable returns a boolean if a field has been set. -func (o *DeleteRouteResponse) HasRouteTable() bool { - if o != nil && o.RouteTable != nil { - return true - } - - return false -} - -// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. -func (o *DeleteRouteResponse) SetRouteTable(v RouteTable) { - o.RouteTable = &v -} - -type NullableDeleteRouteResponse struct { - Value DeleteRouteResponse - ExplicitNull bool -} - -func (v NullableDeleteRouteResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteRouteResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_request.go deleted file mode 100644 index 1fdd102d5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteRouteTableRequest struct for DeleteRouteTableRequest -type DeleteRouteTableRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the route table you want to delete. - RouteTableId string `json:"RouteTableId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteRouteTableRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteRouteTableRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteRouteTableRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteRouteTableRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *DeleteRouteTableRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *DeleteRouteTableRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -type NullableDeleteRouteTableRequest struct { - Value DeleteRouteTableRequest - ExplicitNull bool -} - -func (v NullableDeleteRouteTableRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteRouteTableRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_response.go deleted file mode 100644 index a809fcd3d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_route_table_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteRouteTableResponse struct for DeleteRouteTableResponse -type DeleteRouteTableResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteRouteTableResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteRouteTableResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteRouteTableResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteRouteTableResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteRouteTableResponse struct { - Value DeleteRouteTableResponse - ExplicitNull bool -} - -func (v NullableDeleteRouteTableResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteRouteTableResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_request.go deleted file mode 100644 index 28c88b6c6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_request.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSecurityGroupRequest struct for DeleteSecurityGroupRequest -type DeleteSecurityGroupRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the security group you want to delete. - SecurityGroupId *string `json:"SecurityGroupId,omitempty"` - // (Public Cloud only) The name of the security group. - SecurityGroupName *string `json:"SecurityGroupName,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteSecurityGroupRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRequest) GetSecurityGroupId() string { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret - } - return *o.SecurityGroupId -} - -// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRequest) GetSecurityGroupIdOk() (string, bool) { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret, false - } - return *o.SecurityGroupId, true -} - -// HasSecurityGroupId returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRequest) HasSecurityGroupId() bool { - if o != nil && o.SecurityGroupId != nil { - return true - } - - return false -} - -// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. -func (o *DeleteSecurityGroupRequest) SetSecurityGroupId(v string) { - o.SecurityGroupId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRequest) GetSecurityGroupName() string { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret - } - return *o.SecurityGroupName -} - -// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRequest) GetSecurityGroupNameOk() (string, bool) { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret, false - } - return *o.SecurityGroupName, true -} - -// HasSecurityGroupName returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRequest) HasSecurityGroupName() bool { - if o != nil && o.SecurityGroupName != nil { - return true - } - - return false -} - -// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. -func (o *DeleteSecurityGroupRequest) SetSecurityGroupName(v string) { - o.SecurityGroupName = &v -} - -type NullableDeleteSecurityGroupRequest struct { - Value DeleteSecurityGroupRequest - ExplicitNull bool -} - -func (v NullableDeleteSecurityGroupRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSecurityGroupRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_response.go deleted file mode 100644 index 2b79e041c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSecurityGroupResponse struct for DeleteSecurityGroupResponse -type DeleteSecurityGroupResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteSecurityGroupResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteSecurityGroupResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteSecurityGroupResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteSecurityGroupResponse struct { - Value DeleteSecurityGroupResponse - ExplicitNull bool -} - -func (v NullableDeleteSecurityGroupResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSecurityGroupResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_request.go deleted file mode 100644 index 4e03d0514..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_request.go +++ /dev/null @@ -1,357 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSecurityGroupRuleRequest struct for DeleteSecurityGroupRuleRequest -type DeleteSecurityGroupRuleRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. - Flow string `json:"Flow"` - // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - FromPortRange *int64 `json:"FromPortRange,omitempty"` - // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - IpProtocol *string `json:"IpProtocol,omitempty"` - // The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // One or more rules you want to delete from the security group. - Rules *[]SecurityGroupRule `json:"Rules,omitempty"` - // The account ID of the owner of the security group you want to delete a rule from. - SecurityGroupAccountIdToUnlink *string `json:"SecurityGroupAccountIdToUnlink,omitempty"` - // The ID of the security group you want to delete a rule from. - SecurityGroupId string `json:"SecurityGroupId"` - // The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. - SecurityGroupNameToUnlink *string `json:"SecurityGroupNameToUnlink,omitempty"` - // The end of the port range for the TCP and UDP protocols, or an ICMP type number. - ToPortRange *int64 `json:"ToPortRange,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteSecurityGroupRuleRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlow returns the Flow field value -func (o *DeleteSecurityGroupRuleRequest) GetFlow() string { - if o == nil { - var ret string - return ret - } - - return o.Flow -} - -// SetFlow sets field value -func (o *DeleteSecurityGroupRuleRequest) SetFlow(v string) { - o.Flow = v -} - -// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetFromPortRange() int64 { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret - } - return *o.FromPortRange -} - -// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetFromPortRangeOk() (int64, bool) { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret, false - } - return *o.FromPortRange, true -} - -// HasFromPortRange returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasFromPortRange() bool { - if o != nil && o.FromPortRange != nil { - return true - } - - return false -} - -// SetFromPortRange gets a reference to the given int64 and assigns it to the FromPortRange field. -func (o *DeleteSecurityGroupRuleRequest) SetFromPortRange(v int64) { - o.FromPortRange = &v -} - -// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetIpProtocol() string { - if o == nil || o.IpProtocol == nil { - var ret string - return ret - } - return *o.IpProtocol -} - -// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetIpProtocolOk() (string, bool) { - if o == nil || o.IpProtocol == nil { - var ret string - return ret, false - } - return *o.IpProtocol, true -} - -// HasIpProtocol returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasIpProtocol() bool { - if o != nil && o.IpProtocol != nil { - return true - } - - return false -} - -// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. -func (o *DeleteSecurityGroupRuleRequest) SetIpProtocol(v string) { - o.IpProtocol = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *DeleteSecurityGroupRuleRequest) SetIpRange(v string) { - o.IpRange = &v -} - -// GetRules returns the Rules field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetRules() []SecurityGroupRule { - if o == nil || o.Rules == nil { - var ret []SecurityGroupRule - return ret - } - return *o.Rules -} - -// GetRulesOk returns a tuple with the Rules field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetRulesOk() ([]SecurityGroupRule, bool) { - if o == nil || o.Rules == nil { - var ret []SecurityGroupRule - return ret, false - } - return *o.Rules, true -} - -// HasRules returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasRules() bool { - if o != nil && o.Rules != nil { - return true - } - - return false -} - -// SetRules gets a reference to the given []SecurityGroupRule and assigns it to the Rules field. -func (o *DeleteSecurityGroupRuleRequest) SetRules(v []SecurityGroupRule) { - o.Rules = &v -} - -// GetSecurityGroupAccountIdToUnlink returns the SecurityGroupAccountIdToUnlink field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupAccountIdToUnlink() string { - if o == nil || o.SecurityGroupAccountIdToUnlink == nil { - var ret string - return ret - } - return *o.SecurityGroupAccountIdToUnlink -} - -// GetSecurityGroupAccountIdToUnlinkOk returns a tuple with the SecurityGroupAccountIdToUnlink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupAccountIdToUnlinkOk() (string, bool) { - if o == nil || o.SecurityGroupAccountIdToUnlink == nil { - var ret string - return ret, false - } - return *o.SecurityGroupAccountIdToUnlink, true -} - -// HasSecurityGroupAccountIdToUnlink returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasSecurityGroupAccountIdToUnlink() bool { - if o != nil && o.SecurityGroupAccountIdToUnlink != nil { - return true - } - - return false -} - -// SetSecurityGroupAccountIdToUnlink gets a reference to the given string and assigns it to the SecurityGroupAccountIdToUnlink field. -func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupAccountIdToUnlink(v string) { - o.SecurityGroupAccountIdToUnlink = &v -} - -// GetSecurityGroupId returns the SecurityGroupId field value -func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupId() string { - if o == nil { - var ret string - return ret - } - - return o.SecurityGroupId -} - -// SetSecurityGroupId sets field value -func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupId(v string) { - o.SecurityGroupId = v -} - -// GetSecurityGroupNameToUnlink returns the SecurityGroupNameToUnlink field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupNameToUnlink() string { - if o == nil || o.SecurityGroupNameToUnlink == nil { - var ret string - return ret - } - return *o.SecurityGroupNameToUnlink -} - -// GetSecurityGroupNameToUnlinkOk returns a tuple with the SecurityGroupNameToUnlink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetSecurityGroupNameToUnlinkOk() (string, bool) { - if o == nil || o.SecurityGroupNameToUnlink == nil { - var ret string - return ret, false - } - return *o.SecurityGroupNameToUnlink, true -} - -// HasSecurityGroupNameToUnlink returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasSecurityGroupNameToUnlink() bool { - if o != nil && o.SecurityGroupNameToUnlink != nil { - return true - } - - return false -} - -// SetSecurityGroupNameToUnlink gets a reference to the given string and assigns it to the SecurityGroupNameToUnlink field. -func (o *DeleteSecurityGroupRuleRequest) SetSecurityGroupNameToUnlink(v string) { - o.SecurityGroupNameToUnlink = &v -} - -// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleRequest) GetToPortRange() int64 { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret - } - return *o.ToPortRange -} - -// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleRequest) GetToPortRangeOk() (int64, bool) { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret, false - } - return *o.ToPortRange, true -} - -// HasToPortRange returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleRequest) HasToPortRange() bool { - if o != nil && o.ToPortRange != nil { - return true - } - - return false -} - -// SetToPortRange gets a reference to the given int64 and assigns it to the ToPortRange field. -func (o *DeleteSecurityGroupRuleRequest) SetToPortRange(v int64) { - o.ToPortRange = &v -} - -type NullableDeleteSecurityGroupRuleRequest struct { - Value DeleteSecurityGroupRuleRequest - ExplicitNull bool -} - -func (v NullableDeleteSecurityGroupRuleRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSecurityGroupRuleRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_response.go deleted file mode 100644 index 575e6a8a4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_security_group_rule_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSecurityGroupRuleResponse struct for DeleteSecurityGroupRuleResponse -type DeleteSecurityGroupRuleResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - SecurityGroup *SecurityGroup `json:"SecurityGroup,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteSecurityGroupRuleResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSecurityGroup returns the SecurityGroup field value if set, zero value otherwise. -func (o *DeleteSecurityGroupRuleResponse) GetSecurityGroup() SecurityGroup { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret - } - return *o.SecurityGroup -} - -// GetSecurityGroupOk returns a tuple with the SecurityGroup field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSecurityGroupRuleResponse) GetSecurityGroupOk() (SecurityGroup, bool) { - if o == nil || o.SecurityGroup == nil { - var ret SecurityGroup - return ret, false - } - return *o.SecurityGroup, true -} - -// HasSecurityGroup returns a boolean if a field has been set. -func (o *DeleteSecurityGroupRuleResponse) HasSecurityGroup() bool { - if o != nil && o.SecurityGroup != nil { - return true - } - - return false -} - -// SetSecurityGroup gets a reference to the given SecurityGroup and assigns it to the SecurityGroup field. -func (o *DeleteSecurityGroupRuleResponse) SetSecurityGroup(v SecurityGroup) { - o.SecurityGroup = &v -} - -type NullableDeleteSecurityGroupRuleResponse struct { - Value DeleteSecurityGroupRuleResponse - ExplicitNull bool -} - -func (v NullableDeleteSecurityGroupRuleResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSecurityGroupRuleResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_request.go deleted file mode 100644 index 0f72601fb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteServerCertificateRequest struct for DeleteServerCertificateRequest -type DeleteServerCertificateRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the server certificate you want to delete. - Name string `json:"Name"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteServerCertificateRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteServerCertificateRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteServerCertificateRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteServerCertificateRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetName returns the Name field value -func (o *DeleteServerCertificateRequest) GetName() string { - if o == nil { - var ret string - return ret - } - - return o.Name -} - -// SetName sets field value -func (o *DeleteServerCertificateRequest) SetName(v string) { - o.Name = v -} - -type NullableDeleteServerCertificateRequest struct { - Value DeleteServerCertificateRequest - ExplicitNull bool -} - -func (v NullableDeleteServerCertificateRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteServerCertificateRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_response.go deleted file mode 100644 index 4d523494b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_server_certificate_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteServerCertificateResponse struct for DeleteServerCertificateResponse -type DeleteServerCertificateResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteServerCertificateResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteServerCertificateResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteServerCertificateResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteServerCertificateResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteServerCertificateResponse struct { - Value DeleteServerCertificateResponse - ExplicitNull bool -} - -func (v NullableDeleteServerCertificateResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteServerCertificateResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_request.go deleted file mode 100644 index 37e9e05f9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSnapshotRequest struct for DeleteSnapshotRequest -type DeleteSnapshotRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the snapshot you want to delete. - SnapshotId string `json:"SnapshotId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteSnapshotRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSnapshotRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteSnapshotRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteSnapshotRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetSnapshotId returns the SnapshotId field value -func (o *DeleteSnapshotRequest) GetSnapshotId() string { - if o == nil { - var ret string - return ret - } - - return o.SnapshotId -} - -// SetSnapshotId sets field value -func (o *DeleteSnapshotRequest) SetSnapshotId(v string) { - o.SnapshotId = v -} - -type NullableDeleteSnapshotRequest struct { - Value DeleteSnapshotRequest - ExplicitNull bool -} - -func (v NullableDeleteSnapshotRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSnapshotRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_response.go deleted file mode 100644 index d752e9acf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_snapshot_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSnapshotResponse struct for DeleteSnapshotResponse -type DeleteSnapshotResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteSnapshotResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSnapshotResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteSnapshotResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteSnapshotResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteSnapshotResponse struct { - Value DeleteSnapshotResponse - ExplicitNull bool -} - -func (v NullableDeleteSnapshotResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSnapshotResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_request.go deleted file mode 100644 index ef2bbff5f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSubnetRequest struct for DeleteSubnetRequest -type DeleteSubnetRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Subnet you want to delete. - SubnetId string `json:"SubnetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteSubnetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSubnetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteSubnetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteSubnetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetSubnetId returns the SubnetId field value -func (o *DeleteSubnetRequest) GetSubnetId() string { - if o == nil { - var ret string - return ret - } - - return o.SubnetId -} - -// SetSubnetId sets field value -func (o *DeleteSubnetRequest) SetSubnetId(v string) { - o.SubnetId = v -} - -type NullableDeleteSubnetRequest struct { - Value DeleteSubnetRequest - ExplicitNull bool -} - -func (v NullableDeleteSubnetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSubnetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_response.go deleted file mode 100644 index ac479d035..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_subnet_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteSubnetResponse struct for DeleteSubnetResponse -type DeleteSubnetResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteSubnetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteSubnetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteSubnetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteSubnetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteSubnetResponse struct { - Value DeleteSubnetResponse - ExplicitNull bool -} - -func (v NullableDeleteSubnetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteSubnetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_request.go deleted file mode 100644 index c0b748392..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteTagsRequest struct for DeleteTagsRequest -type DeleteTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more resource IDs. - ResourceIds []string `json:"ResourceIds"` - // One or more tags to delete (if you set a tag value, only the tags matching exactly this value are deleted). - Tags []ResourceTag `json:"Tags"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetResourceIds returns the ResourceIds field value -func (o *DeleteTagsRequest) GetResourceIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.ResourceIds -} - -// SetResourceIds sets field value -func (o *DeleteTagsRequest) SetResourceIds(v []string) { - o.ResourceIds = v -} - -// GetTags returns the Tags field value -func (o *DeleteTagsRequest) GetTags() []ResourceTag { - if o == nil { - var ret []ResourceTag - return ret - } - - return o.Tags -} - -// SetTags sets field value -func (o *DeleteTagsRequest) SetTags(v []ResourceTag) { - o.Tags = v -} - -type NullableDeleteTagsRequest struct { - Value DeleteTagsRequest - ExplicitNull bool -} - -func (v NullableDeleteTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_response.go deleted file mode 100644 index 27d4f194b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_tags_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteTagsResponse struct for DeleteTagsResponse -type DeleteTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteTagsResponse struct { - Value DeleteTagsResponse - ExplicitNull bool -} - -func (v NullableDeleteTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_request.go deleted file mode 100644 index 2ebf1de2f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVirtualGatewayRequest struct for DeleteVirtualGatewayRequest -type DeleteVirtualGatewayRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the virtual gateway you want to delete. - VirtualGatewayId string `json:"VirtualGatewayId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteVirtualGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVirtualGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteVirtualGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteVirtualGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *DeleteVirtualGatewayRequest) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *DeleteVirtualGatewayRequest) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -type NullableDeleteVirtualGatewayRequest struct { - Value DeleteVirtualGatewayRequest - ExplicitNull bool -} - -func (v NullableDeleteVirtualGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVirtualGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_response.go deleted file mode 100644 index 543e6f558..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_virtual_gateway_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVirtualGatewayResponse struct for DeleteVirtualGatewayResponse -type DeleteVirtualGatewayResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteVirtualGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVirtualGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteVirtualGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteVirtualGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteVirtualGatewayResponse struct { - Value DeleteVirtualGatewayResponse - ExplicitNull bool -} - -func (v NullableDeleteVirtualGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVirtualGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_request.go deleted file mode 100644 index a991d2be8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVmsRequest struct for DeleteVmsRequest -type DeleteVmsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more IDs of VMs. - VmIds []string `json:"VmIds"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmIds returns the VmIds field value -func (o *DeleteVmsRequest) GetVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.VmIds -} - -// SetVmIds sets field value -func (o *DeleteVmsRequest) SetVmIds(v []string) { - o.VmIds = v -} - -type NullableDeleteVmsRequest struct { - Value DeleteVmsRequest - ExplicitNull bool -} - -func (v NullableDeleteVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_response.go deleted file mode 100644 index 3efb2f662..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vms_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVmsResponse struct for DeleteVmsResponse -type DeleteVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more terminated VMs. - Vms *[]VmState `json:"Vms,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVms returns the Vms field value if set, zero value otherwise. -func (o *DeleteVmsResponse) GetVms() []VmState { - if o == nil || o.Vms == nil { - var ret []VmState - return ret - } - return *o.Vms -} - -// GetVmsOk returns a tuple with the Vms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVmsResponse) GetVmsOk() ([]VmState, bool) { - if o == nil || o.Vms == nil { - var ret []VmState - return ret, false - } - return *o.Vms, true -} - -// HasVms returns a boolean if a field has been set. -func (o *DeleteVmsResponse) HasVms() bool { - if o != nil && o.Vms != nil { - return true - } - - return false -} - -// SetVms gets a reference to the given []VmState and assigns it to the Vms field. -func (o *DeleteVmsResponse) SetVms(v []VmState) { - o.Vms = &v -} - -type NullableDeleteVmsResponse struct { - Value DeleteVmsResponse - ExplicitNull bool -} - -func (v NullableDeleteVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_request.go deleted file mode 100644 index f78824c9c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVolumeRequest struct for DeleteVolumeRequest -type DeleteVolumeRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the volume you want to delete. - VolumeId string `json:"VolumeId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteVolumeRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVolumeRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteVolumeRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteVolumeRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVolumeId returns the VolumeId field value -func (o *DeleteVolumeRequest) GetVolumeId() string { - if o == nil { - var ret string - return ret - } - - return o.VolumeId -} - -// SetVolumeId sets field value -func (o *DeleteVolumeRequest) SetVolumeId(v string) { - o.VolumeId = v -} - -type NullableDeleteVolumeRequest struct { - Value DeleteVolumeRequest - ExplicitNull bool -} - -func (v NullableDeleteVolumeRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVolumeRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_response.go deleted file mode 100644 index 1d157dcb0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_volume_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVolumeResponse struct for DeleteVolumeResponse -type DeleteVolumeResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteVolumeResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVolumeResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteVolumeResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteVolumeResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteVolumeResponse struct { - Value DeleteVolumeResponse - ExplicitNull bool -} - -func (v NullableDeleteVolumeResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVolumeResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_request.go deleted file mode 100644 index 1ba112e65..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVpnConnectionRequest struct for DeleteVpnConnectionRequest -type DeleteVpnConnectionRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the VPN connection you want to delete. - VpnConnectionId string `json:"VpnConnectionId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteVpnConnectionRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVpnConnectionRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteVpnConnectionRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteVpnConnectionRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVpnConnectionId returns the VpnConnectionId field value -func (o *DeleteVpnConnectionRequest) GetVpnConnectionId() string { - if o == nil { - var ret string - return ret - } - - return o.VpnConnectionId -} - -// SetVpnConnectionId sets field value -func (o *DeleteVpnConnectionRequest) SetVpnConnectionId(v string) { - o.VpnConnectionId = v -} - -type NullableDeleteVpnConnectionRequest struct { - Value DeleteVpnConnectionRequest - ExplicitNull bool -} - -func (v NullableDeleteVpnConnectionRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVpnConnectionRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_response.go deleted file mode 100644 index ffe29e6ff..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVpnConnectionResponse struct for DeleteVpnConnectionResponse -type DeleteVpnConnectionResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteVpnConnectionResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVpnConnectionResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteVpnConnectionResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteVpnConnectionResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteVpnConnectionResponse struct { - Value DeleteVpnConnectionResponse - ExplicitNull bool -} - -func (v NullableDeleteVpnConnectionResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVpnConnectionResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_request.go deleted file mode 100644 index 473bf9754..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVpnConnectionRouteRequest struct for DeleteVpnConnectionRouteRequest -type DeleteVpnConnectionRouteRequest struct { - // The network prefix of the route to delete, in CIDR notation (for example, 10.12.0.0/16). - DestinationIpRange string `json:"DestinationIpRange"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the target VPN connection of the static route to delete. - VpnConnectionId string `json:"VpnConnectionId"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value -func (o *DeleteVpnConnectionRouteRequest) GetDestinationIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.DestinationIpRange -} - -// SetDestinationIpRange sets field value -func (o *DeleteVpnConnectionRouteRequest) SetDestinationIpRange(v string) { - o.DestinationIpRange = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeleteVpnConnectionRouteRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVpnConnectionRouteRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeleteVpnConnectionRouteRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeleteVpnConnectionRouteRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVpnConnectionId returns the VpnConnectionId field value -func (o *DeleteVpnConnectionRouteRequest) GetVpnConnectionId() string { - if o == nil { - var ret string - return ret - } - - return o.VpnConnectionId -} - -// SetVpnConnectionId sets field value -func (o *DeleteVpnConnectionRouteRequest) SetVpnConnectionId(v string) { - o.VpnConnectionId = v -} - -type NullableDeleteVpnConnectionRouteRequest struct { - Value DeleteVpnConnectionRouteRequest - ExplicitNull bool -} - -func (v NullableDeleteVpnConnectionRouteRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVpnConnectionRouteRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_response.go deleted file mode 100644 index fc7733f9f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_delete_vpn_connection_route_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeleteVpnConnectionRouteResponse struct for DeleteVpnConnectionRouteResponse -type DeleteVpnConnectionRouteResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeleteVpnConnectionRouteResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeleteVpnConnectionRouteResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeleteVpnConnectionRouteResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeleteVpnConnectionRouteResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeleteVpnConnectionRouteResponse struct { - Value DeleteVpnConnectionRouteResponse - ExplicitNull bool -} - -func (v NullableDeleteVpnConnectionRouteResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeleteVpnConnectionRouteResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_request.go deleted file mode 100644 index 13b69e0e6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeregisterVmsInLoadBalancerRequest struct for DeregisterVmsInLoadBalancerRequest -type DeregisterVmsInLoadBalancerRequest struct { - // One or more IDs of back-end VMs. - BackendVmIds []string `json:"BackendVmIds"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer. - LoadBalancerName string `json:"LoadBalancerName"` -} - -// GetBackendVmIds returns the BackendVmIds field value -func (o *DeregisterVmsInLoadBalancerRequest) GetBackendVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.BackendVmIds -} - -// SetBackendVmIds sets field value -func (o *DeregisterVmsInLoadBalancerRequest) SetBackendVmIds(v []string) { - o.BackendVmIds = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *DeregisterVmsInLoadBalancerRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeregisterVmsInLoadBalancerRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *DeregisterVmsInLoadBalancerRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *DeregisterVmsInLoadBalancerRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *DeregisterVmsInLoadBalancerRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *DeregisterVmsInLoadBalancerRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -type NullableDeregisterVmsInLoadBalancerRequest struct { - Value DeregisterVmsInLoadBalancerRequest - ExplicitNull bool -} - -func (v NullableDeregisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeregisterVmsInLoadBalancerRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_response.go deleted file mode 100644 index 08afed2b4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_deregister_vms_in_load_balancer_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DeregisterVmsInLoadBalancerResponse struct for DeregisterVmsInLoadBalancerResponse -type DeregisterVmsInLoadBalancerResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *DeregisterVmsInLoadBalancerResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DeregisterVmsInLoadBalancerResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *DeregisterVmsInLoadBalancerResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *DeregisterVmsInLoadBalancerResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableDeregisterVmsInLoadBalancerResponse struct { - Value DeregisterVmsInLoadBalancerResponse - ExplicitNull bool -} - -func (v NullableDeregisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDeregisterVmsInLoadBalancerResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_dhcp_options_set.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_dhcp_options_set.go deleted file mode 100644 index 08d3a2672..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_dhcp_options_set.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DhcpOptionsSet Information about the DHCP options set. -type DhcpOptionsSet struct { - // If `true`, the DHCP options set is a default one. If `false`, it is not. - Default *bool `json:"Default,omitempty"` - // The name of the DHCP options set. - DhcpOptionsName *string `json:"DhcpOptionsName,omitempty"` - // The ID of the DHCP options set. - DhcpOptionsSetId *string `json:"DhcpOptionsSetId,omitempty"` - // The domain name. - DomainName *string `json:"DomainName,omitempty"` - // One or more IP addresses for the domain name servers. - DomainNameServers *[]string `json:"DomainNameServers,omitempty"` - // One or more IP addresses for the NTP servers. - NtpServers *[]string `json:"NtpServers,omitempty"` - // One or more tags associated with the DHCP options set. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetDefault returns the Default field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetDefault() bool { - if o == nil || o.Default == nil { - var ret bool - return ret - } - return *o.Default -} - -// GetDefaultOk returns a tuple with the Default field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetDefaultOk() (bool, bool) { - if o == nil || o.Default == nil { - var ret bool - return ret, false - } - return *o.Default, true -} - -// HasDefault returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasDefault() bool { - if o != nil && o.Default != nil { - return true - } - - return false -} - -// SetDefault gets a reference to the given bool and assigns it to the Default field. -func (o *DhcpOptionsSet) SetDefault(v bool) { - o.Default = &v -} - -// GetDhcpOptionsName returns the DhcpOptionsName field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetDhcpOptionsName() string { - if o == nil || o.DhcpOptionsName == nil { - var ret string - return ret - } - return *o.DhcpOptionsName -} - -// GetDhcpOptionsNameOk returns a tuple with the DhcpOptionsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetDhcpOptionsNameOk() (string, bool) { - if o == nil || o.DhcpOptionsName == nil { - var ret string - return ret, false - } - return *o.DhcpOptionsName, true -} - -// HasDhcpOptionsName returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasDhcpOptionsName() bool { - if o != nil && o.DhcpOptionsName != nil { - return true - } - - return false -} - -// SetDhcpOptionsName gets a reference to the given string and assigns it to the DhcpOptionsName field. -func (o *DhcpOptionsSet) SetDhcpOptionsName(v string) { - o.DhcpOptionsName = &v -} - -// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetDhcpOptionsSetId() string { - if o == nil || o.DhcpOptionsSetId == nil { - var ret string - return ret - } - return *o.DhcpOptionsSetId -} - -// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetDhcpOptionsSetIdOk() (string, bool) { - if o == nil || o.DhcpOptionsSetId == nil { - var ret string - return ret, false - } - return *o.DhcpOptionsSetId, true -} - -// HasDhcpOptionsSetId returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasDhcpOptionsSetId() bool { - if o != nil && o.DhcpOptionsSetId != nil { - return true - } - - return false -} - -// SetDhcpOptionsSetId gets a reference to the given string and assigns it to the DhcpOptionsSetId field. -func (o *DhcpOptionsSet) SetDhcpOptionsSetId(v string) { - o.DhcpOptionsSetId = &v -} - -// GetDomainName returns the DomainName field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetDomainName() string { - if o == nil || o.DomainName == nil { - var ret string - return ret - } - return *o.DomainName -} - -// GetDomainNameOk returns a tuple with the DomainName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetDomainNameOk() (string, bool) { - if o == nil || o.DomainName == nil { - var ret string - return ret, false - } - return *o.DomainName, true -} - -// HasDomainName returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasDomainName() bool { - if o != nil && o.DomainName != nil { - return true - } - - return false -} - -// SetDomainName gets a reference to the given string and assigns it to the DomainName field. -func (o *DhcpOptionsSet) SetDomainName(v string) { - o.DomainName = &v -} - -// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetDomainNameServers() []string { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret - } - return *o.DomainNameServers -} - -// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetDomainNameServersOk() ([]string, bool) { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret, false - } - return *o.DomainNameServers, true -} - -// HasDomainNameServers returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasDomainNameServers() bool { - if o != nil && o.DomainNameServers != nil { - return true - } - - return false -} - -// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. -func (o *DhcpOptionsSet) SetDomainNameServers(v []string) { - o.DomainNameServers = &v -} - -// GetNtpServers returns the NtpServers field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetNtpServers() []string { - if o == nil || o.NtpServers == nil { - var ret []string - return ret - } - return *o.NtpServers -} - -// GetNtpServersOk returns a tuple with the NtpServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetNtpServersOk() ([]string, bool) { - if o == nil || o.NtpServers == nil { - var ret []string - return ret, false - } - return *o.NtpServers, true -} - -// HasNtpServers returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasNtpServers() bool { - if o != nil && o.NtpServers != nil { - return true - } - - return false -} - -// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. -func (o *DhcpOptionsSet) SetNtpServers(v []string) { - o.NtpServers = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *DhcpOptionsSet) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DhcpOptionsSet) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *DhcpOptionsSet) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *DhcpOptionsSet) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableDhcpOptionsSet struct { - Value DhcpOptionsSet - ExplicitNull bool -} - -func (v NullableDhcpOptionsSet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDhcpOptionsSet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link.go deleted file mode 100644 index 905f9c7ad..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DirectLink Information about the DirectLink. -type DirectLink struct { - // The account ID of the owner of the DirectLink. - AccountId *string `json:"AccountId,omitempty"` - // The physical link bandwidth (either 1 Gbps or 10 Gbps). - Bandwidth *string `json:"Bandwidth,omitempty"` - // The ID of the DirectLink (for example, dxcon-xxxxxxxx). - DirectLinkId *string `json:"DirectLinkId,omitempty"` - // The name of the DirectLink. - DirectLinkName *string `json:"DirectLinkName,omitempty"` - // The datacenter where the DirectLink is located. - Location *string `json:"Location,omitempty"` - // The Region in which the DirectLink has been created. - RegionName *string `json:"RegionName,omitempty"` - // The state of the DirectLink.
* `requested`: The DirectLink is requested but the request has not been validated yet.
* `pending`: The DirectLink request has been validated. It remains in the `pending` state until you establish the physical link.
* `available`: The physical link is established and the connection is ready to use.
* `deleting`: The deletion process is in progress.
* `deleted`: The DirectLink is deleted. - State *string `json:"State,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *DirectLink) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *DirectLink) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *DirectLink) SetAccountId(v string) { - o.AccountId = &v -} - -// GetBandwidth returns the Bandwidth field value if set, zero value otherwise. -func (o *DirectLink) GetBandwidth() string { - if o == nil || o.Bandwidth == nil { - var ret string - return ret - } - return *o.Bandwidth -} - -// GetBandwidthOk returns a tuple with the Bandwidth field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetBandwidthOk() (string, bool) { - if o == nil || o.Bandwidth == nil { - var ret string - return ret, false - } - return *o.Bandwidth, true -} - -// HasBandwidth returns a boolean if a field has been set. -func (o *DirectLink) HasBandwidth() bool { - if o != nil && o.Bandwidth != nil { - return true - } - - return false -} - -// SetBandwidth gets a reference to the given string and assigns it to the Bandwidth field. -func (o *DirectLink) SetBandwidth(v string) { - o.Bandwidth = &v -} - -// GetDirectLinkId returns the DirectLinkId field value if set, zero value otherwise. -func (o *DirectLink) GetDirectLinkId() string { - if o == nil || o.DirectLinkId == nil { - var ret string - return ret - } - return *o.DirectLinkId -} - -// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetDirectLinkIdOk() (string, bool) { - if o == nil || o.DirectLinkId == nil { - var ret string - return ret, false - } - return *o.DirectLinkId, true -} - -// HasDirectLinkId returns a boolean if a field has been set. -func (o *DirectLink) HasDirectLinkId() bool { - if o != nil && o.DirectLinkId != nil { - return true - } - - return false -} - -// SetDirectLinkId gets a reference to the given string and assigns it to the DirectLinkId field. -func (o *DirectLink) SetDirectLinkId(v string) { - o.DirectLinkId = &v -} - -// GetDirectLinkName returns the DirectLinkName field value if set, zero value otherwise. -func (o *DirectLink) GetDirectLinkName() string { - if o == nil || o.DirectLinkName == nil { - var ret string - return ret - } - return *o.DirectLinkName -} - -// GetDirectLinkNameOk returns a tuple with the DirectLinkName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetDirectLinkNameOk() (string, bool) { - if o == nil || o.DirectLinkName == nil { - var ret string - return ret, false - } - return *o.DirectLinkName, true -} - -// HasDirectLinkName returns a boolean if a field has been set. -func (o *DirectLink) HasDirectLinkName() bool { - if o != nil && o.DirectLinkName != nil { - return true - } - - return false -} - -// SetDirectLinkName gets a reference to the given string and assigns it to the DirectLinkName field. -func (o *DirectLink) SetDirectLinkName(v string) { - o.DirectLinkName = &v -} - -// GetLocation returns the Location field value if set, zero value otherwise. -func (o *DirectLink) GetLocation() string { - if o == nil || o.Location == nil { - var ret string - return ret - } - return *o.Location -} - -// GetLocationOk returns a tuple with the Location field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetLocationOk() (string, bool) { - if o == nil || o.Location == nil { - var ret string - return ret, false - } - return *o.Location, true -} - -// HasLocation returns a boolean if a field has been set. -func (o *DirectLink) HasLocation() bool { - if o != nil && o.Location != nil { - return true - } - - return false -} - -// SetLocation gets a reference to the given string and assigns it to the Location field. -func (o *DirectLink) SetLocation(v string) { - o.Location = &v -} - -// GetRegionName returns the RegionName field value if set, zero value otherwise. -func (o *DirectLink) GetRegionName() string { - if o == nil || o.RegionName == nil { - var ret string - return ret - } - return *o.RegionName -} - -// GetRegionNameOk returns a tuple with the RegionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetRegionNameOk() (string, bool) { - if o == nil || o.RegionName == nil { - var ret string - return ret, false - } - return *o.RegionName, true -} - -// HasRegionName returns a boolean if a field has been set. -func (o *DirectLink) HasRegionName() bool { - if o != nil && o.RegionName != nil { - return true - } - - return false -} - -// SetRegionName gets a reference to the given string and assigns it to the RegionName field. -func (o *DirectLink) SetRegionName(v string) { - o.RegionName = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *DirectLink) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLink) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *DirectLink) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *DirectLink) SetState(v string) { - o.State = &v -} - -type NullableDirectLink struct { - Value DirectLink - ExplicitNull bool -} - -func (v NullableDirectLink) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDirectLink) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interface.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interface.go deleted file mode 100644 index 0d8e0b37d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interface.go +++ /dev/null @@ -1,216 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DirectLinkInterface Information about the DirectLink interface. -type DirectLinkInterface struct { - // The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. - BgpAsn int64 `json:"BgpAsn"` - // The BGP authentication key. - BgpKey *string `json:"BgpKey,omitempty"` - // The IP address on the customer's side of the DirectLink interface. - ClientPrivateIp *string `json:"ClientPrivateIp,omitempty"` - // The name of the DirectLink interface. - DirectLinkInterfaceName string `json:"DirectLinkInterfaceName"` - // The IP address on 3DS OUTSCALE's side of the DirectLink interface. - OutscalePrivateIp *string `json:"OutscalePrivateIp,omitempty"` - // The ID of the target virtual gateway. - VirtualGatewayId string `json:"VirtualGatewayId"` - // The VLAN number associated with the DirectLink interface. - Vlan int64 `json:"Vlan"` -} - -// GetBgpAsn returns the BgpAsn field value -func (o *DirectLinkInterface) GetBgpAsn() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.BgpAsn -} - -// SetBgpAsn sets field value -func (o *DirectLinkInterface) SetBgpAsn(v int64) { - o.BgpAsn = v -} - -// GetBgpKey returns the BgpKey field value if set, zero value otherwise. -func (o *DirectLinkInterface) GetBgpKey() string { - if o == nil || o.BgpKey == nil { - var ret string - return ret - } - return *o.BgpKey -} - -// GetBgpKeyOk returns a tuple with the BgpKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterface) GetBgpKeyOk() (string, bool) { - if o == nil || o.BgpKey == nil { - var ret string - return ret, false - } - return *o.BgpKey, true -} - -// HasBgpKey returns a boolean if a field has been set. -func (o *DirectLinkInterface) HasBgpKey() bool { - if o != nil && o.BgpKey != nil { - return true - } - - return false -} - -// SetBgpKey gets a reference to the given string and assigns it to the BgpKey field. -func (o *DirectLinkInterface) SetBgpKey(v string) { - o.BgpKey = &v -} - -// GetClientPrivateIp returns the ClientPrivateIp field value if set, zero value otherwise. -func (o *DirectLinkInterface) GetClientPrivateIp() string { - if o == nil || o.ClientPrivateIp == nil { - var ret string - return ret - } - return *o.ClientPrivateIp -} - -// GetClientPrivateIpOk returns a tuple with the ClientPrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterface) GetClientPrivateIpOk() (string, bool) { - if o == nil || o.ClientPrivateIp == nil { - var ret string - return ret, false - } - return *o.ClientPrivateIp, true -} - -// HasClientPrivateIp returns a boolean if a field has been set. -func (o *DirectLinkInterface) HasClientPrivateIp() bool { - if o != nil && o.ClientPrivateIp != nil { - return true - } - - return false -} - -// SetClientPrivateIp gets a reference to the given string and assigns it to the ClientPrivateIp field. -func (o *DirectLinkInterface) SetClientPrivateIp(v string) { - o.ClientPrivateIp = &v -} - -// GetDirectLinkInterfaceName returns the DirectLinkInterfaceName field value -func (o *DirectLinkInterface) GetDirectLinkInterfaceName() string { - if o == nil { - var ret string - return ret - } - - return o.DirectLinkInterfaceName -} - -// SetDirectLinkInterfaceName sets field value -func (o *DirectLinkInterface) SetDirectLinkInterfaceName(v string) { - o.DirectLinkInterfaceName = v -} - -// GetOutscalePrivateIp returns the OutscalePrivateIp field value if set, zero value otherwise. -func (o *DirectLinkInterface) GetOutscalePrivateIp() string { - if o == nil || o.OutscalePrivateIp == nil { - var ret string - return ret - } - return *o.OutscalePrivateIp -} - -// GetOutscalePrivateIpOk returns a tuple with the OutscalePrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterface) GetOutscalePrivateIpOk() (string, bool) { - if o == nil || o.OutscalePrivateIp == nil { - var ret string - return ret, false - } - return *o.OutscalePrivateIp, true -} - -// HasOutscalePrivateIp returns a boolean if a field has been set. -func (o *DirectLinkInterface) HasOutscalePrivateIp() bool { - if o != nil && o.OutscalePrivateIp != nil { - return true - } - - return false -} - -// SetOutscalePrivateIp gets a reference to the given string and assigns it to the OutscalePrivateIp field. -func (o *DirectLinkInterface) SetOutscalePrivateIp(v string) { - o.OutscalePrivateIp = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *DirectLinkInterface) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *DirectLinkInterface) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -// GetVlan returns the Vlan field value -func (o *DirectLinkInterface) GetVlan() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.Vlan -} - -// SetVlan sets field value -func (o *DirectLinkInterface) SetVlan(v int64) { - o.Vlan = v -} - -type NullableDirectLinkInterface struct { - Value DirectLinkInterface - ExplicitNull bool -} - -func (v NullableDirectLinkInterface) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDirectLinkInterface) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interfaces.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interfaces.go deleted file mode 100644 index e1622c85e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_direct_link_interfaces.go +++ /dev/null @@ -1,498 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// DirectLinkInterfaces Information about the DirectLink interfaces. -type DirectLinkInterfaces struct { - // The account ID of the owner of the DirectLink interface. - AccountId *string `json:"AccountId,omitempty"` - // The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. - BgpAsn *int64 `json:"BgpAsn,omitempty"` - // The BGP authentication key. - BgpKey *string `json:"BgpKey,omitempty"` - // The IP address on the customer's side of the DirectLink interface. - ClientPrivateIp *string `json:"ClientPrivateIp,omitempty"` - // The ID of the DirectLink. - DirectLinkId *string `json:"DirectLinkId,omitempty"` - // The ID of the DirectLink interface. - DirectLinkInterfaceId *string `json:"DirectLinkInterfaceId,omitempty"` - // The name of the DirectLink interface. - DirectLinkInterfaceName *string `json:"DirectLinkInterfaceName,omitempty"` - // The type of the DirectLink interface (always `private`). - InterfaceType *string `json:"InterfaceType,omitempty"` - // The datacenter where the DirectLink interface is located. - Location *string `json:"Location,omitempty"` - // The IP address on 3DS OUTSCALE's side of the DirectLink interface. - OutscalePrivateIp *string `json:"OutscalePrivateIp,omitempty"` - // The state of the DirectLink interface (`pending` \\| `available` \\| `deleting` \\| `deleted` \\| `confirming` \\| `rejected` \\| `expired`). - State *string `json:"State,omitempty"` - // The ID of the target virtual gateway. - VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` - // The VLAN number associated with the DirectLink interface. - Vlan *int64 `json:"Vlan,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *DirectLinkInterfaces) SetAccountId(v string) { - o.AccountId = &v -} - -// GetBgpAsn returns the BgpAsn field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetBgpAsn() int64 { - if o == nil || o.BgpAsn == nil { - var ret int64 - return ret - } - return *o.BgpAsn -} - -// GetBgpAsnOk returns a tuple with the BgpAsn field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetBgpAsnOk() (int64, bool) { - if o == nil || o.BgpAsn == nil { - var ret int64 - return ret, false - } - return *o.BgpAsn, true -} - -// HasBgpAsn returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasBgpAsn() bool { - if o != nil && o.BgpAsn != nil { - return true - } - - return false -} - -// SetBgpAsn gets a reference to the given int64 and assigns it to the BgpAsn field. -func (o *DirectLinkInterfaces) SetBgpAsn(v int64) { - o.BgpAsn = &v -} - -// GetBgpKey returns the BgpKey field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetBgpKey() string { - if o == nil || o.BgpKey == nil { - var ret string - return ret - } - return *o.BgpKey -} - -// GetBgpKeyOk returns a tuple with the BgpKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetBgpKeyOk() (string, bool) { - if o == nil || o.BgpKey == nil { - var ret string - return ret, false - } - return *o.BgpKey, true -} - -// HasBgpKey returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasBgpKey() bool { - if o != nil && o.BgpKey != nil { - return true - } - - return false -} - -// SetBgpKey gets a reference to the given string and assigns it to the BgpKey field. -func (o *DirectLinkInterfaces) SetBgpKey(v string) { - o.BgpKey = &v -} - -// GetClientPrivateIp returns the ClientPrivateIp field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetClientPrivateIp() string { - if o == nil || o.ClientPrivateIp == nil { - var ret string - return ret - } - return *o.ClientPrivateIp -} - -// GetClientPrivateIpOk returns a tuple with the ClientPrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetClientPrivateIpOk() (string, bool) { - if o == nil || o.ClientPrivateIp == nil { - var ret string - return ret, false - } - return *o.ClientPrivateIp, true -} - -// HasClientPrivateIp returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasClientPrivateIp() bool { - if o != nil && o.ClientPrivateIp != nil { - return true - } - - return false -} - -// SetClientPrivateIp gets a reference to the given string and assigns it to the ClientPrivateIp field. -func (o *DirectLinkInterfaces) SetClientPrivateIp(v string) { - o.ClientPrivateIp = &v -} - -// GetDirectLinkId returns the DirectLinkId field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetDirectLinkId() string { - if o == nil || o.DirectLinkId == nil { - var ret string - return ret - } - return *o.DirectLinkId -} - -// GetDirectLinkIdOk returns a tuple with the DirectLinkId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetDirectLinkIdOk() (string, bool) { - if o == nil || o.DirectLinkId == nil { - var ret string - return ret, false - } - return *o.DirectLinkId, true -} - -// HasDirectLinkId returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasDirectLinkId() bool { - if o != nil && o.DirectLinkId != nil { - return true - } - - return false -} - -// SetDirectLinkId gets a reference to the given string and assigns it to the DirectLinkId field. -func (o *DirectLinkInterfaces) SetDirectLinkId(v string) { - o.DirectLinkId = &v -} - -// GetDirectLinkInterfaceId returns the DirectLinkInterfaceId field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetDirectLinkInterfaceId() string { - if o == nil || o.DirectLinkInterfaceId == nil { - var ret string - return ret - } - return *o.DirectLinkInterfaceId -} - -// GetDirectLinkInterfaceIdOk returns a tuple with the DirectLinkInterfaceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetDirectLinkInterfaceIdOk() (string, bool) { - if o == nil || o.DirectLinkInterfaceId == nil { - var ret string - return ret, false - } - return *o.DirectLinkInterfaceId, true -} - -// HasDirectLinkInterfaceId returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasDirectLinkInterfaceId() bool { - if o != nil && o.DirectLinkInterfaceId != nil { - return true - } - - return false -} - -// SetDirectLinkInterfaceId gets a reference to the given string and assigns it to the DirectLinkInterfaceId field. -func (o *DirectLinkInterfaces) SetDirectLinkInterfaceId(v string) { - o.DirectLinkInterfaceId = &v -} - -// GetDirectLinkInterfaceName returns the DirectLinkInterfaceName field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetDirectLinkInterfaceName() string { - if o == nil || o.DirectLinkInterfaceName == nil { - var ret string - return ret - } - return *o.DirectLinkInterfaceName -} - -// GetDirectLinkInterfaceNameOk returns a tuple with the DirectLinkInterfaceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetDirectLinkInterfaceNameOk() (string, bool) { - if o == nil || o.DirectLinkInterfaceName == nil { - var ret string - return ret, false - } - return *o.DirectLinkInterfaceName, true -} - -// HasDirectLinkInterfaceName returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasDirectLinkInterfaceName() bool { - if o != nil && o.DirectLinkInterfaceName != nil { - return true - } - - return false -} - -// SetDirectLinkInterfaceName gets a reference to the given string and assigns it to the DirectLinkInterfaceName field. -func (o *DirectLinkInterfaces) SetDirectLinkInterfaceName(v string) { - o.DirectLinkInterfaceName = &v -} - -// GetInterfaceType returns the InterfaceType field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetInterfaceType() string { - if o == nil || o.InterfaceType == nil { - var ret string - return ret - } - return *o.InterfaceType -} - -// GetInterfaceTypeOk returns a tuple with the InterfaceType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetInterfaceTypeOk() (string, bool) { - if o == nil || o.InterfaceType == nil { - var ret string - return ret, false - } - return *o.InterfaceType, true -} - -// HasInterfaceType returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasInterfaceType() bool { - if o != nil && o.InterfaceType != nil { - return true - } - - return false -} - -// SetInterfaceType gets a reference to the given string and assigns it to the InterfaceType field. -func (o *DirectLinkInterfaces) SetInterfaceType(v string) { - o.InterfaceType = &v -} - -// GetLocation returns the Location field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetLocation() string { - if o == nil || o.Location == nil { - var ret string - return ret - } - return *o.Location -} - -// GetLocationOk returns a tuple with the Location field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetLocationOk() (string, bool) { - if o == nil || o.Location == nil { - var ret string - return ret, false - } - return *o.Location, true -} - -// HasLocation returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasLocation() bool { - if o != nil && o.Location != nil { - return true - } - - return false -} - -// SetLocation gets a reference to the given string and assigns it to the Location field. -func (o *DirectLinkInterfaces) SetLocation(v string) { - o.Location = &v -} - -// GetOutscalePrivateIp returns the OutscalePrivateIp field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetOutscalePrivateIp() string { - if o == nil || o.OutscalePrivateIp == nil { - var ret string - return ret - } - return *o.OutscalePrivateIp -} - -// GetOutscalePrivateIpOk returns a tuple with the OutscalePrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetOutscalePrivateIpOk() (string, bool) { - if o == nil || o.OutscalePrivateIp == nil { - var ret string - return ret, false - } - return *o.OutscalePrivateIp, true -} - -// HasOutscalePrivateIp returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasOutscalePrivateIp() bool { - if o != nil && o.OutscalePrivateIp != nil { - return true - } - - return false -} - -// SetOutscalePrivateIp gets a reference to the given string and assigns it to the OutscalePrivateIp field. -func (o *DirectLinkInterfaces) SetOutscalePrivateIp(v string) { - o.OutscalePrivateIp = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *DirectLinkInterfaces) SetState(v string) { - o.State = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetVirtualGatewayId() string { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret - } - return *o.VirtualGatewayId -} - -// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetVirtualGatewayIdOk() (string, bool) { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret, false - } - return *o.VirtualGatewayId, true -} - -// HasVirtualGatewayId returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasVirtualGatewayId() bool { - if o != nil && o.VirtualGatewayId != nil { - return true - } - - return false -} - -// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. -func (o *DirectLinkInterfaces) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = &v -} - -// GetVlan returns the Vlan field value if set, zero value otherwise. -func (o *DirectLinkInterfaces) GetVlan() int64 { - if o == nil || o.Vlan == nil { - var ret int64 - return ret - } - return *o.Vlan -} - -// GetVlanOk returns a tuple with the Vlan field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *DirectLinkInterfaces) GetVlanOk() (int64, bool) { - if o == nil || o.Vlan == nil { - var ret int64 - return ret, false - } - return *o.Vlan, true -} - -// HasVlan returns a boolean if a field has been set. -func (o *DirectLinkInterfaces) HasVlan() bool { - if o != nil && o.Vlan != nil { - return true - } - - return false -} - -// SetVlan gets a reference to the given int64 and assigns it to the Vlan field. -func (o *DirectLinkInterfaces) SetVlan(v int64) { - o.Vlan = &v -} - -type NullableDirectLinkInterfaces struct { - Value DirectLinkInterfaces - ExplicitNull bool -} - -func (v NullableDirectLinkInterfaces) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableDirectLinkInterfaces) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_error_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_error_response.go deleted file mode 100644 index 351943f5c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_error_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ErrorResponse struct for ErrorResponse -type ErrorResponse struct { - // One or more errors. - Errors *[]Errors `json:"Errors,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetErrors returns the Errors field value if set, zero value otherwise. -func (o *ErrorResponse) GetErrors() []Errors { - if o == nil || o.Errors == nil { - var ret []Errors - return ret - } - return *o.Errors -} - -// GetErrorsOk returns a tuple with the Errors field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetErrorsOk() ([]Errors, bool) { - if o == nil || o.Errors == nil { - var ret []Errors - return ret, false - } - return *o.Errors, true -} - -// HasErrors returns a boolean if a field has been set. -func (o *ErrorResponse) HasErrors() bool { - if o != nil && o.Errors != nil { - return true - } - - return false -} - -// SetErrors gets a reference to the given []Errors and assigns it to the Errors field. -func (o *ErrorResponse) SetErrors(v []Errors) { - o.Errors = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ErrorResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ErrorResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ErrorResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableErrorResponse struct { - Value ErrorResponse - ExplicitNull bool -} - -func (v NullableErrorResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableErrorResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_errors.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_errors.go deleted file mode 100644 index d833841f0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_errors.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Errors Information about the errors. -type Errors struct { - // The code of the error. - Code *string `json:"Code,omitempty"` - // The details of the error. - Details *string `json:"Details,omitempty"` - // The type of the error. - Type *string `json:"Type,omitempty"` -} - -// GetCode returns the Code field value if set, zero value otherwise. -func (o *Errors) GetCode() string { - if o == nil || o.Code == nil { - var ret string - return ret - } - return *o.Code -} - -// GetCodeOk returns a tuple with the Code field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Errors) GetCodeOk() (string, bool) { - if o == nil || o.Code == nil { - var ret string - return ret, false - } - return *o.Code, true -} - -// HasCode returns a boolean if a field has been set. -func (o *Errors) HasCode() bool { - if o != nil && o.Code != nil { - return true - } - - return false -} - -// SetCode gets a reference to the given string and assigns it to the Code field. -func (o *Errors) SetCode(v string) { - o.Code = &v -} - -// GetDetails returns the Details field value if set, zero value otherwise. -func (o *Errors) GetDetails() string { - if o == nil || o.Details == nil { - var ret string - return ret - } - return *o.Details -} - -// GetDetailsOk returns a tuple with the Details field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Errors) GetDetailsOk() (string, bool) { - if o == nil || o.Details == nil { - var ret string - return ret, false - } - return *o.Details, true -} - -// HasDetails returns a boolean if a field has been set. -func (o *Errors) HasDetails() bool { - if o != nil && o.Details != nil { - return true - } - - return false -} - -// SetDetails gets a reference to the given string and assigns it to the Details field. -func (o *Errors) SetDetails(v string) { - o.Details = &v -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *Errors) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Errors) GetTypeOk() (string, bool) { - if o == nil || o.Type == nil { - var ret string - return ret, false - } - return *o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *Errors) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *Errors) SetType(v string) { - o.Type = &v -} - -type NullableErrors struct { - Value Errors - ExplicitNull bool -} - -func (v NullableErrors) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableErrors) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_access_keys.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_access_keys.go deleted file mode 100644 index 633d64e08..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_access_keys.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersAccessKeys One or more filters. -type FiltersAccessKeys struct { - // The IDs of the access keys. - AccessKeyIds *[]string `json:"AccessKeyIds,omitempty"` - // The states of the access keys (`active` \\| `inactive`). - States *[]string `json:"States,omitempty"` -} - -// GetAccessKeyIds returns the AccessKeyIds field value if set, zero value otherwise. -func (o *FiltersAccessKeys) GetAccessKeyIds() []string { - if o == nil || o.AccessKeyIds == nil { - var ret []string - return ret - } - return *o.AccessKeyIds -} - -// GetAccessKeyIdsOk returns a tuple with the AccessKeyIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersAccessKeys) GetAccessKeyIdsOk() ([]string, bool) { - if o == nil || o.AccessKeyIds == nil { - var ret []string - return ret, false - } - return *o.AccessKeyIds, true -} - -// HasAccessKeyIds returns a boolean if a field has been set. -func (o *FiltersAccessKeys) HasAccessKeyIds() bool { - if o != nil && o.AccessKeyIds != nil { - return true - } - - return false -} - -// SetAccessKeyIds gets a reference to the given []string and assigns it to the AccessKeyIds field. -func (o *FiltersAccessKeys) SetAccessKeyIds(v []string) { - o.AccessKeyIds = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersAccessKeys) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersAccessKeys) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersAccessKeys) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersAccessKeys) SetStates(v []string) { - o.States = &v -} - -type NullableFiltersAccessKeys struct { - Value FiltersAccessKeys - ExplicitNull bool -} - -func (v NullableFiltersAccessKeys) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersAccessKeys) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_api_log.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_api_log.go deleted file mode 100644 index ab5f51567..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_api_log.go +++ /dev/null @@ -1,358 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersApiLog One or more filters. -type FiltersApiLog struct { - // One or more API keys used for the query. - QueryAccessKeys *[]string `json:"QueryAccessKeys,omitempty"` - // The name of one or more API services used for the query. - QueryApiNames *[]string `json:"QueryApiNames,omitempty"` - // The name of one or more calls. - QueryCallNames *[]string `json:"QueryCallNames,omitempty"` - // The logs of the queries made after the date and time you specify (in ISO 8601 base or extended format). - QueryDateAfter *string `json:"QueryDateAfter,omitempty"` - // The logs of the queries made before the date and time you specify (in ISO 8601 base or extended format). - QueryDateBefore *string `json:"QueryDateBefore,omitempty"` - // One or more IP addresses used for the query. - QueryIpAddresses *[]string `json:"QueryIpAddresses,omitempty"` - // One or more user agents used for the HTTP request. - QueryUserAgents *[]string `json:"QueryUserAgents,omitempty"` - // One or more request IDs. - RequestIds *[]string `json:"RequestIds,omitempty"` - // One or more HTTP codes provided by the responses. - ResponseStatusCodes *[]int64 `json:"ResponseStatusCodes,omitempty"` -} - -// GetQueryAccessKeys returns the QueryAccessKeys field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryAccessKeys() []string { - if o == nil || o.QueryAccessKeys == nil { - var ret []string - return ret - } - return *o.QueryAccessKeys -} - -// GetQueryAccessKeysOk returns a tuple with the QueryAccessKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryAccessKeysOk() ([]string, bool) { - if o == nil || o.QueryAccessKeys == nil { - var ret []string - return ret, false - } - return *o.QueryAccessKeys, true -} - -// HasQueryAccessKeys returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryAccessKeys() bool { - if o != nil && o.QueryAccessKeys != nil { - return true - } - - return false -} - -// SetQueryAccessKeys gets a reference to the given []string and assigns it to the QueryAccessKeys field. -func (o *FiltersApiLog) SetQueryAccessKeys(v []string) { - o.QueryAccessKeys = &v -} - -// GetQueryApiNames returns the QueryApiNames field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryApiNames() []string { - if o == nil || o.QueryApiNames == nil { - var ret []string - return ret - } - return *o.QueryApiNames -} - -// GetQueryApiNamesOk returns a tuple with the QueryApiNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryApiNamesOk() ([]string, bool) { - if o == nil || o.QueryApiNames == nil { - var ret []string - return ret, false - } - return *o.QueryApiNames, true -} - -// HasQueryApiNames returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryApiNames() bool { - if o != nil && o.QueryApiNames != nil { - return true - } - - return false -} - -// SetQueryApiNames gets a reference to the given []string and assigns it to the QueryApiNames field. -func (o *FiltersApiLog) SetQueryApiNames(v []string) { - o.QueryApiNames = &v -} - -// GetQueryCallNames returns the QueryCallNames field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryCallNames() []string { - if o == nil || o.QueryCallNames == nil { - var ret []string - return ret - } - return *o.QueryCallNames -} - -// GetQueryCallNamesOk returns a tuple with the QueryCallNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryCallNamesOk() ([]string, bool) { - if o == nil || o.QueryCallNames == nil { - var ret []string - return ret, false - } - return *o.QueryCallNames, true -} - -// HasQueryCallNames returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryCallNames() bool { - if o != nil && o.QueryCallNames != nil { - return true - } - - return false -} - -// SetQueryCallNames gets a reference to the given []string and assigns it to the QueryCallNames field. -func (o *FiltersApiLog) SetQueryCallNames(v []string) { - o.QueryCallNames = &v -} - -// GetQueryDateAfter returns the QueryDateAfter field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryDateAfter() string { - if o == nil || o.QueryDateAfter == nil { - var ret string - return ret - } - return *o.QueryDateAfter -} - -// GetQueryDateAfterOk returns a tuple with the QueryDateAfter field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryDateAfterOk() (string, bool) { - if o == nil || o.QueryDateAfter == nil { - var ret string - return ret, false - } - return *o.QueryDateAfter, true -} - -// HasQueryDateAfter returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryDateAfter() bool { - if o != nil && o.QueryDateAfter != nil { - return true - } - - return false -} - -// SetQueryDateAfter gets a reference to the given string and assigns it to the QueryDateAfter field. -func (o *FiltersApiLog) SetQueryDateAfter(v string) { - o.QueryDateAfter = &v -} - -// GetQueryDateBefore returns the QueryDateBefore field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryDateBefore() string { - if o == nil || o.QueryDateBefore == nil { - var ret string - return ret - } - return *o.QueryDateBefore -} - -// GetQueryDateBeforeOk returns a tuple with the QueryDateBefore field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryDateBeforeOk() (string, bool) { - if o == nil || o.QueryDateBefore == nil { - var ret string - return ret, false - } - return *o.QueryDateBefore, true -} - -// HasQueryDateBefore returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryDateBefore() bool { - if o != nil && o.QueryDateBefore != nil { - return true - } - - return false -} - -// SetQueryDateBefore gets a reference to the given string and assigns it to the QueryDateBefore field. -func (o *FiltersApiLog) SetQueryDateBefore(v string) { - o.QueryDateBefore = &v -} - -// GetQueryIpAddresses returns the QueryIpAddresses field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryIpAddresses() []string { - if o == nil || o.QueryIpAddresses == nil { - var ret []string - return ret - } - return *o.QueryIpAddresses -} - -// GetQueryIpAddressesOk returns a tuple with the QueryIpAddresses field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryIpAddressesOk() ([]string, bool) { - if o == nil || o.QueryIpAddresses == nil { - var ret []string - return ret, false - } - return *o.QueryIpAddresses, true -} - -// HasQueryIpAddresses returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryIpAddresses() bool { - if o != nil && o.QueryIpAddresses != nil { - return true - } - - return false -} - -// SetQueryIpAddresses gets a reference to the given []string and assigns it to the QueryIpAddresses field. -func (o *FiltersApiLog) SetQueryIpAddresses(v []string) { - o.QueryIpAddresses = &v -} - -// GetQueryUserAgents returns the QueryUserAgents field value if set, zero value otherwise. -func (o *FiltersApiLog) GetQueryUserAgents() []string { - if o == nil || o.QueryUserAgents == nil { - var ret []string - return ret - } - return *o.QueryUserAgents -} - -// GetQueryUserAgentsOk returns a tuple with the QueryUserAgents field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetQueryUserAgentsOk() ([]string, bool) { - if o == nil || o.QueryUserAgents == nil { - var ret []string - return ret, false - } - return *o.QueryUserAgents, true -} - -// HasQueryUserAgents returns a boolean if a field has been set. -func (o *FiltersApiLog) HasQueryUserAgents() bool { - if o != nil && o.QueryUserAgents != nil { - return true - } - - return false -} - -// SetQueryUserAgents gets a reference to the given []string and assigns it to the QueryUserAgents field. -func (o *FiltersApiLog) SetQueryUserAgents(v []string) { - o.QueryUserAgents = &v -} - -// GetRequestIds returns the RequestIds field value if set, zero value otherwise. -func (o *FiltersApiLog) GetRequestIds() []string { - if o == nil || o.RequestIds == nil { - var ret []string - return ret - } - return *o.RequestIds -} - -// GetRequestIdsOk returns a tuple with the RequestIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetRequestIdsOk() ([]string, bool) { - if o == nil || o.RequestIds == nil { - var ret []string - return ret, false - } - return *o.RequestIds, true -} - -// HasRequestIds returns a boolean if a field has been set. -func (o *FiltersApiLog) HasRequestIds() bool { - if o != nil && o.RequestIds != nil { - return true - } - - return false -} - -// SetRequestIds gets a reference to the given []string and assigns it to the RequestIds field. -func (o *FiltersApiLog) SetRequestIds(v []string) { - o.RequestIds = &v -} - -// GetResponseStatusCodes returns the ResponseStatusCodes field value if set, zero value otherwise. -func (o *FiltersApiLog) GetResponseStatusCodes() []int64 { - if o == nil || o.ResponseStatusCodes == nil { - var ret []int64 - return ret - } - return *o.ResponseStatusCodes -} - -// GetResponseStatusCodesOk returns a tuple with the ResponseStatusCodes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersApiLog) GetResponseStatusCodesOk() ([]int64, bool) { - if o == nil || o.ResponseStatusCodes == nil { - var ret []int64 - return ret, false - } - return *o.ResponseStatusCodes, true -} - -// HasResponseStatusCodes returns a boolean if a field has been set. -func (o *FiltersApiLog) HasResponseStatusCodes() bool { - if o != nil && o.ResponseStatusCodes != nil { - return true - } - - return false -} - -// SetResponseStatusCodes gets a reference to the given []int64 and assigns it to the ResponseStatusCodes field. -func (o *FiltersApiLog) SetResponseStatusCodes(v []int64) { - o.ResponseStatusCodes = &v -} - -type NullableFiltersApiLog struct { - Value FiltersApiLog - ExplicitNull bool -} - -func (v NullableFiltersApiLog) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersApiLog) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_client_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_client_gateway.go deleted file mode 100644 index adbc7e280..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_client_gateway.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersClientGateway One or more filters. -type FiltersClientGateway struct { - // The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. - BgpAsns *[]int64 `json:"BgpAsns,omitempty"` - // The IDs of the client gateways. - ClientGatewayIds *[]string `json:"ClientGatewayIds,omitempty"` - // The types of communication tunnels used by the client gateways (only `ipsec.1` is supported). - ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` - // The public IPv4 addresses of the client gateways. - PublicIps *[]string `json:"PublicIps,omitempty"` - // The states of the client gateways (`pending` \\| `available` \\| `deleting` \\| `deleted`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the client gateways. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the client gateways. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the client gateways, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetBgpAsns returns the BgpAsns field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetBgpAsns() []int64 { - if o == nil || o.BgpAsns == nil { - var ret []int64 - return ret - } - return *o.BgpAsns -} - -// GetBgpAsnsOk returns a tuple with the BgpAsns field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetBgpAsnsOk() ([]int64, bool) { - if o == nil || o.BgpAsns == nil { - var ret []int64 - return ret, false - } - return *o.BgpAsns, true -} - -// HasBgpAsns returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasBgpAsns() bool { - if o != nil && o.BgpAsns != nil { - return true - } - - return false -} - -// SetBgpAsns gets a reference to the given []int64 and assigns it to the BgpAsns field. -func (o *FiltersClientGateway) SetBgpAsns(v []int64) { - o.BgpAsns = &v -} - -// GetClientGatewayIds returns the ClientGatewayIds field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetClientGatewayIds() []string { - if o == nil || o.ClientGatewayIds == nil { - var ret []string - return ret - } - return *o.ClientGatewayIds -} - -// GetClientGatewayIdsOk returns a tuple with the ClientGatewayIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetClientGatewayIdsOk() ([]string, bool) { - if o == nil || o.ClientGatewayIds == nil { - var ret []string - return ret, false - } - return *o.ClientGatewayIds, true -} - -// HasClientGatewayIds returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasClientGatewayIds() bool { - if o != nil && o.ClientGatewayIds != nil { - return true - } - - return false -} - -// SetClientGatewayIds gets a reference to the given []string and assigns it to the ClientGatewayIds field. -func (o *FiltersClientGateway) SetClientGatewayIds(v []string) { - o.ClientGatewayIds = &v -} - -// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetConnectionTypes() []string { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret - } - return *o.ConnectionTypes -} - -// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetConnectionTypesOk() ([]string, bool) { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret, false - } - return *o.ConnectionTypes, true -} - -// HasConnectionTypes returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasConnectionTypes() bool { - if o != nil && o.ConnectionTypes != nil { - return true - } - - return false -} - -// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. -func (o *FiltersClientGateway) SetConnectionTypes(v []string) { - o.ConnectionTypes = &v -} - -// GetPublicIps returns the PublicIps field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetPublicIps() []string { - if o == nil || o.PublicIps == nil { - var ret []string - return ret - } - return *o.PublicIps -} - -// GetPublicIpsOk returns a tuple with the PublicIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetPublicIpsOk() ([]string, bool) { - if o == nil || o.PublicIps == nil { - var ret []string - return ret, false - } - return *o.PublicIps, true -} - -// HasPublicIps returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasPublicIps() bool { - if o != nil && o.PublicIps != nil { - return true - } - - return false -} - -// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. -func (o *FiltersClientGateway) SetPublicIps(v []string) { - o.PublicIps = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersClientGateway) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersClientGateway) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersClientGateway) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersClientGateway) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersClientGateway) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersClientGateway) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersClientGateway) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersClientGateway struct { - Value FiltersClientGateway - ExplicitNull bool -} - -func (v NullableFiltersClientGateway) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersClientGateway) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_dhcp_options.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_dhcp_options.go deleted file mode 100644 index 20c1d2166..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_dhcp_options.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersDhcpOptions One or more filters. -type FiltersDhcpOptions struct { - // If `true`, lists all default DHCP options set. If `false`, lists all non-default DHCP options set. - Default *bool `json:"Default,omitempty"` - // The IDs of the DHCP options sets. - DhcpOptionsSetIds *[]string `json:"DhcpOptionsSetIds,omitempty"` - // The domain name servers used for the DHCP options sets. - DomainNameServers *[]string `json:"DomainNameServers,omitempty"` - // The domain names used for the DHCP options sets. - DomainNames *[]string `json:"DomainNames,omitempty"` - // The Network Time Protocol (NTP) servers used for the DHCP options sets. - NtpServers *[]string `json:"NtpServers,omitempty"` - // The keys of the tags associated with the DHCP options sets. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the DHCP options sets. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the DHCP options sets, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetDefault returns the Default field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetDefault() bool { - if o == nil || o.Default == nil { - var ret bool - return ret - } - return *o.Default -} - -// GetDefaultOk returns a tuple with the Default field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetDefaultOk() (bool, bool) { - if o == nil || o.Default == nil { - var ret bool - return ret, false - } - return *o.Default, true -} - -// HasDefault returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasDefault() bool { - if o != nil && o.Default != nil { - return true - } - - return false -} - -// SetDefault gets a reference to the given bool and assigns it to the Default field. -func (o *FiltersDhcpOptions) SetDefault(v bool) { - o.Default = &v -} - -// GetDhcpOptionsSetIds returns the DhcpOptionsSetIds field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetDhcpOptionsSetIds() []string { - if o == nil || o.DhcpOptionsSetIds == nil { - var ret []string - return ret - } - return *o.DhcpOptionsSetIds -} - -// GetDhcpOptionsSetIdsOk returns a tuple with the DhcpOptionsSetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetDhcpOptionsSetIdsOk() ([]string, bool) { - if o == nil || o.DhcpOptionsSetIds == nil { - var ret []string - return ret, false - } - return *o.DhcpOptionsSetIds, true -} - -// HasDhcpOptionsSetIds returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasDhcpOptionsSetIds() bool { - if o != nil && o.DhcpOptionsSetIds != nil { - return true - } - - return false -} - -// SetDhcpOptionsSetIds gets a reference to the given []string and assigns it to the DhcpOptionsSetIds field. -func (o *FiltersDhcpOptions) SetDhcpOptionsSetIds(v []string) { - o.DhcpOptionsSetIds = &v -} - -// GetDomainNameServers returns the DomainNameServers field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetDomainNameServers() []string { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret - } - return *o.DomainNameServers -} - -// GetDomainNameServersOk returns a tuple with the DomainNameServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetDomainNameServersOk() ([]string, bool) { - if o == nil || o.DomainNameServers == nil { - var ret []string - return ret, false - } - return *o.DomainNameServers, true -} - -// HasDomainNameServers returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasDomainNameServers() bool { - if o != nil && o.DomainNameServers != nil { - return true - } - - return false -} - -// SetDomainNameServers gets a reference to the given []string and assigns it to the DomainNameServers field. -func (o *FiltersDhcpOptions) SetDomainNameServers(v []string) { - o.DomainNameServers = &v -} - -// GetDomainNames returns the DomainNames field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetDomainNames() []string { - if o == nil || o.DomainNames == nil { - var ret []string - return ret - } - return *o.DomainNames -} - -// GetDomainNamesOk returns a tuple with the DomainNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetDomainNamesOk() ([]string, bool) { - if o == nil || o.DomainNames == nil { - var ret []string - return ret, false - } - return *o.DomainNames, true -} - -// HasDomainNames returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasDomainNames() bool { - if o != nil && o.DomainNames != nil { - return true - } - - return false -} - -// SetDomainNames gets a reference to the given []string and assigns it to the DomainNames field. -func (o *FiltersDhcpOptions) SetDomainNames(v []string) { - o.DomainNames = &v -} - -// GetNtpServers returns the NtpServers field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetNtpServers() []string { - if o == nil || o.NtpServers == nil { - var ret []string - return ret - } - return *o.NtpServers -} - -// GetNtpServersOk returns a tuple with the NtpServers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetNtpServersOk() ([]string, bool) { - if o == nil || o.NtpServers == nil { - var ret []string - return ret, false - } - return *o.NtpServers, true -} - -// HasNtpServers returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasNtpServers() bool { - if o != nil && o.NtpServers != nil { - return true - } - - return false -} - -// SetNtpServers gets a reference to the given []string and assigns it to the NtpServers field. -func (o *FiltersDhcpOptions) SetNtpServers(v []string) { - o.NtpServers = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersDhcpOptions) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersDhcpOptions) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersDhcpOptions) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDhcpOptions) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersDhcpOptions) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersDhcpOptions) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersDhcpOptions struct { - Value FiltersDhcpOptions - ExplicitNull bool -} - -func (v NullableFiltersDhcpOptions) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersDhcpOptions) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link.go deleted file mode 100644 index cfc49daf2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersDirectLink One or more filters. -type FiltersDirectLink struct { - // The IDs of the DirectLinks. - DirectLinkIds *[]string `json:"DirectLinkIds,omitempty"` -} - -// GetDirectLinkIds returns the DirectLinkIds field value if set, zero value otherwise. -func (o *FiltersDirectLink) GetDirectLinkIds() []string { - if o == nil || o.DirectLinkIds == nil { - var ret []string - return ret - } - return *o.DirectLinkIds -} - -// GetDirectLinkIdsOk returns a tuple with the DirectLinkIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDirectLink) GetDirectLinkIdsOk() ([]string, bool) { - if o == nil || o.DirectLinkIds == nil { - var ret []string - return ret, false - } - return *o.DirectLinkIds, true -} - -// HasDirectLinkIds returns a boolean if a field has been set. -func (o *FiltersDirectLink) HasDirectLinkIds() bool { - if o != nil && o.DirectLinkIds != nil { - return true - } - - return false -} - -// SetDirectLinkIds gets a reference to the given []string and assigns it to the DirectLinkIds field. -func (o *FiltersDirectLink) SetDirectLinkIds(v []string) { - o.DirectLinkIds = &v -} - -type NullableFiltersDirectLink struct { - Value FiltersDirectLink - ExplicitNull bool -} - -func (v NullableFiltersDirectLink) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersDirectLink) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link_interface.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link_interface.go deleted file mode 100644 index 297b69534..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_direct_link_interface.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersDirectLinkInterface One or more filters. -type FiltersDirectLinkInterface struct { - // The IDs of the DirectLinks. - DirectLinkIds *[]string `json:"DirectLinkIds,omitempty"` - // The IDs of the DirectLink interfaces. - DirectLinkInterfaceIds *[]string `json:"DirectLinkInterfaceIds,omitempty"` -} - -// GetDirectLinkIds returns the DirectLinkIds field value if set, zero value otherwise. -func (o *FiltersDirectLinkInterface) GetDirectLinkIds() []string { - if o == nil || o.DirectLinkIds == nil { - var ret []string - return ret - } - return *o.DirectLinkIds -} - -// GetDirectLinkIdsOk returns a tuple with the DirectLinkIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDirectLinkInterface) GetDirectLinkIdsOk() ([]string, bool) { - if o == nil || o.DirectLinkIds == nil { - var ret []string - return ret, false - } - return *o.DirectLinkIds, true -} - -// HasDirectLinkIds returns a boolean if a field has been set. -func (o *FiltersDirectLinkInterface) HasDirectLinkIds() bool { - if o != nil && o.DirectLinkIds != nil { - return true - } - - return false -} - -// SetDirectLinkIds gets a reference to the given []string and assigns it to the DirectLinkIds field. -func (o *FiltersDirectLinkInterface) SetDirectLinkIds(v []string) { - o.DirectLinkIds = &v -} - -// GetDirectLinkInterfaceIds returns the DirectLinkInterfaceIds field value if set, zero value otherwise. -func (o *FiltersDirectLinkInterface) GetDirectLinkInterfaceIds() []string { - if o == nil || o.DirectLinkInterfaceIds == nil { - var ret []string - return ret - } - return *o.DirectLinkInterfaceIds -} - -// GetDirectLinkInterfaceIdsOk returns a tuple with the DirectLinkInterfaceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersDirectLinkInterface) GetDirectLinkInterfaceIdsOk() ([]string, bool) { - if o == nil || o.DirectLinkInterfaceIds == nil { - var ret []string - return ret, false - } - return *o.DirectLinkInterfaceIds, true -} - -// HasDirectLinkInterfaceIds returns a boolean if a field has been set. -func (o *FiltersDirectLinkInterface) HasDirectLinkInterfaceIds() bool { - if o != nil && o.DirectLinkInterfaceIds != nil { - return true - } - - return false -} - -// SetDirectLinkInterfaceIds gets a reference to the given []string and assigns it to the DirectLinkInterfaceIds field. -func (o *FiltersDirectLinkInterface) SetDirectLinkInterfaceIds(v []string) { - o.DirectLinkInterfaceIds = &v -} - -type NullableFiltersDirectLinkInterface struct { - Value FiltersDirectLinkInterface - ExplicitNull bool -} - -func (v NullableFiltersDirectLinkInterface) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersDirectLinkInterface) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_export_task.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_export_task.go deleted file mode 100644 index cd2c8d196..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_export_task.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersExportTask One or more filters. -type FiltersExportTask struct { - // The keys of the tags associated with the export tasks. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the export tasks. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the export tasks, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The IDs of the export tasks. - TaskIds *[]string `json:"TaskIds,omitempty"` -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersExportTask) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersExportTask) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersExportTask) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersExportTask) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersExportTask) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersExportTask) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersExportTask) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersExportTask) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersExportTask) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersExportTask) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersExportTask) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersExportTask) SetTags(v []string) { - o.Tags = &v -} - -// GetTaskIds returns the TaskIds field value if set, zero value otherwise. -func (o *FiltersExportTask) GetTaskIds() []string { - if o == nil || o.TaskIds == nil { - var ret []string - return ret - } - return *o.TaskIds -} - -// GetTaskIdsOk returns a tuple with the TaskIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersExportTask) GetTaskIdsOk() ([]string, bool) { - if o == nil || o.TaskIds == nil { - var ret []string - return ret, false - } - return *o.TaskIds, true -} - -// HasTaskIds returns a boolean if a field has been set. -func (o *FiltersExportTask) HasTaskIds() bool { - if o != nil && o.TaskIds != nil { - return true - } - - return false -} - -// SetTaskIds gets a reference to the given []string and assigns it to the TaskIds field. -func (o *FiltersExportTask) SetTaskIds(v []string) { - o.TaskIds = &v -} - -type NullableFiltersExportTask struct { - Value FiltersExportTask - ExplicitNull bool -} - -func (v NullableFiltersExportTask) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersExportTask) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_flexible_gpu.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_flexible_gpu.go deleted file mode 100644 index 5783d7da3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_flexible_gpu.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersFlexibleGpu One or more filters. -type FiltersFlexibleGpu struct { - // Indicates whether the fGPU is deleted when terminating the VM. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // One or more IDs of fGPUs. - FlexibleGpuIds *[]string `json:"FlexibleGpuIds,omitempty"` - // One or more models of fGPUs. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - ModelNames *[]string `json:"ModelNames,omitempty"` - // The states of the fGPUs (`allocated` \\| `attaching` \\| `attached` \\| `detaching`). - States *[]string `json:"States,omitempty"` - // The Subregions where the fGPUs are located. - SubregionNames *[]string `json:"SubregionNames,omitempty"` - // One or more IDs of VMs. - VmIds *[]string `json:"VmIds,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *FiltersFlexibleGpu) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetFlexibleGpuIds returns the FlexibleGpuIds field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetFlexibleGpuIds() []string { - if o == nil || o.FlexibleGpuIds == nil { - var ret []string - return ret - } - return *o.FlexibleGpuIds -} - -// GetFlexibleGpuIdsOk returns a tuple with the FlexibleGpuIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetFlexibleGpuIdsOk() ([]string, bool) { - if o == nil || o.FlexibleGpuIds == nil { - var ret []string - return ret, false - } - return *o.FlexibleGpuIds, true -} - -// HasFlexibleGpuIds returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasFlexibleGpuIds() bool { - if o != nil && o.FlexibleGpuIds != nil { - return true - } - - return false -} - -// SetFlexibleGpuIds gets a reference to the given []string and assigns it to the FlexibleGpuIds field. -func (o *FiltersFlexibleGpu) SetFlexibleGpuIds(v []string) { - o.FlexibleGpuIds = &v -} - -// GetModelNames returns the ModelNames field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetModelNames() []string { - if o == nil || o.ModelNames == nil { - var ret []string - return ret - } - return *o.ModelNames -} - -// GetModelNamesOk returns a tuple with the ModelNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetModelNamesOk() ([]string, bool) { - if o == nil || o.ModelNames == nil { - var ret []string - return ret, false - } - return *o.ModelNames, true -} - -// HasModelNames returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasModelNames() bool { - if o != nil && o.ModelNames != nil { - return true - } - - return false -} - -// SetModelNames gets a reference to the given []string and assigns it to the ModelNames field. -func (o *FiltersFlexibleGpu) SetModelNames(v []string) { - o.ModelNames = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersFlexibleGpu) SetStates(v []string) { - o.States = &v -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *FiltersFlexibleGpu) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -// GetVmIds returns the VmIds field value if set, zero value otherwise. -func (o *FiltersFlexibleGpu) GetVmIds() []string { - if o == nil || o.VmIds == nil { - var ret []string - return ret - } - return *o.VmIds -} - -// GetVmIdsOk returns a tuple with the VmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersFlexibleGpu) GetVmIdsOk() ([]string, bool) { - if o == nil || o.VmIds == nil { - var ret []string - return ret, false - } - return *o.VmIds, true -} - -// HasVmIds returns a boolean if a field has been set. -func (o *FiltersFlexibleGpu) HasVmIds() bool { - if o != nil && o.VmIds != nil { - return true - } - - return false -} - -// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. -func (o *FiltersFlexibleGpu) SetVmIds(v []string) { - o.VmIds = &v -} - -type NullableFiltersFlexibleGpu struct { - Value FiltersFlexibleGpu - ExplicitNull bool -} - -func (v NullableFiltersFlexibleGpu) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersFlexibleGpu) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_image.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_image.go deleted file mode 100644 index 169c1ea5f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_image.go +++ /dev/null @@ -1,778 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersImage One or more filters. -type FiltersImage struct { - // The account aliases of the owners of the OMIs. - AccountAliases *[]string `json:"AccountAliases,omitempty"` - // The account IDs of the owners of the OMIs. By default, all the OMIs for which you have launch permissions are described. - AccountIds *[]string `json:"AccountIds,omitempty"` - // The architectures of the OMIs (`i386` \\| `x86_64`). - Architectures *[]string `json:"Architectures,omitempty"` - // Indicates whether the block device mapping is deleted when terminating the VM. - BlockDeviceMappingDeleteOnVmDeletion *bool `json:"BlockDeviceMappingDeleteOnVmDeletion,omitempty"` - // The device names for the volumes. - BlockDeviceMappingDeviceNames *[]string `json:"BlockDeviceMappingDeviceNames,omitempty"` - // The IDs of the snapshots used to create the volumes. - BlockDeviceMappingSnapshotIds *[]string `json:"BlockDeviceMappingSnapshotIds,omitempty"` - // The sizes of the volumes, in gibibytes (GiB). - BlockDeviceMappingVolumeSizes *[]int64 `json:"BlockDeviceMappingVolumeSizes,omitempty"` - // The types of volumes (`standard` \\| `gp2` \\| `io1`). - BlockDeviceMappingVolumeTypes *[]string `json:"BlockDeviceMappingVolumeTypes,omitempty"` - // The descriptions of the OMIs, provided when they were created. - Descriptions *[]string `json:"Descriptions,omitempty"` - // The locations where the OMI files are stored on Object Storage Unit (OSU). - FileLocations *[]string `json:"FileLocations,omitempty"` - // The IDs of the OMIs. - ImageIds *[]string `json:"ImageIds,omitempty"` - // The names of the OMIs, provided when they were created. - ImageNames *[]string `json:"ImageNames,omitempty"` - // The account IDs of the users who have launch permissions for the OMIs. - PermissionsToLaunchAccountIds *[]string `json:"PermissionsToLaunchAccountIds,omitempty"` - // If `true`, lists all public OMIs. If `false`, lists all private OMIs. - PermissionsToLaunchGlobalPermission *bool `json:"PermissionsToLaunchGlobalPermission,omitempty"` - // The device names of the root devices (for example, `/dev/sda1`). - RootDeviceNames *[]string `json:"RootDeviceNames,omitempty"` - // The types of root device used by the OMIs (always `bsu`). - RootDeviceTypes *[]string `json:"RootDeviceTypes,omitempty"` - // The states of the OMIs (`pending` \\| `available` \\| `failed`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the OMIs. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the OMIs. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the OMIs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The virtualization types (always `hvm`). - VirtualizationTypes *[]string `json:"VirtualizationTypes,omitempty"` -} - -// GetAccountAliases returns the AccountAliases field value if set, zero value otherwise. -func (o *FiltersImage) GetAccountAliases() []string { - if o == nil || o.AccountAliases == nil { - var ret []string - return ret - } - return *o.AccountAliases -} - -// GetAccountAliasesOk returns a tuple with the AccountAliases field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetAccountAliasesOk() ([]string, bool) { - if o == nil || o.AccountAliases == nil { - var ret []string - return ret, false - } - return *o.AccountAliases, true -} - -// HasAccountAliases returns a boolean if a field has been set. -func (o *FiltersImage) HasAccountAliases() bool { - if o != nil && o.AccountAliases != nil { - return true - } - - return false -} - -// SetAccountAliases gets a reference to the given []string and assigns it to the AccountAliases field. -func (o *FiltersImage) SetAccountAliases(v []string) { - o.AccountAliases = &v -} - -// GetAccountIds returns the AccountIds field value if set, zero value otherwise. -func (o *FiltersImage) GetAccountIds() []string { - if o == nil || o.AccountIds == nil { - var ret []string - return ret - } - return *o.AccountIds -} - -// GetAccountIdsOk returns a tuple with the AccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetAccountIdsOk() ([]string, bool) { - if o == nil || o.AccountIds == nil { - var ret []string - return ret, false - } - return *o.AccountIds, true -} - -// HasAccountIds returns a boolean if a field has been set. -func (o *FiltersImage) HasAccountIds() bool { - if o != nil && o.AccountIds != nil { - return true - } - - return false -} - -// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. -func (o *FiltersImage) SetAccountIds(v []string) { - o.AccountIds = &v -} - -// GetArchitectures returns the Architectures field value if set, zero value otherwise. -func (o *FiltersImage) GetArchitectures() []string { - if o == nil || o.Architectures == nil { - var ret []string - return ret - } - return *o.Architectures -} - -// GetArchitecturesOk returns a tuple with the Architectures field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetArchitecturesOk() ([]string, bool) { - if o == nil || o.Architectures == nil { - var ret []string - return ret, false - } - return *o.Architectures, true -} - -// HasArchitectures returns a boolean if a field has been set. -func (o *FiltersImage) HasArchitectures() bool { - if o != nil && o.Architectures != nil { - return true - } - - return false -} - -// SetArchitectures gets a reference to the given []string and assigns it to the Architectures field. -func (o *FiltersImage) SetArchitectures(v []string) { - o.Architectures = &v -} - -// GetBlockDeviceMappingDeleteOnVmDeletion returns the BlockDeviceMappingDeleteOnVmDeletion field value if set, zero value otherwise. -func (o *FiltersImage) GetBlockDeviceMappingDeleteOnVmDeletion() bool { - if o == nil || o.BlockDeviceMappingDeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.BlockDeviceMappingDeleteOnVmDeletion -} - -// GetBlockDeviceMappingDeleteOnVmDeletionOk returns a tuple with the BlockDeviceMappingDeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetBlockDeviceMappingDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.BlockDeviceMappingDeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.BlockDeviceMappingDeleteOnVmDeletion, true -} - -// HasBlockDeviceMappingDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *FiltersImage) HasBlockDeviceMappingDeleteOnVmDeletion() bool { - if o != nil && o.BlockDeviceMappingDeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetBlockDeviceMappingDeleteOnVmDeletion gets a reference to the given bool and assigns it to the BlockDeviceMappingDeleteOnVmDeletion field. -func (o *FiltersImage) SetBlockDeviceMappingDeleteOnVmDeletion(v bool) { - o.BlockDeviceMappingDeleteOnVmDeletion = &v -} - -// GetBlockDeviceMappingDeviceNames returns the BlockDeviceMappingDeviceNames field value if set, zero value otherwise. -func (o *FiltersImage) GetBlockDeviceMappingDeviceNames() []string { - if o == nil || o.BlockDeviceMappingDeviceNames == nil { - var ret []string - return ret - } - return *o.BlockDeviceMappingDeviceNames -} - -// GetBlockDeviceMappingDeviceNamesOk returns a tuple with the BlockDeviceMappingDeviceNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetBlockDeviceMappingDeviceNamesOk() ([]string, bool) { - if o == nil || o.BlockDeviceMappingDeviceNames == nil { - var ret []string - return ret, false - } - return *o.BlockDeviceMappingDeviceNames, true -} - -// HasBlockDeviceMappingDeviceNames returns a boolean if a field has been set. -func (o *FiltersImage) HasBlockDeviceMappingDeviceNames() bool { - if o != nil && o.BlockDeviceMappingDeviceNames != nil { - return true - } - - return false -} - -// SetBlockDeviceMappingDeviceNames gets a reference to the given []string and assigns it to the BlockDeviceMappingDeviceNames field. -func (o *FiltersImage) SetBlockDeviceMappingDeviceNames(v []string) { - o.BlockDeviceMappingDeviceNames = &v -} - -// GetBlockDeviceMappingSnapshotIds returns the BlockDeviceMappingSnapshotIds field value if set, zero value otherwise. -func (o *FiltersImage) GetBlockDeviceMappingSnapshotIds() []string { - if o == nil || o.BlockDeviceMappingSnapshotIds == nil { - var ret []string - return ret - } - return *o.BlockDeviceMappingSnapshotIds -} - -// GetBlockDeviceMappingSnapshotIdsOk returns a tuple with the BlockDeviceMappingSnapshotIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetBlockDeviceMappingSnapshotIdsOk() ([]string, bool) { - if o == nil || o.BlockDeviceMappingSnapshotIds == nil { - var ret []string - return ret, false - } - return *o.BlockDeviceMappingSnapshotIds, true -} - -// HasBlockDeviceMappingSnapshotIds returns a boolean if a field has been set. -func (o *FiltersImage) HasBlockDeviceMappingSnapshotIds() bool { - if o != nil && o.BlockDeviceMappingSnapshotIds != nil { - return true - } - - return false -} - -// SetBlockDeviceMappingSnapshotIds gets a reference to the given []string and assigns it to the BlockDeviceMappingSnapshotIds field. -func (o *FiltersImage) SetBlockDeviceMappingSnapshotIds(v []string) { - o.BlockDeviceMappingSnapshotIds = &v -} - -// GetBlockDeviceMappingVolumeSizes returns the BlockDeviceMappingVolumeSizes field value if set, zero value otherwise. -func (o *FiltersImage) GetBlockDeviceMappingVolumeSizes() []int64 { - if o == nil || o.BlockDeviceMappingVolumeSizes == nil { - var ret []int64 - return ret - } - return *o.BlockDeviceMappingVolumeSizes -} - -// GetBlockDeviceMappingVolumeSizesOk returns a tuple with the BlockDeviceMappingVolumeSizes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetBlockDeviceMappingVolumeSizesOk() ([]int64, bool) { - if o == nil || o.BlockDeviceMappingVolumeSizes == nil { - var ret []int64 - return ret, false - } - return *o.BlockDeviceMappingVolumeSizes, true -} - -// HasBlockDeviceMappingVolumeSizes returns a boolean if a field has been set. -func (o *FiltersImage) HasBlockDeviceMappingVolumeSizes() bool { - if o != nil && o.BlockDeviceMappingVolumeSizes != nil { - return true - } - - return false -} - -// SetBlockDeviceMappingVolumeSizes gets a reference to the given []int64 and assigns it to the BlockDeviceMappingVolumeSizes field. -func (o *FiltersImage) SetBlockDeviceMappingVolumeSizes(v []int64) { - o.BlockDeviceMappingVolumeSizes = &v -} - -// GetBlockDeviceMappingVolumeTypes returns the BlockDeviceMappingVolumeTypes field value if set, zero value otherwise. -func (o *FiltersImage) GetBlockDeviceMappingVolumeTypes() []string { - if o == nil || o.BlockDeviceMappingVolumeTypes == nil { - var ret []string - return ret - } - return *o.BlockDeviceMappingVolumeTypes -} - -// GetBlockDeviceMappingVolumeTypesOk returns a tuple with the BlockDeviceMappingVolumeTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetBlockDeviceMappingVolumeTypesOk() ([]string, bool) { - if o == nil || o.BlockDeviceMappingVolumeTypes == nil { - var ret []string - return ret, false - } - return *o.BlockDeviceMappingVolumeTypes, true -} - -// HasBlockDeviceMappingVolumeTypes returns a boolean if a field has been set. -func (o *FiltersImage) HasBlockDeviceMappingVolumeTypes() bool { - if o != nil && o.BlockDeviceMappingVolumeTypes != nil { - return true - } - - return false -} - -// SetBlockDeviceMappingVolumeTypes gets a reference to the given []string and assigns it to the BlockDeviceMappingVolumeTypes field. -func (o *FiltersImage) SetBlockDeviceMappingVolumeTypes(v []string) { - o.BlockDeviceMappingVolumeTypes = &v -} - -// GetDescriptions returns the Descriptions field value if set, zero value otherwise. -func (o *FiltersImage) GetDescriptions() []string { - if o == nil || o.Descriptions == nil { - var ret []string - return ret - } - return *o.Descriptions -} - -// GetDescriptionsOk returns a tuple with the Descriptions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetDescriptionsOk() ([]string, bool) { - if o == nil || o.Descriptions == nil { - var ret []string - return ret, false - } - return *o.Descriptions, true -} - -// HasDescriptions returns a boolean if a field has been set. -func (o *FiltersImage) HasDescriptions() bool { - if o != nil && o.Descriptions != nil { - return true - } - - return false -} - -// SetDescriptions gets a reference to the given []string and assigns it to the Descriptions field. -func (o *FiltersImage) SetDescriptions(v []string) { - o.Descriptions = &v -} - -// GetFileLocations returns the FileLocations field value if set, zero value otherwise. -func (o *FiltersImage) GetFileLocations() []string { - if o == nil || o.FileLocations == nil { - var ret []string - return ret - } - return *o.FileLocations -} - -// GetFileLocationsOk returns a tuple with the FileLocations field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetFileLocationsOk() ([]string, bool) { - if o == nil || o.FileLocations == nil { - var ret []string - return ret, false - } - return *o.FileLocations, true -} - -// HasFileLocations returns a boolean if a field has been set. -func (o *FiltersImage) HasFileLocations() bool { - if o != nil && o.FileLocations != nil { - return true - } - - return false -} - -// SetFileLocations gets a reference to the given []string and assigns it to the FileLocations field. -func (o *FiltersImage) SetFileLocations(v []string) { - o.FileLocations = &v -} - -// GetImageIds returns the ImageIds field value if set, zero value otherwise. -func (o *FiltersImage) GetImageIds() []string { - if o == nil || o.ImageIds == nil { - var ret []string - return ret - } - return *o.ImageIds -} - -// GetImageIdsOk returns a tuple with the ImageIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetImageIdsOk() ([]string, bool) { - if o == nil || o.ImageIds == nil { - var ret []string - return ret, false - } - return *o.ImageIds, true -} - -// HasImageIds returns a boolean if a field has been set. -func (o *FiltersImage) HasImageIds() bool { - if o != nil && o.ImageIds != nil { - return true - } - - return false -} - -// SetImageIds gets a reference to the given []string and assigns it to the ImageIds field. -func (o *FiltersImage) SetImageIds(v []string) { - o.ImageIds = &v -} - -// GetImageNames returns the ImageNames field value if set, zero value otherwise. -func (o *FiltersImage) GetImageNames() []string { - if o == nil || o.ImageNames == nil { - var ret []string - return ret - } - return *o.ImageNames -} - -// GetImageNamesOk returns a tuple with the ImageNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetImageNamesOk() ([]string, bool) { - if o == nil || o.ImageNames == nil { - var ret []string - return ret, false - } - return *o.ImageNames, true -} - -// HasImageNames returns a boolean if a field has been set. -func (o *FiltersImage) HasImageNames() bool { - if o != nil && o.ImageNames != nil { - return true - } - - return false -} - -// SetImageNames gets a reference to the given []string and assigns it to the ImageNames field. -func (o *FiltersImage) SetImageNames(v []string) { - o.ImageNames = &v -} - -// GetPermissionsToLaunchAccountIds returns the PermissionsToLaunchAccountIds field value if set, zero value otherwise. -func (o *FiltersImage) GetPermissionsToLaunchAccountIds() []string { - if o == nil || o.PermissionsToLaunchAccountIds == nil { - var ret []string - return ret - } - return *o.PermissionsToLaunchAccountIds -} - -// GetPermissionsToLaunchAccountIdsOk returns a tuple with the PermissionsToLaunchAccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetPermissionsToLaunchAccountIdsOk() ([]string, bool) { - if o == nil || o.PermissionsToLaunchAccountIds == nil { - var ret []string - return ret, false - } - return *o.PermissionsToLaunchAccountIds, true -} - -// HasPermissionsToLaunchAccountIds returns a boolean if a field has been set. -func (o *FiltersImage) HasPermissionsToLaunchAccountIds() bool { - if o != nil && o.PermissionsToLaunchAccountIds != nil { - return true - } - - return false -} - -// SetPermissionsToLaunchAccountIds gets a reference to the given []string and assigns it to the PermissionsToLaunchAccountIds field. -func (o *FiltersImage) SetPermissionsToLaunchAccountIds(v []string) { - o.PermissionsToLaunchAccountIds = &v -} - -// GetPermissionsToLaunchGlobalPermission returns the PermissionsToLaunchGlobalPermission field value if set, zero value otherwise. -func (o *FiltersImage) GetPermissionsToLaunchGlobalPermission() bool { - if o == nil || o.PermissionsToLaunchGlobalPermission == nil { - var ret bool - return ret - } - return *o.PermissionsToLaunchGlobalPermission -} - -// GetPermissionsToLaunchGlobalPermissionOk returns a tuple with the PermissionsToLaunchGlobalPermission field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetPermissionsToLaunchGlobalPermissionOk() (bool, bool) { - if o == nil || o.PermissionsToLaunchGlobalPermission == nil { - var ret bool - return ret, false - } - return *o.PermissionsToLaunchGlobalPermission, true -} - -// HasPermissionsToLaunchGlobalPermission returns a boolean if a field has been set. -func (o *FiltersImage) HasPermissionsToLaunchGlobalPermission() bool { - if o != nil && o.PermissionsToLaunchGlobalPermission != nil { - return true - } - - return false -} - -// SetPermissionsToLaunchGlobalPermission gets a reference to the given bool and assigns it to the PermissionsToLaunchGlobalPermission field. -func (o *FiltersImage) SetPermissionsToLaunchGlobalPermission(v bool) { - o.PermissionsToLaunchGlobalPermission = &v -} - -// GetRootDeviceNames returns the RootDeviceNames field value if set, zero value otherwise. -func (o *FiltersImage) GetRootDeviceNames() []string { - if o == nil || o.RootDeviceNames == nil { - var ret []string - return ret - } - return *o.RootDeviceNames -} - -// GetRootDeviceNamesOk returns a tuple with the RootDeviceNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetRootDeviceNamesOk() ([]string, bool) { - if o == nil || o.RootDeviceNames == nil { - var ret []string - return ret, false - } - return *o.RootDeviceNames, true -} - -// HasRootDeviceNames returns a boolean if a field has been set. -func (o *FiltersImage) HasRootDeviceNames() bool { - if o != nil && o.RootDeviceNames != nil { - return true - } - - return false -} - -// SetRootDeviceNames gets a reference to the given []string and assigns it to the RootDeviceNames field. -func (o *FiltersImage) SetRootDeviceNames(v []string) { - o.RootDeviceNames = &v -} - -// GetRootDeviceTypes returns the RootDeviceTypes field value if set, zero value otherwise. -func (o *FiltersImage) GetRootDeviceTypes() []string { - if o == nil || o.RootDeviceTypes == nil { - var ret []string - return ret - } - return *o.RootDeviceTypes -} - -// GetRootDeviceTypesOk returns a tuple with the RootDeviceTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetRootDeviceTypesOk() ([]string, bool) { - if o == nil || o.RootDeviceTypes == nil { - var ret []string - return ret, false - } - return *o.RootDeviceTypes, true -} - -// HasRootDeviceTypes returns a boolean if a field has been set. -func (o *FiltersImage) HasRootDeviceTypes() bool { - if o != nil && o.RootDeviceTypes != nil { - return true - } - - return false -} - -// SetRootDeviceTypes gets a reference to the given []string and assigns it to the RootDeviceTypes field. -func (o *FiltersImage) SetRootDeviceTypes(v []string) { - o.RootDeviceTypes = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersImage) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersImage) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersImage) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersImage) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersImage) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersImage) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersImage) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersImage) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersImage) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersImage) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersImage) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersImage) SetTags(v []string) { - o.Tags = &v -} - -// GetVirtualizationTypes returns the VirtualizationTypes field value if set, zero value otherwise. -func (o *FiltersImage) GetVirtualizationTypes() []string { - if o == nil || o.VirtualizationTypes == nil { - var ret []string - return ret - } - return *o.VirtualizationTypes -} - -// GetVirtualizationTypesOk returns a tuple with the VirtualizationTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersImage) GetVirtualizationTypesOk() ([]string, bool) { - if o == nil || o.VirtualizationTypes == nil { - var ret []string - return ret, false - } - return *o.VirtualizationTypes, true -} - -// HasVirtualizationTypes returns a boolean if a field has been set. -func (o *FiltersImage) HasVirtualizationTypes() bool { - if o != nil && o.VirtualizationTypes != nil { - return true - } - - return false -} - -// SetVirtualizationTypes gets a reference to the given []string and assigns it to the VirtualizationTypes field. -func (o *FiltersImage) SetVirtualizationTypes(v []string) { - o.VirtualizationTypes = &v -} - -type NullableFiltersImage struct { - Value FiltersImage - ExplicitNull bool -} - -func (v NullableFiltersImage) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersImage) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_internet_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_internet_service.go deleted file mode 100644 index 4ac1bf7ca..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_internet_service.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersInternetService One or more filters. -type FiltersInternetService struct { - // The IDs of the Internet services. - InternetServiceIds *[]string `json:"InternetServiceIds,omitempty"` - // The keys of the tags associated with the Internet services. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the Internet services. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the Internet services, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetInternetServiceIds returns the InternetServiceIds field value if set, zero value otherwise. -func (o *FiltersInternetService) GetInternetServiceIds() []string { - if o == nil || o.InternetServiceIds == nil { - var ret []string - return ret - } - return *o.InternetServiceIds -} - -// GetInternetServiceIdsOk returns a tuple with the InternetServiceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersInternetService) GetInternetServiceIdsOk() ([]string, bool) { - if o == nil || o.InternetServiceIds == nil { - var ret []string - return ret, false - } - return *o.InternetServiceIds, true -} - -// HasInternetServiceIds returns a boolean if a field has been set. -func (o *FiltersInternetService) HasInternetServiceIds() bool { - if o != nil && o.InternetServiceIds != nil { - return true - } - - return false -} - -// SetInternetServiceIds gets a reference to the given []string and assigns it to the InternetServiceIds field. -func (o *FiltersInternetService) SetInternetServiceIds(v []string) { - o.InternetServiceIds = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersInternetService) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersInternetService) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersInternetService) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersInternetService) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersInternetService) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersInternetService) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersInternetService) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersInternetService) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersInternetService) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersInternetService) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersInternetService) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersInternetService) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersInternetService struct { - Value FiltersInternetService - ExplicitNull bool -} - -func (v NullableFiltersInternetService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersInternetService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_keypair.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_keypair.go deleted file mode 100644 index a9afa7535..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_keypair.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersKeypair One or more filters. -type FiltersKeypair struct { - // The fingerprints of the keypairs. - KeypairFingerprints *[]string `json:"KeypairFingerprints,omitempty"` - // The names of the keypairs. - KeypairNames *[]string `json:"KeypairNames,omitempty"` -} - -// GetKeypairFingerprints returns the KeypairFingerprints field value if set, zero value otherwise. -func (o *FiltersKeypair) GetKeypairFingerprints() []string { - if o == nil || o.KeypairFingerprints == nil { - var ret []string - return ret - } - return *o.KeypairFingerprints -} - -// GetKeypairFingerprintsOk returns a tuple with the KeypairFingerprints field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersKeypair) GetKeypairFingerprintsOk() ([]string, bool) { - if o == nil || o.KeypairFingerprints == nil { - var ret []string - return ret, false - } - return *o.KeypairFingerprints, true -} - -// HasKeypairFingerprints returns a boolean if a field has been set. -func (o *FiltersKeypair) HasKeypairFingerprints() bool { - if o != nil && o.KeypairFingerprints != nil { - return true - } - - return false -} - -// SetKeypairFingerprints gets a reference to the given []string and assigns it to the KeypairFingerprints field. -func (o *FiltersKeypair) SetKeypairFingerprints(v []string) { - o.KeypairFingerprints = &v -} - -// GetKeypairNames returns the KeypairNames field value if set, zero value otherwise. -func (o *FiltersKeypair) GetKeypairNames() []string { - if o == nil || o.KeypairNames == nil { - var ret []string - return ret - } - return *o.KeypairNames -} - -// GetKeypairNamesOk returns a tuple with the KeypairNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersKeypair) GetKeypairNamesOk() ([]string, bool) { - if o == nil || o.KeypairNames == nil { - var ret []string - return ret, false - } - return *o.KeypairNames, true -} - -// HasKeypairNames returns a boolean if a field has been set. -func (o *FiltersKeypair) HasKeypairNames() bool { - if o != nil && o.KeypairNames != nil { - return true - } - - return false -} - -// SetKeypairNames gets a reference to the given []string and assigns it to the KeypairNames field. -func (o *FiltersKeypair) SetKeypairNames(v []string) { - o.KeypairNames = &v -} - -type NullableFiltersKeypair struct { - Value FiltersKeypair - ExplicitNull bool -} - -func (v NullableFiltersKeypair) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersKeypair) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_listener_rule.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_listener_rule.go deleted file mode 100644 index bd68cb799..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_listener_rule.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersListenerRule One or more filters. -type FiltersListenerRule struct { - // The names of the listener rules. - ListenerRuleNames *[]string `json:"ListenerRuleNames,omitempty"` -} - -// GetListenerRuleNames returns the ListenerRuleNames field value if set, zero value otherwise. -func (o *FiltersListenerRule) GetListenerRuleNames() []string { - if o == nil || o.ListenerRuleNames == nil { - var ret []string - return ret - } - return *o.ListenerRuleNames -} - -// GetListenerRuleNamesOk returns a tuple with the ListenerRuleNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersListenerRule) GetListenerRuleNamesOk() ([]string, bool) { - if o == nil || o.ListenerRuleNames == nil { - var ret []string - return ret, false - } - return *o.ListenerRuleNames, true -} - -// HasListenerRuleNames returns a boolean if a field has been set. -func (o *FiltersListenerRule) HasListenerRuleNames() bool { - if o != nil && o.ListenerRuleNames != nil { - return true - } - - return false -} - -// SetListenerRuleNames gets a reference to the given []string and assigns it to the ListenerRuleNames field. -func (o *FiltersListenerRule) SetListenerRuleNames(v []string) { - o.ListenerRuleNames = &v -} - -type NullableFiltersListenerRule struct { - Value FiltersListenerRule - ExplicitNull bool -} - -func (v NullableFiltersListenerRule) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersListenerRule) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_load_balancer.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_load_balancer.go deleted file mode 100644 index 72984bb92..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_load_balancer.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersLoadBalancer One or more filters. -type FiltersLoadBalancer struct { - // The names of the load balancers. - LoadBalancerNames *[]string `json:"LoadBalancerNames,omitempty"` -} - -// GetLoadBalancerNames returns the LoadBalancerNames field value if set, zero value otherwise. -func (o *FiltersLoadBalancer) GetLoadBalancerNames() []string { - if o == nil || o.LoadBalancerNames == nil { - var ret []string - return ret - } - return *o.LoadBalancerNames -} - -// GetLoadBalancerNamesOk returns a tuple with the LoadBalancerNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersLoadBalancer) GetLoadBalancerNamesOk() ([]string, bool) { - if o == nil || o.LoadBalancerNames == nil { - var ret []string - return ret, false - } - return *o.LoadBalancerNames, true -} - -// HasLoadBalancerNames returns a boolean if a field has been set. -func (o *FiltersLoadBalancer) HasLoadBalancerNames() bool { - if o != nil && o.LoadBalancerNames != nil { - return true - } - - return false -} - -// SetLoadBalancerNames gets a reference to the given []string and assigns it to the LoadBalancerNames field. -func (o *FiltersLoadBalancer) SetLoadBalancerNames(v []string) { - o.LoadBalancerNames = &v -} - -type NullableFiltersLoadBalancer struct { - Value FiltersLoadBalancer - ExplicitNull bool -} - -func (v NullableFiltersLoadBalancer) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersLoadBalancer) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nat_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nat_service.go deleted file mode 100644 index 670434924..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nat_service.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersNatService One or more filters. -type FiltersNatService struct { - // The IDs of the NAT services. - NatServiceIds *[]string `json:"NatServiceIds,omitempty"` - // The IDs of the Nets in which the NAT services are. - NetIds *[]string `json:"NetIds,omitempty"` - // The states of the NAT services (`pending` \\| `available` \\| `deleting` \\| `deleted`). - States *[]string `json:"States,omitempty"` - // The IDs of the Subnets in which the NAT services are. - SubnetIds *[]string `json:"SubnetIds,omitempty"` - // The keys of the tags associated with the NAT services. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the NAT services. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the NAT services, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetNatServiceIds returns the NatServiceIds field value if set, zero value otherwise. -func (o *FiltersNatService) GetNatServiceIds() []string { - if o == nil || o.NatServiceIds == nil { - var ret []string - return ret - } - return *o.NatServiceIds -} - -// GetNatServiceIdsOk returns a tuple with the NatServiceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetNatServiceIdsOk() ([]string, bool) { - if o == nil || o.NatServiceIds == nil { - var ret []string - return ret, false - } - return *o.NatServiceIds, true -} - -// HasNatServiceIds returns a boolean if a field has been set. -func (o *FiltersNatService) HasNatServiceIds() bool { - if o != nil && o.NatServiceIds != nil { - return true - } - - return false -} - -// SetNatServiceIds gets a reference to the given []string and assigns it to the NatServiceIds field. -func (o *FiltersNatService) SetNatServiceIds(v []string) { - o.NatServiceIds = &v -} - -// GetNetIds returns the NetIds field value if set, zero value otherwise. -func (o *FiltersNatService) GetNetIds() []string { - if o == nil || o.NetIds == nil { - var ret []string - return ret - } - return *o.NetIds -} - -// GetNetIdsOk returns a tuple with the NetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetNetIdsOk() ([]string, bool) { - if o == nil || o.NetIds == nil { - var ret []string - return ret, false - } - return *o.NetIds, true -} - -// HasNetIds returns a boolean if a field has been set. -func (o *FiltersNatService) HasNetIds() bool { - if o != nil && o.NetIds != nil { - return true - } - - return false -} - -// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. -func (o *FiltersNatService) SetNetIds(v []string) { - o.NetIds = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersNatService) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersNatService) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersNatService) SetStates(v []string) { - o.States = &v -} - -// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. -func (o *FiltersNatService) GetSubnetIds() []string { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret - } - return *o.SubnetIds -} - -// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetSubnetIdsOk() ([]string, bool) { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret, false - } - return *o.SubnetIds, true -} - -// HasSubnetIds returns a boolean if a field has been set. -func (o *FiltersNatService) HasSubnetIds() bool { - if o != nil && o.SubnetIds != nil { - return true - } - - return false -} - -// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. -func (o *FiltersNatService) SetSubnetIds(v []string) { - o.SubnetIds = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersNatService) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersNatService) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersNatService) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersNatService) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersNatService) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersNatService) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersNatService) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNatService) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersNatService) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersNatService) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersNatService struct { - Value FiltersNatService - ExplicitNull bool -} - -func (v NullableFiltersNatService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersNatService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net.go deleted file mode 100644 index ab0aecf3b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersNet One or more filters. -type FiltersNet struct { - // The IDs of the DHCP options sets. - DhcpOptionsSetIds *[]string `json:"DhcpOptionsSetIds,omitempty"` - // The IP ranges for the Nets, in CIDR notation (for example, 10.0.0.0/16). - IpRanges *[]string `json:"IpRanges,omitempty"` - // The IDs of the Nets. - NetIds *[]string `json:"NetIds,omitempty"` - // The states of the Nets (`pending` \\| `available`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the Nets. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the Nets. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the Nets, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetDhcpOptionsSetIds returns the DhcpOptionsSetIds field value if set, zero value otherwise. -func (o *FiltersNet) GetDhcpOptionsSetIds() []string { - if o == nil || o.DhcpOptionsSetIds == nil { - var ret []string - return ret - } - return *o.DhcpOptionsSetIds -} - -// GetDhcpOptionsSetIdsOk returns a tuple with the DhcpOptionsSetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetDhcpOptionsSetIdsOk() ([]string, bool) { - if o == nil || o.DhcpOptionsSetIds == nil { - var ret []string - return ret, false - } - return *o.DhcpOptionsSetIds, true -} - -// HasDhcpOptionsSetIds returns a boolean if a field has been set. -func (o *FiltersNet) HasDhcpOptionsSetIds() bool { - if o != nil && o.DhcpOptionsSetIds != nil { - return true - } - - return false -} - -// SetDhcpOptionsSetIds gets a reference to the given []string and assigns it to the DhcpOptionsSetIds field. -func (o *FiltersNet) SetDhcpOptionsSetIds(v []string) { - o.DhcpOptionsSetIds = &v -} - -// GetIpRanges returns the IpRanges field value if set, zero value otherwise. -func (o *FiltersNet) GetIpRanges() []string { - if o == nil || o.IpRanges == nil { - var ret []string - return ret - } - return *o.IpRanges -} - -// GetIpRangesOk returns a tuple with the IpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetIpRangesOk() ([]string, bool) { - if o == nil || o.IpRanges == nil { - var ret []string - return ret, false - } - return *o.IpRanges, true -} - -// HasIpRanges returns a boolean if a field has been set. -func (o *FiltersNet) HasIpRanges() bool { - if o != nil && o.IpRanges != nil { - return true - } - - return false -} - -// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. -func (o *FiltersNet) SetIpRanges(v []string) { - o.IpRanges = &v -} - -// GetNetIds returns the NetIds field value if set, zero value otherwise. -func (o *FiltersNet) GetNetIds() []string { - if o == nil || o.NetIds == nil { - var ret []string - return ret - } - return *o.NetIds -} - -// GetNetIdsOk returns a tuple with the NetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetNetIdsOk() ([]string, bool) { - if o == nil || o.NetIds == nil { - var ret []string - return ret, false - } - return *o.NetIds, true -} - -// HasNetIds returns a boolean if a field has been set. -func (o *FiltersNet) HasNetIds() bool { - if o != nil && o.NetIds != nil { - return true - } - - return false -} - -// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. -func (o *FiltersNet) SetNetIds(v []string) { - o.NetIds = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersNet) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersNet) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersNet) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersNet) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersNet) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersNet) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersNet) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersNet) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersNet) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersNet) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNet) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersNet) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersNet) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersNet struct { - Value FiltersNet - ExplicitNull bool -} - -func (v NullableFiltersNet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersNet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_access_point.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_access_point.go deleted file mode 100644 index 337012e39..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_access_point.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersNetAccessPoint One or more filters. -type FiltersNetAccessPoint struct { - // The IDs of the Net access points. - NetAccessPointIds *[]string `json:"NetAccessPointIds,omitempty"` - // The IDs of the Nets. - NetIds *[]string `json:"NetIds,omitempty"` - // The names of the prefix lists corresponding to the services. For more information, see [DescribePrefixLists](#describeprefixlists) - ServiceNames *[]string `json:"ServiceNames,omitempty"` - // The states of the Net access points (`pending` \\| `available` \\| `deleting` \\| `deleted`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the Net access points. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the Net access points. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the Net access points, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetNetAccessPointIds returns the NetAccessPointIds field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetNetAccessPointIds() []string { - if o == nil || o.NetAccessPointIds == nil { - var ret []string - return ret - } - return *o.NetAccessPointIds -} - -// GetNetAccessPointIdsOk returns a tuple with the NetAccessPointIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetNetAccessPointIdsOk() ([]string, bool) { - if o == nil || o.NetAccessPointIds == nil { - var ret []string - return ret, false - } - return *o.NetAccessPointIds, true -} - -// HasNetAccessPointIds returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasNetAccessPointIds() bool { - if o != nil && o.NetAccessPointIds != nil { - return true - } - - return false -} - -// SetNetAccessPointIds gets a reference to the given []string and assigns it to the NetAccessPointIds field. -func (o *FiltersNetAccessPoint) SetNetAccessPointIds(v []string) { - o.NetAccessPointIds = &v -} - -// GetNetIds returns the NetIds field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetNetIds() []string { - if o == nil || o.NetIds == nil { - var ret []string - return ret - } - return *o.NetIds -} - -// GetNetIdsOk returns a tuple with the NetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetNetIdsOk() ([]string, bool) { - if o == nil || o.NetIds == nil { - var ret []string - return ret, false - } - return *o.NetIds, true -} - -// HasNetIds returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasNetIds() bool { - if o != nil && o.NetIds != nil { - return true - } - - return false -} - -// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. -func (o *FiltersNetAccessPoint) SetNetIds(v []string) { - o.NetIds = &v -} - -// GetServiceNames returns the ServiceNames field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetServiceNames() []string { - if o == nil || o.ServiceNames == nil { - var ret []string - return ret - } - return *o.ServiceNames -} - -// GetServiceNamesOk returns a tuple with the ServiceNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetServiceNamesOk() ([]string, bool) { - if o == nil || o.ServiceNames == nil { - var ret []string - return ret, false - } - return *o.ServiceNames, true -} - -// HasServiceNames returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasServiceNames() bool { - if o != nil && o.ServiceNames != nil { - return true - } - - return false -} - -// SetServiceNames gets a reference to the given []string and assigns it to the ServiceNames field. -func (o *FiltersNetAccessPoint) SetServiceNames(v []string) { - o.ServiceNames = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersNetAccessPoint) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersNetAccessPoint) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersNetAccessPoint) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersNetAccessPoint) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetAccessPoint) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersNetAccessPoint) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersNetAccessPoint) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersNetAccessPoint struct { - Value FiltersNetAccessPoint - ExplicitNull bool -} - -func (v NullableFiltersNetAccessPoint) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersNetAccessPoint) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_peering.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_peering.go deleted file mode 100644 index 93a9af2e8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_net_peering.go +++ /dev/null @@ -1,463 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersNetPeering One or more filters. -type FiltersNetPeering struct { - // The account IDs of the owners of the peer Nets. - AccepterNetAccountIds *[]string `json:"AccepterNetAccountIds,omitempty"` - // The IP ranges of the peer Nets, in CIDR notation (for example, 10.0.0.0/24). - AccepterNetIpRanges *[]string `json:"AccepterNetIpRanges,omitempty"` - // The IDs of the peer Nets. - AccepterNetNetIds *[]string `json:"AccepterNetNetIds,omitempty"` - // The IDs of the Net peering connections. - NetPeeringIds *[]string `json:"NetPeeringIds,omitempty"` - // The account IDs of the owners of the peer Nets. - SourceNetAccountIds *[]string `json:"SourceNetAccountIds,omitempty"` - // The IP ranges of the peer Nets. - SourceNetIpRanges *[]string `json:"SourceNetIpRanges,omitempty"` - // The IDs of the peer Nets. - SourceNetNetIds *[]string `json:"SourceNetNetIds,omitempty"` - // Additional information about the states of the Net peering connections. - StateMessages *[]string `json:"StateMessages,omitempty"` - // The states of the Net peering connections (`pending-acceptance` \\| `active` \\| `rejected` \\| `failed` \\| `expired` \\| `deleted`). - StateNames *[]string `json:"StateNames,omitempty"` - // The keys of the tags associated with the Net peering connections. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the Net peering connections. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the Net peering connections, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetAccepterNetAccountIds returns the AccepterNetAccountIds field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetAccepterNetAccountIds() []string { - if o == nil || o.AccepterNetAccountIds == nil { - var ret []string - return ret - } - return *o.AccepterNetAccountIds -} - -// GetAccepterNetAccountIdsOk returns a tuple with the AccepterNetAccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetAccepterNetAccountIdsOk() ([]string, bool) { - if o == nil || o.AccepterNetAccountIds == nil { - var ret []string - return ret, false - } - return *o.AccepterNetAccountIds, true -} - -// HasAccepterNetAccountIds returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasAccepterNetAccountIds() bool { - if o != nil && o.AccepterNetAccountIds != nil { - return true - } - - return false -} - -// SetAccepterNetAccountIds gets a reference to the given []string and assigns it to the AccepterNetAccountIds field. -func (o *FiltersNetPeering) SetAccepterNetAccountIds(v []string) { - o.AccepterNetAccountIds = &v -} - -// GetAccepterNetIpRanges returns the AccepterNetIpRanges field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetAccepterNetIpRanges() []string { - if o == nil || o.AccepterNetIpRanges == nil { - var ret []string - return ret - } - return *o.AccepterNetIpRanges -} - -// GetAccepterNetIpRangesOk returns a tuple with the AccepterNetIpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetAccepterNetIpRangesOk() ([]string, bool) { - if o == nil || o.AccepterNetIpRanges == nil { - var ret []string - return ret, false - } - return *o.AccepterNetIpRanges, true -} - -// HasAccepterNetIpRanges returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasAccepterNetIpRanges() bool { - if o != nil && o.AccepterNetIpRanges != nil { - return true - } - - return false -} - -// SetAccepterNetIpRanges gets a reference to the given []string and assigns it to the AccepterNetIpRanges field. -func (o *FiltersNetPeering) SetAccepterNetIpRanges(v []string) { - o.AccepterNetIpRanges = &v -} - -// GetAccepterNetNetIds returns the AccepterNetNetIds field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetAccepterNetNetIds() []string { - if o == nil || o.AccepterNetNetIds == nil { - var ret []string - return ret - } - return *o.AccepterNetNetIds -} - -// GetAccepterNetNetIdsOk returns a tuple with the AccepterNetNetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetAccepterNetNetIdsOk() ([]string, bool) { - if o == nil || o.AccepterNetNetIds == nil { - var ret []string - return ret, false - } - return *o.AccepterNetNetIds, true -} - -// HasAccepterNetNetIds returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasAccepterNetNetIds() bool { - if o != nil && o.AccepterNetNetIds != nil { - return true - } - - return false -} - -// SetAccepterNetNetIds gets a reference to the given []string and assigns it to the AccepterNetNetIds field. -func (o *FiltersNetPeering) SetAccepterNetNetIds(v []string) { - o.AccepterNetNetIds = &v -} - -// GetNetPeeringIds returns the NetPeeringIds field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetNetPeeringIds() []string { - if o == nil || o.NetPeeringIds == nil { - var ret []string - return ret - } - return *o.NetPeeringIds -} - -// GetNetPeeringIdsOk returns a tuple with the NetPeeringIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetNetPeeringIdsOk() ([]string, bool) { - if o == nil || o.NetPeeringIds == nil { - var ret []string - return ret, false - } - return *o.NetPeeringIds, true -} - -// HasNetPeeringIds returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasNetPeeringIds() bool { - if o != nil && o.NetPeeringIds != nil { - return true - } - - return false -} - -// SetNetPeeringIds gets a reference to the given []string and assigns it to the NetPeeringIds field. -func (o *FiltersNetPeering) SetNetPeeringIds(v []string) { - o.NetPeeringIds = &v -} - -// GetSourceNetAccountIds returns the SourceNetAccountIds field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetSourceNetAccountIds() []string { - if o == nil || o.SourceNetAccountIds == nil { - var ret []string - return ret - } - return *o.SourceNetAccountIds -} - -// GetSourceNetAccountIdsOk returns a tuple with the SourceNetAccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetSourceNetAccountIdsOk() ([]string, bool) { - if o == nil || o.SourceNetAccountIds == nil { - var ret []string - return ret, false - } - return *o.SourceNetAccountIds, true -} - -// HasSourceNetAccountIds returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasSourceNetAccountIds() bool { - if o != nil && o.SourceNetAccountIds != nil { - return true - } - - return false -} - -// SetSourceNetAccountIds gets a reference to the given []string and assigns it to the SourceNetAccountIds field. -func (o *FiltersNetPeering) SetSourceNetAccountIds(v []string) { - o.SourceNetAccountIds = &v -} - -// GetSourceNetIpRanges returns the SourceNetIpRanges field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetSourceNetIpRanges() []string { - if o == nil || o.SourceNetIpRanges == nil { - var ret []string - return ret - } - return *o.SourceNetIpRanges -} - -// GetSourceNetIpRangesOk returns a tuple with the SourceNetIpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetSourceNetIpRangesOk() ([]string, bool) { - if o == nil || o.SourceNetIpRanges == nil { - var ret []string - return ret, false - } - return *o.SourceNetIpRanges, true -} - -// HasSourceNetIpRanges returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasSourceNetIpRanges() bool { - if o != nil && o.SourceNetIpRanges != nil { - return true - } - - return false -} - -// SetSourceNetIpRanges gets a reference to the given []string and assigns it to the SourceNetIpRanges field. -func (o *FiltersNetPeering) SetSourceNetIpRanges(v []string) { - o.SourceNetIpRanges = &v -} - -// GetSourceNetNetIds returns the SourceNetNetIds field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetSourceNetNetIds() []string { - if o == nil || o.SourceNetNetIds == nil { - var ret []string - return ret - } - return *o.SourceNetNetIds -} - -// GetSourceNetNetIdsOk returns a tuple with the SourceNetNetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetSourceNetNetIdsOk() ([]string, bool) { - if o == nil || o.SourceNetNetIds == nil { - var ret []string - return ret, false - } - return *o.SourceNetNetIds, true -} - -// HasSourceNetNetIds returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasSourceNetNetIds() bool { - if o != nil && o.SourceNetNetIds != nil { - return true - } - - return false -} - -// SetSourceNetNetIds gets a reference to the given []string and assigns it to the SourceNetNetIds field. -func (o *FiltersNetPeering) SetSourceNetNetIds(v []string) { - o.SourceNetNetIds = &v -} - -// GetStateMessages returns the StateMessages field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetStateMessages() []string { - if o == nil || o.StateMessages == nil { - var ret []string - return ret - } - return *o.StateMessages -} - -// GetStateMessagesOk returns a tuple with the StateMessages field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetStateMessagesOk() ([]string, bool) { - if o == nil || o.StateMessages == nil { - var ret []string - return ret, false - } - return *o.StateMessages, true -} - -// HasStateMessages returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasStateMessages() bool { - if o != nil && o.StateMessages != nil { - return true - } - - return false -} - -// SetStateMessages gets a reference to the given []string and assigns it to the StateMessages field. -func (o *FiltersNetPeering) SetStateMessages(v []string) { - o.StateMessages = &v -} - -// GetStateNames returns the StateNames field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetStateNames() []string { - if o == nil || o.StateNames == nil { - var ret []string - return ret - } - return *o.StateNames -} - -// GetStateNamesOk returns a tuple with the StateNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetStateNamesOk() ([]string, bool) { - if o == nil || o.StateNames == nil { - var ret []string - return ret, false - } - return *o.StateNames, true -} - -// HasStateNames returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasStateNames() bool { - if o != nil && o.StateNames != nil { - return true - } - - return false -} - -// SetStateNames gets a reference to the given []string and assigns it to the StateNames field. -func (o *FiltersNetPeering) SetStateNames(v []string) { - o.StateNames = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersNetPeering) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersNetPeering) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersNetPeering) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNetPeering) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersNetPeering) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersNetPeering) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersNetPeering struct { - Value FiltersNetPeering - ExplicitNull bool -} - -func (v NullableFiltersNetPeering) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersNetPeering) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nic.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nic.go deleted file mode 100644 index 7203e1401..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_nic.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersNic One or more filters. -type FiltersNic struct { - // The device numbers the NICs are attached to. - LinkNicSortNumbers *[]int64 `json:"LinkNicSortNumbers,omitempty"` - // The IDs of the VMs the NICs are attached to. - LinkNicVmIds *[]string `json:"LinkNicVmIds,omitempty"` - // The IDs of the NICs. - NicIds *[]string `json:"NicIds,omitempty"` - // The private IP addresses of the NICs. - PrivateIpsPrivateIps *[]string `json:"PrivateIpsPrivateIps,omitempty"` - // The IDs of the Subnets for the NICs. - SubnetIds *[]string `json:"SubnetIds,omitempty"` -} - -// GetLinkNicSortNumbers returns the LinkNicSortNumbers field value if set, zero value otherwise. -func (o *FiltersNic) GetLinkNicSortNumbers() []int64 { - if o == nil || o.LinkNicSortNumbers == nil { - var ret []int64 - return ret - } - return *o.LinkNicSortNumbers -} - -// GetLinkNicSortNumbersOk returns a tuple with the LinkNicSortNumbers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNic) GetLinkNicSortNumbersOk() ([]int64, bool) { - if o == nil || o.LinkNicSortNumbers == nil { - var ret []int64 - return ret, false - } - return *o.LinkNicSortNumbers, true -} - -// HasLinkNicSortNumbers returns a boolean if a field has been set. -func (o *FiltersNic) HasLinkNicSortNumbers() bool { - if o != nil && o.LinkNicSortNumbers != nil { - return true - } - - return false -} - -// SetLinkNicSortNumbers gets a reference to the given []int64 and assigns it to the LinkNicSortNumbers field. -func (o *FiltersNic) SetLinkNicSortNumbers(v []int64) { - o.LinkNicSortNumbers = &v -} - -// GetLinkNicVmIds returns the LinkNicVmIds field value if set, zero value otherwise. -func (o *FiltersNic) GetLinkNicVmIds() []string { - if o == nil || o.LinkNicVmIds == nil { - var ret []string - return ret - } - return *o.LinkNicVmIds -} - -// GetLinkNicVmIdsOk returns a tuple with the LinkNicVmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNic) GetLinkNicVmIdsOk() ([]string, bool) { - if o == nil || o.LinkNicVmIds == nil { - var ret []string - return ret, false - } - return *o.LinkNicVmIds, true -} - -// HasLinkNicVmIds returns a boolean if a field has been set. -func (o *FiltersNic) HasLinkNicVmIds() bool { - if o != nil && o.LinkNicVmIds != nil { - return true - } - - return false -} - -// SetLinkNicVmIds gets a reference to the given []string and assigns it to the LinkNicVmIds field. -func (o *FiltersNic) SetLinkNicVmIds(v []string) { - o.LinkNicVmIds = &v -} - -// GetNicIds returns the NicIds field value if set, zero value otherwise. -func (o *FiltersNic) GetNicIds() []string { - if o == nil || o.NicIds == nil { - var ret []string - return ret - } - return *o.NicIds -} - -// GetNicIdsOk returns a tuple with the NicIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNic) GetNicIdsOk() ([]string, bool) { - if o == nil || o.NicIds == nil { - var ret []string - return ret, false - } - return *o.NicIds, true -} - -// HasNicIds returns a boolean if a field has been set. -func (o *FiltersNic) HasNicIds() bool { - if o != nil && o.NicIds != nil { - return true - } - - return false -} - -// SetNicIds gets a reference to the given []string and assigns it to the NicIds field. -func (o *FiltersNic) SetNicIds(v []string) { - o.NicIds = &v -} - -// GetPrivateIpsPrivateIps returns the PrivateIpsPrivateIps field value if set, zero value otherwise. -func (o *FiltersNic) GetPrivateIpsPrivateIps() []string { - if o == nil || o.PrivateIpsPrivateIps == nil { - var ret []string - return ret - } - return *o.PrivateIpsPrivateIps -} - -// GetPrivateIpsPrivateIpsOk returns a tuple with the PrivateIpsPrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNic) GetPrivateIpsPrivateIpsOk() ([]string, bool) { - if o == nil || o.PrivateIpsPrivateIps == nil { - var ret []string - return ret, false - } - return *o.PrivateIpsPrivateIps, true -} - -// HasPrivateIpsPrivateIps returns a boolean if a field has been set. -func (o *FiltersNic) HasPrivateIpsPrivateIps() bool { - if o != nil && o.PrivateIpsPrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIpsPrivateIps gets a reference to the given []string and assigns it to the PrivateIpsPrivateIps field. -func (o *FiltersNic) SetPrivateIpsPrivateIps(v []string) { - o.PrivateIpsPrivateIps = &v -} - -// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. -func (o *FiltersNic) GetSubnetIds() []string { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret - } - return *o.SubnetIds -} - -// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersNic) GetSubnetIdsOk() ([]string, bool) { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret, false - } - return *o.SubnetIds, true -} - -// HasSubnetIds returns a boolean if a field has been set. -func (o *FiltersNic) HasSubnetIds() bool { - if o != nil && o.SubnetIds != nil { - return true - } - - return false -} - -// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. -func (o *FiltersNic) SetSubnetIds(v []string) { - o.SubnetIds = &v -} - -type NullableFiltersNic struct { - Value FiltersNic - ExplicitNull bool -} - -func (v NullableFiltersNic) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersNic) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_product_type.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_product_type.go deleted file mode 100644 index 0e147ccb7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_product_type.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersProductType One or more filters. -type FiltersProductType struct { - // The IDs of the product types. - ProductTypeIds *[]string `json:"ProductTypeIds,omitempty"` -} - -// GetProductTypeIds returns the ProductTypeIds field value if set, zero value otherwise. -func (o *FiltersProductType) GetProductTypeIds() []string { - if o == nil || o.ProductTypeIds == nil { - var ret []string - return ret - } - return *o.ProductTypeIds -} - -// GetProductTypeIdsOk returns a tuple with the ProductTypeIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersProductType) GetProductTypeIdsOk() ([]string, bool) { - if o == nil || o.ProductTypeIds == nil { - var ret []string - return ret, false - } - return *o.ProductTypeIds, true -} - -// HasProductTypeIds returns a boolean if a field has been set. -func (o *FiltersProductType) HasProductTypeIds() bool { - if o != nil && o.ProductTypeIds != nil { - return true - } - - return false -} - -// SetProductTypeIds gets a reference to the given []string and assigns it to the ProductTypeIds field. -func (o *FiltersProductType) SetProductTypeIds(v []string) { - o.ProductTypeIds = &v -} - -type NullableFiltersProductType struct { - Value FiltersProductType - ExplicitNull bool -} - -func (v NullableFiltersProductType) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersProductType) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_public_ip.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_public_ip.go deleted file mode 100644 index 8d985d3a2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_public_ip.go +++ /dev/null @@ -1,428 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersPublicIp One or more filters. -type FiltersPublicIp struct { - // The IDs representing the associations of EIPs with VMs or NICs. - LinkPublicIpIds *[]string `json:"LinkPublicIpIds,omitempty"` - // The account IDs of the owners of the NICs. - NicAccountIds *[]string `json:"NicAccountIds,omitempty"` - // The IDs of the NICs. - NicIds *[]string `json:"NicIds,omitempty"` - // Whether the EIPs are for use in the public Cloud or in a Net. - Placements *[]string `json:"Placements,omitempty"` - // The private IP addresses associated with the EIPs. - PrivateIps *[]string `json:"PrivateIps,omitempty"` - // The IDs of the External IP addresses (EIPs). - PublicIpIds *[]string `json:"PublicIpIds,omitempty"` - // The External IP addresses (EIPs). - PublicIps *[]string `json:"PublicIps,omitempty"` - // The keys of the tags associated with the EIPs. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the EIPs. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the EIPs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The IDs of the VMs. - VmIds *[]string `json:"VmIds,omitempty"` -} - -// GetLinkPublicIpIds returns the LinkPublicIpIds field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetLinkPublicIpIds() []string { - if o == nil || o.LinkPublicIpIds == nil { - var ret []string - return ret - } - return *o.LinkPublicIpIds -} - -// GetLinkPublicIpIdsOk returns a tuple with the LinkPublicIpIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetLinkPublicIpIdsOk() ([]string, bool) { - if o == nil || o.LinkPublicIpIds == nil { - var ret []string - return ret, false - } - return *o.LinkPublicIpIds, true -} - -// HasLinkPublicIpIds returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasLinkPublicIpIds() bool { - if o != nil && o.LinkPublicIpIds != nil { - return true - } - - return false -} - -// SetLinkPublicIpIds gets a reference to the given []string and assigns it to the LinkPublicIpIds field. -func (o *FiltersPublicIp) SetLinkPublicIpIds(v []string) { - o.LinkPublicIpIds = &v -} - -// GetNicAccountIds returns the NicAccountIds field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetNicAccountIds() []string { - if o == nil || o.NicAccountIds == nil { - var ret []string - return ret - } - return *o.NicAccountIds -} - -// GetNicAccountIdsOk returns a tuple with the NicAccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetNicAccountIdsOk() ([]string, bool) { - if o == nil || o.NicAccountIds == nil { - var ret []string - return ret, false - } - return *o.NicAccountIds, true -} - -// HasNicAccountIds returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasNicAccountIds() bool { - if o != nil && o.NicAccountIds != nil { - return true - } - - return false -} - -// SetNicAccountIds gets a reference to the given []string and assigns it to the NicAccountIds field. -func (o *FiltersPublicIp) SetNicAccountIds(v []string) { - o.NicAccountIds = &v -} - -// GetNicIds returns the NicIds field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetNicIds() []string { - if o == nil || o.NicIds == nil { - var ret []string - return ret - } - return *o.NicIds -} - -// GetNicIdsOk returns a tuple with the NicIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetNicIdsOk() ([]string, bool) { - if o == nil || o.NicIds == nil { - var ret []string - return ret, false - } - return *o.NicIds, true -} - -// HasNicIds returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasNicIds() bool { - if o != nil && o.NicIds != nil { - return true - } - - return false -} - -// SetNicIds gets a reference to the given []string and assigns it to the NicIds field. -func (o *FiltersPublicIp) SetNicIds(v []string) { - o.NicIds = &v -} - -// GetPlacements returns the Placements field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetPlacements() []string { - if o == nil || o.Placements == nil { - var ret []string - return ret - } - return *o.Placements -} - -// GetPlacementsOk returns a tuple with the Placements field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetPlacementsOk() ([]string, bool) { - if o == nil || o.Placements == nil { - var ret []string - return ret, false - } - return *o.Placements, true -} - -// HasPlacements returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasPlacements() bool { - if o != nil && o.Placements != nil { - return true - } - - return false -} - -// SetPlacements gets a reference to the given []string and assigns it to the Placements field. -func (o *FiltersPublicIp) SetPlacements(v []string) { - o.Placements = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetPrivateIps() []string { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetPrivateIpsOk() ([]string, bool) { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. -func (o *FiltersPublicIp) SetPrivateIps(v []string) { - o.PrivateIps = &v -} - -// GetPublicIpIds returns the PublicIpIds field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetPublicIpIds() []string { - if o == nil || o.PublicIpIds == nil { - var ret []string - return ret - } - return *o.PublicIpIds -} - -// GetPublicIpIdsOk returns a tuple with the PublicIpIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetPublicIpIdsOk() ([]string, bool) { - if o == nil || o.PublicIpIds == nil { - var ret []string - return ret, false - } - return *o.PublicIpIds, true -} - -// HasPublicIpIds returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasPublicIpIds() bool { - if o != nil && o.PublicIpIds != nil { - return true - } - - return false -} - -// SetPublicIpIds gets a reference to the given []string and assigns it to the PublicIpIds field. -func (o *FiltersPublicIp) SetPublicIpIds(v []string) { - o.PublicIpIds = &v -} - -// GetPublicIps returns the PublicIps field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetPublicIps() []string { - if o == nil || o.PublicIps == nil { - var ret []string - return ret - } - return *o.PublicIps -} - -// GetPublicIpsOk returns a tuple with the PublicIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetPublicIpsOk() ([]string, bool) { - if o == nil || o.PublicIps == nil { - var ret []string - return ret, false - } - return *o.PublicIps, true -} - -// HasPublicIps returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasPublicIps() bool { - if o != nil && o.PublicIps != nil { - return true - } - - return false -} - -// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. -func (o *FiltersPublicIp) SetPublicIps(v []string) { - o.PublicIps = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersPublicIp) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersPublicIp) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersPublicIp) SetTags(v []string) { - o.Tags = &v -} - -// GetVmIds returns the VmIds field value if set, zero value otherwise. -func (o *FiltersPublicIp) GetVmIds() []string { - if o == nil || o.VmIds == nil { - var ret []string - return ret - } - return *o.VmIds -} - -// GetVmIdsOk returns a tuple with the VmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersPublicIp) GetVmIdsOk() ([]string, bool) { - if o == nil || o.VmIds == nil { - var ret []string - return ret, false - } - return *o.VmIds, true -} - -// HasVmIds returns a boolean if a field has been set. -func (o *FiltersPublicIp) HasVmIds() bool { - if o != nil && o.VmIds != nil { - return true - } - - return false -} - -// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. -func (o *FiltersPublicIp) SetVmIds(v []string) { - o.VmIds = &v -} - -type NullableFiltersPublicIp struct { - Value FiltersPublicIp - ExplicitNull bool -} - -func (v NullableFiltersPublicIp) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersPublicIp) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_quota.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_quota.go deleted file mode 100644 index 2fe83f964..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_quota.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersQuota One or more filters. -type FiltersQuota struct { - // The group names of the quotas. - Collections *[]string `json:"Collections,omitempty"` - // The names of the quotas. - QuotaNames *[]string `json:"QuotaNames,omitempty"` - // The resource IDs if these are resource-specific quotas, `global` if they are not. - QuotaTypes *[]string `json:"QuotaTypes,omitempty"` - // The description of the quotas. - ShortDescriptions *[]string `json:"ShortDescriptions,omitempty"` -} - -// GetCollections returns the Collections field value if set, zero value otherwise. -func (o *FiltersQuota) GetCollections() []string { - if o == nil || o.Collections == nil { - var ret []string - return ret - } - return *o.Collections -} - -// GetCollectionsOk returns a tuple with the Collections field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersQuota) GetCollectionsOk() ([]string, bool) { - if o == nil || o.Collections == nil { - var ret []string - return ret, false - } - return *o.Collections, true -} - -// HasCollections returns a boolean if a field has been set. -func (o *FiltersQuota) HasCollections() bool { - if o != nil && o.Collections != nil { - return true - } - - return false -} - -// SetCollections gets a reference to the given []string and assigns it to the Collections field. -func (o *FiltersQuota) SetCollections(v []string) { - o.Collections = &v -} - -// GetQuotaNames returns the QuotaNames field value if set, zero value otherwise. -func (o *FiltersQuota) GetQuotaNames() []string { - if o == nil || o.QuotaNames == nil { - var ret []string - return ret - } - return *o.QuotaNames -} - -// GetQuotaNamesOk returns a tuple with the QuotaNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersQuota) GetQuotaNamesOk() ([]string, bool) { - if o == nil || o.QuotaNames == nil { - var ret []string - return ret, false - } - return *o.QuotaNames, true -} - -// HasQuotaNames returns a boolean if a field has been set. -func (o *FiltersQuota) HasQuotaNames() bool { - if o != nil && o.QuotaNames != nil { - return true - } - - return false -} - -// SetQuotaNames gets a reference to the given []string and assigns it to the QuotaNames field. -func (o *FiltersQuota) SetQuotaNames(v []string) { - o.QuotaNames = &v -} - -// GetQuotaTypes returns the QuotaTypes field value if set, zero value otherwise. -func (o *FiltersQuota) GetQuotaTypes() []string { - if o == nil || o.QuotaTypes == nil { - var ret []string - return ret - } - return *o.QuotaTypes -} - -// GetQuotaTypesOk returns a tuple with the QuotaTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersQuota) GetQuotaTypesOk() ([]string, bool) { - if o == nil || o.QuotaTypes == nil { - var ret []string - return ret, false - } - return *o.QuotaTypes, true -} - -// HasQuotaTypes returns a boolean if a field has been set. -func (o *FiltersQuota) HasQuotaTypes() bool { - if o != nil && o.QuotaTypes != nil { - return true - } - - return false -} - -// SetQuotaTypes gets a reference to the given []string and assigns it to the QuotaTypes field. -func (o *FiltersQuota) SetQuotaTypes(v []string) { - o.QuotaTypes = &v -} - -// GetShortDescriptions returns the ShortDescriptions field value if set, zero value otherwise. -func (o *FiltersQuota) GetShortDescriptions() []string { - if o == nil || o.ShortDescriptions == nil { - var ret []string - return ret - } - return *o.ShortDescriptions -} - -// GetShortDescriptionsOk returns a tuple with the ShortDescriptions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersQuota) GetShortDescriptionsOk() ([]string, bool) { - if o == nil || o.ShortDescriptions == nil { - var ret []string - return ret, false - } - return *o.ShortDescriptions, true -} - -// HasShortDescriptions returns a boolean if a field has been set. -func (o *FiltersQuota) HasShortDescriptions() bool { - if o != nil && o.ShortDescriptions != nil { - return true - } - - return false -} - -// SetShortDescriptions gets a reference to the given []string and assigns it to the ShortDescriptions field. -func (o *FiltersQuota) SetShortDescriptions(v []string) { - o.ShortDescriptions = &v -} - -type NullableFiltersQuota struct { - Value FiltersQuota - ExplicitNull bool -} - -func (v NullableFiltersQuota) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersQuota) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_route_table.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_route_table.go deleted file mode 100644 index baed31993..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_route_table.go +++ /dev/null @@ -1,533 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersRouteTable One or more filters. -type FiltersRouteTable struct { - // The IDs of the associations between the route tables and the Subnets. - LinkRouteTableLinkRouteTableIds *[]string `json:"LinkRouteTableLinkRouteTableIds,omitempty"` - // The IDs of the Subnets involved in the associations. - LinkSubnetIds *[]string `json:"LinkSubnetIds,omitempty"` - // The IDs of the Nets for the route tables. - NetIds *[]string `json:"NetIds,omitempty"` - // The methods used to create a route. - RouteCreationMethods *[]string `json:"RouteCreationMethods,omitempty"` - // The IP ranges specified in routes in the tables. - RouteDestinationIpRanges *[]string `json:"RouteDestinationIpRanges,omitempty"` - // The IDs of the gateways specified in routes in the tables. - RouteGatewayIds *[]string `json:"RouteGatewayIds,omitempty"` - // The IDs of the NAT services specified in routes in the tables. - RouteNatServiceIds *[]string `json:"RouteNatServiceIds,omitempty"` - // The IDs of the Net peering connections specified in routes in the tables. - RouteNetPeeringIds *[]string `json:"RouteNetPeeringIds,omitempty"` - // The states of routes in the route tables (`active` \\| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - RouteStates *[]string `json:"RouteStates,omitempty"` - // The IDs of the route tables. - RouteTableIds *[]string `json:"RouteTableIds,omitempty"` - // The IDs of the VMs specified in routes in the tables. - RouteVmIds *[]string `json:"RouteVmIds,omitempty"` - // The keys of the tags associated with the route tables. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the route tables. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the route tables, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetLinkRouteTableLinkRouteTableIds returns the LinkRouteTableLinkRouteTableIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetLinkRouteTableLinkRouteTableIds() []string { - if o == nil || o.LinkRouteTableLinkRouteTableIds == nil { - var ret []string - return ret - } - return *o.LinkRouteTableLinkRouteTableIds -} - -// GetLinkRouteTableLinkRouteTableIdsOk returns a tuple with the LinkRouteTableLinkRouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetLinkRouteTableLinkRouteTableIdsOk() ([]string, bool) { - if o == nil || o.LinkRouteTableLinkRouteTableIds == nil { - var ret []string - return ret, false - } - return *o.LinkRouteTableLinkRouteTableIds, true -} - -// HasLinkRouteTableLinkRouteTableIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasLinkRouteTableLinkRouteTableIds() bool { - if o != nil && o.LinkRouteTableLinkRouteTableIds != nil { - return true - } - - return false -} - -// SetLinkRouteTableLinkRouteTableIds gets a reference to the given []string and assigns it to the LinkRouteTableLinkRouteTableIds field. -func (o *FiltersRouteTable) SetLinkRouteTableLinkRouteTableIds(v []string) { - o.LinkRouteTableLinkRouteTableIds = &v -} - -// GetLinkSubnetIds returns the LinkSubnetIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetLinkSubnetIds() []string { - if o == nil || o.LinkSubnetIds == nil { - var ret []string - return ret - } - return *o.LinkSubnetIds -} - -// GetLinkSubnetIdsOk returns a tuple with the LinkSubnetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetLinkSubnetIdsOk() ([]string, bool) { - if o == nil || o.LinkSubnetIds == nil { - var ret []string - return ret, false - } - return *o.LinkSubnetIds, true -} - -// HasLinkSubnetIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasLinkSubnetIds() bool { - if o != nil && o.LinkSubnetIds != nil { - return true - } - - return false -} - -// SetLinkSubnetIds gets a reference to the given []string and assigns it to the LinkSubnetIds field. -func (o *FiltersRouteTable) SetLinkSubnetIds(v []string) { - o.LinkSubnetIds = &v -} - -// GetNetIds returns the NetIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetNetIds() []string { - if o == nil || o.NetIds == nil { - var ret []string - return ret - } - return *o.NetIds -} - -// GetNetIdsOk returns a tuple with the NetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetNetIdsOk() ([]string, bool) { - if o == nil || o.NetIds == nil { - var ret []string - return ret, false - } - return *o.NetIds, true -} - -// HasNetIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasNetIds() bool { - if o != nil && o.NetIds != nil { - return true - } - - return false -} - -// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. -func (o *FiltersRouteTable) SetNetIds(v []string) { - o.NetIds = &v -} - -// GetRouteCreationMethods returns the RouteCreationMethods field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteCreationMethods() []string { - if o == nil || o.RouteCreationMethods == nil { - var ret []string - return ret - } - return *o.RouteCreationMethods -} - -// GetRouteCreationMethodsOk returns a tuple with the RouteCreationMethods field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteCreationMethodsOk() ([]string, bool) { - if o == nil || o.RouteCreationMethods == nil { - var ret []string - return ret, false - } - return *o.RouteCreationMethods, true -} - -// HasRouteCreationMethods returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteCreationMethods() bool { - if o != nil && o.RouteCreationMethods != nil { - return true - } - - return false -} - -// SetRouteCreationMethods gets a reference to the given []string and assigns it to the RouteCreationMethods field. -func (o *FiltersRouteTable) SetRouteCreationMethods(v []string) { - o.RouteCreationMethods = &v -} - -// GetRouteDestinationIpRanges returns the RouteDestinationIpRanges field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteDestinationIpRanges() []string { - if o == nil || o.RouteDestinationIpRanges == nil { - var ret []string - return ret - } - return *o.RouteDestinationIpRanges -} - -// GetRouteDestinationIpRangesOk returns a tuple with the RouteDestinationIpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteDestinationIpRangesOk() ([]string, bool) { - if o == nil || o.RouteDestinationIpRanges == nil { - var ret []string - return ret, false - } - return *o.RouteDestinationIpRanges, true -} - -// HasRouteDestinationIpRanges returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteDestinationIpRanges() bool { - if o != nil && o.RouteDestinationIpRanges != nil { - return true - } - - return false -} - -// SetRouteDestinationIpRanges gets a reference to the given []string and assigns it to the RouteDestinationIpRanges field. -func (o *FiltersRouteTable) SetRouteDestinationIpRanges(v []string) { - o.RouteDestinationIpRanges = &v -} - -// GetRouteGatewayIds returns the RouteGatewayIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteGatewayIds() []string { - if o == nil || o.RouteGatewayIds == nil { - var ret []string - return ret - } - return *o.RouteGatewayIds -} - -// GetRouteGatewayIdsOk returns a tuple with the RouteGatewayIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteGatewayIdsOk() ([]string, bool) { - if o == nil || o.RouteGatewayIds == nil { - var ret []string - return ret, false - } - return *o.RouteGatewayIds, true -} - -// HasRouteGatewayIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteGatewayIds() bool { - if o != nil && o.RouteGatewayIds != nil { - return true - } - - return false -} - -// SetRouteGatewayIds gets a reference to the given []string and assigns it to the RouteGatewayIds field. -func (o *FiltersRouteTable) SetRouteGatewayIds(v []string) { - o.RouteGatewayIds = &v -} - -// GetRouteNatServiceIds returns the RouteNatServiceIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteNatServiceIds() []string { - if o == nil || o.RouteNatServiceIds == nil { - var ret []string - return ret - } - return *o.RouteNatServiceIds -} - -// GetRouteNatServiceIdsOk returns a tuple with the RouteNatServiceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteNatServiceIdsOk() ([]string, bool) { - if o == nil || o.RouteNatServiceIds == nil { - var ret []string - return ret, false - } - return *o.RouteNatServiceIds, true -} - -// HasRouteNatServiceIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteNatServiceIds() bool { - if o != nil && o.RouteNatServiceIds != nil { - return true - } - - return false -} - -// SetRouteNatServiceIds gets a reference to the given []string and assigns it to the RouteNatServiceIds field. -func (o *FiltersRouteTable) SetRouteNatServiceIds(v []string) { - o.RouteNatServiceIds = &v -} - -// GetRouteNetPeeringIds returns the RouteNetPeeringIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteNetPeeringIds() []string { - if o == nil || o.RouteNetPeeringIds == nil { - var ret []string - return ret - } - return *o.RouteNetPeeringIds -} - -// GetRouteNetPeeringIdsOk returns a tuple with the RouteNetPeeringIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteNetPeeringIdsOk() ([]string, bool) { - if o == nil || o.RouteNetPeeringIds == nil { - var ret []string - return ret, false - } - return *o.RouteNetPeeringIds, true -} - -// HasRouteNetPeeringIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteNetPeeringIds() bool { - if o != nil && o.RouteNetPeeringIds != nil { - return true - } - - return false -} - -// SetRouteNetPeeringIds gets a reference to the given []string and assigns it to the RouteNetPeeringIds field. -func (o *FiltersRouteTable) SetRouteNetPeeringIds(v []string) { - o.RouteNetPeeringIds = &v -} - -// GetRouteStates returns the RouteStates field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteStates() []string { - if o == nil || o.RouteStates == nil { - var ret []string - return ret - } - return *o.RouteStates -} - -// GetRouteStatesOk returns a tuple with the RouteStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteStatesOk() ([]string, bool) { - if o == nil || o.RouteStates == nil { - var ret []string - return ret, false - } - return *o.RouteStates, true -} - -// HasRouteStates returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteStates() bool { - if o != nil && o.RouteStates != nil { - return true - } - - return false -} - -// SetRouteStates gets a reference to the given []string and assigns it to the RouteStates field. -func (o *FiltersRouteTable) SetRouteStates(v []string) { - o.RouteStates = &v -} - -// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteTableIds() []string { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret - } - return *o.RouteTableIds -} - -// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteTableIdsOk() ([]string, bool) { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret, false - } - return *o.RouteTableIds, true -} - -// HasRouteTableIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteTableIds() bool { - if o != nil && o.RouteTableIds != nil { - return true - } - - return false -} - -// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. -func (o *FiltersRouteTable) SetRouteTableIds(v []string) { - o.RouteTableIds = &v -} - -// GetRouteVmIds returns the RouteVmIds field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetRouteVmIds() []string { - if o == nil || o.RouteVmIds == nil { - var ret []string - return ret - } - return *o.RouteVmIds -} - -// GetRouteVmIdsOk returns a tuple with the RouteVmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetRouteVmIdsOk() ([]string, bool) { - if o == nil || o.RouteVmIds == nil { - var ret []string - return ret, false - } - return *o.RouteVmIds, true -} - -// HasRouteVmIds returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasRouteVmIds() bool { - if o != nil && o.RouteVmIds != nil { - return true - } - - return false -} - -// SetRouteVmIds gets a reference to the given []string and assigns it to the RouteVmIds field. -func (o *FiltersRouteTable) SetRouteVmIds(v []string) { - o.RouteVmIds = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersRouteTable) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersRouteTable) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersRouteTable) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersRouteTable) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersRouteTable) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersRouteTable) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersRouteTable struct { - Value FiltersRouteTable - ExplicitNull bool -} - -func (v NullableFiltersRouteTable) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersRouteTable) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_security_group.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_security_group.go deleted file mode 100644 index 93db9d8a2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_security_group.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersSecurityGroup One or more filters. -type FiltersSecurityGroup struct { - // The account IDs of the owners of the security groups. - AccountIds *[]string `json:"AccountIds,omitempty"` - // The IDs of the security groups. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` - // The names of the security groups. - SecurityGroupNames *[]string `json:"SecurityGroupNames,omitempty"` - // The keys of the tags associated with the security groups. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the security groups. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the security groups, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` -} - -// GetAccountIds returns the AccountIds field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetAccountIds() []string { - if o == nil || o.AccountIds == nil { - var ret []string - return ret - } - return *o.AccountIds -} - -// GetAccountIdsOk returns a tuple with the AccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetAccountIdsOk() ([]string, bool) { - if o == nil || o.AccountIds == nil { - var ret []string - return ret, false - } - return *o.AccountIds, true -} - -// HasAccountIds returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasAccountIds() bool { - if o != nil && o.AccountIds != nil { - return true - } - - return false -} - -// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. -func (o *FiltersSecurityGroup) SetAccountIds(v []string) { - o.AccountIds = &v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *FiltersSecurityGroup) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -// GetSecurityGroupNames returns the SecurityGroupNames field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetSecurityGroupNames() []string { - if o == nil || o.SecurityGroupNames == nil { - var ret []string - return ret - } - return *o.SecurityGroupNames -} - -// GetSecurityGroupNamesOk returns a tuple with the SecurityGroupNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetSecurityGroupNamesOk() ([]string, bool) { - if o == nil || o.SecurityGroupNames == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupNames, true -} - -// HasSecurityGroupNames returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasSecurityGroupNames() bool { - if o != nil && o.SecurityGroupNames != nil { - return true - } - - return false -} - -// SetSecurityGroupNames gets a reference to the given []string and assigns it to the SecurityGroupNames field. -func (o *FiltersSecurityGroup) SetSecurityGroupNames(v []string) { - o.SecurityGroupNames = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersSecurityGroup) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersSecurityGroup) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersSecurityGroup) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSecurityGroup) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersSecurityGroup) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersSecurityGroup) SetTags(v []string) { - o.Tags = &v -} - -type NullableFiltersSecurityGroup struct { - Value FiltersSecurityGroup - ExplicitNull bool -} - -func (v NullableFiltersSecurityGroup) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersSecurityGroup) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_server_certificate.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_server_certificate.go deleted file mode 100644 index cfe02ac57..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_server_certificate.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersServerCertificate One or more filters. -type FiltersServerCertificate struct { - // The path to the server certificate. - Paths *string `json:"Paths,omitempty"` -} - -// GetPaths returns the Paths field value if set, zero value otherwise. -func (o *FiltersServerCertificate) GetPaths() string { - if o == nil || o.Paths == nil { - var ret string - return ret - } - return *o.Paths -} - -// GetPathsOk returns a tuple with the Paths field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersServerCertificate) GetPathsOk() (string, bool) { - if o == nil || o.Paths == nil { - var ret string - return ret, false - } - return *o.Paths, true -} - -// HasPaths returns a boolean if a field has been set. -func (o *FiltersServerCertificate) HasPaths() bool { - if o != nil && o.Paths != nil { - return true - } - - return false -} - -// SetPaths gets a reference to the given string and assigns it to the Paths field. -func (o *FiltersServerCertificate) SetPaths(v string) { - o.Paths = &v -} - -type NullableFiltersServerCertificate struct { - Value FiltersServerCertificate - ExplicitNull bool -} - -func (v NullableFiltersServerCertificate) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersServerCertificate) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_service.go deleted file mode 100644 index fe32c9c2d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_service.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersService One or more filters. -type FiltersService struct { - // The IDs of the services. - ServiceIds *[]string `json:"ServiceIds,omitempty"` - // The names of the prefix lists, which identify the 3DS OUTSCALE services they are associated with. - ServiceNames *[]string `json:"ServiceNames,omitempty"` -} - -// GetServiceIds returns the ServiceIds field value if set, zero value otherwise. -func (o *FiltersService) GetServiceIds() []string { - if o == nil || o.ServiceIds == nil { - var ret []string - return ret - } - return *o.ServiceIds -} - -// GetServiceIdsOk returns a tuple with the ServiceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersService) GetServiceIdsOk() ([]string, bool) { - if o == nil || o.ServiceIds == nil { - var ret []string - return ret, false - } - return *o.ServiceIds, true -} - -// HasServiceIds returns a boolean if a field has been set. -func (o *FiltersService) HasServiceIds() bool { - if o != nil && o.ServiceIds != nil { - return true - } - - return false -} - -// SetServiceIds gets a reference to the given []string and assigns it to the ServiceIds field. -func (o *FiltersService) SetServiceIds(v []string) { - o.ServiceIds = &v -} - -// GetServiceNames returns the ServiceNames field value if set, zero value otherwise. -func (o *FiltersService) GetServiceNames() []string { - if o == nil || o.ServiceNames == nil { - var ret []string - return ret - } - return *o.ServiceNames -} - -// GetServiceNamesOk returns a tuple with the ServiceNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersService) GetServiceNamesOk() ([]string, bool) { - if o == nil || o.ServiceNames == nil { - var ret []string - return ret, false - } - return *o.ServiceNames, true -} - -// HasServiceNames returns a boolean if a field has been set. -func (o *FiltersService) HasServiceNames() bool { - if o != nil && o.ServiceNames != nil { - return true - } - - return false -} - -// SetServiceNames gets a reference to the given []string and assigns it to the ServiceNames field. -func (o *FiltersService) SetServiceNames(v []string) { - o.ServiceNames = &v -} - -type NullableFiltersService struct { - Value FiltersService - ExplicitNull bool -} - -func (v NullableFiltersService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_snapshot.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_snapshot.go deleted file mode 100644 index 7f5c6e234..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_snapshot.go +++ /dev/null @@ -1,498 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersSnapshot One or more filters. -type FiltersSnapshot struct { - // The account aliases of the owners of the snapshots. - AccountAliases *[]string `json:"AccountAliases,omitempty"` - // The account IDs of the owners of the snapshots. - AccountIds *[]string `json:"AccountIds,omitempty"` - // The descriptions of the snapshots. - Descriptions *[]string `json:"Descriptions,omitempty"` - // The account IDs of one or more users who have permissions to create volumes. - PermissionsToCreateVolumeAccountIds *[]string `json:"PermissionsToCreateVolumeAccountIds,omitempty"` - // If `true`, lists all public volumes. If `false`, lists all private volumes. - PermissionsToCreateVolumeGlobalPermission *bool `json:"PermissionsToCreateVolumeGlobalPermission,omitempty"` - // The progresses of the snapshots, as a percentage. - Progresses *[]int64 `json:"Progresses,omitempty"` - // The IDs of the snapshots. - SnapshotIds *[]string `json:"SnapshotIds,omitempty"` - // The states of the snapshots (`in-queue` \\| `completed` \\| `error`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the snapshots. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the snapshots. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the snapshots, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The IDs of the volumes used to create the snapshots. - VolumeIds *[]string `json:"VolumeIds,omitempty"` - // The sizes of the volumes used to create the snapshots, in gibibytes (GiB). - VolumeSizes *[]int64 `json:"VolumeSizes,omitempty"` -} - -// GetAccountAliases returns the AccountAliases field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetAccountAliases() []string { - if o == nil || o.AccountAliases == nil { - var ret []string - return ret - } - return *o.AccountAliases -} - -// GetAccountAliasesOk returns a tuple with the AccountAliases field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetAccountAliasesOk() ([]string, bool) { - if o == nil || o.AccountAliases == nil { - var ret []string - return ret, false - } - return *o.AccountAliases, true -} - -// HasAccountAliases returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasAccountAliases() bool { - if o != nil && o.AccountAliases != nil { - return true - } - - return false -} - -// SetAccountAliases gets a reference to the given []string and assigns it to the AccountAliases field. -func (o *FiltersSnapshot) SetAccountAliases(v []string) { - o.AccountAliases = &v -} - -// GetAccountIds returns the AccountIds field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetAccountIds() []string { - if o == nil || o.AccountIds == nil { - var ret []string - return ret - } - return *o.AccountIds -} - -// GetAccountIdsOk returns a tuple with the AccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetAccountIdsOk() ([]string, bool) { - if o == nil || o.AccountIds == nil { - var ret []string - return ret, false - } - return *o.AccountIds, true -} - -// HasAccountIds returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasAccountIds() bool { - if o != nil && o.AccountIds != nil { - return true - } - - return false -} - -// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. -func (o *FiltersSnapshot) SetAccountIds(v []string) { - o.AccountIds = &v -} - -// GetDescriptions returns the Descriptions field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetDescriptions() []string { - if o == nil || o.Descriptions == nil { - var ret []string - return ret - } - return *o.Descriptions -} - -// GetDescriptionsOk returns a tuple with the Descriptions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetDescriptionsOk() ([]string, bool) { - if o == nil || o.Descriptions == nil { - var ret []string - return ret, false - } - return *o.Descriptions, true -} - -// HasDescriptions returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasDescriptions() bool { - if o != nil && o.Descriptions != nil { - return true - } - - return false -} - -// SetDescriptions gets a reference to the given []string and assigns it to the Descriptions field. -func (o *FiltersSnapshot) SetDescriptions(v []string) { - o.Descriptions = &v -} - -// GetPermissionsToCreateVolumeAccountIds returns the PermissionsToCreateVolumeAccountIds field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetPermissionsToCreateVolumeAccountIds() []string { - if o == nil || o.PermissionsToCreateVolumeAccountIds == nil { - var ret []string - return ret - } - return *o.PermissionsToCreateVolumeAccountIds -} - -// GetPermissionsToCreateVolumeAccountIdsOk returns a tuple with the PermissionsToCreateVolumeAccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetPermissionsToCreateVolumeAccountIdsOk() ([]string, bool) { - if o == nil || o.PermissionsToCreateVolumeAccountIds == nil { - var ret []string - return ret, false - } - return *o.PermissionsToCreateVolumeAccountIds, true -} - -// HasPermissionsToCreateVolumeAccountIds returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasPermissionsToCreateVolumeAccountIds() bool { - if o != nil && o.PermissionsToCreateVolumeAccountIds != nil { - return true - } - - return false -} - -// SetPermissionsToCreateVolumeAccountIds gets a reference to the given []string and assigns it to the PermissionsToCreateVolumeAccountIds field. -func (o *FiltersSnapshot) SetPermissionsToCreateVolumeAccountIds(v []string) { - o.PermissionsToCreateVolumeAccountIds = &v -} - -// GetPermissionsToCreateVolumeGlobalPermission returns the PermissionsToCreateVolumeGlobalPermission field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetPermissionsToCreateVolumeGlobalPermission() bool { - if o == nil || o.PermissionsToCreateVolumeGlobalPermission == nil { - var ret bool - return ret - } - return *o.PermissionsToCreateVolumeGlobalPermission -} - -// GetPermissionsToCreateVolumeGlobalPermissionOk returns a tuple with the PermissionsToCreateVolumeGlobalPermission field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetPermissionsToCreateVolumeGlobalPermissionOk() (bool, bool) { - if o == nil || o.PermissionsToCreateVolumeGlobalPermission == nil { - var ret bool - return ret, false - } - return *o.PermissionsToCreateVolumeGlobalPermission, true -} - -// HasPermissionsToCreateVolumeGlobalPermission returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasPermissionsToCreateVolumeGlobalPermission() bool { - if o != nil && o.PermissionsToCreateVolumeGlobalPermission != nil { - return true - } - - return false -} - -// SetPermissionsToCreateVolumeGlobalPermission gets a reference to the given bool and assigns it to the PermissionsToCreateVolumeGlobalPermission field. -func (o *FiltersSnapshot) SetPermissionsToCreateVolumeGlobalPermission(v bool) { - o.PermissionsToCreateVolumeGlobalPermission = &v -} - -// GetProgresses returns the Progresses field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetProgresses() []int64 { - if o == nil || o.Progresses == nil { - var ret []int64 - return ret - } - return *o.Progresses -} - -// GetProgressesOk returns a tuple with the Progresses field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetProgressesOk() ([]int64, bool) { - if o == nil || o.Progresses == nil { - var ret []int64 - return ret, false - } - return *o.Progresses, true -} - -// HasProgresses returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasProgresses() bool { - if o != nil && o.Progresses != nil { - return true - } - - return false -} - -// SetProgresses gets a reference to the given []int64 and assigns it to the Progresses field. -func (o *FiltersSnapshot) SetProgresses(v []int64) { - o.Progresses = &v -} - -// GetSnapshotIds returns the SnapshotIds field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetSnapshotIds() []string { - if o == nil || o.SnapshotIds == nil { - var ret []string - return ret - } - return *o.SnapshotIds -} - -// GetSnapshotIdsOk returns a tuple with the SnapshotIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetSnapshotIdsOk() ([]string, bool) { - if o == nil || o.SnapshotIds == nil { - var ret []string - return ret, false - } - return *o.SnapshotIds, true -} - -// HasSnapshotIds returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasSnapshotIds() bool { - if o != nil && o.SnapshotIds != nil { - return true - } - - return false -} - -// SetSnapshotIds gets a reference to the given []string and assigns it to the SnapshotIds field. -func (o *FiltersSnapshot) SetSnapshotIds(v []string) { - o.SnapshotIds = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersSnapshot) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersSnapshot) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersSnapshot) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersSnapshot) SetTags(v []string) { - o.Tags = &v -} - -// GetVolumeIds returns the VolumeIds field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetVolumeIds() []string { - if o == nil || o.VolumeIds == nil { - var ret []string - return ret - } - return *o.VolumeIds -} - -// GetVolumeIdsOk returns a tuple with the VolumeIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetVolumeIdsOk() ([]string, bool) { - if o == nil || o.VolumeIds == nil { - var ret []string - return ret, false - } - return *o.VolumeIds, true -} - -// HasVolumeIds returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasVolumeIds() bool { - if o != nil && o.VolumeIds != nil { - return true - } - - return false -} - -// SetVolumeIds gets a reference to the given []string and assigns it to the VolumeIds field. -func (o *FiltersSnapshot) SetVolumeIds(v []string) { - o.VolumeIds = &v -} - -// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. -func (o *FiltersSnapshot) GetVolumeSizes() []int64 { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret - } - return *o.VolumeSizes -} - -// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSnapshot) GetVolumeSizesOk() ([]int64, bool) { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret, false - } - return *o.VolumeSizes, true -} - -// HasVolumeSizes returns a boolean if a field has been set. -func (o *FiltersSnapshot) HasVolumeSizes() bool { - if o != nil && o.VolumeSizes != nil { - return true - } - - return false -} - -// SetVolumeSizes gets a reference to the given []int64 and assigns it to the VolumeSizes field. -func (o *FiltersSnapshot) SetVolumeSizes(v []int64) { - o.VolumeSizes = &v -} - -type NullableFiltersSnapshot struct { - Value FiltersSnapshot - ExplicitNull bool -} - -func (v NullableFiltersSnapshot) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersSnapshot) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subnet.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subnet.go deleted file mode 100644 index f085ecf73..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subnet.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersSubnet One or more filters. -type FiltersSubnet struct { - // The number of available IPs. - AvailableIpsCounts *[]int64 `json:"AvailableIpsCounts,omitempty"` - // The IP ranges in the Subnets, in CIDR notation (for example, 10.0.0.0/16). - IpRanges *[]string `json:"IpRanges,omitempty"` - // The IDs of the Nets in which the Subnets are. - NetIds *[]string `json:"NetIds,omitempty"` - // The states of the Subnets (`pending` \\| `available`). - States *[]string `json:"States,omitempty"` - // The IDs of the Subnets. - SubnetIds *[]string `json:"SubnetIds,omitempty"` - // The names of the Subregions in which the Subnets are located. - SubregionNames *[]string `json:"SubregionNames,omitempty"` -} - -// GetAvailableIpsCounts returns the AvailableIpsCounts field value if set, zero value otherwise. -func (o *FiltersSubnet) GetAvailableIpsCounts() []int64 { - if o == nil || o.AvailableIpsCounts == nil { - var ret []int64 - return ret - } - return *o.AvailableIpsCounts -} - -// GetAvailableIpsCountsOk returns a tuple with the AvailableIpsCounts field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetAvailableIpsCountsOk() ([]int64, bool) { - if o == nil || o.AvailableIpsCounts == nil { - var ret []int64 - return ret, false - } - return *o.AvailableIpsCounts, true -} - -// HasAvailableIpsCounts returns a boolean if a field has been set. -func (o *FiltersSubnet) HasAvailableIpsCounts() bool { - if o != nil && o.AvailableIpsCounts != nil { - return true - } - - return false -} - -// SetAvailableIpsCounts gets a reference to the given []int64 and assigns it to the AvailableIpsCounts field. -func (o *FiltersSubnet) SetAvailableIpsCounts(v []int64) { - o.AvailableIpsCounts = &v -} - -// GetIpRanges returns the IpRanges field value if set, zero value otherwise. -func (o *FiltersSubnet) GetIpRanges() []string { - if o == nil || o.IpRanges == nil { - var ret []string - return ret - } - return *o.IpRanges -} - -// GetIpRangesOk returns a tuple with the IpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetIpRangesOk() ([]string, bool) { - if o == nil || o.IpRanges == nil { - var ret []string - return ret, false - } - return *o.IpRanges, true -} - -// HasIpRanges returns a boolean if a field has been set. -func (o *FiltersSubnet) HasIpRanges() bool { - if o != nil && o.IpRanges != nil { - return true - } - - return false -} - -// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. -func (o *FiltersSubnet) SetIpRanges(v []string) { - o.IpRanges = &v -} - -// GetNetIds returns the NetIds field value if set, zero value otherwise. -func (o *FiltersSubnet) GetNetIds() []string { - if o == nil || o.NetIds == nil { - var ret []string - return ret - } - return *o.NetIds -} - -// GetNetIdsOk returns a tuple with the NetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetNetIdsOk() ([]string, bool) { - if o == nil || o.NetIds == nil { - var ret []string - return ret, false - } - return *o.NetIds, true -} - -// HasNetIds returns a boolean if a field has been set. -func (o *FiltersSubnet) HasNetIds() bool { - if o != nil && o.NetIds != nil { - return true - } - - return false -} - -// SetNetIds gets a reference to the given []string and assigns it to the NetIds field. -func (o *FiltersSubnet) SetNetIds(v []string) { - o.NetIds = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersSubnet) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersSubnet) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersSubnet) SetStates(v []string) { - o.States = &v -} - -// GetSubnetIds returns the SubnetIds field value if set, zero value otherwise. -func (o *FiltersSubnet) GetSubnetIds() []string { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret - } - return *o.SubnetIds -} - -// GetSubnetIdsOk returns a tuple with the SubnetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetSubnetIdsOk() ([]string, bool) { - if o == nil || o.SubnetIds == nil { - var ret []string - return ret, false - } - return *o.SubnetIds, true -} - -// HasSubnetIds returns a boolean if a field has been set. -func (o *FiltersSubnet) HasSubnetIds() bool { - if o != nil && o.SubnetIds != nil { - return true - } - - return false -} - -// SetSubnetIds gets a reference to the given []string and assigns it to the SubnetIds field. -func (o *FiltersSubnet) SetSubnetIds(v []string) { - o.SubnetIds = &v -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *FiltersSubnet) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubnet) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *FiltersSubnet) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *FiltersSubnet) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -type NullableFiltersSubnet struct { - Value FiltersSubnet - ExplicitNull bool -} - -func (v NullableFiltersSubnet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersSubnet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subregion.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subregion.go deleted file mode 100644 index c5bdd9436..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_subregion.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersSubregion One or more filters. -type FiltersSubregion struct { - // The names of the Subregions. - SubregionNames *[]string `json:"SubregionNames,omitempty"` -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *FiltersSubregion) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersSubregion) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *FiltersSubregion) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *FiltersSubregion) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -type NullableFiltersSubregion struct { - Value FiltersSubregion - ExplicitNull bool -} - -func (v NullableFiltersSubregion) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersSubregion) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_tag.go deleted file mode 100644 index da6d4dea8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_tag.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersTag One or more filters. -type FiltersTag struct { - // The keys of the tags that are assigned to the resources. You can use this filter alongside the `Values` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. - Keys *[]string `json:"Keys,omitempty"` - // The IDs of the resources with which the tags are associated. - ResourceIds *[]string `json:"ResourceIds,omitempty"` - // The resource type (`vm` \\| `image` \\| `volume` \\| `snapshot` \\| `public-ip` \\| `security-group` \\| `route-table` \\| `nic` \\| `net` \\| `subnet` \\| `net-peering` \\| `net-access-point` \\| `nat-service` \\| `internet-service` \\| `client-gateway` \\| `virtual-gateway` \\| `vpn-connection` \\| `dhcp-options` \\| `task`). - ResourceTypes *[]string `json:"ResourceTypes,omitempty"` - // The values of the tags that are assigned to the resources. You can use this filter alongside the `TagKeys` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. - Values *[]string `json:"Values,omitempty"` -} - -// GetKeys returns the Keys field value if set, zero value otherwise. -func (o *FiltersTag) GetKeys() []string { - if o == nil || o.Keys == nil { - var ret []string - return ret - } - return *o.Keys -} - -// GetKeysOk returns a tuple with the Keys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersTag) GetKeysOk() ([]string, bool) { - if o == nil || o.Keys == nil { - var ret []string - return ret, false - } - return *o.Keys, true -} - -// HasKeys returns a boolean if a field has been set. -func (o *FiltersTag) HasKeys() bool { - if o != nil && o.Keys != nil { - return true - } - - return false -} - -// SetKeys gets a reference to the given []string and assigns it to the Keys field. -func (o *FiltersTag) SetKeys(v []string) { - o.Keys = &v -} - -// GetResourceIds returns the ResourceIds field value if set, zero value otherwise. -func (o *FiltersTag) GetResourceIds() []string { - if o == nil || o.ResourceIds == nil { - var ret []string - return ret - } - return *o.ResourceIds -} - -// GetResourceIdsOk returns a tuple with the ResourceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersTag) GetResourceIdsOk() ([]string, bool) { - if o == nil || o.ResourceIds == nil { - var ret []string - return ret, false - } - return *o.ResourceIds, true -} - -// HasResourceIds returns a boolean if a field has been set. -func (o *FiltersTag) HasResourceIds() bool { - if o != nil && o.ResourceIds != nil { - return true - } - - return false -} - -// SetResourceIds gets a reference to the given []string and assigns it to the ResourceIds field. -func (o *FiltersTag) SetResourceIds(v []string) { - o.ResourceIds = &v -} - -// GetResourceTypes returns the ResourceTypes field value if set, zero value otherwise. -func (o *FiltersTag) GetResourceTypes() []string { - if o == nil || o.ResourceTypes == nil { - var ret []string - return ret - } - return *o.ResourceTypes -} - -// GetResourceTypesOk returns a tuple with the ResourceTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersTag) GetResourceTypesOk() ([]string, bool) { - if o == nil || o.ResourceTypes == nil { - var ret []string - return ret, false - } - return *o.ResourceTypes, true -} - -// HasResourceTypes returns a boolean if a field has been set. -func (o *FiltersTag) HasResourceTypes() bool { - if o != nil && o.ResourceTypes != nil { - return true - } - - return false -} - -// SetResourceTypes gets a reference to the given []string and assigns it to the ResourceTypes field. -func (o *FiltersTag) SetResourceTypes(v []string) { - o.ResourceTypes = &v -} - -// GetValues returns the Values field value if set, zero value otherwise. -func (o *FiltersTag) GetValues() []string { - if o == nil || o.Values == nil { - var ret []string - return ret - } - return *o.Values -} - -// GetValuesOk returns a tuple with the Values field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersTag) GetValuesOk() ([]string, bool) { - if o == nil || o.Values == nil { - var ret []string - return ret, false - } - return *o.Values, true -} - -// HasValues returns a boolean if a field has been set. -func (o *FiltersTag) HasValues() bool { - if o != nil && o.Values != nil { - return true - } - - return false -} - -// SetValues gets a reference to the given []string and assigns it to the Values field. -func (o *FiltersTag) SetValues(v []string) { - o.Values = &v -} - -type NullableFiltersTag struct { - Value FiltersTag - ExplicitNull bool -} - -func (v NullableFiltersTag) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersTag) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_virtual_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_virtual_gateway.go deleted file mode 100644 index 1e0369fc2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_virtual_gateway.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVirtualGateway One or more filters. -type FiltersVirtualGateway struct { - // The types of the virtual gateways (only `ipsec.1` is supported). - ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` - // The IDs of the Nets the virtual gateways are attached to. - LinkNetIds *[]string `json:"LinkNetIds,omitempty"` - // The current states of the attachments between the virtual gateways and the Nets (`attaching` \\| `attached` \\| `detaching` \\| `detached`). - LinkStates *[]string `json:"LinkStates,omitempty"` - // The states of the virtual gateways (`pending` \\| `available` \\| `deleting` \\| `deleted`). - States *[]string `json:"States,omitempty"` - // The keys of the tags associated with the virtual gateways. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the virtual gateways. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the virtual gateways, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The IDs of the virtual gateways. - VirtualGatewayIds *[]string `json:"VirtualGatewayIds,omitempty"` -} - -// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetConnectionTypes() []string { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret - } - return *o.ConnectionTypes -} - -// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetConnectionTypesOk() ([]string, bool) { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret, false - } - return *o.ConnectionTypes, true -} - -// HasConnectionTypes returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasConnectionTypes() bool { - if o != nil && o.ConnectionTypes != nil { - return true - } - - return false -} - -// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. -func (o *FiltersVirtualGateway) SetConnectionTypes(v []string) { - o.ConnectionTypes = &v -} - -// GetLinkNetIds returns the LinkNetIds field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetLinkNetIds() []string { - if o == nil || o.LinkNetIds == nil { - var ret []string - return ret - } - return *o.LinkNetIds -} - -// GetLinkNetIdsOk returns a tuple with the LinkNetIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetLinkNetIdsOk() ([]string, bool) { - if o == nil || o.LinkNetIds == nil { - var ret []string - return ret, false - } - return *o.LinkNetIds, true -} - -// HasLinkNetIds returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasLinkNetIds() bool { - if o != nil && o.LinkNetIds != nil { - return true - } - - return false -} - -// SetLinkNetIds gets a reference to the given []string and assigns it to the LinkNetIds field. -func (o *FiltersVirtualGateway) SetLinkNetIds(v []string) { - o.LinkNetIds = &v -} - -// GetLinkStates returns the LinkStates field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetLinkStates() []string { - if o == nil || o.LinkStates == nil { - var ret []string - return ret - } - return *o.LinkStates -} - -// GetLinkStatesOk returns a tuple with the LinkStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetLinkStatesOk() ([]string, bool) { - if o == nil || o.LinkStates == nil { - var ret []string - return ret, false - } - return *o.LinkStates, true -} - -// HasLinkStates returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasLinkStates() bool { - if o != nil && o.LinkStates != nil { - return true - } - - return false -} - -// SetLinkStates gets a reference to the given []string and assigns it to the LinkStates field. -func (o *FiltersVirtualGateway) SetLinkStates(v []string) { - o.LinkStates = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersVirtualGateway) SetStates(v []string) { - o.States = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersVirtualGateway) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersVirtualGateway) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersVirtualGateway) SetTags(v []string) { - o.Tags = &v -} - -// GetVirtualGatewayIds returns the VirtualGatewayIds field value if set, zero value otherwise. -func (o *FiltersVirtualGateway) GetVirtualGatewayIds() []string { - if o == nil || o.VirtualGatewayIds == nil { - var ret []string - return ret - } - return *o.VirtualGatewayIds -} - -// GetVirtualGatewayIdsOk returns a tuple with the VirtualGatewayIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVirtualGateway) GetVirtualGatewayIdsOk() ([]string, bool) { - if o == nil || o.VirtualGatewayIds == nil { - var ret []string - return ret, false - } - return *o.VirtualGatewayIds, true -} - -// HasVirtualGatewayIds returns a boolean if a field has been set. -func (o *FiltersVirtualGateway) HasVirtualGatewayIds() bool { - if o != nil && o.VirtualGatewayIds != nil { - return true - } - - return false -} - -// SetVirtualGatewayIds gets a reference to the given []string and assigns it to the VirtualGatewayIds field. -func (o *FiltersVirtualGateway) SetVirtualGatewayIds(v []string) { - o.VirtualGatewayIds = &v -} - -type NullableFiltersVirtualGateway struct { - Value FiltersVirtualGateway - ExplicitNull bool -} - -func (v NullableFiltersVirtualGateway) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVirtualGateway) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm.go deleted file mode 100644 index af0e3ae0c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVm One or more filters. -type FiltersVm struct { - // The keys of the tags associated with the VMs. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the VMs. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the VMs, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // One or more IDs of VMs. - VmIds *[]string `json:"VmIds,omitempty"` -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersVm) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVm) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersVm) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersVm) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersVm) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVm) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersVm) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersVm) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersVm) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVm) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersVm) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersVm) SetTags(v []string) { - o.Tags = &v -} - -// GetVmIds returns the VmIds field value if set, zero value otherwise. -func (o *FiltersVm) GetVmIds() []string { - if o == nil || o.VmIds == nil { - var ret []string - return ret - } - return *o.VmIds -} - -// GetVmIdsOk returns a tuple with the VmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVm) GetVmIdsOk() ([]string, bool) { - if o == nil || o.VmIds == nil { - var ret []string - return ret, false - } - return *o.VmIds, true -} - -// HasVmIds returns a boolean if a field has been set. -func (o *FiltersVm) HasVmIds() bool { - if o != nil && o.VmIds != nil { - return true - } - - return false -} - -// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. -func (o *FiltersVm) SetVmIds(v []string) { - o.VmIds = &v -} - -type NullableFiltersVm struct { - Value FiltersVm - ExplicitNull bool -} - -func (v NullableFiltersVm) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVm) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm_type.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm_type.go deleted file mode 100644 index 69e0cab4e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vm_type.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVmType One or more filters. -type FiltersVmType struct { - // Indicates whether the VM is optimized for BSU I/O. - BsuOptimized *bool `json:"BsuOptimized,omitempty"` - // The amounts of memory, in gibibytes (GiB). - MemorySizes *[]float32 `json:"MemorySizes,omitempty"` - // The numbers of vCores. - VcoreCounts *[]int64 `json:"VcoreCounts,omitempty"` - // The names of the VM types. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - VmTypeNames *[]string `json:"VmTypeNames,omitempty"` - // The maximum number of ephemeral storage disks. - VolumeCounts *[]int64 `json:"VolumeCounts,omitempty"` - // The size of one ephemeral storage disk, in gibibytes (GiB). - VolumeSizes *[]int64 `json:"VolumeSizes,omitempty"` -} - -// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. -func (o *FiltersVmType) GetBsuOptimized() bool { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret - } - return *o.BsuOptimized -} - -// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetBsuOptimizedOk() (bool, bool) { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret, false - } - return *o.BsuOptimized, true -} - -// HasBsuOptimized returns a boolean if a field has been set. -func (o *FiltersVmType) HasBsuOptimized() bool { - if o != nil && o.BsuOptimized != nil { - return true - } - - return false -} - -// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. -func (o *FiltersVmType) SetBsuOptimized(v bool) { - o.BsuOptimized = &v -} - -// GetMemorySizes returns the MemorySizes field value if set, zero value otherwise. -func (o *FiltersVmType) GetMemorySizes() []float32 { - if o == nil || o.MemorySizes == nil { - var ret []float32 - return ret - } - return *o.MemorySizes -} - -// GetMemorySizesOk returns a tuple with the MemorySizes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetMemorySizesOk() ([]float32, bool) { - if o == nil || o.MemorySizes == nil { - var ret []float32 - return ret, false - } - return *o.MemorySizes, true -} - -// HasMemorySizes returns a boolean if a field has been set. -func (o *FiltersVmType) HasMemorySizes() bool { - if o != nil && o.MemorySizes != nil { - return true - } - - return false -} - -// SetMemorySizes gets a reference to the given []float32 and assigns it to the MemorySizes field. -func (o *FiltersVmType) SetMemorySizes(v []float32) { - o.MemorySizes = &v -} - -// GetVcoreCounts returns the VcoreCounts field value if set, zero value otherwise. -func (o *FiltersVmType) GetVcoreCounts() []int64 { - if o == nil || o.VcoreCounts == nil { - var ret []int64 - return ret - } - return *o.VcoreCounts -} - -// GetVcoreCountsOk returns a tuple with the VcoreCounts field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetVcoreCountsOk() ([]int64, bool) { - if o == nil || o.VcoreCounts == nil { - var ret []int64 - return ret, false - } - return *o.VcoreCounts, true -} - -// HasVcoreCounts returns a boolean if a field has been set. -func (o *FiltersVmType) HasVcoreCounts() bool { - if o != nil && o.VcoreCounts != nil { - return true - } - - return false -} - -// SetVcoreCounts gets a reference to the given []int64 and assigns it to the VcoreCounts field. -func (o *FiltersVmType) SetVcoreCounts(v []int64) { - o.VcoreCounts = &v -} - -// GetVmTypeNames returns the VmTypeNames field value if set, zero value otherwise. -func (o *FiltersVmType) GetVmTypeNames() []string { - if o == nil || o.VmTypeNames == nil { - var ret []string - return ret - } - return *o.VmTypeNames -} - -// GetVmTypeNamesOk returns a tuple with the VmTypeNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetVmTypeNamesOk() ([]string, bool) { - if o == nil || o.VmTypeNames == nil { - var ret []string - return ret, false - } - return *o.VmTypeNames, true -} - -// HasVmTypeNames returns a boolean if a field has been set. -func (o *FiltersVmType) HasVmTypeNames() bool { - if o != nil && o.VmTypeNames != nil { - return true - } - - return false -} - -// SetVmTypeNames gets a reference to the given []string and assigns it to the VmTypeNames field. -func (o *FiltersVmType) SetVmTypeNames(v []string) { - o.VmTypeNames = &v -} - -// GetVolumeCounts returns the VolumeCounts field value if set, zero value otherwise. -func (o *FiltersVmType) GetVolumeCounts() []int64 { - if o == nil || o.VolumeCounts == nil { - var ret []int64 - return ret - } - return *o.VolumeCounts -} - -// GetVolumeCountsOk returns a tuple with the VolumeCounts field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetVolumeCountsOk() ([]int64, bool) { - if o == nil || o.VolumeCounts == nil { - var ret []int64 - return ret, false - } - return *o.VolumeCounts, true -} - -// HasVolumeCounts returns a boolean if a field has been set. -func (o *FiltersVmType) HasVolumeCounts() bool { - if o != nil && o.VolumeCounts != nil { - return true - } - - return false -} - -// SetVolumeCounts gets a reference to the given []int64 and assigns it to the VolumeCounts field. -func (o *FiltersVmType) SetVolumeCounts(v []int64) { - o.VolumeCounts = &v -} - -// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. -func (o *FiltersVmType) GetVolumeSizes() []int64 { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret - } - return *o.VolumeSizes -} - -// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmType) GetVolumeSizesOk() ([]int64, bool) { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret, false - } - return *o.VolumeSizes, true -} - -// HasVolumeSizes returns a boolean if a field has been set. -func (o *FiltersVmType) HasVolumeSizes() bool { - if o != nil && o.VolumeSizes != nil { - return true - } - - return false -} - -// SetVolumeSizes gets a reference to the given []int64 and assigns it to the VolumeSizes field. -func (o *FiltersVmType) SetVolumeSizes(v []int64) { - o.VolumeSizes = &v -} - -type NullableFiltersVmType struct { - Value FiltersVmType - ExplicitNull bool -} - -func (v NullableFiltersVmType) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVmType) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vms_state.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vms_state.go deleted file mode 100644 index d61b68463..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vms_state.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVmsState One or more filters. -type FiltersVmsState struct { - // The names of the Subregions of the VMs. - SubregionNames *[]string `json:"SubregionNames,omitempty"` - // One or more IDs of VMs. - VmIds *[]string `json:"VmIds,omitempty"` - // The states of the VMs (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). - VmStates *[]string `json:"VmStates,omitempty"` -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *FiltersVmsState) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmsState) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *FiltersVmsState) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *FiltersVmsState) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -// GetVmIds returns the VmIds field value if set, zero value otherwise. -func (o *FiltersVmsState) GetVmIds() []string { - if o == nil || o.VmIds == nil { - var ret []string - return ret - } - return *o.VmIds -} - -// GetVmIdsOk returns a tuple with the VmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmsState) GetVmIdsOk() ([]string, bool) { - if o == nil || o.VmIds == nil { - var ret []string - return ret, false - } - return *o.VmIds, true -} - -// HasVmIds returns a boolean if a field has been set. -func (o *FiltersVmsState) HasVmIds() bool { - if o != nil && o.VmIds != nil { - return true - } - - return false -} - -// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. -func (o *FiltersVmsState) SetVmIds(v []string) { - o.VmIds = &v -} - -// GetVmStates returns the VmStates field value if set, zero value otherwise. -func (o *FiltersVmsState) GetVmStates() []string { - if o == nil || o.VmStates == nil { - var ret []string - return ret - } - return *o.VmStates -} - -// GetVmStatesOk returns a tuple with the VmStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVmsState) GetVmStatesOk() ([]string, bool) { - if o == nil || o.VmStates == nil { - var ret []string - return ret, false - } - return *o.VmStates, true -} - -// HasVmStates returns a boolean if a field has been set. -func (o *FiltersVmsState) HasVmStates() bool { - if o != nil && o.VmStates != nil { - return true - } - - return false -} - -// SetVmStates gets a reference to the given []string and assigns it to the VmStates field. -func (o *FiltersVmsState) SetVmStates(v []string) { - o.VmStates = &v -} - -type NullableFiltersVmsState struct { - Value FiltersVmsState - ExplicitNull bool -} - -func (v NullableFiltersVmsState) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVmsState) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_volume.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_volume.go deleted file mode 100644 index 354fc24c0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_volume.go +++ /dev/null @@ -1,568 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVolume One or more filters. -type FiltersVolume struct { - // The dates and times at which the volumes were created. - CreationDates *[]string `json:"CreationDates,omitempty"` - // Indicates whether the volumes are deleted when terminating the VMs. - LinkVolumeDeleteOnVmDeletion *bool `json:"LinkVolumeDeleteOnVmDeletion,omitempty"` - // The VM device names. - LinkVolumeDeviceNames *[]string `json:"LinkVolumeDeviceNames,omitempty"` - // The dates and times at which the volumes were created. - LinkVolumeLinkDates *[]string `json:"LinkVolumeLinkDates,omitempty"` - // The attachment states of the volumes (`attaching` \\| `detaching` \\| `attached` \\| `detached`). - LinkVolumeLinkStates *[]string `json:"LinkVolumeLinkStates,omitempty"` - // One or more IDs of VMs. - LinkVolumeVmIds *[]string `json:"LinkVolumeVmIds,omitempty"` - // The snapshots from which the volumes were created. - SnapshotIds *[]string `json:"SnapshotIds,omitempty"` - // The names of the Subregions in which the volumes were created. - SubregionNames *[]string `json:"SubregionNames,omitempty"` - // The keys of the tags associated with the volumes. - TagKeys *[]string `json:"TagKeys,omitempty"` - // The values of the tags associated with the volumes. - TagValues *[]string `json:"TagValues,omitempty"` - // The key/value combination of the tags associated with the volumes, in the following format: \"Filters\":{\"Tags\":[\"TAGKEY=TAGVALUE\"]}. - Tags *[]string `json:"Tags,omitempty"` - // The IDs of the volumes. - VolumeIds *[]string `json:"VolumeIds,omitempty"` - // The sizes of the volumes, in gibibytes (GiB). - VolumeSizes *[]int64 `json:"VolumeSizes,omitempty"` - // The states of the volumes (`creating` \\| `available` \\| `in-use` \\| `deleting` \\| `error`). - VolumeStates *[]string `json:"VolumeStates,omitempty"` - // The types of the volumes (`standard` \\| `gp2` \\| `io1`). - VolumeTypes *[]string `json:"VolumeTypes,omitempty"` -} - -// GetCreationDates returns the CreationDates field value if set, zero value otherwise. -func (o *FiltersVolume) GetCreationDates() []string { - if o == nil || o.CreationDates == nil { - var ret []string - return ret - } - return *o.CreationDates -} - -// GetCreationDatesOk returns a tuple with the CreationDates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetCreationDatesOk() ([]string, bool) { - if o == nil || o.CreationDates == nil { - var ret []string - return ret, false - } - return *o.CreationDates, true -} - -// HasCreationDates returns a boolean if a field has been set. -func (o *FiltersVolume) HasCreationDates() bool { - if o != nil && o.CreationDates != nil { - return true - } - - return false -} - -// SetCreationDates gets a reference to the given []string and assigns it to the CreationDates field. -func (o *FiltersVolume) SetCreationDates(v []string) { - o.CreationDates = &v -} - -// GetLinkVolumeDeleteOnVmDeletion returns the LinkVolumeDeleteOnVmDeletion field value if set, zero value otherwise. -func (o *FiltersVolume) GetLinkVolumeDeleteOnVmDeletion() bool { - if o == nil || o.LinkVolumeDeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.LinkVolumeDeleteOnVmDeletion -} - -// GetLinkVolumeDeleteOnVmDeletionOk returns a tuple with the LinkVolumeDeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetLinkVolumeDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.LinkVolumeDeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.LinkVolumeDeleteOnVmDeletion, true -} - -// HasLinkVolumeDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *FiltersVolume) HasLinkVolumeDeleteOnVmDeletion() bool { - if o != nil && o.LinkVolumeDeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetLinkVolumeDeleteOnVmDeletion gets a reference to the given bool and assigns it to the LinkVolumeDeleteOnVmDeletion field. -func (o *FiltersVolume) SetLinkVolumeDeleteOnVmDeletion(v bool) { - o.LinkVolumeDeleteOnVmDeletion = &v -} - -// GetLinkVolumeDeviceNames returns the LinkVolumeDeviceNames field value if set, zero value otherwise. -func (o *FiltersVolume) GetLinkVolumeDeviceNames() []string { - if o == nil || o.LinkVolumeDeviceNames == nil { - var ret []string - return ret - } - return *o.LinkVolumeDeviceNames -} - -// GetLinkVolumeDeviceNamesOk returns a tuple with the LinkVolumeDeviceNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetLinkVolumeDeviceNamesOk() ([]string, bool) { - if o == nil || o.LinkVolumeDeviceNames == nil { - var ret []string - return ret, false - } - return *o.LinkVolumeDeviceNames, true -} - -// HasLinkVolumeDeviceNames returns a boolean if a field has been set. -func (o *FiltersVolume) HasLinkVolumeDeviceNames() bool { - if o != nil && o.LinkVolumeDeviceNames != nil { - return true - } - - return false -} - -// SetLinkVolumeDeviceNames gets a reference to the given []string and assigns it to the LinkVolumeDeviceNames field. -func (o *FiltersVolume) SetLinkVolumeDeviceNames(v []string) { - o.LinkVolumeDeviceNames = &v -} - -// GetLinkVolumeLinkDates returns the LinkVolumeLinkDates field value if set, zero value otherwise. -func (o *FiltersVolume) GetLinkVolumeLinkDates() []string { - if o == nil || o.LinkVolumeLinkDates == nil { - var ret []string - return ret - } - return *o.LinkVolumeLinkDates -} - -// GetLinkVolumeLinkDatesOk returns a tuple with the LinkVolumeLinkDates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetLinkVolumeLinkDatesOk() ([]string, bool) { - if o == nil || o.LinkVolumeLinkDates == nil { - var ret []string - return ret, false - } - return *o.LinkVolumeLinkDates, true -} - -// HasLinkVolumeLinkDates returns a boolean if a field has been set. -func (o *FiltersVolume) HasLinkVolumeLinkDates() bool { - if o != nil && o.LinkVolumeLinkDates != nil { - return true - } - - return false -} - -// SetLinkVolumeLinkDates gets a reference to the given []string and assigns it to the LinkVolumeLinkDates field. -func (o *FiltersVolume) SetLinkVolumeLinkDates(v []string) { - o.LinkVolumeLinkDates = &v -} - -// GetLinkVolumeLinkStates returns the LinkVolumeLinkStates field value if set, zero value otherwise. -func (o *FiltersVolume) GetLinkVolumeLinkStates() []string { - if o == nil || o.LinkVolumeLinkStates == nil { - var ret []string - return ret - } - return *o.LinkVolumeLinkStates -} - -// GetLinkVolumeLinkStatesOk returns a tuple with the LinkVolumeLinkStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetLinkVolumeLinkStatesOk() ([]string, bool) { - if o == nil || o.LinkVolumeLinkStates == nil { - var ret []string - return ret, false - } - return *o.LinkVolumeLinkStates, true -} - -// HasLinkVolumeLinkStates returns a boolean if a field has been set. -func (o *FiltersVolume) HasLinkVolumeLinkStates() bool { - if o != nil && o.LinkVolumeLinkStates != nil { - return true - } - - return false -} - -// SetLinkVolumeLinkStates gets a reference to the given []string and assigns it to the LinkVolumeLinkStates field. -func (o *FiltersVolume) SetLinkVolumeLinkStates(v []string) { - o.LinkVolumeLinkStates = &v -} - -// GetLinkVolumeVmIds returns the LinkVolumeVmIds field value if set, zero value otherwise. -func (o *FiltersVolume) GetLinkVolumeVmIds() []string { - if o == nil || o.LinkVolumeVmIds == nil { - var ret []string - return ret - } - return *o.LinkVolumeVmIds -} - -// GetLinkVolumeVmIdsOk returns a tuple with the LinkVolumeVmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetLinkVolumeVmIdsOk() ([]string, bool) { - if o == nil || o.LinkVolumeVmIds == nil { - var ret []string - return ret, false - } - return *o.LinkVolumeVmIds, true -} - -// HasLinkVolumeVmIds returns a boolean if a field has been set. -func (o *FiltersVolume) HasLinkVolumeVmIds() bool { - if o != nil && o.LinkVolumeVmIds != nil { - return true - } - - return false -} - -// SetLinkVolumeVmIds gets a reference to the given []string and assigns it to the LinkVolumeVmIds field. -func (o *FiltersVolume) SetLinkVolumeVmIds(v []string) { - o.LinkVolumeVmIds = &v -} - -// GetSnapshotIds returns the SnapshotIds field value if set, zero value otherwise. -func (o *FiltersVolume) GetSnapshotIds() []string { - if o == nil || o.SnapshotIds == nil { - var ret []string - return ret - } - return *o.SnapshotIds -} - -// GetSnapshotIdsOk returns a tuple with the SnapshotIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetSnapshotIdsOk() ([]string, bool) { - if o == nil || o.SnapshotIds == nil { - var ret []string - return ret, false - } - return *o.SnapshotIds, true -} - -// HasSnapshotIds returns a boolean if a field has been set. -func (o *FiltersVolume) HasSnapshotIds() bool { - if o != nil && o.SnapshotIds != nil { - return true - } - - return false -} - -// SetSnapshotIds gets a reference to the given []string and assigns it to the SnapshotIds field. -func (o *FiltersVolume) SetSnapshotIds(v []string) { - o.SnapshotIds = &v -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *FiltersVolume) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *FiltersVolume) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *FiltersVolume) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -// GetTagKeys returns the TagKeys field value if set, zero value otherwise. -func (o *FiltersVolume) GetTagKeys() []string { - if o == nil || o.TagKeys == nil { - var ret []string - return ret - } - return *o.TagKeys -} - -// GetTagKeysOk returns a tuple with the TagKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetTagKeysOk() ([]string, bool) { - if o == nil || o.TagKeys == nil { - var ret []string - return ret, false - } - return *o.TagKeys, true -} - -// HasTagKeys returns a boolean if a field has been set. -func (o *FiltersVolume) HasTagKeys() bool { - if o != nil && o.TagKeys != nil { - return true - } - - return false -} - -// SetTagKeys gets a reference to the given []string and assigns it to the TagKeys field. -func (o *FiltersVolume) SetTagKeys(v []string) { - o.TagKeys = &v -} - -// GetTagValues returns the TagValues field value if set, zero value otherwise. -func (o *FiltersVolume) GetTagValues() []string { - if o == nil || o.TagValues == nil { - var ret []string - return ret - } - return *o.TagValues -} - -// GetTagValuesOk returns a tuple with the TagValues field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetTagValuesOk() ([]string, bool) { - if o == nil || o.TagValues == nil { - var ret []string - return ret, false - } - return *o.TagValues, true -} - -// HasTagValues returns a boolean if a field has been set. -func (o *FiltersVolume) HasTagValues() bool { - if o != nil && o.TagValues != nil { - return true - } - - return false -} - -// SetTagValues gets a reference to the given []string and assigns it to the TagValues field. -func (o *FiltersVolume) SetTagValues(v []string) { - o.TagValues = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *FiltersVolume) GetTags() []string { - if o == nil || o.Tags == nil { - var ret []string - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetTagsOk() ([]string, bool) { - if o == nil || o.Tags == nil { - var ret []string - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *FiltersVolume) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []string and assigns it to the Tags field. -func (o *FiltersVolume) SetTags(v []string) { - o.Tags = &v -} - -// GetVolumeIds returns the VolumeIds field value if set, zero value otherwise. -func (o *FiltersVolume) GetVolumeIds() []string { - if o == nil || o.VolumeIds == nil { - var ret []string - return ret - } - return *o.VolumeIds -} - -// GetVolumeIdsOk returns a tuple with the VolumeIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetVolumeIdsOk() ([]string, bool) { - if o == nil || o.VolumeIds == nil { - var ret []string - return ret, false - } - return *o.VolumeIds, true -} - -// HasVolumeIds returns a boolean if a field has been set. -func (o *FiltersVolume) HasVolumeIds() bool { - if o != nil && o.VolumeIds != nil { - return true - } - - return false -} - -// SetVolumeIds gets a reference to the given []string and assigns it to the VolumeIds field. -func (o *FiltersVolume) SetVolumeIds(v []string) { - o.VolumeIds = &v -} - -// GetVolumeSizes returns the VolumeSizes field value if set, zero value otherwise. -func (o *FiltersVolume) GetVolumeSizes() []int64 { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret - } - return *o.VolumeSizes -} - -// GetVolumeSizesOk returns a tuple with the VolumeSizes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetVolumeSizesOk() ([]int64, bool) { - if o == nil || o.VolumeSizes == nil { - var ret []int64 - return ret, false - } - return *o.VolumeSizes, true -} - -// HasVolumeSizes returns a boolean if a field has been set. -func (o *FiltersVolume) HasVolumeSizes() bool { - if o != nil && o.VolumeSizes != nil { - return true - } - - return false -} - -// SetVolumeSizes gets a reference to the given []int64 and assigns it to the VolumeSizes field. -func (o *FiltersVolume) SetVolumeSizes(v []int64) { - o.VolumeSizes = &v -} - -// GetVolumeStates returns the VolumeStates field value if set, zero value otherwise. -func (o *FiltersVolume) GetVolumeStates() []string { - if o == nil || o.VolumeStates == nil { - var ret []string - return ret - } - return *o.VolumeStates -} - -// GetVolumeStatesOk returns a tuple with the VolumeStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetVolumeStatesOk() ([]string, bool) { - if o == nil || o.VolumeStates == nil { - var ret []string - return ret, false - } - return *o.VolumeStates, true -} - -// HasVolumeStates returns a boolean if a field has been set. -func (o *FiltersVolume) HasVolumeStates() bool { - if o != nil && o.VolumeStates != nil { - return true - } - - return false -} - -// SetVolumeStates gets a reference to the given []string and assigns it to the VolumeStates field. -func (o *FiltersVolume) SetVolumeStates(v []string) { - o.VolumeStates = &v -} - -// GetVolumeTypes returns the VolumeTypes field value if set, zero value otherwise. -func (o *FiltersVolume) GetVolumeTypes() []string { - if o == nil || o.VolumeTypes == nil { - var ret []string - return ret - } - return *o.VolumeTypes -} - -// GetVolumeTypesOk returns a tuple with the VolumeTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVolume) GetVolumeTypesOk() ([]string, bool) { - if o == nil || o.VolumeTypes == nil { - var ret []string - return ret, false - } - return *o.VolumeTypes, true -} - -// HasVolumeTypes returns a boolean if a field has been set. -func (o *FiltersVolume) HasVolumeTypes() bool { - if o != nil && o.VolumeTypes != nil { - return true - } - - return false -} - -// SetVolumeTypes gets a reference to the given []string and assigns it to the VolumeTypes field. -func (o *FiltersVolume) SetVolumeTypes(v []string) { - o.VolumeTypes = &v -} - -type NullableFiltersVolume struct { - Value FiltersVolume - ExplicitNull bool -} - -func (v NullableFiltersVolume) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVolume) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vpn_connection.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vpn_connection.go deleted file mode 100644 index af2423351..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_filters_vpn_connection.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FiltersVpnConnection One or more filters. -type FiltersVpnConnection struct { - // The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. - BgpAsns *[]int64 `json:"BgpAsns,omitempty"` - // The IDs of the client gateways. - ClientGatewayIds *[]string `json:"ClientGatewayIds,omitempty"` - // The types of the VPN connections (only `ipsec.1` is supported). - ConnectionTypes *[]string `json:"ConnectionTypes,omitempty"` - // The destination IP ranges. - RouteDestinationIpRanges *[]string `json:"RouteDestinationIpRanges,omitempty"` - // The states of the VPN connections (`pending` \\| `available` \\| `deleting` \\| `deleted`). - States *[]string `json:"States,omitempty"` - // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` - // The IDs of the virtual gateways. - VirtualGatewayIds *[]string `json:"VirtualGatewayIds,omitempty"` - // The IDs of the VPN connections. - VpnConnectionIds *[]string `json:"VpnConnectionIds,omitempty"` -} - -// GetBgpAsns returns the BgpAsns field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetBgpAsns() []int64 { - if o == nil || o.BgpAsns == nil { - var ret []int64 - return ret - } - return *o.BgpAsns -} - -// GetBgpAsnsOk returns a tuple with the BgpAsns field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetBgpAsnsOk() ([]int64, bool) { - if o == nil || o.BgpAsns == nil { - var ret []int64 - return ret, false - } - return *o.BgpAsns, true -} - -// HasBgpAsns returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasBgpAsns() bool { - if o != nil && o.BgpAsns != nil { - return true - } - - return false -} - -// SetBgpAsns gets a reference to the given []int64 and assigns it to the BgpAsns field. -func (o *FiltersVpnConnection) SetBgpAsns(v []int64) { - o.BgpAsns = &v -} - -// GetClientGatewayIds returns the ClientGatewayIds field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetClientGatewayIds() []string { - if o == nil || o.ClientGatewayIds == nil { - var ret []string - return ret - } - return *o.ClientGatewayIds -} - -// GetClientGatewayIdsOk returns a tuple with the ClientGatewayIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetClientGatewayIdsOk() ([]string, bool) { - if o == nil || o.ClientGatewayIds == nil { - var ret []string - return ret, false - } - return *o.ClientGatewayIds, true -} - -// HasClientGatewayIds returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasClientGatewayIds() bool { - if o != nil && o.ClientGatewayIds != nil { - return true - } - - return false -} - -// SetClientGatewayIds gets a reference to the given []string and assigns it to the ClientGatewayIds field. -func (o *FiltersVpnConnection) SetClientGatewayIds(v []string) { - o.ClientGatewayIds = &v -} - -// GetConnectionTypes returns the ConnectionTypes field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetConnectionTypes() []string { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret - } - return *o.ConnectionTypes -} - -// GetConnectionTypesOk returns a tuple with the ConnectionTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetConnectionTypesOk() ([]string, bool) { - if o == nil || o.ConnectionTypes == nil { - var ret []string - return ret, false - } - return *o.ConnectionTypes, true -} - -// HasConnectionTypes returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasConnectionTypes() bool { - if o != nil && o.ConnectionTypes != nil { - return true - } - - return false -} - -// SetConnectionTypes gets a reference to the given []string and assigns it to the ConnectionTypes field. -func (o *FiltersVpnConnection) SetConnectionTypes(v []string) { - o.ConnectionTypes = &v -} - -// GetRouteDestinationIpRanges returns the RouteDestinationIpRanges field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetRouteDestinationIpRanges() []string { - if o == nil || o.RouteDestinationIpRanges == nil { - var ret []string - return ret - } - return *o.RouteDestinationIpRanges -} - -// GetRouteDestinationIpRangesOk returns a tuple with the RouteDestinationIpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetRouteDestinationIpRangesOk() ([]string, bool) { - if o == nil || o.RouteDestinationIpRanges == nil { - var ret []string - return ret, false - } - return *o.RouteDestinationIpRanges, true -} - -// HasRouteDestinationIpRanges returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasRouteDestinationIpRanges() bool { - if o != nil && o.RouteDestinationIpRanges != nil { - return true - } - - return false -} - -// SetRouteDestinationIpRanges gets a reference to the given []string and assigns it to the RouteDestinationIpRanges field. -func (o *FiltersVpnConnection) SetRouteDestinationIpRanges(v []string) { - o.RouteDestinationIpRanges = &v -} - -// GetStates returns the States field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetStates() []string { - if o == nil || o.States == nil { - var ret []string - return ret - } - return *o.States -} - -// GetStatesOk returns a tuple with the States field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetStatesOk() ([]string, bool) { - if o == nil || o.States == nil { - var ret []string - return ret, false - } - return *o.States, true -} - -// HasStates returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasStates() bool { - if o != nil && o.States != nil { - return true - } - - return false -} - -// SetStates gets a reference to the given []string and assigns it to the States field. -func (o *FiltersVpnConnection) SetStates(v []string) { - o.States = &v -} - -// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetStaticRoutesOnly() bool { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret - } - return *o.StaticRoutesOnly -} - -// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetStaticRoutesOnlyOk() (bool, bool) { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret, false - } - return *o.StaticRoutesOnly, true -} - -// HasStaticRoutesOnly returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasStaticRoutesOnly() bool { - if o != nil && o.StaticRoutesOnly != nil { - return true - } - - return false -} - -// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. -func (o *FiltersVpnConnection) SetStaticRoutesOnly(v bool) { - o.StaticRoutesOnly = &v -} - -// GetVirtualGatewayIds returns the VirtualGatewayIds field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetVirtualGatewayIds() []string { - if o == nil || o.VirtualGatewayIds == nil { - var ret []string - return ret - } - return *o.VirtualGatewayIds -} - -// GetVirtualGatewayIdsOk returns a tuple with the VirtualGatewayIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetVirtualGatewayIdsOk() ([]string, bool) { - if o == nil || o.VirtualGatewayIds == nil { - var ret []string - return ret, false - } - return *o.VirtualGatewayIds, true -} - -// HasVirtualGatewayIds returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasVirtualGatewayIds() bool { - if o != nil && o.VirtualGatewayIds != nil { - return true - } - - return false -} - -// SetVirtualGatewayIds gets a reference to the given []string and assigns it to the VirtualGatewayIds field. -func (o *FiltersVpnConnection) SetVirtualGatewayIds(v []string) { - o.VirtualGatewayIds = &v -} - -// GetVpnConnectionIds returns the VpnConnectionIds field value if set, zero value otherwise. -func (o *FiltersVpnConnection) GetVpnConnectionIds() []string { - if o == nil || o.VpnConnectionIds == nil { - var ret []string - return ret - } - return *o.VpnConnectionIds -} - -// GetVpnConnectionIdsOk returns a tuple with the VpnConnectionIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FiltersVpnConnection) GetVpnConnectionIdsOk() ([]string, bool) { - if o == nil || o.VpnConnectionIds == nil { - var ret []string - return ret, false - } - return *o.VpnConnectionIds, true -} - -// HasVpnConnectionIds returns a boolean if a field has been set. -func (o *FiltersVpnConnection) HasVpnConnectionIds() bool { - if o != nil && o.VpnConnectionIds != nil { - return true - } - - return false -} - -// SetVpnConnectionIds gets a reference to the given []string and assigns it to the VpnConnectionIds field. -func (o *FiltersVpnConnection) SetVpnConnectionIds(v []string) { - o.VpnConnectionIds = &v -} - -type NullableFiltersVpnConnection struct { - Value FiltersVpnConnection - ExplicitNull bool -} - -func (v NullableFiltersVpnConnection) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFiltersVpnConnection) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu.go deleted file mode 100644 index 20216ad17..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FlexibleGpu Information about the flexible GPU (fGPU). -type FlexibleGpu struct { - // If `true`, the fGPU is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The ID of the fGPU. - FlexibleGpuId *string `json:"FlexibleGpuId,omitempty"` - // The compatible processor generation. - Generation *string `json:"Generation,omitempty"` - // The model of fGPU. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - ModelName *string `json:"ModelName,omitempty"` - // The state of the fGPU (`allocated` \\| `attaching` \\| `attached` \\| `detaching`). - State *string `json:"State,omitempty"` - // The Subregion where the fGPU is located. - SubregionName *string `json:"SubregionName,omitempty"` - // The ID of the VM the fGPU is attached to, if any. - VmId *string `json:"VmId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *FlexibleGpu) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *FlexibleGpu) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *FlexibleGpu) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetFlexibleGpuId returns the FlexibleGpuId field value if set, zero value otherwise. -func (o *FlexibleGpu) GetFlexibleGpuId() string { - if o == nil || o.FlexibleGpuId == nil { - var ret string - return ret - } - return *o.FlexibleGpuId -} - -// GetFlexibleGpuIdOk returns a tuple with the FlexibleGpuId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetFlexibleGpuIdOk() (string, bool) { - if o == nil || o.FlexibleGpuId == nil { - var ret string - return ret, false - } - return *o.FlexibleGpuId, true -} - -// HasFlexibleGpuId returns a boolean if a field has been set. -func (o *FlexibleGpu) HasFlexibleGpuId() bool { - if o != nil && o.FlexibleGpuId != nil { - return true - } - - return false -} - -// SetFlexibleGpuId gets a reference to the given string and assigns it to the FlexibleGpuId field. -func (o *FlexibleGpu) SetFlexibleGpuId(v string) { - o.FlexibleGpuId = &v -} - -// GetGeneration returns the Generation field value if set, zero value otherwise. -func (o *FlexibleGpu) GetGeneration() string { - if o == nil || o.Generation == nil { - var ret string - return ret - } - return *o.Generation -} - -// GetGenerationOk returns a tuple with the Generation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetGenerationOk() (string, bool) { - if o == nil || o.Generation == nil { - var ret string - return ret, false - } - return *o.Generation, true -} - -// HasGeneration returns a boolean if a field has been set. -func (o *FlexibleGpu) HasGeneration() bool { - if o != nil && o.Generation != nil { - return true - } - - return false -} - -// SetGeneration gets a reference to the given string and assigns it to the Generation field. -func (o *FlexibleGpu) SetGeneration(v string) { - o.Generation = &v -} - -// GetModelName returns the ModelName field value if set, zero value otherwise. -func (o *FlexibleGpu) GetModelName() string { - if o == nil || o.ModelName == nil { - var ret string - return ret - } - return *o.ModelName -} - -// GetModelNameOk returns a tuple with the ModelName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetModelNameOk() (string, bool) { - if o == nil || o.ModelName == nil { - var ret string - return ret, false - } - return *o.ModelName, true -} - -// HasModelName returns a boolean if a field has been set. -func (o *FlexibleGpu) HasModelName() bool { - if o != nil && o.ModelName != nil { - return true - } - - return false -} - -// SetModelName gets a reference to the given string and assigns it to the ModelName field. -func (o *FlexibleGpu) SetModelName(v string) { - o.ModelName = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *FlexibleGpu) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *FlexibleGpu) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *FlexibleGpu) SetState(v string) { - o.State = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *FlexibleGpu) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *FlexibleGpu) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *FlexibleGpu) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *FlexibleGpu) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpu) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *FlexibleGpu) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *FlexibleGpu) SetVmId(v string) { - o.VmId = &v -} - -type NullableFlexibleGpu struct { - Value FlexibleGpu - ExplicitNull bool -} - -func (v NullableFlexibleGpu) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFlexibleGpu) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu_catalog.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu_catalog.go deleted file mode 100644 index 750627f26..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_flexible_gpu_catalog.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// FlexibleGpuCatalog Information about the flexible GPU (fGPU) that is available in the public catalog. -type FlexibleGpuCatalog struct { - // The generations of VMs that the fGPU is compatible with. - Generations *string `json:"Generations,omitempty"` - // The maximum number of VM vCores that the fGPU is compatible with. - MaxCpu *int64 `json:"MaxCpu,omitempty"` - // The maximum amount of VM memory that the fGPU is compatible with. - MaxRam *int64 `json:"MaxRam,omitempty"` - // The model of fGPU. - ModelName *string `json:"ModelName,omitempty"` - // The amount of video RAM (VRAM) of the fGPU. - VRam *int64 `json:"VRam,omitempty"` -} - -// GetGenerations returns the Generations field value if set, zero value otherwise. -func (o *FlexibleGpuCatalog) GetGenerations() string { - if o == nil || o.Generations == nil { - var ret string - return ret - } - return *o.Generations -} - -// GetGenerationsOk returns a tuple with the Generations field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpuCatalog) GetGenerationsOk() (string, bool) { - if o == nil || o.Generations == nil { - var ret string - return ret, false - } - return *o.Generations, true -} - -// HasGenerations returns a boolean if a field has been set. -func (o *FlexibleGpuCatalog) HasGenerations() bool { - if o != nil && o.Generations != nil { - return true - } - - return false -} - -// SetGenerations gets a reference to the given string and assigns it to the Generations field. -func (o *FlexibleGpuCatalog) SetGenerations(v string) { - o.Generations = &v -} - -// GetMaxCpu returns the MaxCpu field value if set, zero value otherwise. -func (o *FlexibleGpuCatalog) GetMaxCpu() int64 { - if o == nil || o.MaxCpu == nil { - var ret int64 - return ret - } - return *o.MaxCpu -} - -// GetMaxCpuOk returns a tuple with the MaxCpu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpuCatalog) GetMaxCpuOk() (int64, bool) { - if o == nil || o.MaxCpu == nil { - var ret int64 - return ret, false - } - return *o.MaxCpu, true -} - -// HasMaxCpu returns a boolean if a field has been set. -func (o *FlexibleGpuCatalog) HasMaxCpu() bool { - if o != nil && o.MaxCpu != nil { - return true - } - - return false -} - -// SetMaxCpu gets a reference to the given int64 and assigns it to the MaxCpu field. -func (o *FlexibleGpuCatalog) SetMaxCpu(v int64) { - o.MaxCpu = &v -} - -// GetMaxRam returns the MaxRam field value if set, zero value otherwise. -func (o *FlexibleGpuCatalog) GetMaxRam() int64 { - if o == nil || o.MaxRam == nil { - var ret int64 - return ret - } - return *o.MaxRam -} - -// GetMaxRamOk returns a tuple with the MaxRam field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpuCatalog) GetMaxRamOk() (int64, bool) { - if o == nil || o.MaxRam == nil { - var ret int64 - return ret, false - } - return *o.MaxRam, true -} - -// HasMaxRam returns a boolean if a field has been set. -func (o *FlexibleGpuCatalog) HasMaxRam() bool { - if o != nil && o.MaxRam != nil { - return true - } - - return false -} - -// SetMaxRam gets a reference to the given int64 and assigns it to the MaxRam field. -func (o *FlexibleGpuCatalog) SetMaxRam(v int64) { - o.MaxRam = &v -} - -// GetModelName returns the ModelName field value if set, zero value otherwise. -func (o *FlexibleGpuCatalog) GetModelName() string { - if o == nil || o.ModelName == nil { - var ret string - return ret - } - return *o.ModelName -} - -// GetModelNameOk returns a tuple with the ModelName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpuCatalog) GetModelNameOk() (string, bool) { - if o == nil || o.ModelName == nil { - var ret string - return ret, false - } - return *o.ModelName, true -} - -// HasModelName returns a boolean if a field has been set. -func (o *FlexibleGpuCatalog) HasModelName() bool { - if o != nil && o.ModelName != nil { - return true - } - - return false -} - -// SetModelName gets a reference to the given string and assigns it to the ModelName field. -func (o *FlexibleGpuCatalog) SetModelName(v string) { - o.ModelName = &v -} - -// GetVRam returns the VRam field value if set, zero value otherwise. -func (o *FlexibleGpuCatalog) GetVRam() int64 { - if o == nil || o.VRam == nil { - var ret int64 - return ret - } - return *o.VRam -} - -// GetVRamOk returns a tuple with the VRam field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *FlexibleGpuCatalog) GetVRamOk() (int64, bool) { - if o == nil || o.VRam == nil { - var ret int64 - return ret, false - } - return *o.VRam, true -} - -// HasVRam returns a boolean if a field has been set. -func (o *FlexibleGpuCatalog) HasVRam() bool { - if o != nil && o.VRam != nil { - return true - } - - return false -} - -// SetVRam gets a reference to the given int64 and assigns it to the VRam field. -func (o *FlexibleGpuCatalog) SetVRam(v int64) { - o.VRam = &v -} - -type NullableFlexibleGpuCatalog struct { - Value FlexibleGpuCatalog - ExplicitNull bool -} - -func (v NullableFlexibleGpuCatalog) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFlexibleGpuCatalog) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_health_check.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_health_check.go deleted file mode 100644 index 1d34332b8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_health_check.go +++ /dev/null @@ -1,162 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// HealthCheck Information about the health check configuration. -type HealthCheck struct { - // The number of seconds between two pings (between `5` and `600` both included). - CheckInterval int64 `json:"CheckInterval"` - // The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - HealthyThreshold int64 `json:"HealthyThreshold"` - // The path for HTTP or HTTPS requests. - Path string `json:"Path"` - // The port number (between `1` and `65535`, both included). - Port int64 `json:"Port"` - // The protocol for the URL of the VM (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). - Protocol string `json:"Protocol"` - // The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - Timeout int64 `json:"Timeout"` - // The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). - UnhealthyThreshold int64 `json:"UnhealthyThreshold"` -} - -// GetCheckInterval returns the CheckInterval field value -func (o *HealthCheck) GetCheckInterval() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.CheckInterval -} - -// SetCheckInterval sets field value -func (o *HealthCheck) SetCheckInterval(v int64) { - o.CheckInterval = v -} - -// GetHealthyThreshold returns the HealthyThreshold field value -func (o *HealthCheck) GetHealthyThreshold() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.HealthyThreshold -} - -// SetHealthyThreshold sets field value -func (o *HealthCheck) SetHealthyThreshold(v int64) { - o.HealthyThreshold = v -} - -// GetPath returns the Path field value -func (o *HealthCheck) GetPath() string { - if o == nil { - var ret string - return ret - } - - return o.Path -} - -// SetPath sets field value -func (o *HealthCheck) SetPath(v string) { - o.Path = v -} - -// GetPort returns the Port field value -func (o *HealthCheck) GetPort() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.Port -} - -// SetPort sets field value -func (o *HealthCheck) SetPort(v int64) { - o.Port = v -} - -// GetProtocol returns the Protocol field value -func (o *HealthCheck) GetProtocol() string { - if o == nil { - var ret string - return ret - } - - return o.Protocol -} - -// SetProtocol sets field value -func (o *HealthCheck) SetProtocol(v string) { - o.Protocol = v -} - -// GetTimeout returns the Timeout field value -func (o *HealthCheck) GetTimeout() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.Timeout -} - -// SetTimeout sets field value -func (o *HealthCheck) SetTimeout(v int64) { - o.Timeout = v -} - -// GetUnhealthyThreshold returns the UnhealthyThreshold field value -func (o *HealthCheck) GetUnhealthyThreshold() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.UnhealthyThreshold -} - -// SetUnhealthyThreshold sets field value -func (o *HealthCheck) SetUnhealthyThreshold(v int64) { - o.UnhealthyThreshold = v -} - -type NullableHealthCheck struct { - Value HealthCheck - ExplicitNull bool -} - -func (v NullableHealthCheck) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableHealthCheck) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_image.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_image.go deleted file mode 100644 index f875f9b17..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_image.go +++ /dev/null @@ -1,636 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Image Information about the OMI. -type Image struct { - // The account alias of the owner of the OMI. - AccountAlias *string `json:"AccountAlias,omitempty"` - // The account ID of the owner of the OMI. - AccountId *string `json:"AccountId,omitempty"` - // The architecture of the OMI (by default, `i386`). - Architecture *string `json:"Architecture,omitempty"` - // One or more block device mappings. - BlockDeviceMappings *[]BlockDeviceMappingImage `json:"BlockDeviceMappings,omitempty"` - // The date and time at which the OMI was created. - CreationDate *string `json:"CreationDate,omitempty"` - // The description of the OMI. - Description *string `json:"Description,omitempty"` - // The location where the OMI file is stored on Object Storage Unit (OSU). - FileLocation *string `json:"FileLocation,omitempty"` - // The ID of the OMI. - ImageId *string `json:"ImageId,omitempty"` - // The name of the OMI. - ImageName *string `json:"ImageName,omitempty"` - // The type of the OMI. - ImageType *string `json:"ImageType,omitempty"` - PermissionsToLaunch *PermissionsOnResource `json:"PermissionsToLaunch,omitempty"` - // The product code associated with the OMI (`0001` Linux/Unix \\| `0002` Windows \\| `0004` Linux/Oracle \\| `0005` Windows 10). - ProductCodes *[]string `json:"ProductCodes,omitempty"` - // The name of the root device. - RootDeviceName *string `json:"RootDeviceName,omitempty"` - // The type of root device used by the OMI (always `bsu`). - RootDeviceType *string `json:"RootDeviceType,omitempty"` - // The state of the OMI (`pending` \\| `available` \\| `failed`). - State *string `json:"State,omitempty"` - StateComment *StateComment `json:"StateComment,omitempty"` - // One or more tags associated with the OMI. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAccountAlias returns the AccountAlias field value if set, zero value otherwise. -func (o *Image) GetAccountAlias() string { - if o == nil || o.AccountAlias == nil { - var ret string - return ret - } - return *o.AccountAlias -} - -// GetAccountAliasOk returns a tuple with the AccountAlias field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetAccountAliasOk() (string, bool) { - if o == nil || o.AccountAlias == nil { - var ret string - return ret, false - } - return *o.AccountAlias, true -} - -// HasAccountAlias returns a boolean if a field has been set. -func (o *Image) HasAccountAlias() bool { - if o != nil && o.AccountAlias != nil { - return true - } - - return false -} - -// SetAccountAlias gets a reference to the given string and assigns it to the AccountAlias field. -func (o *Image) SetAccountAlias(v string) { - o.AccountAlias = &v -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Image) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Image) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Image) SetAccountId(v string) { - o.AccountId = &v -} - -// GetArchitecture returns the Architecture field value if set, zero value otherwise. -func (o *Image) GetArchitecture() string { - if o == nil || o.Architecture == nil { - var ret string - return ret - } - return *o.Architecture -} - -// GetArchitectureOk returns a tuple with the Architecture field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetArchitectureOk() (string, bool) { - if o == nil || o.Architecture == nil { - var ret string - return ret, false - } - return *o.Architecture, true -} - -// HasArchitecture returns a boolean if a field has been set. -func (o *Image) HasArchitecture() bool { - if o != nil && o.Architecture != nil { - return true - } - - return false -} - -// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. -func (o *Image) SetArchitecture(v string) { - o.Architecture = &v -} - -// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. -func (o *Image) GetBlockDeviceMappings() []BlockDeviceMappingImage { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingImage - return ret - } - return *o.BlockDeviceMappings -} - -// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetBlockDeviceMappingsOk() ([]BlockDeviceMappingImage, bool) { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingImage - return ret, false - } - return *o.BlockDeviceMappings, true -} - -// HasBlockDeviceMappings returns a boolean if a field has been set. -func (o *Image) HasBlockDeviceMappings() bool { - if o != nil && o.BlockDeviceMappings != nil { - return true - } - - return false -} - -// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingImage and assigns it to the BlockDeviceMappings field. -func (o *Image) SetBlockDeviceMappings(v []BlockDeviceMappingImage) { - o.BlockDeviceMappings = &v -} - -// GetCreationDate returns the CreationDate field value if set, zero value otherwise. -func (o *Image) GetCreationDate() string { - if o == nil || o.CreationDate == nil { - var ret string - return ret - } - return *o.CreationDate -} - -// GetCreationDateOk returns a tuple with the CreationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetCreationDateOk() (string, bool) { - if o == nil || o.CreationDate == nil { - var ret string - return ret, false - } - return *o.CreationDate, true -} - -// HasCreationDate returns a boolean if a field has been set. -func (o *Image) HasCreationDate() bool { - if o != nil && o.CreationDate != nil { - return true - } - - return false -} - -// SetCreationDate gets a reference to the given string and assigns it to the CreationDate field. -func (o *Image) SetCreationDate(v string) { - o.CreationDate = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *Image) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *Image) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *Image) SetDescription(v string) { - o.Description = &v -} - -// GetFileLocation returns the FileLocation field value if set, zero value otherwise. -func (o *Image) GetFileLocation() string { - if o == nil || o.FileLocation == nil { - var ret string - return ret - } - return *o.FileLocation -} - -// GetFileLocationOk returns a tuple with the FileLocation field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetFileLocationOk() (string, bool) { - if o == nil || o.FileLocation == nil { - var ret string - return ret, false - } - return *o.FileLocation, true -} - -// HasFileLocation returns a boolean if a field has been set. -func (o *Image) HasFileLocation() bool { - if o != nil && o.FileLocation != nil { - return true - } - - return false -} - -// SetFileLocation gets a reference to the given string and assigns it to the FileLocation field. -func (o *Image) SetFileLocation(v string) { - o.FileLocation = &v -} - -// GetImageId returns the ImageId field value if set, zero value otherwise. -func (o *Image) GetImageId() string { - if o == nil || o.ImageId == nil { - var ret string - return ret - } - return *o.ImageId -} - -// GetImageIdOk returns a tuple with the ImageId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetImageIdOk() (string, bool) { - if o == nil || o.ImageId == nil { - var ret string - return ret, false - } - return *o.ImageId, true -} - -// HasImageId returns a boolean if a field has been set. -func (o *Image) HasImageId() bool { - if o != nil && o.ImageId != nil { - return true - } - - return false -} - -// SetImageId gets a reference to the given string and assigns it to the ImageId field. -func (o *Image) SetImageId(v string) { - o.ImageId = &v -} - -// GetImageName returns the ImageName field value if set, zero value otherwise. -func (o *Image) GetImageName() string { - if o == nil || o.ImageName == nil { - var ret string - return ret - } - return *o.ImageName -} - -// GetImageNameOk returns a tuple with the ImageName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetImageNameOk() (string, bool) { - if o == nil || o.ImageName == nil { - var ret string - return ret, false - } - return *o.ImageName, true -} - -// HasImageName returns a boolean if a field has been set. -func (o *Image) HasImageName() bool { - if o != nil && o.ImageName != nil { - return true - } - - return false -} - -// SetImageName gets a reference to the given string and assigns it to the ImageName field. -func (o *Image) SetImageName(v string) { - o.ImageName = &v -} - -// GetImageType returns the ImageType field value if set, zero value otherwise. -func (o *Image) GetImageType() string { - if o == nil || o.ImageType == nil { - var ret string - return ret - } - return *o.ImageType -} - -// GetImageTypeOk returns a tuple with the ImageType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetImageTypeOk() (string, bool) { - if o == nil || o.ImageType == nil { - var ret string - return ret, false - } - return *o.ImageType, true -} - -// HasImageType returns a boolean if a field has been set. -func (o *Image) HasImageType() bool { - if o != nil && o.ImageType != nil { - return true - } - - return false -} - -// SetImageType gets a reference to the given string and assigns it to the ImageType field. -func (o *Image) SetImageType(v string) { - o.ImageType = &v -} - -// GetPermissionsToLaunch returns the PermissionsToLaunch field value if set, zero value otherwise. -func (o *Image) GetPermissionsToLaunch() PermissionsOnResource { - if o == nil || o.PermissionsToLaunch == nil { - var ret PermissionsOnResource - return ret - } - return *o.PermissionsToLaunch -} - -// GetPermissionsToLaunchOk returns a tuple with the PermissionsToLaunch field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetPermissionsToLaunchOk() (PermissionsOnResource, bool) { - if o == nil || o.PermissionsToLaunch == nil { - var ret PermissionsOnResource - return ret, false - } - return *o.PermissionsToLaunch, true -} - -// HasPermissionsToLaunch returns a boolean if a field has been set. -func (o *Image) HasPermissionsToLaunch() bool { - if o != nil && o.PermissionsToLaunch != nil { - return true - } - - return false -} - -// SetPermissionsToLaunch gets a reference to the given PermissionsOnResource and assigns it to the PermissionsToLaunch field. -func (o *Image) SetPermissionsToLaunch(v PermissionsOnResource) { - o.PermissionsToLaunch = &v -} - -// GetProductCodes returns the ProductCodes field value if set, zero value otherwise. -func (o *Image) GetProductCodes() []string { - if o == nil || o.ProductCodes == nil { - var ret []string - return ret - } - return *o.ProductCodes -} - -// GetProductCodesOk returns a tuple with the ProductCodes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetProductCodesOk() ([]string, bool) { - if o == nil || o.ProductCodes == nil { - var ret []string - return ret, false - } - return *o.ProductCodes, true -} - -// HasProductCodes returns a boolean if a field has been set. -func (o *Image) HasProductCodes() bool { - if o != nil && o.ProductCodes != nil { - return true - } - - return false -} - -// SetProductCodes gets a reference to the given []string and assigns it to the ProductCodes field. -func (o *Image) SetProductCodes(v []string) { - o.ProductCodes = &v -} - -// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. -func (o *Image) GetRootDeviceName() string { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret - } - return *o.RootDeviceName -} - -// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetRootDeviceNameOk() (string, bool) { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret, false - } - return *o.RootDeviceName, true -} - -// HasRootDeviceName returns a boolean if a field has been set. -func (o *Image) HasRootDeviceName() bool { - if o != nil && o.RootDeviceName != nil { - return true - } - - return false -} - -// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. -func (o *Image) SetRootDeviceName(v string) { - o.RootDeviceName = &v -} - -// GetRootDeviceType returns the RootDeviceType field value if set, zero value otherwise. -func (o *Image) GetRootDeviceType() string { - if o == nil || o.RootDeviceType == nil { - var ret string - return ret - } - return *o.RootDeviceType -} - -// GetRootDeviceTypeOk returns a tuple with the RootDeviceType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetRootDeviceTypeOk() (string, bool) { - if o == nil || o.RootDeviceType == nil { - var ret string - return ret, false - } - return *o.RootDeviceType, true -} - -// HasRootDeviceType returns a boolean if a field has been set. -func (o *Image) HasRootDeviceType() bool { - if o != nil && o.RootDeviceType != nil { - return true - } - - return false -} - -// SetRootDeviceType gets a reference to the given string and assigns it to the RootDeviceType field. -func (o *Image) SetRootDeviceType(v string) { - o.RootDeviceType = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Image) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Image) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Image) SetState(v string) { - o.State = &v -} - -// GetStateComment returns the StateComment field value if set, zero value otherwise. -func (o *Image) GetStateComment() StateComment { - if o == nil || o.StateComment == nil { - var ret StateComment - return ret - } - return *o.StateComment -} - -// GetStateCommentOk returns a tuple with the StateComment field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetStateCommentOk() (StateComment, bool) { - if o == nil || o.StateComment == nil { - var ret StateComment - return ret, false - } - return *o.StateComment, true -} - -// HasStateComment returns a boolean if a field has been set. -func (o *Image) HasStateComment() bool { - if o != nil && o.StateComment != nil { - return true - } - - return false -} - -// SetStateComment gets a reference to the given StateComment and assigns it to the StateComment field. -func (o *Image) SetStateComment(v StateComment) { - o.StateComment = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Image) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Image) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Image) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Image) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableImage struct { - Value Image - ExplicitNull bool -} - -func (v NullableImage) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableImage) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_image_export_task.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_image_export_task.go deleted file mode 100644 index 7f17b5b38..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_image_export_task.go +++ /dev/null @@ -1,287 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ImageExportTask Information about the OMI export task. -type ImageExportTask struct { - // If the OMI export task fails, an error message appears. - Comment *string `json:"Comment,omitempty"` - // The ID of the OMI to be exported. - ImageId *string `json:"ImageId,omitempty"` - OsuExport *OsuExport `json:"OsuExport,omitempty"` - // The progress of the OMI export task, as a percentage. - Progress *int64 `json:"Progress,omitempty"` - // The state of the OMI export task (`pending/queued` \\| `pending` \\| `completed` \\| `failed` \\| `cancelled`). - State *string `json:"State,omitempty"` - // One or more tags associated with the image export task. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the OMI export task. - TaskId *string `json:"TaskId,omitempty"` -} - -// GetComment returns the Comment field value if set, zero value otherwise. -func (o *ImageExportTask) GetComment() string { - if o == nil || o.Comment == nil { - var ret string - return ret - } - return *o.Comment -} - -// GetCommentOk returns a tuple with the Comment field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetCommentOk() (string, bool) { - if o == nil || o.Comment == nil { - var ret string - return ret, false - } - return *o.Comment, true -} - -// HasComment returns a boolean if a field has been set. -func (o *ImageExportTask) HasComment() bool { - if o != nil && o.Comment != nil { - return true - } - - return false -} - -// SetComment gets a reference to the given string and assigns it to the Comment field. -func (o *ImageExportTask) SetComment(v string) { - o.Comment = &v -} - -// GetImageId returns the ImageId field value if set, zero value otherwise. -func (o *ImageExportTask) GetImageId() string { - if o == nil || o.ImageId == nil { - var ret string - return ret - } - return *o.ImageId -} - -// GetImageIdOk returns a tuple with the ImageId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetImageIdOk() (string, bool) { - if o == nil || o.ImageId == nil { - var ret string - return ret, false - } - return *o.ImageId, true -} - -// HasImageId returns a boolean if a field has been set. -func (o *ImageExportTask) HasImageId() bool { - if o != nil && o.ImageId != nil { - return true - } - - return false -} - -// SetImageId gets a reference to the given string and assigns it to the ImageId field. -func (o *ImageExportTask) SetImageId(v string) { - o.ImageId = &v -} - -// GetOsuExport returns the OsuExport field value if set, zero value otherwise. -func (o *ImageExportTask) GetOsuExport() OsuExport { - if o == nil || o.OsuExport == nil { - var ret OsuExport - return ret - } - return *o.OsuExport -} - -// GetOsuExportOk returns a tuple with the OsuExport field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetOsuExportOk() (OsuExport, bool) { - if o == nil || o.OsuExport == nil { - var ret OsuExport - return ret, false - } - return *o.OsuExport, true -} - -// HasOsuExport returns a boolean if a field has been set. -func (o *ImageExportTask) HasOsuExport() bool { - if o != nil && o.OsuExport != nil { - return true - } - - return false -} - -// SetOsuExport gets a reference to the given OsuExport and assigns it to the OsuExport field. -func (o *ImageExportTask) SetOsuExport(v OsuExport) { - o.OsuExport = &v -} - -// GetProgress returns the Progress field value if set, zero value otherwise. -func (o *ImageExportTask) GetProgress() int64 { - if o == nil || o.Progress == nil { - var ret int64 - return ret - } - return *o.Progress -} - -// GetProgressOk returns a tuple with the Progress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetProgressOk() (int64, bool) { - if o == nil || o.Progress == nil { - var ret int64 - return ret, false - } - return *o.Progress, true -} - -// HasProgress returns a boolean if a field has been set. -func (o *ImageExportTask) HasProgress() bool { - if o != nil && o.Progress != nil { - return true - } - - return false -} - -// SetProgress gets a reference to the given int64 and assigns it to the Progress field. -func (o *ImageExportTask) SetProgress(v int64) { - o.Progress = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *ImageExportTask) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *ImageExportTask) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *ImageExportTask) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *ImageExportTask) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *ImageExportTask) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *ImageExportTask) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetTaskId returns the TaskId field value if set, zero value otherwise. -func (o *ImageExportTask) GetTaskId() string { - if o == nil || o.TaskId == nil { - var ret string - return ret - } - return *o.TaskId -} - -// GetTaskIdOk returns a tuple with the TaskId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ImageExportTask) GetTaskIdOk() (string, bool) { - if o == nil || o.TaskId == nil { - var ret string - return ret, false - } - return *o.TaskId, true -} - -// HasTaskId returns a boolean if a field has been set. -func (o *ImageExportTask) HasTaskId() bool { - if o != nil && o.TaskId != nil { - return true - } - - return false -} - -// SetTaskId gets a reference to the given string and assigns it to the TaskId field. -func (o *ImageExportTask) SetTaskId(v string) { - o.TaskId = &v -} - -type NullableImageExportTask struct { - Value ImageExportTask - ExplicitNull bool -} - -func (v NullableImageExportTask) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableImageExportTask) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_internet_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_internet_service.go deleted file mode 100644 index 8bfc3c57b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_internet_service.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// InternetService Information about the Internet service. -type InternetService struct { - // The ID of the Internet service. - InternetServiceId *string `json:"InternetServiceId,omitempty"` - // The ID of the Net attached to the Internet service. - NetId *string `json:"NetId,omitempty"` - // The state of the attachment of the Net to the Internet service (always `available`). - State *string `json:"State,omitempty"` - // One or more tags associated with the Internet service. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetInternetServiceId returns the InternetServiceId field value if set, zero value otherwise. -func (o *InternetService) GetInternetServiceId() string { - if o == nil || o.InternetServiceId == nil { - var ret string - return ret - } - return *o.InternetServiceId -} - -// GetInternetServiceIdOk returns a tuple with the InternetServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *InternetService) GetInternetServiceIdOk() (string, bool) { - if o == nil || o.InternetServiceId == nil { - var ret string - return ret, false - } - return *o.InternetServiceId, true -} - -// HasInternetServiceId returns a boolean if a field has been set. -func (o *InternetService) HasInternetServiceId() bool { - if o != nil && o.InternetServiceId != nil { - return true - } - - return false -} - -// SetInternetServiceId gets a reference to the given string and assigns it to the InternetServiceId field. -func (o *InternetService) SetInternetServiceId(v string) { - o.InternetServiceId = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *InternetService) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *InternetService) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *InternetService) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *InternetService) SetNetId(v string) { - o.NetId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *InternetService) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *InternetService) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *InternetService) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *InternetService) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *InternetService) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *InternetService) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *InternetService) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *InternetService) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableInternetService struct { - Value InternetService - ExplicitNull bool -} - -func (v NullableInternetService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableInternetService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair.go deleted file mode 100644 index 70751a041..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Keypair Information about the keypair. -type Keypair struct { - // If you create a keypair, the SHA-1 digest of the DER encoded private key.
If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716. - KeypairFingerprint *string `json:"KeypairFingerprint,omitempty"` - // The name of the keypair. - KeypairName *string `json:"KeypairName,omitempty"` -} - -// GetKeypairFingerprint returns the KeypairFingerprint field value if set, zero value otherwise. -func (o *Keypair) GetKeypairFingerprint() string { - if o == nil || o.KeypairFingerprint == nil { - var ret string - return ret - } - return *o.KeypairFingerprint -} - -// GetKeypairFingerprintOk returns a tuple with the KeypairFingerprint field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Keypair) GetKeypairFingerprintOk() (string, bool) { - if o == nil || o.KeypairFingerprint == nil { - var ret string - return ret, false - } - return *o.KeypairFingerprint, true -} - -// HasKeypairFingerprint returns a boolean if a field has been set. -func (o *Keypair) HasKeypairFingerprint() bool { - if o != nil && o.KeypairFingerprint != nil { - return true - } - - return false -} - -// SetKeypairFingerprint gets a reference to the given string and assigns it to the KeypairFingerprint field. -func (o *Keypair) SetKeypairFingerprint(v string) { - o.KeypairFingerprint = &v -} - -// GetKeypairName returns the KeypairName field value if set, zero value otherwise. -func (o *Keypair) GetKeypairName() string { - if o == nil || o.KeypairName == nil { - var ret string - return ret - } - return *o.KeypairName -} - -// GetKeypairNameOk returns a tuple with the KeypairName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Keypair) GetKeypairNameOk() (string, bool) { - if o == nil || o.KeypairName == nil { - var ret string - return ret, false - } - return *o.KeypairName, true -} - -// HasKeypairName returns a boolean if a field has been set. -func (o *Keypair) HasKeypairName() bool { - if o != nil && o.KeypairName != nil { - return true - } - - return false -} - -// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. -func (o *Keypair) SetKeypairName(v string) { - o.KeypairName = &v -} - -type NullableKeypair struct { - Value Keypair - ExplicitNull bool -} - -func (v NullableKeypair) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableKeypair) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair_created.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair_created.go deleted file mode 100644 index ae9e44317..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_keypair_created.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// KeypairCreated Information about the created keypair. -type KeypairCreated struct { - // If you create a keypair, the SHA-1 digest of the DER encoded private key.
If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716. - KeypairFingerprint *string `json:"KeypairFingerprint,omitempty"` - // The name of the keypair. - KeypairName *string `json:"KeypairName,omitempty"` - // The private key. - PrivateKey *string `json:"PrivateKey,omitempty"` -} - -// GetKeypairFingerprint returns the KeypairFingerprint field value if set, zero value otherwise. -func (o *KeypairCreated) GetKeypairFingerprint() string { - if o == nil || o.KeypairFingerprint == nil { - var ret string - return ret - } - return *o.KeypairFingerprint -} - -// GetKeypairFingerprintOk returns a tuple with the KeypairFingerprint field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *KeypairCreated) GetKeypairFingerprintOk() (string, bool) { - if o == nil || o.KeypairFingerprint == nil { - var ret string - return ret, false - } - return *o.KeypairFingerprint, true -} - -// HasKeypairFingerprint returns a boolean if a field has been set. -func (o *KeypairCreated) HasKeypairFingerprint() bool { - if o != nil && o.KeypairFingerprint != nil { - return true - } - - return false -} - -// SetKeypairFingerprint gets a reference to the given string and assigns it to the KeypairFingerprint field. -func (o *KeypairCreated) SetKeypairFingerprint(v string) { - o.KeypairFingerprint = &v -} - -// GetKeypairName returns the KeypairName field value if set, zero value otherwise. -func (o *KeypairCreated) GetKeypairName() string { - if o == nil || o.KeypairName == nil { - var ret string - return ret - } - return *o.KeypairName -} - -// GetKeypairNameOk returns a tuple with the KeypairName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *KeypairCreated) GetKeypairNameOk() (string, bool) { - if o == nil || o.KeypairName == nil { - var ret string - return ret, false - } - return *o.KeypairName, true -} - -// HasKeypairName returns a boolean if a field has been set. -func (o *KeypairCreated) HasKeypairName() bool { - if o != nil && o.KeypairName != nil { - return true - } - - return false -} - -// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. -func (o *KeypairCreated) SetKeypairName(v string) { - o.KeypairName = &v -} - -// GetPrivateKey returns the PrivateKey field value if set, zero value otherwise. -func (o *KeypairCreated) GetPrivateKey() string { - if o == nil || o.PrivateKey == nil { - var ret string - return ret - } - return *o.PrivateKey -} - -// GetPrivateKeyOk returns a tuple with the PrivateKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *KeypairCreated) GetPrivateKeyOk() (string, bool) { - if o == nil || o.PrivateKey == nil { - var ret string - return ret, false - } - return *o.PrivateKey, true -} - -// HasPrivateKey returns a boolean if a field has been set. -func (o *KeypairCreated) HasPrivateKey() bool { - if o != nil && o.PrivateKey != nil { - return true - } - - return false -} - -// SetPrivateKey gets a reference to the given string and assigns it to the PrivateKey field. -func (o *KeypairCreated) SetPrivateKey(v string) { - o.PrivateKey = &v -} - -type NullableKeypairCreated struct { - Value KeypairCreated - ExplicitNull bool -} - -func (v NullableKeypairCreated) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableKeypairCreated) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_request.go deleted file mode 100644 index 804c42847..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkFlexibleGpuRequest struct for LinkFlexibleGpuRequest -type LinkFlexibleGpuRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the fGPU you want to attach. - FlexibleGpuId string `json:"FlexibleGpuId"` - // The ID of the VM you want to attach the fGPU to. - VmId string `json:"VmId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkFlexibleGpuRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkFlexibleGpuRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkFlexibleGpuRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkFlexibleGpuRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlexibleGpuId returns the FlexibleGpuId field value -func (o *LinkFlexibleGpuRequest) GetFlexibleGpuId() string { - if o == nil { - var ret string - return ret - } - - return o.FlexibleGpuId -} - -// SetFlexibleGpuId sets field value -func (o *LinkFlexibleGpuRequest) SetFlexibleGpuId(v string) { - o.FlexibleGpuId = v -} - -// GetVmId returns the VmId field value -func (o *LinkFlexibleGpuRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *LinkFlexibleGpuRequest) SetVmId(v string) { - o.VmId = v -} - -type NullableLinkFlexibleGpuRequest struct { - Value LinkFlexibleGpuRequest - ExplicitNull bool -} - -func (v NullableLinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkFlexibleGpuRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_response.go deleted file mode 100644 index 7b54ba629..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_flexible_gpu_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkFlexibleGpuResponse struct for LinkFlexibleGpuResponse -type LinkFlexibleGpuResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkFlexibleGpuResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkFlexibleGpuResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkFlexibleGpuResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkFlexibleGpuResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkFlexibleGpuResponse struct { - Value LinkFlexibleGpuResponse - ExplicitNull bool -} - -func (v NullableLinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkFlexibleGpuResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_request.go deleted file mode 100644 index 2c65aec83..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkInternetServiceRequest struct for LinkInternetServiceRequest -type LinkInternetServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Internet service you want to attach. - InternetServiceId string `json:"InternetServiceId"` - // The ID of the Net to which you want to attach the Internet service. - NetId string `json:"NetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkInternetServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkInternetServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkInternetServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkInternetServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetInternetServiceId returns the InternetServiceId field value -func (o *LinkInternetServiceRequest) GetInternetServiceId() string { - if o == nil { - var ret string - return ret - } - - return o.InternetServiceId -} - -// SetInternetServiceId sets field value -func (o *LinkInternetServiceRequest) SetInternetServiceId(v string) { - o.InternetServiceId = v -} - -// GetNetId returns the NetId field value -func (o *LinkInternetServiceRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *LinkInternetServiceRequest) SetNetId(v string) { - o.NetId = v -} - -type NullableLinkInternetServiceRequest struct { - Value LinkInternetServiceRequest - ExplicitNull bool -} - -func (v NullableLinkInternetServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkInternetServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_response.go deleted file mode 100644 index 0071ba17f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_internet_service_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkInternetServiceResponse struct for LinkInternetServiceResponse -type LinkInternetServiceResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkInternetServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkInternetServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkInternetServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkInternetServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkInternetServiceResponse struct { - Value LinkInternetServiceResponse - ExplicitNull bool -} - -func (v NullableLinkInternetServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkInternetServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic.go deleted file mode 100644 index 273ade194..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkNic Information about the NIC attachment. -type LinkNic struct { - // If `true`, the volume is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The device index for the NIC attachment (between 1 and 7, both included). - DeviceNumber *int64 `json:"DeviceNumber,omitempty"` - // The ID of the NIC to attach. - LinkNicId *string `json:"LinkNicId,omitempty"` - // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). - State *string `json:"State,omitempty"` - // The account ID of the owner of the VM. - VmAccountId *string `json:"VmAccountId,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *LinkNic) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *LinkNic) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *LinkNic) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. -func (o *LinkNic) GetDeviceNumber() int64 { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret - } - return *o.DeviceNumber -} - -// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetDeviceNumberOk() (int64, bool) { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret, false - } - return *o.DeviceNumber, true -} - -// HasDeviceNumber returns a boolean if a field has been set. -func (o *LinkNic) HasDeviceNumber() bool { - if o != nil && o.DeviceNumber != nil { - return true - } - - return false -} - -// SetDeviceNumber gets a reference to the given int64 and assigns it to the DeviceNumber field. -func (o *LinkNic) SetDeviceNumber(v int64) { - o.DeviceNumber = &v -} - -// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. -func (o *LinkNic) GetLinkNicId() string { - if o == nil || o.LinkNicId == nil { - var ret string - return ret - } - return *o.LinkNicId -} - -// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetLinkNicIdOk() (string, bool) { - if o == nil || o.LinkNicId == nil { - var ret string - return ret, false - } - return *o.LinkNicId, true -} - -// HasLinkNicId returns a boolean if a field has been set. -func (o *LinkNic) HasLinkNicId() bool { - if o != nil && o.LinkNicId != nil { - return true - } - - return false -} - -// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. -func (o *LinkNic) SetLinkNicId(v string) { - o.LinkNicId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *LinkNic) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *LinkNic) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *LinkNic) SetState(v string) { - o.State = &v -} - -// GetVmAccountId returns the VmAccountId field value if set, zero value otherwise. -func (o *LinkNic) GetVmAccountId() string { - if o == nil || o.VmAccountId == nil { - var ret string - return ret - } - return *o.VmAccountId -} - -// GetVmAccountIdOk returns a tuple with the VmAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetVmAccountIdOk() (string, bool) { - if o == nil || o.VmAccountId == nil { - var ret string - return ret, false - } - return *o.VmAccountId, true -} - -// HasVmAccountId returns a boolean if a field has been set. -func (o *LinkNic) HasVmAccountId() bool { - if o != nil && o.VmAccountId != nil { - return true - } - - return false -} - -// SetVmAccountId gets a reference to the given string and assigns it to the VmAccountId field. -func (o *LinkNic) SetVmAccountId(v string) { - o.VmAccountId = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *LinkNic) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNic) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *LinkNic) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *LinkNic) SetVmId(v string) { - o.VmId = &v -} - -type NullableLinkNic struct { - Value LinkNic - ExplicitNull bool -} - -func (v NullableLinkNic) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkNic) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_light.go deleted file mode 100644 index 6290542fd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_light.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkNicLight Information about the network interface card (NIC). -type LinkNicLight struct { - // If `true`, the volume is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The device index for the NIC attachment (between 1 and 7, both included). - DeviceNumber *int64 `json:"DeviceNumber,omitempty"` - // The ID of the NIC to attach. - LinkNicId *string `json:"LinkNicId,omitempty"` - // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). - State *string `json:"State,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *LinkNicLight) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicLight) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *LinkNicLight) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *LinkNicLight) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. -func (o *LinkNicLight) GetDeviceNumber() int64 { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret - } - return *o.DeviceNumber -} - -// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicLight) GetDeviceNumberOk() (int64, bool) { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret, false - } - return *o.DeviceNumber, true -} - -// HasDeviceNumber returns a boolean if a field has been set. -func (o *LinkNicLight) HasDeviceNumber() bool { - if o != nil && o.DeviceNumber != nil { - return true - } - - return false -} - -// SetDeviceNumber gets a reference to the given int64 and assigns it to the DeviceNumber field. -func (o *LinkNicLight) SetDeviceNumber(v int64) { - o.DeviceNumber = &v -} - -// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. -func (o *LinkNicLight) GetLinkNicId() string { - if o == nil || o.LinkNicId == nil { - var ret string - return ret - } - return *o.LinkNicId -} - -// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicLight) GetLinkNicIdOk() (string, bool) { - if o == nil || o.LinkNicId == nil { - var ret string - return ret, false - } - return *o.LinkNicId, true -} - -// HasLinkNicId returns a boolean if a field has been set. -func (o *LinkNicLight) HasLinkNicId() bool { - if o != nil && o.LinkNicId != nil { - return true - } - - return false -} - -// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. -func (o *LinkNicLight) SetLinkNicId(v string) { - o.LinkNicId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *LinkNicLight) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicLight) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *LinkNicLight) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *LinkNicLight) SetState(v string) { - o.State = &v -} - -type NullableLinkNicLight struct { - Value LinkNicLight - ExplicitNull bool -} - -func (v NullableLinkNicLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkNicLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_request.go deleted file mode 100644 index d2544e525..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_request.go +++ /dev/null @@ -1,129 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkNicRequest struct for LinkNicRequest -type LinkNicRequest struct { - // The index of the VM device for the NIC attachment (between 1 and 7, both included). - DeviceNumber int64 `json:"DeviceNumber"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the NIC you want to attach. - NicId string `json:"NicId"` - // The ID of the VM to which you want to attach the NIC. - VmId string `json:"VmId"` -} - -// GetDeviceNumber returns the DeviceNumber field value -func (o *LinkNicRequest) GetDeviceNumber() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.DeviceNumber -} - -// SetDeviceNumber sets field value -func (o *LinkNicRequest) SetDeviceNumber(v int64) { - o.DeviceNumber = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkNicRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkNicRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkNicRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNicId returns the NicId field value -func (o *LinkNicRequest) GetNicId() string { - if o == nil { - var ret string - return ret - } - - return o.NicId -} - -// SetNicId sets field value -func (o *LinkNicRequest) SetNicId(v string) { - o.NicId = v -} - -// GetVmId returns the VmId field value -func (o *LinkNicRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *LinkNicRequest) SetVmId(v string) { - o.VmId = v -} - -type NullableLinkNicRequest struct { - Value LinkNicRequest - ExplicitNull bool -} - -func (v NullableLinkNicRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkNicRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_response.go deleted file mode 100644 index c95aa0793..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkNicResponse struct for LinkNicResponse -type LinkNicResponse struct { - // The ID of the NIC attachment. - LinkNicId *string `json:"LinkNicId,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. -func (o *LinkNicResponse) GetLinkNicId() string { - if o == nil || o.LinkNicId == nil { - var ret string - return ret - } - return *o.LinkNicId -} - -// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicResponse) GetLinkNicIdOk() (string, bool) { - if o == nil || o.LinkNicId == nil { - var ret string - return ret, false - } - return *o.LinkNicId, true -} - -// HasLinkNicId returns a boolean if a field has been set. -func (o *LinkNicResponse) HasLinkNicId() bool { - if o != nil && o.LinkNicId != nil { - return true - } - - return false -} - -// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. -func (o *LinkNicResponse) SetLinkNicId(v string) { - o.LinkNicId = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkNicResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkNicResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkNicResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkNicResponse struct { - Value LinkNicResponse - ExplicitNull bool -} - -func (v NullableLinkNicResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkNicResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_to_update.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_to_update.go deleted file mode 100644 index 132176435..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_nic_to_update.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkNicToUpdate Information about the NIC attachment. If you are modifying the `DeleteOnVmDeletion` attribute, you must specify the ID of the NIC attachment. -type LinkNicToUpdate struct { - // If `true`, the NIC is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The ID of the NIC attachment. - LinkNicId *string `json:"LinkNicId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *LinkNicToUpdate) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicToUpdate) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *LinkNicToUpdate) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *LinkNicToUpdate) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetLinkNicId returns the LinkNicId field value if set, zero value otherwise. -func (o *LinkNicToUpdate) GetLinkNicId() string { - if o == nil || o.LinkNicId == nil { - var ret string - return ret - } - return *o.LinkNicId -} - -// GetLinkNicIdOk returns a tuple with the LinkNicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkNicToUpdate) GetLinkNicIdOk() (string, bool) { - if o == nil || o.LinkNicId == nil { - var ret string - return ret, false - } - return *o.LinkNicId, true -} - -// HasLinkNicId returns a boolean if a field has been set. -func (o *LinkNicToUpdate) HasLinkNicId() bool { - if o != nil && o.LinkNicId != nil { - return true - } - - return false -} - -// SetLinkNicId gets a reference to the given string and assigns it to the LinkNicId field. -func (o *LinkNicToUpdate) SetLinkNicId(v string) { - o.LinkNicId = &v -} - -type NullableLinkNicToUpdate struct { - Value LinkNicToUpdate - ExplicitNull bool -} - -func (v NullableLinkNicToUpdate) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkNicToUpdate) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_request.go deleted file mode 100644 index 3127804a0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_request.go +++ /dev/null @@ -1,200 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPrivateIpsRequest struct for LinkPrivateIpsRequest -type LinkPrivateIpsRequest struct { - // If `true`, allows an IP address that is already assigned to another NIC in the same Subnet to be assigned to the NIC you specified. - AllowRelink *bool `json:"AllowRelink,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the NIC. - NicId string `json:"NicId"` - // The secondary private IP address or addresses you want to assign to the NIC within the IP address range of the Subnet. - PrivateIps *[]string `json:"PrivateIps,omitempty"` - // The number of secondary private IP addresses to assign to the NIC. - SecondaryPrivateIpCount *int64 `json:"SecondaryPrivateIpCount,omitempty"` -} - -// GetAllowRelink returns the AllowRelink field value if set, zero value otherwise. -func (o *LinkPrivateIpsRequest) GetAllowRelink() bool { - if o == nil || o.AllowRelink == nil { - var ret bool - return ret - } - return *o.AllowRelink -} - -// GetAllowRelinkOk returns a tuple with the AllowRelink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPrivateIpsRequest) GetAllowRelinkOk() (bool, bool) { - if o == nil || o.AllowRelink == nil { - var ret bool - return ret, false - } - return *o.AllowRelink, true -} - -// HasAllowRelink returns a boolean if a field has been set. -func (o *LinkPrivateIpsRequest) HasAllowRelink() bool { - if o != nil && o.AllowRelink != nil { - return true - } - - return false -} - -// SetAllowRelink gets a reference to the given bool and assigns it to the AllowRelink field. -func (o *LinkPrivateIpsRequest) SetAllowRelink(v bool) { - o.AllowRelink = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkPrivateIpsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPrivateIpsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkPrivateIpsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkPrivateIpsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNicId returns the NicId field value -func (o *LinkPrivateIpsRequest) GetNicId() string { - if o == nil { - var ret string - return ret - } - - return o.NicId -} - -// SetNicId sets field value -func (o *LinkPrivateIpsRequest) SetNicId(v string) { - o.NicId = v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *LinkPrivateIpsRequest) GetPrivateIps() []string { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPrivateIpsRequest) GetPrivateIpsOk() ([]string, bool) { - if o == nil || o.PrivateIps == nil { - var ret []string - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *LinkPrivateIpsRequest) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []string and assigns it to the PrivateIps field. -func (o *LinkPrivateIpsRequest) SetPrivateIps(v []string) { - o.PrivateIps = &v -} - -// GetSecondaryPrivateIpCount returns the SecondaryPrivateIpCount field value if set, zero value otherwise. -func (o *LinkPrivateIpsRequest) GetSecondaryPrivateIpCount() int64 { - if o == nil || o.SecondaryPrivateIpCount == nil { - var ret int64 - return ret - } - return *o.SecondaryPrivateIpCount -} - -// GetSecondaryPrivateIpCountOk returns a tuple with the SecondaryPrivateIpCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPrivateIpsRequest) GetSecondaryPrivateIpCountOk() (int64, bool) { - if o == nil || o.SecondaryPrivateIpCount == nil { - var ret int64 - return ret, false - } - return *o.SecondaryPrivateIpCount, true -} - -// HasSecondaryPrivateIpCount returns a boolean if a field has been set. -func (o *LinkPrivateIpsRequest) HasSecondaryPrivateIpCount() bool { - if o != nil && o.SecondaryPrivateIpCount != nil { - return true - } - - return false -} - -// SetSecondaryPrivateIpCount gets a reference to the given int64 and assigns it to the SecondaryPrivateIpCount field. -func (o *LinkPrivateIpsRequest) SetSecondaryPrivateIpCount(v int64) { - o.SecondaryPrivateIpCount = &v -} - -type NullableLinkPrivateIpsRequest struct { - Value LinkPrivateIpsRequest - ExplicitNull bool -} - -func (v NullableLinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPrivateIpsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_response.go deleted file mode 100644 index f5f296b6f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_private_ips_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPrivateIpsResponse struct for LinkPrivateIpsResponse -type LinkPrivateIpsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkPrivateIpsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPrivateIpsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkPrivateIpsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkPrivateIpsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkPrivateIpsResponse struct { - Value LinkPrivateIpsResponse - ExplicitNull bool -} - -func (v NullableLinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPrivateIpsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip.go deleted file mode 100644 index 7d469e604..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPublicIp Information about the EIP association. -type LinkPublicIp struct { - // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` - // The name of the public DNS. - PublicDnsName *string `json:"PublicDnsName,omitempty"` - // The External IP address (EIP) associated with the NIC. - PublicIp *string `json:"PublicIp,omitempty"` - // The account ID of the owner of the EIP. - PublicIpAccountId *string `json:"PublicIpAccountId,omitempty"` - // The allocation ID of the EIP. - PublicIpId *string `json:"PublicIpId,omitempty"` -} - -// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. -func (o *LinkPublicIp) GetLinkPublicIpId() string { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret - } - return *o.LinkPublicIpId -} - -// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIp) GetLinkPublicIpIdOk() (string, bool) { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret, false - } - return *o.LinkPublicIpId, true -} - -// HasLinkPublicIpId returns a boolean if a field has been set. -func (o *LinkPublicIp) HasLinkPublicIpId() bool { - if o != nil && o.LinkPublicIpId != nil { - return true - } - - return false -} - -// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. -func (o *LinkPublicIp) SetLinkPublicIpId(v string) { - o.LinkPublicIpId = &v -} - -// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. -func (o *LinkPublicIp) GetPublicDnsName() string { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret - } - return *o.PublicDnsName -} - -// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIp) GetPublicDnsNameOk() (string, bool) { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret, false - } - return *o.PublicDnsName, true -} - -// HasPublicDnsName returns a boolean if a field has been set. -func (o *LinkPublicIp) HasPublicDnsName() bool { - if o != nil && o.PublicDnsName != nil { - return true - } - - return false -} - -// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. -func (o *LinkPublicIp) SetPublicDnsName(v string) { - o.PublicDnsName = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *LinkPublicIp) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIp) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *LinkPublicIp) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *LinkPublicIp) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpAccountId returns the PublicIpAccountId field value if set, zero value otherwise. -func (o *LinkPublicIp) GetPublicIpAccountId() string { - if o == nil || o.PublicIpAccountId == nil { - var ret string - return ret - } - return *o.PublicIpAccountId -} - -// GetPublicIpAccountIdOk returns a tuple with the PublicIpAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIp) GetPublicIpAccountIdOk() (string, bool) { - if o == nil || o.PublicIpAccountId == nil { - var ret string - return ret, false - } - return *o.PublicIpAccountId, true -} - -// HasPublicIpAccountId returns a boolean if a field has been set. -func (o *LinkPublicIp) HasPublicIpAccountId() bool { - if o != nil && o.PublicIpAccountId != nil { - return true - } - - return false -} - -// SetPublicIpAccountId gets a reference to the given string and assigns it to the PublicIpAccountId field. -func (o *LinkPublicIp) SetPublicIpAccountId(v string) { - o.PublicIpAccountId = &v -} - -// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. -func (o *LinkPublicIp) GetPublicIpId() string { - if o == nil || o.PublicIpId == nil { - var ret string - return ret - } - return *o.PublicIpId -} - -// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIp) GetPublicIpIdOk() (string, bool) { - if o == nil || o.PublicIpId == nil { - var ret string - return ret, false - } - return *o.PublicIpId, true -} - -// HasPublicIpId returns a boolean if a field has been set. -func (o *LinkPublicIp) HasPublicIpId() bool { - if o != nil && o.PublicIpId != nil { - return true - } - - return false -} - -// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. -func (o *LinkPublicIp) SetPublicIpId(v string) { - o.PublicIpId = &v -} - -type NullableLinkPublicIp struct { - Value LinkPublicIp - ExplicitNull bool -} - -func (v NullableLinkPublicIp) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPublicIp) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_light_for_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_light_for_vm.go deleted file mode 100644 index 54a15ffd3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_light_for_vm.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPublicIpLightForVm Information about the EIP associated with the NIC. -type LinkPublicIpLightForVm struct { - // The name of the public DNS. - PublicDnsName *string `json:"PublicDnsName,omitempty"` - // The External IP address (EIP) associated with the NIC. - PublicIp *string `json:"PublicIp,omitempty"` - // The account ID of the owner of the EIP. - PublicIpAccountId *string `json:"PublicIpAccountId,omitempty"` -} - -// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. -func (o *LinkPublicIpLightForVm) GetPublicDnsName() string { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret - } - return *o.PublicDnsName -} - -// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpLightForVm) GetPublicDnsNameOk() (string, bool) { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret, false - } - return *o.PublicDnsName, true -} - -// HasPublicDnsName returns a boolean if a field has been set. -func (o *LinkPublicIpLightForVm) HasPublicDnsName() bool { - if o != nil && o.PublicDnsName != nil { - return true - } - - return false -} - -// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. -func (o *LinkPublicIpLightForVm) SetPublicDnsName(v string) { - o.PublicDnsName = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *LinkPublicIpLightForVm) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpLightForVm) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *LinkPublicIpLightForVm) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *LinkPublicIpLightForVm) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpAccountId returns the PublicIpAccountId field value if set, zero value otherwise. -func (o *LinkPublicIpLightForVm) GetPublicIpAccountId() string { - if o == nil || o.PublicIpAccountId == nil { - var ret string - return ret - } - return *o.PublicIpAccountId -} - -// GetPublicIpAccountIdOk returns a tuple with the PublicIpAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpLightForVm) GetPublicIpAccountIdOk() (string, bool) { - if o == nil || o.PublicIpAccountId == nil { - var ret string - return ret, false - } - return *o.PublicIpAccountId, true -} - -// HasPublicIpAccountId returns a boolean if a field has been set. -func (o *LinkPublicIpLightForVm) HasPublicIpAccountId() bool { - if o != nil && o.PublicIpAccountId != nil { - return true - } - - return false -} - -// SetPublicIpAccountId gets a reference to the given string and assigns it to the PublicIpAccountId field. -func (o *LinkPublicIpLightForVm) SetPublicIpAccountId(v string) { - o.PublicIpAccountId = &v -} - -type NullableLinkPublicIpLightForVm struct { - Value LinkPublicIpLightForVm - ExplicitNull bool -} - -func (v NullableLinkPublicIpLightForVm) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPublicIpLightForVm) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_request.go deleted file mode 100644 index 7e5f69d9b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_request.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPublicIpRequest struct for LinkPublicIpRequest -type LinkPublicIpRequest struct { - // - If `true`, allows the EIP to be associated with the VM or NIC that you specify even if it is already associated with another VM or NIC.
- If `false`, prevents the EIP from being associated with the VM or NIC that you specify if it is already associated with another VM or NIC.

(By default, `true` in the public Cloud, `false` in a Net.) - AllowRelink *bool `json:"AllowRelink,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // (Net only) The ID of the NIC. This parameter is required if the VM has more than one NIC attached. Otherwise, you need to specify the `VmId` parameter instead. You cannot specify both parameters at the same time. - NicId *string `json:"NicId,omitempty"` - // (Net only) The primary or secondary private IP address of the specified NIC. By default, the primary private IP address. - PrivateIp *string `json:"PrivateIp,omitempty"` - // The EIP. In the public Cloud, this parameter is required. - PublicIp *string `json:"PublicIp,omitempty"` - // The allocation ID of the EIP. In a Net, this parameter is required. - PublicIpId *string `json:"PublicIpId,omitempty"` - // The ID of the VM.
- In the public Cloud, this parameter is required.
- In a Net, this parameter is required if the VM has only one NIC. Otherwise, you need to specify the `NicId` parameter instead. You cannot specify both parameters at the same time. - VmId *string `json:"VmId,omitempty"` -} - -// GetAllowRelink returns the AllowRelink field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetAllowRelink() bool { - if o == nil || o.AllowRelink == nil { - var ret bool - return ret - } - return *o.AllowRelink -} - -// GetAllowRelinkOk returns a tuple with the AllowRelink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetAllowRelinkOk() (bool, bool) { - if o == nil || o.AllowRelink == nil { - var ret bool - return ret, false - } - return *o.AllowRelink, true -} - -// HasAllowRelink returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasAllowRelink() bool { - if o != nil && o.AllowRelink != nil { - return true - } - - return false -} - -// SetAllowRelink gets a reference to the given bool and assigns it to the AllowRelink field. -func (o *LinkPublicIpRequest) SetAllowRelink(v bool) { - o.AllowRelink = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkPublicIpRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *LinkPublicIpRequest) SetNicId(v string) { - o.NicId = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *LinkPublicIpRequest) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *LinkPublicIpRequest) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetPublicIpId() string { - if o == nil || o.PublicIpId == nil { - var ret string - return ret - } - return *o.PublicIpId -} - -// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetPublicIpIdOk() (string, bool) { - if o == nil || o.PublicIpId == nil { - var ret string - return ret, false - } - return *o.PublicIpId, true -} - -// HasPublicIpId returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasPublicIpId() bool { - if o != nil && o.PublicIpId != nil { - return true - } - - return false -} - -// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. -func (o *LinkPublicIpRequest) SetPublicIpId(v string) { - o.PublicIpId = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *LinkPublicIpRequest) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpRequest) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *LinkPublicIpRequest) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *LinkPublicIpRequest) SetVmId(v string) { - o.VmId = &v -} - -type NullableLinkPublicIpRequest struct { - Value LinkPublicIpRequest - ExplicitNull bool -} - -func (v NullableLinkPublicIpRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPublicIpRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_response.go deleted file mode 100644 index ea092d343..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_public_ip_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkPublicIpResponse struct for LinkPublicIpResponse -type LinkPublicIpResponse struct { - // (Net only) The ID representing the association of the EIP with the VM or the NIC. - LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. -func (o *LinkPublicIpResponse) GetLinkPublicIpId() string { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret - } - return *o.LinkPublicIpId -} - -// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpResponse) GetLinkPublicIpIdOk() (string, bool) { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret, false - } - return *o.LinkPublicIpId, true -} - -// HasLinkPublicIpId returns a boolean if a field has been set. -func (o *LinkPublicIpResponse) HasLinkPublicIpId() bool { - if o != nil && o.LinkPublicIpId != nil { - return true - } - - return false -} - -// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. -func (o *LinkPublicIpResponse) SetLinkPublicIpId(v string) { - o.LinkPublicIpId = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkPublicIpResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkPublicIpResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkPublicIpResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkPublicIpResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkPublicIpResponse struct { - Value LinkPublicIpResponse - ExplicitNull bool -} - -func (v NullableLinkPublicIpResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkPublicIpResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table.go deleted file mode 100644 index 35d5ea9f3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkRouteTable One or more associations between the route table and the Subnets. -type LinkRouteTable struct { - // The ID of the association between the route table and the Subnet. - LinkRouteTableId *string `json:"LinkRouteTableId,omitempty"` - // If `true`, the route table is the main one. - Main *bool `json:"Main,omitempty"` - // The ID of the route table. - RouteTableId *string `json:"RouteTableId,omitempty"` - // The ID of the Subnet. - SubnetId *string `json:"SubnetId,omitempty"` -} - -// GetLinkRouteTableId returns the LinkRouteTableId field value if set, zero value otherwise. -func (o *LinkRouteTable) GetLinkRouteTableId() string { - if o == nil || o.LinkRouteTableId == nil { - var ret string - return ret - } - return *o.LinkRouteTableId -} - -// GetLinkRouteTableIdOk returns a tuple with the LinkRouteTableId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTable) GetLinkRouteTableIdOk() (string, bool) { - if o == nil || o.LinkRouteTableId == nil { - var ret string - return ret, false - } - return *o.LinkRouteTableId, true -} - -// HasLinkRouteTableId returns a boolean if a field has been set. -func (o *LinkRouteTable) HasLinkRouteTableId() bool { - if o != nil && o.LinkRouteTableId != nil { - return true - } - - return false -} - -// SetLinkRouteTableId gets a reference to the given string and assigns it to the LinkRouteTableId field. -func (o *LinkRouteTable) SetLinkRouteTableId(v string) { - o.LinkRouteTableId = &v -} - -// GetMain returns the Main field value if set, zero value otherwise. -func (o *LinkRouteTable) GetMain() bool { - if o == nil || o.Main == nil { - var ret bool - return ret - } - return *o.Main -} - -// GetMainOk returns a tuple with the Main field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTable) GetMainOk() (bool, bool) { - if o == nil || o.Main == nil { - var ret bool - return ret, false - } - return *o.Main, true -} - -// HasMain returns a boolean if a field has been set. -func (o *LinkRouteTable) HasMain() bool { - if o != nil && o.Main != nil { - return true - } - - return false -} - -// SetMain gets a reference to the given bool and assigns it to the Main field. -func (o *LinkRouteTable) SetMain(v bool) { - o.Main = &v -} - -// GetRouteTableId returns the RouteTableId field value if set, zero value otherwise. -func (o *LinkRouteTable) GetRouteTableId() string { - if o == nil || o.RouteTableId == nil { - var ret string - return ret - } - return *o.RouteTableId -} - -// GetRouteTableIdOk returns a tuple with the RouteTableId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTable) GetRouteTableIdOk() (string, bool) { - if o == nil || o.RouteTableId == nil { - var ret string - return ret, false - } - return *o.RouteTableId, true -} - -// HasRouteTableId returns a boolean if a field has been set. -func (o *LinkRouteTable) HasRouteTableId() bool { - if o != nil && o.RouteTableId != nil { - return true - } - - return false -} - -// SetRouteTableId gets a reference to the given string and assigns it to the RouteTableId field. -func (o *LinkRouteTable) SetRouteTableId(v string) { - o.RouteTableId = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *LinkRouteTable) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTable) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *LinkRouteTable) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *LinkRouteTable) SetSubnetId(v string) { - o.SubnetId = &v -} - -type NullableLinkRouteTable struct { - Value LinkRouteTable - ExplicitNull bool -} - -func (v NullableLinkRouteTable) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkRouteTable) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_request.go deleted file mode 100644 index baf3329e7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkRouteTableRequest struct for LinkRouteTableRequest -type LinkRouteTableRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the route table. - RouteTableId string `json:"RouteTableId"` - // The ID of the Subnet. - SubnetId string `json:"SubnetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkRouteTableRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTableRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkRouteTableRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkRouteTableRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *LinkRouteTableRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *LinkRouteTableRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -// GetSubnetId returns the SubnetId field value -func (o *LinkRouteTableRequest) GetSubnetId() string { - if o == nil { - var ret string - return ret - } - - return o.SubnetId -} - -// SetSubnetId sets field value -func (o *LinkRouteTableRequest) SetSubnetId(v string) { - o.SubnetId = v -} - -type NullableLinkRouteTableRequest struct { - Value LinkRouteTableRequest - ExplicitNull bool -} - -func (v NullableLinkRouteTableRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkRouteTableRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_response.go deleted file mode 100644 index b714c2468..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_route_table_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkRouteTableResponse struct for LinkRouteTableResponse -type LinkRouteTableResponse struct { - // The ID of the association between the route table and the Subnet. - LinkRouteTableId *string `json:"LinkRouteTableId,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLinkRouteTableId returns the LinkRouteTableId field value if set, zero value otherwise. -func (o *LinkRouteTableResponse) GetLinkRouteTableId() string { - if o == nil || o.LinkRouteTableId == nil { - var ret string - return ret - } - return *o.LinkRouteTableId -} - -// GetLinkRouteTableIdOk returns a tuple with the LinkRouteTableId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTableResponse) GetLinkRouteTableIdOk() (string, bool) { - if o == nil || o.LinkRouteTableId == nil { - var ret string - return ret, false - } - return *o.LinkRouteTableId, true -} - -// HasLinkRouteTableId returns a boolean if a field has been set. -func (o *LinkRouteTableResponse) HasLinkRouteTableId() bool { - if o != nil && o.LinkRouteTableId != nil { - return true - } - - return false -} - -// SetLinkRouteTableId gets a reference to the given string and assigns it to the LinkRouteTableId field. -func (o *LinkRouteTableResponse) SetLinkRouteTableId(v string) { - o.LinkRouteTableId = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkRouteTableResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkRouteTableResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkRouteTableResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkRouteTableResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkRouteTableResponse struct { - Value LinkRouteTableResponse - ExplicitNull bool -} - -func (v NullableLinkRouteTableResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkRouteTableResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_request.go deleted file mode 100644 index a3a940e54..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkVirtualGatewayRequest struct for LinkVirtualGatewayRequest -type LinkVirtualGatewayRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net to which you want to attach the virtual gateway. - NetId string `json:"NetId"` - // The ID of the virtual gateway. - VirtualGatewayId string `json:"VirtualGatewayId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkVirtualGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkVirtualGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkVirtualGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkVirtualGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *LinkVirtualGatewayRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *LinkVirtualGatewayRequest) SetNetId(v string) { - o.NetId = v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *LinkVirtualGatewayRequest) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *LinkVirtualGatewayRequest) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -type NullableLinkVirtualGatewayRequest struct { - Value LinkVirtualGatewayRequest - ExplicitNull bool -} - -func (v NullableLinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkVirtualGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_response.go deleted file mode 100644 index eedca1b56..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_virtual_gateway_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkVirtualGatewayResponse struct for LinkVirtualGatewayResponse -type LinkVirtualGatewayResponse struct { - NetToVirtualGatewayLink *NetToVirtualGatewayLink `json:"NetToVirtualGatewayLink,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetToVirtualGatewayLink returns the NetToVirtualGatewayLink field value if set, zero value otherwise. -func (o *LinkVirtualGatewayResponse) GetNetToVirtualGatewayLink() NetToVirtualGatewayLink { - if o == nil || o.NetToVirtualGatewayLink == nil { - var ret NetToVirtualGatewayLink - return ret - } - return *o.NetToVirtualGatewayLink -} - -// GetNetToVirtualGatewayLinkOk returns a tuple with the NetToVirtualGatewayLink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkVirtualGatewayResponse) GetNetToVirtualGatewayLinkOk() (NetToVirtualGatewayLink, bool) { - if o == nil || o.NetToVirtualGatewayLink == nil { - var ret NetToVirtualGatewayLink - return ret, false - } - return *o.NetToVirtualGatewayLink, true -} - -// HasNetToVirtualGatewayLink returns a boolean if a field has been set. -func (o *LinkVirtualGatewayResponse) HasNetToVirtualGatewayLink() bool { - if o != nil && o.NetToVirtualGatewayLink != nil { - return true - } - - return false -} - -// SetNetToVirtualGatewayLink gets a reference to the given NetToVirtualGatewayLink and assigns it to the NetToVirtualGatewayLink field. -func (o *LinkVirtualGatewayResponse) SetNetToVirtualGatewayLink(v NetToVirtualGatewayLink) { - o.NetToVirtualGatewayLink = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkVirtualGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkVirtualGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkVirtualGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkVirtualGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkVirtualGatewayResponse struct { - Value LinkVirtualGatewayResponse - ExplicitNull bool -} - -func (v NullableLinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkVirtualGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_request.go deleted file mode 100644 index 8551b318d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_request.go +++ /dev/null @@ -1,129 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkVolumeRequest struct for LinkVolumeRequest -type LinkVolumeRequest struct { - // The name of the device. - DeviceName string `json:"DeviceName"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the VM you want to attach the volume to. - VmId string `json:"VmId"` - // The ID of the volume you want to attach. - VolumeId string `json:"VolumeId"` -} - -// GetDeviceName returns the DeviceName field value -func (o *LinkVolumeRequest) GetDeviceName() string { - if o == nil { - var ret string - return ret - } - - return o.DeviceName -} - -// SetDeviceName sets field value -func (o *LinkVolumeRequest) SetDeviceName(v string) { - o.DeviceName = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *LinkVolumeRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkVolumeRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *LinkVolumeRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *LinkVolumeRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmId returns the VmId field value -func (o *LinkVolumeRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *LinkVolumeRequest) SetVmId(v string) { - o.VmId = v -} - -// GetVolumeId returns the VolumeId field value -func (o *LinkVolumeRequest) GetVolumeId() string { - if o == nil { - var ret string - return ret - } - - return o.VolumeId -} - -// SetVolumeId sets field value -func (o *LinkVolumeRequest) SetVolumeId(v string) { - o.VolumeId = v -} - -type NullableLinkVolumeRequest struct { - Value LinkVolumeRequest - ExplicitNull bool -} - -func (v NullableLinkVolumeRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkVolumeRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_response.go deleted file mode 100644 index 28f495b6e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_link_volume_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkVolumeResponse struct for LinkVolumeResponse -type LinkVolumeResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *LinkVolumeResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkVolumeResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *LinkVolumeResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *LinkVolumeResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableLinkVolumeResponse struct { - Value LinkVolumeResponse - ExplicitNull bool -} - -func (v NullableLinkVolumeResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkVolumeResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_linked_volume.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_linked_volume.go deleted file mode 100644 index 8bfc1c31e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_linked_volume.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LinkedVolume Information about volume attachment. -type LinkedVolume struct { - // If `true`, the volume is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The name of the device. - DeviceName *string `json:"DeviceName,omitempty"` - // The state of the attachment of the volume (`attaching` \\| `detaching` \\| `attached` \\| `detached`). - State *string `json:"State,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` - // The ID of the volume. - VolumeId *string `json:"VolumeId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *LinkedVolume) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkedVolume) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *LinkedVolume) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *LinkedVolume) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDeviceName returns the DeviceName field value if set, zero value otherwise. -func (o *LinkedVolume) GetDeviceName() string { - if o == nil || o.DeviceName == nil { - var ret string - return ret - } - return *o.DeviceName -} - -// GetDeviceNameOk returns a tuple with the DeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkedVolume) GetDeviceNameOk() (string, bool) { - if o == nil || o.DeviceName == nil { - var ret string - return ret, false - } - return *o.DeviceName, true -} - -// HasDeviceName returns a boolean if a field has been set. -func (o *LinkedVolume) HasDeviceName() bool { - if o != nil && o.DeviceName != nil { - return true - } - - return false -} - -// SetDeviceName gets a reference to the given string and assigns it to the DeviceName field. -func (o *LinkedVolume) SetDeviceName(v string) { - o.DeviceName = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *LinkedVolume) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkedVolume) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *LinkedVolume) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *LinkedVolume) SetState(v string) { - o.State = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *LinkedVolume) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkedVolume) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *LinkedVolume) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *LinkedVolume) SetVmId(v string) { - o.VmId = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *LinkedVolume) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LinkedVolume) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *LinkedVolume) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *LinkedVolume) SetVolumeId(v string) { - o.VolumeId = &v -} - -type NullableLinkedVolume struct { - Value LinkedVolume - ExplicitNull bool -} - -func (v NullableLinkedVolume) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLinkedVolume) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_listener.go deleted file mode 100644 index 0671ec979..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Listener Information about the listener. -type Listener struct { - // The port on which the back-end VM is listening (between `1` and `65535`, both included). - BackendPort *int64 `json:"BackendPort,omitempty"` - // The protocol for routing traffic to back-end VMs (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). - BackendProtocol *string `json:"BackendProtocol,omitempty"` - // The port on which the load balancer is listening (between 1 and `65535`, both included). - LoadBalancerPort *int64 `json:"LoadBalancerPort,omitempty"` - // The routing protocol (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). - LoadBalancerProtocol *string `json:"LoadBalancerProtocol,omitempty"` - // The names of the policies. If there are no policies enabled, the list is empty. - PolicyNames *[]string `json:"PolicyNames,omitempty"` - // The ID of the server certificate. - ServerCertificateId *string `json:"ServerCertificateId,omitempty"` -} - -// GetBackendPort returns the BackendPort field value if set, zero value otherwise. -func (o *Listener) GetBackendPort() int64 { - if o == nil || o.BackendPort == nil { - var ret int64 - return ret - } - return *o.BackendPort -} - -// GetBackendPortOk returns a tuple with the BackendPort field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetBackendPortOk() (int64, bool) { - if o == nil || o.BackendPort == nil { - var ret int64 - return ret, false - } - return *o.BackendPort, true -} - -// HasBackendPort returns a boolean if a field has been set. -func (o *Listener) HasBackendPort() bool { - if o != nil && o.BackendPort != nil { - return true - } - - return false -} - -// SetBackendPort gets a reference to the given int64 and assigns it to the BackendPort field. -func (o *Listener) SetBackendPort(v int64) { - o.BackendPort = &v -} - -// GetBackendProtocol returns the BackendProtocol field value if set, zero value otherwise. -func (o *Listener) GetBackendProtocol() string { - if o == nil || o.BackendProtocol == nil { - var ret string - return ret - } - return *o.BackendProtocol -} - -// GetBackendProtocolOk returns a tuple with the BackendProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetBackendProtocolOk() (string, bool) { - if o == nil || o.BackendProtocol == nil { - var ret string - return ret, false - } - return *o.BackendProtocol, true -} - -// HasBackendProtocol returns a boolean if a field has been set. -func (o *Listener) HasBackendProtocol() bool { - if o != nil && o.BackendProtocol != nil { - return true - } - - return false -} - -// SetBackendProtocol gets a reference to the given string and assigns it to the BackendProtocol field. -func (o *Listener) SetBackendProtocol(v string) { - o.BackendProtocol = &v -} - -// GetLoadBalancerPort returns the LoadBalancerPort field value if set, zero value otherwise. -func (o *Listener) GetLoadBalancerPort() int64 { - if o == nil || o.LoadBalancerPort == nil { - var ret int64 - return ret - } - return *o.LoadBalancerPort -} - -// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetLoadBalancerPortOk() (int64, bool) { - if o == nil || o.LoadBalancerPort == nil { - var ret int64 - return ret, false - } - return *o.LoadBalancerPort, true -} - -// HasLoadBalancerPort returns a boolean if a field has been set. -func (o *Listener) HasLoadBalancerPort() bool { - if o != nil && o.LoadBalancerPort != nil { - return true - } - - return false -} - -// SetLoadBalancerPort gets a reference to the given int64 and assigns it to the LoadBalancerPort field. -func (o *Listener) SetLoadBalancerPort(v int64) { - o.LoadBalancerPort = &v -} - -// GetLoadBalancerProtocol returns the LoadBalancerProtocol field value if set, zero value otherwise. -func (o *Listener) GetLoadBalancerProtocol() string { - if o == nil || o.LoadBalancerProtocol == nil { - var ret string - return ret - } - return *o.LoadBalancerProtocol -} - -// GetLoadBalancerProtocolOk returns a tuple with the LoadBalancerProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetLoadBalancerProtocolOk() (string, bool) { - if o == nil || o.LoadBalancerProtocol == nil { - var ret string - return ret, false - } - return *o.LoadBalancerProtocol, true -} - -// HasLoadBalancerProtocol returns a boolean if a field has been set. -func (o *Listener) HasLoadBalancerProtocol() bool { - if o != nil && o.LoadBalancerProtocol != nil { - return true - } - - return false -} - -// SetLoadBalancerProtocol gets a reference to the given string and assigns it to the LoadBalancerProtocol field. -func (o *Listener) SetLoadBalancerProtocol(v string) { - o.LoadBalancerProtocol = &v -} - -// GetPolicyNames returns the PolicyNames field value if set, zero value otherwise. -func (o *Listener) GetPolicyNames() []string { - if o == nil || o.PolicyNames == nil { - var ret []string - return ret - } - return *o.PolicyNames -} - -// GetPolicyNamesOk returns a tuple with the PolicyNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetPolicyNamesOk() ([]string, bool) { - if o == nil || o.PolicyNames == nil { - var ret []string - return ret, false - } - return *o.PolicyNames, true -} - -// HasPolicyNames returns a boolean if a field has been set. -func (o *Listener) HasPolicyNames() bool { - if o != nil && o.PolicyNames != nil { - return true - } - - return false -} - -// SetPolicyNames gets a reference to the given []string and assigns it to the PolicyNames field. -func (o *Listener) SetPolicyNames(v []string) { - o.PolicyNames = &v -} - -// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. -func (o *Listener) GetServerCertificateId() string { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret - } - return *o.ServerCertificateId -} - -// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Listener) GetServerCertificateIdOk() (string, bool) { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret, false - } - return *o.ServerCertificateId, true -} - -// HasServerCertificateId returns a boolean if a field has been set. -func (o *Listener) HasServerCertificateId() bool { - if o != nil && o.ServerCertificateId != nil { - return true - } - - return false -} - -// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. -func (o *Listener) SetServerCertificateId(v string) { - o.ServerCertificateId = &v -} - -type NullableListener struct { - Value Listener - ExplicitNull bool -} - -func (v NullableListener) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableListener) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_for_creation.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_for_creation.go deleted file mode 100644 index a3830cd18..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_for_creation.go +++ /dev/null @@ -1,164 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ListenerForCreation Information about the listener to create. -type ListenerForCreation struct { - // The port on which the back-end VM is listening (between `1` and `65535`, both included). - BackendPort int64 `json:"BackendPort"` - // The protocol for routing traffic to back-end VMs (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). - BackendProtocol *string `json:"BackendProtocol,omitempty"` - // The port on which the load balancer is listening (between `1` and `65535`, both included). - LoadBalancerPort int64 `json:"LoadBalancerPort"` - // The routing protocol (`HTTP` \\| `HTTPS` \\| `TCP` \\| `SSL` \\| `UDP`). - LoadBalancerProtocol string `json:"LoadBalancerProtocol"` - // The ID of the server certificate. - ServerCertificateId *string `json:"ServerCertificateId,omitempty"` -} - -// GetBackendPort returns the BackendPort field value -func (o *ListenerForCreation) GetBackendPort() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.BackendPort -} - -// SetBackendPort sets field value -func (o *ListenerForCreation) SetBackendPort(v int64) { - o.BackendPort = v -} - -// GetBackendProtocol returns the BackendProtocol field value if set, zero value otherwise. -func (o *ListenerForCreation) GetBackendProtocol() string { - if o == nil || o.BackendProtocol == nil { - var ret string - return ret - } - return *o.BackendProtocol -} - -// GetBackendProtocolOk returns a tuple with the BackendProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerForCreation) GetBackendProtocolOk() (string, bool) { - if o == nil || o.BackendProtocol == nil { - var ret string - return ret, false - } - return *o.BackendProtocol, true -} - -// HasBackendProtocol returns a boolean if a field has been set. -func (o *ListenerForCreation) HasBackendProtocol() bool { - if o != nil && o.BackendProtocol != nil { - return true - } - - return false -} - -// SetBackendProtocol gets a reference to the given string and assigns it to the BackendProtocol field. -func (o *ListenerForCreation) SetBackendProtocol(v string) { - o.BackendProtocol = &v -} - -// GetLoadBalancerPort returns the LoadBalancerPort field value -func (o *ListenerForCreation) GetLoadBalancerPort() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.LoadBalancerPort -} - -// SetLoadBalancerPort sets field value -func (o *ListenerForCreation) SetLoadBalancerPort(v int64) { - o.LoadBalancerPort = v -} - -// GetLoadBalancerProtocol returns the LoadBalancerProtocol field value -func (o *ListenerForCreation) GetLoadBalancerProtocol() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerProtocol -} - -// SetLoadBalancerProtocol sets field value -func (o *ListenerForCreation) SetLoadBalancerProtocol(v string) { - o.LoadBalancerProtocol = v -} - -// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. -func (o *ListenerForCreation) GetServerCertificateId() string { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret - } - return *o.ServerCertificateId -} - -// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerForCreation) GetServerCertificateIdOk() (string, bool) { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret, false - } - return *o.ServerCertificateId, true -} - -// HasServerCertificateId returns a boolean if a field has been set. -func (o *ListenerForCreation) HasServerCertificateId() bool { - if o != nil && o.ServerCertificateId != nil { - return true - } - - return false -} - -// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. -func (o *ListenerForCreation) SetServerCertificateId(v string) { - o.ServerCertificateId = &v -} - -type NullableListenerForCreation struct { - Value ListenerForCreation - ExplicitNull bool -} - -func (v NullableListenerForCreation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableListenerForCreation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule.go deleted file mode 100644 index c8bd0c2b2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ListenerRule Information about the listener rule. -type ListenerRule struct { - // The type of action for the rule (always `forward`). - Action *string `json:"Action,omitempty"` - // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. - HostNamePattern *string `json:"HostNamePattern,omitempty"` - // The ID of the listener. - ListenerId *int64 `json:"ListenerId,omitempty"` - // The ID of the listener rule. - ListenerRuleId *int64 `json:"ListenerRuleId,omitempty"` - // A human-readable name for the listener rule. - ListenerRuleName *string `json:"ListenerRuleName,omitempty"` - // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. - PathPattern *string `json:"PathPattern,omitempty"` - // The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. - Priority *int64 `json:"Priority,omitempty"` - // The IDs of the backend VMs. - VmIds *[]string `json:"VmIds,omitempty"` -} - -// GetAction returns the Action field value if set, zero value otherwise. -func (o *ListenerRule) GetAction() string { - if o == nil || o.Action == nil { - var ret string - return ret - } - return *o.Action -} - -// GetActionOk returns a tuple with the Action field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetActionOk() (string, bool) { - if o == nil || o.Action == nil { - var ret string - return ret, false - } - return *o.Action, true -} - -// HasAction returns a boolean if a field has been set. -func (o *ListenerRule) HasAction() bool { - if o != nil && o.Action != nil { - return true - } - - return false -} - -// SetAction gets a reference to the given string and assigns it to the Action field. -func (o *ListenerRule) SetAction(v string) { - o.Action = &v -} - -// GetHostNamePattern returns the HostNamePattern field value if set, zero value otherwise. -func (o *ListenerRule) GetHostNamePattern() string { - if o == nil || o.HostNamePattern == nil { - var ret string - return ret - } - return *o.HostNamePattern -} - -// GetHostNamePatternOk returns a tuple with the HostNamePattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetHostNamePatternOk() (string, bool) { - if o == nil || o.HostNamePattern == nil { - var ret string - return ret, false - } - return *o.HostNamePattern, true -} - -// HasHostNamePattern returns a boolean if a field has been set. -func (o *ListenerRule) HasHostNamePattern() bool { - if o != nil && o.HostNamePattern != nil { - return true - } - - return false -} - -// SetHostNamePattern gets a reference to the given string and assigns it to the HostNamePattern field. -func (o *ListenerRule) SetHostNamePattern(v string) { - o.HostNamePattern = &v -} - -// GetListenerId returns the ListenerId field value if set, zero value otherwise. -func (o *ListenerRule) GetListenerId() int64 { - if o == nil || o.ListenerId == nil { - var ret int64 - return ret - } - return *o.ListenerId -} - -// GetListenerIdOk returns a tuple with the ListenerId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetListenerIdOk() (int64, bool) { - if o == nil || o.ListenerId == nil { - var ret int64 - return ret, false - } - return *o.ListenerId, true -} - -// HasListenerId returns a boolean if a field has been set. -func (o *ListenerRule) HasListenerId() bool { - if o != nil && o.ListenerId != nil { - return true - } - - return false -} - -// SetListenerId gets a reference to the given int64 and assigns it to the ListenerId field. -func (o *ListenerRule) SetListenerId(v int64) { - o.ListenerId = &v -} - -// GetListenerRuleId returns the ListenerRuleId field value if set, zero value otherwise. -func (o *ListenerRule) GetListenerRuleId() int64 { - if o == nil || o.ListenerRuleId == nil { - var ret int64 - return ret - } - return *o.ListenerRuleId -} - -// GetListenerRuleIdOk returns a tuple with the ListenerRuleId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetListenerRuleIdOk() (int64, bool) { - if o == nil || o.ListenerRuleId == nil { - var ret int64 - return ret, false - } - return *o.ListenerRuleId, true -} - -// HasListenerRuleId returns a boolean if a field has been set. -func (o *ListenerRule) HasListenerRuleId() bool { - if o != nil && o.ListenerRuleId != nil { - return true - } - - return false -} - -// SetListenerRuleId gets a reference to the given int64 and assigns it to the ListenerRuleId field. -func (o *ListenerRule) SetListenerRuleId(v int64) { - o.ListenerRuleId = &v -} - -// GetListenerRuleName returns the ListenerRuleName field value if set, zero value otherwise. -func (o *ListenerRule) GetListenerRuleName() string { - if o == nil || o.ListenerRuleName == nil { - var ret string - return ret - } - return *o.ListenerRuleName -} - -// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetListenerRuleNameOk() (string, bool) { - if o == nil || o.ListenerRuleName == nil { - var ret string - return ret, false - } - return *o.ListenerRuleName, true -} - -// HasListenerRuleName returns a boolean if a field has been set. -func (o *ListenerRule) HasListenerRuleName() bool { - if o != nil && o.ListenerRuleName != nil { - return true - } - - return false -} - -// SetListenerRuleName gets a reference to the given string and assigns it to the ListenerRuleName field. -func (o *ListenerRule) SetListenerRuleName(v string) { - o.ListenerRuleName = &v -} - -// GetPathPattern returns the PathPattern field value if set, zero value otherwise. -func (o *ListenerRule) GetPathPattern() string { - if o == nil || o.PathPattern == nil { - var ret string - return ret - } - return *o.PathPattern -} - -// GetPathPatternOk returns a tuple with the PathPattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetPathPatternOk() (string, bool) { - if o == nil || o.PathPattern == nil { - var ret string - return ret, false - } - return *o.PathPattern, true -} - -// HasPathPattern returns a boolean if a field has been set. -func (o *ListenerRule) HasPathPattern() bool { - if o != nil && o.PathPattern != nil { - return true - } - - return false -} - -// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. -func (o *ListenerRule) SetPathPattern(v string) { - o.PathPattern = &v -} - -// GetPriority returns the Priority field value if set, zero value otherwise. -func (o *ListenerRule) GetPriority() int64 { - if o == nil || o.Priority == nil { - var ret int64 - return ret - } - return *o.Priority -} - -// GetPriorityOk returns a tuple with the Priority field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetPriorityOk() (int64, bool) { - if o == nil || o.Priority == nil { - var ret int64 - return ret, false - } - return *o.Priority, true -} - -// HasPriority returns a boolean if a field has been set. -func (o *ListenerRule) HasPriority() bool { - if o != nil && o.Priority != nil { - return true - } - - return false -} - -// SetPriority gets a reference to the given int64 and assigns it to the Priority field. -func (o *ListenerRule) SetPriority(v int64) { - o.Priority = &v -} - -// GetVmIds returns the VmIds field value if set, zero value otherwise. -func (o *ListenerRule) GetVmIds() []string { - if o == nil || o.VmIds == nil { - var ret []string - return ret - } - return *o.VmIds -} - -// GetVmIdsOk returns a tuple with the VmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRule) GetVmIdsOk() ([]string, bool) { - if o == nil || o.VmIds == nil { - var ret []string - return ret, false - } - return *o.VmIds, true -} - -// HasVmIds returns a boolean if a field has been set. -func (o *ListenerRule) HasVmIds() bool { - if o != nil && o.VmIds != nil { - return true - } - - return false -} - -// SetVmIds gets a reference to the given []string and assigns it to the VmIds field. -func (o *ListenerRule) SetVmIds(v []string) { - o.VmIds = &v -} - -type NullableListenerRule struct { - Value ListenerRule - ExplicitNull bool -} - -func (v NullableListenerRule) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableListenerRule) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule_for_creation.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule_for_creation.go deleted file mode 100644 index abfcd9296..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_listener_rule_for_creation.go +++ /dev/null @@ -1,235 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ListenerRuleForCreation Information about the listener rule. -type ListenerRuleForCreation struct { - // The type of action for the rule (always `forward`). - Action *string `json:"Action,omitempty"` - // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. - HostNamePattern *string `json:"HostNamePattern,omitempty"` - // The ID of the listener. - ListenerRuleId *string `json:"ListenerRuleId,omitempty"` - // A human-readable name for the listener rule. - ListenerRuleName *string `json:"ListenerRuleName,omitempty"` - // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. - PathPattern *string `json:"PathPattern,omitempty"` - // The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. - Priority int64 `json:"Priority"` -} - -// GetAction returns the Action field value if set, zero value otherwise. -func (o *ListenerRuleForCreation) GetAction() string { - if o == nil || o.Action == nil { - var ret string - return ret - } - return *o.Action -} - -// GetActionOk returns a tuple with the Action field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRuleForCreation) GetActionOk() (string, bool) { - if o == nil || o.Action == nil { - var ret string - return ret, false - } - return *o.Action, true -} - -// HasAction returns a boolean if a field has been set. -func (o *ListenerRuleForCreation) HasAction() bool { - if o != nil && o.Action != nil { - return true - } - - return false -} - -// SetAction gets a reference to the given string and assigns it to the Action field. -func (o *ListenerRuleForCreation) SetAction(v string) { - o.Action = &v -} - -// GetHostNamePattern returns the HostNamePattern field value if set, zero value otherwise. -func (o *ListenerRuleForCreation) GetHostNamePattern() string { - if o == nil || o.HostNamePattern == nil { - var ret string - return ret - } - return *o.HostNamePattern -} - -// GetHostNamePatternOk returns a tuple with the HostNamePattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRuleForCreation) GetHostNamePatternOk() (string, bool) { - if o == nil || o.HostNamePattern == nil { - var ret string - return ret, false - } - return *o.HostNamePattern, true -} - -// HasHostNamePattern returns a boolean if a field has been set. -func (o *ListenerRuleForCreation) HasHostNamePattern() bool { - if o != nil && o.HostNamePattern != nil { - return true - } - - return false -} - -// SetHostNamePattern gets a reference to the given string and assigns it to the HostNamePattern field. -func (o *ListenerRuleForCreation) SetHostNamePattern(v string) { - o.HostNamePattern = &v -} - -// GetListenerRuleId returns the ListenerRuleId field value if set, zero value otherwise. -func (o *ListenerRuleForCreation) GetListenerRuleId() string { - if o == nil || o.ListenerRuleId == nil { - var ret string - return ret - } - return *o.ListenerRuleId -} - -// GetListenerRuleIdOk returns a tuple with the ListenerRuleId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRuleForCreation) GetListenerRuleIdOk() (string, bool) { - if o == nil || o.ListenerRuleId == nil { - var ret string - return ret, false - } - return *o.ListenerRuleId, true -} - -// HasListenerRuleId returns a boolean if a field has been set. -func (o *ListenerRuleForCreation) HasListenerRuleId() bool { - if o != nil && o.ListenerRuleId != nil { - return true - } - - return false -} - -// SetListenerRuleId gets a reference to the given string and assigns it to the ListenerRuleId field. -func (o *ListenerRuleForCreation) SetListenerRuleId(v string) { - o.ListenerRuleId = &v -} - -// GetListenerRuleName returns the ListenerRuleName field value if set, zero value otherwise. -func (o *ListenerRuleForCreation) GetListenerRuleName() string { - if o == nil || o.ListenerRuleName == nil { - var ret string - return ret - } - return *o.ListenerRuleName -} - -// GetListenerRuleNameOk returns a tuple with the ListenerRuleName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRuleForCreation) GetListenerRuleNameOk() (string, bool) { - if o == nil || o.ListenerRuleName == nil { - var ret string - return ret, false - } - return *o.ListenerRuleName, true -} - -// HasListenerRuleName returns a boolean if a field has been set. -func (o *ListenerRuleForCreation) HasListenerRuleName() bool { - if o != nil && o.ListenerRuleName != nil { - return true - } - - return false -} - -// SetListenerRuleName gets a reference to the given string and assigns it to the ListenerRuleName field. -func (o *ListenerRuleForCreation) SetListenerRuleName(v string) { - o.ListenerRuleName = &v -} - -// GetPathPattern returns the PathPattern field value if set, zero value otherwise. -func (o *ListenerRuleForCreation) GetPathPattern() string { - if o == nil || o.PathPattern == nil { - var ret string - return ret - } - return *o.PathPattern -} - -// GetPathPatternOk returns a tuple with the PathPattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ListenerRuleForCreation) GetPathPatternOk() (string, bool) { - if o == nil || o.PathPattern == nil { - var ret string - return ret, false - } - return *o.PathPattern, true -} - -// HasPathPattern returns a boolean if a field has been set. -func (o *ListenerRuleForCreation) HasPathPattern() bool { - if o != nil && o.PathPattern != nil { - return true - } - - return false -} - -// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. -func (o *ListenerRuleForCreation) SetPathPattern(v string) { - o.PathPattern = &v -} - -// GetPriority returns the Priority field value -func (o *ListenerRuleForCreation) GetPriority() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.Priority -} - -// SetPriority sets field value -func (o *ListenerRuleForCreation) SetPriority(v int64) { - o.Priority = v -} - -type NullableListenerRuleForCreation struct { - Value ListenerRuleForCreation - ExplicitNull bool -} - -func (v NullableListenerRuleForCreation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableListenerRuleForCreation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer.go deleted file mode 100644 index c622540fb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer.go +++ /dev/null @@ -1,565 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LoadBalancer Information about the load balancer. -type LoadBalancer struct { - AccessLog *AccessLog `json:"AccessLog,omitempty"` - // The stickiness policies defined for the load balancer. - ApplicationStickyCookiePolicies *[]ApplicationStickyCookiePolicy `json:"ApplicationStickyCookiePolicies,omitempty"` - // One or more IDs of back-end VMs for the load balancer. - BackendVmIds *[]string `json:"BackendVmIds,omitempty"` - // The DNS name of the load balancer. - DnsName *string `json:"DnsName,omitempty"` - HealthCheck *HealthCheck `json:"HealthCheck,omitempty"` - // The listeners for the load balancer. - Listeners *[]Listener `json:"Listeners,omitempty"` - // The name of the load balancer. - LoadBalancerName *string `json:"LoadBalancerName,omitempty"` - // The policies defined for the load balancer. - LoadBalancerStickyCookiePolicies *[]LoadBalancerStickyCookiePolicy `json:"LoadBalancerStickyCookiePolicies,omitempty"` - // The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. - LoadBalancerType *string `json:"LoadBalancerType,omitempty"` - // The ID of the Net for the load balancer. - NetId *string `json:"NetId,omitempty"` - // One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. - SecurityGroups *[]string `json:"SecurityGroups,omitempty"` - SourceSecurityGroup *SourceSecurityGroup `json:"SourceSecurityGroup,omitempty"` - // The IDs of the Subnets for the load balancer. - Subnets *[]string `json:"Subnets,omitempty"` - // One or more names of Subregions for the load balancer. - SubregionNames *[]string `json:"SubregionNames,omitempty"` - // One or more tags associated with the load balancer. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAccessLog returns the AccessLog field value if set, zero value otherwise. -func (o *LoadBalancer) GetAccessLog() AccessLog { - if o == nil || o.AccessLog == nil { - var ret AccessLog - return ret - } - return *o.AccessLog -} - -// GetAccessLogOk returns a tuple with the AccessLog field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetAccessLogOk() (AccessLog, bool) { - if o == nil || o.AccessLog == nil { - var ret AccessLog - return ret, false - } - return *o.AccessLog, true -} - -// HasAccessLog returns a boolean if a field has been set. -func (o *LoadBalancer) HasAccessLog() bool { - if o != nil && o.AccessLog != nil { - return true - } - - return false -} - -// SetAccessLog gets a reference to the given AccessLog and assigns it to the AccessLog field. -func (o *LoadBalancer) SetAccessLog(v AccessLog) { - o.AccessLog = &v -} - -// GetApplicationStickyCookiePolicies returns the ApplicationStickyCookiePolicies field value if set, zero value otherwise. -func (o *LoadBalancer) GetApplicationStickyCookiePolicies() []ApplicationStickyCookiePolicy { - if o == nil || o.ApplicationStickyCookiePolicies == nil { - var ret []ApplicationStickyCookiePolicy - return ret - } - return *o.ApplicationStickyCookiePolicies -} - -// GetApplicationStickyCookiePoliciesOk returns a tuple with the ApplicationStickyCookiePolicies field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetApplicationStickyCookiePoliciesOk() ([]ApplicationStickyCookiePolicy, bool) { - if o == nil || o.ApplicationStickyCookiePolicies == nil { - var ret []ApplicationStickyCookiePolicy - return ret, false - } - return *o.ApplicationStickyCookiePolicies, true -} - -// HasApplicationStickyCookiePolicies returns a boolean if a field has been set. -func (o *LoadBalancer) HasApplicationStickyCookiePolicies() bool { - if o != nil && o.ApplicationStickyCookiePolicies != nil { - return true - } - - return false -} - -// SetApplicationStickyCookiePolicies gets a reference to the given []ApplicationStickyCookiePolicy and assigns it to the ApplicationStickyCookiePolicies field. -func (o *LoadBalancer) SetApplicationStickyCookiePolicies(v []ApplicationStickyCookiePolicy) { - o.ApplicationStickyCookiePolicies = &v -} - -// GetBackendVmIds returns the BackendVmIds field value if set, zero value otherwise. -func (o *LoadBalancer) GetBackendVmIds() []string { - if o == nil || o.BackendVmIds == nil { - var ret []string - return ret - } - return *o.BackendVmIds -} - -// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetBackendVmIdsOk() ([]string, bool) { - if o == nil || o.BackendVmIds == nil { - var ret []string - return ret, false - } - return *o.BackendVmIds, true -} - -// HasBackendVmIds returns a boolean if a field has been set. -func (o *LoadBalancer) HasBackendVmIds() bool { - if o != nil && o.BackendVmIds != nil { - return true - } - - return false -} - -// SetBackendVmIds gets a reference to the given []string and assigns it to the BackendVmIds field. -func (o *LoadBalancer) SetBackendVmIds(v []string) { - o.BackendVmIds = &v -} - -// GetDnsName returns the DnsName field value if set, zero value otherwise. -func (o *LoadBalancer) GetDnsName() string { - if o == nil || o.DnsName == nil { - var ret string - return ret - } - return *o.DnsName -} - -// GetDnsNameOk returns a tuple with the DnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetDnsNameOk() (string, bool) { - if o == nil || o.DnsName == nil { - var ret string - return ret, false - } - return *o.DnsName, true -} - -// HasDnsName returns a boolean if a field has been set. -func (o *LoadBalancer) HasDnsName() bool { - if o != nil && o.DnsName != nil { - return true - } - - return false -} - -// SetDnsName gets a reference to the given string and assigns it to the DnsName field. -func (o *LoadBalancer) SetDnsName(v string) { - o.DnsName = &v -} - -// GetHealthCheck returns the HealthCheck field value if set, zero value otherwise. -func (o *LoadBalancer) GetHealthCheck() HealthCheck { - if o == nil || o.HealthCheck == nil { - var ret HealthCheck - return ret - } - return *o.HealthCheck -} - -// GetHealthCheckOk returns a tuple with the HealthCheck field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetHealthCheckOk() (HealthCheck, bool) { - if o == nil || o.HealthCheck == nil { - var ret HealthCheck - return ret, false - } - return *o.HealthCheck, true -} - -// HasHealthCheck returns a boolean if a field has been set. -func (o *LoadBalancer) HasHealthCheck() bool { - if o != nil && o.HealthCheck != nil { - return true - } - - return false -} - -// SetHealthCheck gets a reference to the given HealthCheck and assigns it to the HealthCheck field. -func (o *LoadBalancer) SetHealthCheck(v HealthCheck) { - o.HealthCheck = &v -} - -// GetListeners returns the Listeners field value if set, zero value otherwise. -func (o *LoadBalancer) GetListeners() []Listener { - if o == nil || o.Listeners == nil { - var ret []Listener - return ret - } - return *o.Listeners -} - -// GetListenersOk returns a tuple with the Listeners field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetListenersOk() ([]Listener, bool) { - if o == nil || o.Listeners == nil { - var ret []Listener - return ret, false - } - return *o.Listeners, true -} - -// HasListeners returns a boolean if a field has been set. -func (o *LoadBalancer) HasListeners() bool { - if o != nil && o.Listeners != nil { - return true - } - - return false -} - -// SetListeners gets a reference to the given []Listener and assigns it to the Listeners field. -func (o *LoadBalancer) SetListeners(v []Listener) { - o.Listeners = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value if set, zero value otherwise. -func (o *LoadBalancer) GetLoadBalancerName() string { - if o == nil || o.LoadBalancerName == nil { - var ret string - return ret - } - return *o.LoadBalancerName -} - -// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetLoadBalancerNameOk() (string, bool) { - if o == nil || o.LoadBalancerName == nil { - var ret string - return ret, false - } - return *o.LoadBalancerName, true -} - -// HasLoadBalancerName returns a boolean if a field has been set. -func (o *LoadBalancer) HasLoadBalancerName() bool { - if o != nil && o.LoadBalancerName != nil { - return true - } - - return false -} - -// SetLoadBalancerName gets a reference to the given string and assigns it to the LoadBalancerName field. -func (o *LoadBalancer) SetLoadBalancerName(v string) { - o.LoadBalancerName = &v -} - -// GetLoadBalancerStickyCookiePolicies returns the LoadBalancerStickyCookiePolicies field value if set, zero value otherwise. -func (o *LoadBalancer) GetLoadBalancerStickyCookiePolicies() []LoadBalancerStickyCookiePolicy { - if o == nil || o.LoadBalancerStickyCookiePolicies == nil { - var ret []LoadBalancerStickyCookiePolicy - return ret - } - return *o.LoadBalancerStickyCookiePolicies -} - -// GetLoadBalancerStickyCookiePoliciesOk returns a tuple with the LoadBalancerStickyCookiePolicies field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetLoadBalancerStickyCookiePoliciesOk() ([]LoadBalancerStickyCookiePolicy, bool) { - if o == nil || o.LoadBalancerStickyCookiePolicies == nil { - var ret []LoadBalancerStickyCookiePolicy - return ret, false - } - return *o.LoadBalancerStickyCookiePolicies, true -} - -// HasLoadBalancerStickyCookiePolicies returns a boolean if a field has been set. -func (o *LoadBalancer) HasLoadBalancerStickyCookiePolicies() bool { - if o != nil && o.LoadBalancerStickyCookiePolicies != nil { - return true - } - - return false -} - -// SetLoadBalancerStickyCookiePolicies gets a reference to the given []LoadBalancerStickyCookiePolicy and assigns it to the LoadBalancerStickyCookiePolicies field. -func (o *LoadBalancer) SetLoadBalancerStickyCookiePolicies(v []LoadBalancerStickyCookiePolicy) { - o.LoadBalancerStickyCookiePolicies = &v -} - -// GetLoadBalancerType returns the LoadBalancerType field value if set, zero value otherwise. -func (o *LoadBalancer) GetLoadBalancerType() string { - if o == nil || o.LoadBalancerType == nil { - var ret string - return ret - } - return *o.LoadBalancerType -} - -// GetLoadBalancerTypeOk returns a tuple with the LoadBalancerType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetLoadBalancerTypeOk() (string, bool) { - if o == nil || o.LoadBalancerType == nil { - var ret string - return ret, false - } - return *o.LoadBalancerType, true -} - -// HasLoadBalancerType returns a boolean if a field has been set. -func (o *LoadBalancer) HasLoadBalancerType() bool { - if o != nil && o.LoadBalancerType != nil { - return true - } - - return false -} - -// SetLoadBalancerType gets a reference to the given string and assigns it to the LoadBalancerType field. -func (o *LoadBalancer) SetLoadBalancerType(v string) { - o.LoadBalancerType = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *LoadBalancer) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *LoadBalancer) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *LoadBalancer) SetNetId(v string) { - o.NetId = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *LoadBalancer) GetSecurityGroups() []string { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetSecurityGroupsOk() ([]string, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []string - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *LoadBalancer) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []string and assigns it to the SecurityGroups field. -func (o *LoadBalancer) SetSecurityGroups(v []string) { - o.SecurityGroups = &v -} - -// GetSourceSecurityGroup returns the SourceSecurityGroup field value if set, zero value otherwise. -func (o *LoadBalancer) GetSourceSecurityGroup() SourceSecurityGroup { - if o == nil || o.SourceSecurityGroup == nil { - var ret SourceSecurityGroup - return ret - } - return *o.SourceSecurityGroup -} - -// GetSourceSecurityGroupOk returns a tuple with the SourceSecurityGroup field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetSourceSecurityGroupOk() (SourceSecurityGroup, bool) { - if o == nil || o.SourceSecurityGroup == nil { - var ret SourceSecurityGroup - return ret, false - } - return *o.SourceSecurityGroup, true -} - -// HasSourceSecurityGroup returns a boolean if a field has been set. -func (o *LoadBalancer) HasSourceSecurityGroup() bool { - if o != nil && o.SourceSecurityGroup != nil { - return true - } - - return false -} - -// SetSourceSecurityGroup gets a reference to the given SourceSecurityGroup and assigns it to the SourceSecurityGroup field. -func (o *LoadBalancer) SetSourceSecurityGroup(v SourceSecurityGroup) { - o.SourceSecurityGroup = &v -} - -// GetSubnets returns the Subnets field value if set, zero value otherwise. -func (o *LoadBalancer) GetSubnets() []string { - if o == nil || o.Subnets == nil { - var ret []string - return ret - } - return *o.Subnets -} - -// GetSubnetsOk returns a tuple with the Subnets field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetSubnetsOk() ([]string, bool) { - if o == nil || o.Subnets == nil { - var ret []string - return ret, false - } - return *o.Subnets, true -} - -// HasSubnets returns a boolean if a field has been set. -func (o *LoadBalancer) HasSubnets() bool { - if o != nil && o.Subnets != nil { - return true - } - - return false -} - -// SetSubnets gets a reference to the given []string and assigns it to the Subnets field. -func (o *LoadBalancer) SetSubnets(v []string) { - o.Subnets = &v -} - -// GetSubregionNames returns the SubregionNames field value if set, zero value otherwise. -func (o *LoadBalancer) GetSubregionNames() []string { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret - } - return *o.SubregionNames -} - -// GetSubregionNamesOk returns a tuple with the SubregionNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetSubregionNamesOk() ([]string, bool) { - if o == nil || o.SubregionNames == nil { - var ret []string - return ret, false - } - return *o.SubregionNames, true -} - -// HasSubregionNames returns a boolean if a field has been set. -func (o *LoadBalancer) HasSubregionNames() bool { - if o != nil && o.SubregionNames != nil { - return true - } - - return false -} - -// SetSubregionNames gets a reference to the given []string and assigns it to the SubregionNames field. -func (o *LoadBalancer) SetSubregionNames(v []string) { - o.SubregionNames = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *LoadBalancer) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancer) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *LoadBalancer) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *LoadBalancer) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableLoadBalancer struct { - Value LoadBalancer - ExplicitNull bool -} - -func (v NullableLoadBalancer) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLoadBalancer) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_light.go deleted file mode 100644 index a1c59f473..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_light.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LoadBalancerLight Information about the load balancer. -type LoadBalancerLight struct { - // The name of the load balancer to which the listener is attached. - LoadBalancerName string `json:"LoadBalancerName"` - // The port of load balancer on which the load balancer is listening (between `1` and `65535` both included). - LoadBalancerPort int64 `json:"LoadBalancerPort"` -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *LoadBalancerLight) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *LoadBalancerLight) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetLoadBalancerPort returns the LoadBalancerPort field value -func (o *LoadBalancerLight) GetLoadBalancerPort() int64 { - if o == nil { - var ret int64 - return ret - } - - return o.LoadBalancerPort -} - -// SetLoadBalancerPort sets field value -func (o *LoadBalancerLight) SetLoadBalancerPort(v int64) { - o.LoadBalancerPort = v -} - -type NullableLoadBalancerLight struct { - Value LoadBalancerLight - ExplicitNull bool -} - -func (v NullableLoadBalancerLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLoadBalancerLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_sticky_cookie_policy.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_sticky_cookie_policy.go deleted file mode 100644 index 7559fc75b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_sticky_cookie_policy.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LoadBalancerStickyCookiePolicy Information about the stickiness policy. -type LoadBalancerStickyCookiePolicy struct { - // The name of the stickiness policy. - PolicyName *string `json:"PolicyName,omitempty"` -} - -// GetPolicyName returns the PolicyName field value if set, zero value otherwise. -func (o *LoadBalancerStickyCookiePolicy) GetPolicyName() string { - if o == nil || o.PolicyName == nil { - var ret string - return ret - } - return *o.PolicyName -} - -// GetPolicyNameOk returns a tuple with the PolicyName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancerStickyCookiePolicy) GetPolicyNameOk() (string, bool) { - if o == nil || o.PolicyName == nil { - var ret string - return ret, false - } - return *o.PolicyName, true -} - -// HasPolicyName returns a boolean if a field has been set. -func (o *LoadBalancerStickyCookiePolicy) HasPolicyName() bool { - if o != nil && o.PolicyName != nil { - return true - } - - return false -} - -// SetPolicyName gets a reference to the given string and assigns it to the PolicyName field. -func (o *LoadBalancerStickyCookiePolicy) SetPolicyName(v string) { - o.PolicyName = &v -} - -type NullableLoadBalancerStickyCookiePolicy struct { - Value LoadBalancerStickyCookiePolicy - ExplicitNull bool -} - -func (v NullableLoadBalancerStickyCookiePolicy) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLoadBalancerStickyCookiePolicy) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_tag.go deleted file mode 100644 index d3ea47bc7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_load_balancer_tag.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// LoadBalancerTag Information about the load balancer tag. -type LoadBalancerTag struct { - // The key of the tag. - Key *string `json:"Key,omitempty"` - // The name of the load balancer. - LoadBalancerName *string `json:"LoadBalancerName,omitempty"` - // The value of the tag. - Value *string `json:"Value,omitempty"` -} - -// GetKey returns the Key field value if set, zero value otherwise. -func (o *LoadBalancerTag) GetKey() string { - if o == nil || o.Key == nil { - var ret string - return ret - } - return *o.Key -} - -// GetKeyOk returns a tuple with the Key field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancerTag) GetKeyOk() (string, bool) { - if o == nil || o.Key == nil { - var ret string - return ret, false - } - return *o.Key, true -} - -// HasKey returns a boolean if a field has been set. -func (o *LoadBalancerTag) HasKey() bool { - if o != nil && o.Key != nil { - return true - } - - return false -} - -// SetKey gets a reference to the given string and assigns it to the Key field. -func (o *LoadBalancerTag) SetKey(v string) { - o.Key = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value if set, zero value otherwise. -func (o *LoadBalancerTag) GetLoadBalancerName() string { - if o == nil || o.LoadBalancerName == nil { - var ret string - return ret - } - return *o.LoadBalancerName -} - -// GetLoadBalancerNameOk returns a tuple with the LoadBalancerName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancerTag) GetLoadBalancerNameOk() (string, bool) { - if o == nil || o.LoadBalancerName == nil { - var ret string - return ret, false - } - return *o.LoadBalancerName, true -} - -// HasLoadBalancerName returns a boolean if a field has been set. -func (o *LoadBalancerTag) HasLoadBalancerName() bool { - if o != nil && o.LoadBalancerName != nil { - return true - } - - return false -} - -// SetLoadBalancerName gets a reference to the given string and assigns it to the LoadBalancerName field. -func (o *LoadBalancerTag) SetLoadBalancerName(v string) { - o.LoadBalancerName = &v -} - -// GetValue returns the Value field value if set, zero value otherwise. -func (o *LoadBalancerTag) GetValue() string { - if o == nil || o.Value == nil { - var ret string - return ret - } - return *o.Value -} - -// GetValueOk returns a tuple with the Value field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *LoadBalancerTag) GetValueOk() (string, bool) { - if o == nil || o.Value == nil { - var ret string - return ret, false - } - return *o.Value, true -} - -// HasValue returns a boolean if a field has been set. -func (o *LoadBalancerTag) HasValue() bool { - if o != nil && o.Value != nil { - return true - } - - return false -} - -// SetValue gets a reference to the given string and assigns it to the Value field. -func (o *LoadBalancerTag) SetValue(v string) { - o.Value = &v -} - -type NullableLoadBalancerTag struct { - Value LoadBalancerTag - ExplicitNull bool -} - -func (v NullableLoadBalancerTag) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLoadBalancerTag) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_location.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_location.go deleted file mode 100644 index d833ad81a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_location.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Location Information about the DirectLink location. -type Location struct { - // The location code, to be set as the `Location` parameter of the *CreateDirectLink* method when creating a DirectLink. - Code *string `json:"Code,omitempty"` - // The name and description of the location, corresponding to a datacenter. - Name *string `json:"Name,omitempty"` -} - -// GetCode returns the Code field value if set, zero value otherwise. -func (o *Location) GetCode() string { - if o == nil || o.Code == nil { - var ret string - return ret - } - return *o.Code -} - -// GetCodeOk returns a tuple with the Code field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Location) GetCodeOk() (string, bool) { - if o == nil || o.Code == nil { - var ret string - return ret, false - } - return *o.Code, true -} - -// HasCode returns a boolean if a field has been set. -func (o *Location) HasCode() bool { - if o != nil && o.Code != nil { - return true - } - - return false -} - -// SetCode gets a reference to the given string and assigns it to the Code field. -func (o *Location) SetCode(v string) { - o.Code = &v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *Location) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Location) GetNameOk() (string, bool) { - if o == nil || o.Name == nil { - var ret string - return ret, false - } - return *o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *Location) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *Location) SetName(v string) { - o.Name = &v -} - -type NullableLocation struct { - Value Location - ExplicitNull bool -} - -func (v NullableLocation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLocation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_log.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_log.go deleted file mode 100644 index 51c92d5ce..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_log.go +++ /dev/null @@ -1,603 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Log Information about the log. -type Log struct { - // The account ID. - AccountId *string `json:"AccountId,omitempty"` - // The duration of the call (in milliseconds). - CallDuration *int64 `json:"CallDuration,omitempty"` - // The API key used for the query. - QueryAccessKey *string `json:"QueryAccessKey,omitempty"` - // The name of the API service used by the call. - QueryApiName *string `json:"QueryApiName,omitempty"` - // The version of the API service used by the call. - QueryApiVersion *string `json:"QueryApiVersion,omitempty"` - // The name of the call. - QueryCallName *string `json:"QueryCallName,omitempty"` - // The date and time of the query (in ISO 8601 base or extended format). - QueryDate *string `json:"QueryDate,omitempty"` - // The query header raw. - QueryHeaderRaw *string `json:"QueryHeaderRaw,omitempty"` - // The query header size. - QueryHeaderSize *int64 `json:"QueryHeaderSize,omitempty"` - // The IP address used for the query. - QueryIpAddress *string `json:"QueryIpAddress,omitempty"` - // The query payload raw. - QueryPayloadRaw *string `json:"QueryPayloadRaw,omitempty"` - // The query payload size. - QueryPayloadSize *int64 `json:"QueryPayloadSize,omitempty"` - // The user agent used for the HTTP request. - QueryUserAgent *string `json:"QueryUserAgent,omitempty"` - // The ID provided in the response. - RequestId *string `json:"RequestId,omitempty"` - // The size of the response (in bytes). - ResponseSize *int64 `json:"ResponseSize,omitempty"` - // The HTTP code provided in the response. - ResponseStatusCode *int64 `json:"ResponseStatusCode,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Log) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Log) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Log) SetAccountId(v string) { - o.AccountId = &v -} - -// GetCallDuration returns the CallDuration field value if set, zero value otherwise. -func (o *Log) GetCallDuration() int64 { - if o == nil || o.CallDuration == nil { - var ret int64 - return ret - } - return *o.CallDuration -} - -// GetCallDurationOk returns a tuple with the CallDuration field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetCallDurationOk() (int64, bool) { - if o == nil || o.CallDuration == nil { - var ret int64 - return ret, false - } - return *o.CallDuration, true -} - -// HasCallDuration returns a boolean if a field has been set. -func (o *Log) HasCallDuration() bool { - if o != nil && o.CallDuration != nil { - return true - } - - return false -} - -// SetCallDuration gets a reference to the given int64 and assigns it to the CallDuration field. -func (o *Log) SetCallDuration(v int64) { - o.CallDuration = &v -} - -// GetQueryAccessKey returns the QueryAccessKey field value if set, zero value otherwise. -func (o *Log) GetQueryAccessKey() string { - if o == nil || o.QueryAccessKey == nil { - var ret string - return ret - } - return *o.QueryAccessKey -} - -// GetQueryAccessKeyOk returns a tuple with the QueryAccessKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryAccessKeyOk() (string, bool) { - if o == nil || o.QueryAccessKey == nil { - var ret string - return ret, false - } - return *o.QueryAccessKey, true -} - -// HasQueryAccessKey returns a boolean if a field has been set. -func (o *Log) HasQueryAccessKey() bool { - if o != nil && o.QueryAccessKey != nil { - return true - } - - return false -} - -// SetQueryAccessKey gets a reference to the given string and assigns it to the QueryAccessKey field. -func (o *Log) SetQueryAccessKey(v string) { - o.QueryAccessKey = &v -} - -// GetQueryApiName returns the QueryApiName field value if set, zero value otherwise. -func (o *Log) GetQueryApiName() string { - if o == nil || o.QueryApiName == nil { - var ret string - return ret - } - return *o.QueryApiName -} - -// GetQueryApiNameOk returns a tuple with the QueryApiName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryApiNameOk() (string, bool) { - if o == nil || o.QueryApiName == nil { - var ret string - return ret, false - } - return *o.QueryApiName, true -} - -// HasQueryApiName returns a boolean if a field has been set. -func (o *Log) HasQueryApiName() bool { - if o != nil && o.QueryApiName != nil { - return true - } - - return false -} - -// SetQueryApiName gets a reference to the given string and assigns it to the QueryApiName field. -func (o *Log) SetQueryApiName(v string) { - o.QueryApiName = &v -} - -// GetQueryApiVersion returns the QueryApiVersion field value if set, zero value otherwise. -func (o *Log) GetQueryApiVersion() string { - if o == nil || o.QueryApiVersion == nil { - var ret string - return ret - } - return *o.QueryApiVersion -} - -// GetQueryApiVersionOk returns a tuple with the QueryApiVersion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryApiVersionOk() (string, bool) { - if o == nil || o.QueryApiVersion == nil { - var ret string - return ret, false - } - return *o.QueryApiVersion, true -} - -// HasQueryApiVersion returns a boolean if a field has been set. -func (o *Log) HasQueryApiVersion() bool { - if o != nil && o.QueryApiVersion != nil { - return true - } - - return false -} - -// SetQueryApiVersion gets a reference to the given string and assigns it to the QueryApiVersion field. -func (o *Log) SetQueryApiVersion(v string) { - o.QueryApiVersion = &v -} - -// GetQueryCallName returns the QueryCallName field value if set, zero value otherwise. -func (o *Log) GetQueryCallName() string { - if o == nil || o.QueryCallName == nil { - var ret string - return ret - } - return *o.QueryCallName -} - -// GetQueryCallNameOk returns a tuple with the QueryCallName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryCallNameOk() (string, bool) { - if o == nil || o.QueryCallName == nil { - var ret string - return ret, false - } - return *o.QueryCallName, true -} - -// HasQueryCallName returns a boolean if a field has been set. -func (o *Log) HasQueryCallName() bool { - if o != nil && o.QueryCallName != nil { - return true - } - - return false -} - -// SetQueryCallName gets a reference to the given string and assigns it to the QueryCallName field. -func (o *Log) SetQueryCallName(v string) { - o.QueryCallName = &v -} - -// GetQueryDate returns the QueryDate field value if set, zero value otherwise. -func (o *Log) GetQueryDate() string { - if o == nil || o.QueryDate == nil { - var ret string - return ret - } - return *o.QueryDate -} - -// GetQueryDateOk returns a tuple with the QueryDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryDateOk() (string, bool) { - if o == nil || o.QueryDate == nil { - var ret string - return ret, false - } - return *o.QueryDate, true -} - -// HasQueryDate returns a boolean if a field has been set. -func (o *Log) HasQueryDate() bool { - if o != nil && o.QueryDate != nil { - return true - } - - return false -} - -// SetQueryDate gets a reference to the given string and assigns it to the QueryDate field. -func (o *Log) SetQueryDate(v string) { - o.QueryDate = &v -} - -// GetQueryHeaderRaw returns the QueryHeaderRaw field value if set, zero value otherwise. -func (o *Log) GetQueryHeaderRaw() string { - if o == nil || o.QueryHeaderRaw == nil { - var ret string - return ret - } - return *o.QueryHeaderRaw -} - -// GetQueryHeaderRawOk returns a tuple with the QueryHeaderRaw field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryHeaderRawOk() (string, bool) { - if o == nil || o.QueryHeaderRaw == nil { - var ret string - return ret, false - } - return *o.QueryHeaderRaw, true -} - -// HasQueryHeaderRaw returns a boolean if a field has been set. -func (o *Log) HasQueryHeaderRaw() bool { - if o != nil && o.QueryHeaderRaw != nil { - return true - } - - return false -} - -// SetQueryHeaderRaw gets a reference to the given string and assigns it to the QueryHeaderRaw field. -func (o *Log) SetQueryHeaderRaw(v string) { - o.QueryHeaderRaw = &v -} - -// GetQueryHeaderSize returns the QueryHeaderSize field value if set, zero value otherwise. -func (o *Log) GetQueryHeaderSize() int64 { - if o == nil || o.QueryHeaderSize == nil { - var ret int64 - return ret - } - return *o.QueryHeaderSize -} - -// GetQueryHeaderSizeOk returns a tuple with the QueryHeaderSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryHeaderSizeOk() (int64, bool) { - if o == nil || o.QueryHeaderSize == nil { - var ret int64 - return ret, false - } - return *o.QueryHeaderSize, true -} - -// HasQueryHeaderSize returns a boolean if a field has been set. -func (o *Log) HasQueryHeaderSize() bool { - if o != nil && o.QueryHeaderSize != nil { - return true - } - - return false -} - -// SetQueryHeaderSize gets a reference to the given int64 and assigns it to the QueryHeaderSize field. -func (o *Log) SetQueryHeaderSize(v int64) { - o.QueryHeaderSize = &v -} - -// GetQueryIpAddress returns the QueryIpAddress field value if set, zero value otherwise. -func (o *Log) GetQueryIpAddress() string { - if o == nil || o.QueryIpAddress == nil { - var ret string - return ret - } - return *o.QueryIpAddress -} - -// GetQueryIpAddressOk returns a tuple with the QueryIpAddress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryIpAddressOk() (string, bool) { - if o == nil || o.QueryIpAddress == nil { - var ret string - return ret, false - } - return *o.QueryIpAddress, true -} - -// HasQueryIpAddress returns a boolean if a field has been set. -func (o *Log) HasQueryIpAddress() bool { - if o != nil && o.QueryIpAddress != nil { - return true - } - - return false -} - -// SetQueryIpAddress gets a reference to the given string and assigns it to the QueryIpAddress field. -func (o *Log) SetQueryIpAddress(v string) { - o.QueryIpAddress = &v -} - -// GetQueryPayloadRaw returns the QueryPayloadRaw field value if set, zero value otherwise. -func (o *Log) GetQueryPayloadRaw() string { - if o == nil || o.QueryPayloadRaw == nil { - var ret string - return ret - } - return *o.QueryPayloadRaw -} - -// GetQueryPayloadRawOk returns a tuple with the QueryPayloadRaw field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryPayloadRawOk() (string, bool) { - if o == nil || o.QueryPayloadRaw == nil { - var ret string - return ret, false - } - return *o.QueryPayloadRaw, true -} - -// HasQueryPayloadRaw returns a boolean if a field has been set. -func (o *Log) HasQueryPayloadRaw() bool { - if o != nil && o.QueryPayloadRaw != nil { - return true - } - - return false -} - -// SetQueryPayloadRaw gets a reference to the given string and assigns it to the QueryPayloadRaw field. -func (o *Log) SetQueryPayloadRaw(v string) { - o.QueryPayloadRaw = &v -} - -// GetQueryPayloadSize returns the QueryPayloadSize field value if set, zero value otherwise. -func (o *Log) GetQueryPayloadSize() int64 { - if o == nil || o.QueryPayloadSize == nil { - var ret int64 - return ret - } - return *o.QueryPayloadSize -} - -// GetQueryPayloadSizeOk returns a tuple with the QueryPayloadSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryPayloadSizeOk() (int64, bool) { - if o == nil || o.QueryPayloadSize == nil { - var ret int64 - return ret, false - } - return *o.QueryPayloadSize, true -} - -// HasQueryPayloadSize returns a boolean if a field has been set. -func (o *Log) HasQueryPayloadSize() bool { - if o != nil && o.QueryPayloadSize != nil { - return true - } - - return false -} - -// SetQueryPayloadSize gets a reference to the given int64 and assigns it to the QueryPayloadSize field. -func (o *Log) SetQueryPayloadSize(v int64) { - o.QueryPayloadSize = &v -} - -// GetQueryUserAgent returns the QueryUserAgent field value if set, zero value otherwise. -func (o *Log) GetQueryUserAgent() string { - if o == nil || o.QueryUserAgent == nil { - var ret string - return ret - } - return *o.QueryUserAgent -} - -// GetQueryUserAgentOk returns a tuple with the QueryUserAgent field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetQueryUserAgentOk() (string, bool) { - if o == nil || o.QueryUserAgent == nil { - var ret string - return ret, false - } - return *o.QueryUserAgent, true -} - -// HasQueryUserAgent returns a boolean if a field has been set. -func (o *Log) HasQueryUserAgent() bool { - if o != nil && o.QueryUserAgent != nil { - return true - } - - return false -} - -// SetQueryUserAgent gets a reference to the given string and assigns it to the QueryUserAgent field. -func (o *Log) SetQueryUserAgent(v string) { - o.QueryUserAgent = &v -} - -// GetRequestId returns the RequestId field value if set, zero value otherwise. -func (o *Log) GetRequestId() string { - if o == nil || o.RequestId == nil { - var ret string - return ret - } - return *o.RequestId -} - -// GetRequestIdOk returns a tuple with the RequestId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetRequestIdOk() (string, bool) { - if o == nil || o.RequestId == nil { - var ret string - return ret, false - } - return *o.RequestId, true -} - -// HasRequestId returns a boolean if a field has been set. -func (o *Log) HasRequestId() bool { - if o != nil && o.RequestId != nil { - return true - } - - return false -} - -// SetRequestId gets a reference to the given string and assigns it to the RequestId field. -func (o *Log) SetRequestId(v string) { - o.RequestId = &v -} - -// GetResponseSize returns the ResponseSize field value if set, zero value otherwise. -func (o *Log) GetResponseSize() int64 { - if o == nil || o.ResponseSize == nil { - var ret int64 - return ret - } - return *o.ResponseSize -} - -// GetResponseSizeOk returns a tuple with the ResponseSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetResponseSizeOk() (int64, bool) { - if o == nil || o.ResponseSize == nil { - var ret int64 - return ret, false - } - return *o.ResponseSize, true -} - -// HasResponseSize returns a boolean if a field has been set. -func (o *Log) HasResponseSize() bool { - if o != nil && o.ResponseSize != nil { - return true - } - - return false -} - -// SetResponseSize gets a reference to the given int64 and assigns it to the ResponseSize field. -func (o *Log) SetResponseSize(v int64) { - o.ResponseSize = &v -} - -// GetResponseStatusCode returns the ResponseStatusCode field value if set, zero value otherwise. -func (o *Log) GetResponseStatusCode() int64 { - if o == nil || o.ResponseStatusCode == nil { - var ret int64 - return ret - } - return *o.ResponseStatusCode -} - -// GetResponseStatusCodeOk returns a tuple with the ResponseStatusCode field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Log) GetResponseStatusCodeOk() (int64, bool) { - if o == nil || o.ResponseStatusCode == nil { - var ret int64 - return ret, false - } - return *o.ResponseStatusCode, true -} - -// HasResponseStatusCode returns a boolean if a field has been set. -func (o *Log) HasResponseStatusCode() bool { - if o != nil && o.ResponseStatusCode != nil { - return true - } - - return false -} - -// SetResponseStatusCode gets a reference to the given int64 and assigns it to the ResponseStatusCode field. -func (o *Log) SetResponseStatusCode(v int64) { - o.ResponseStatusCode = &v -} - -type NullableLog struct { - Value Log - ExplicitNull bool -} - -func (v NullableLog) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableLog) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_maintenance_event.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_maintenance_event.go deleted file mode 100644 index dc79c2650..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_maintenance_event.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// MaintenanceEvent Information about the maintenance event. -type MaintenanceEvent struct { - // The code of the event (`system-reboot` \\| `system-maintenance`). - Code *string `json:"Code,omitempty"` - // The description of the event. - Description *string `json:"Description,omitempty"` - // The latest scheduled end time for the event. - NotAfter *string `json:"NotAfter,omitempty"` - // The earliest scheduled start time for the event. - NotBefore *string `json:"NotBefore,omitempty"` -} - -// GetCode returns the Code field value if set, zero value otherwise. -func (o *MaintenanceEvent) GetCode() string { - if o == nil || o.Code == nil { - var ret string - return ret - } - return *o.Code -} - -// GetCodeOk returns a tuple with the Code field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *MaintenanceEvent) GetCodeOk() (string, bool) { - if o == nil || o.Code == nil { - var ret string - return ret, false - } - return *o.Code, true -} - -// HasCode returns a boolean if a field has been set. -func (o *MaintenanceEvent) HasCode() bool { - if o != nil && o.Code != nil { - return true - } - - return false -} - -// SetCode gets a reference to the given string and assigns it to the Code field. -func (o *MaintenanceEvent) SetCode(v string) { - o.Code = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *MaintenanceEvent) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *MaintenanceEvent) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *MaintenanceEvent) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *MaintenanceEvent) SetDescription(v string) { - o.Description = &v -} - -// GetNotAfter returns the NotAfter field value if set, zero value otherwise. -func (o *MaintenanceEvent) GetNotAfter() string { - if o == nil || o.NotAfter == nil { - var ret string - return ret - } - return *o.NotAfter -} - -// GetNotAfterOk returns a tuple with the NotAfter field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *MaintenanceEvent) GetNotAfterOk() (string, bool) { - if o == nil || o.NotAfter == nil { - var ret string - return ret, false - } - return *o.NotAfter, true -} - -// HasNotAfter returns a boolean if a field has been set. -func (o *MaintenanceEvent) HasNotAfter() bool { - if o != nil && o.NotAfter != nil { - return true - } - - return false -} - -// SetNotAfter gets a reference to the given string and assigns it to the NotAfter field. -func (o *MaintenanceEvent) SetNotAfter(v string) { - o.NotAfter = &v -} - -// GetNotBefore returns the NotBefore field value if set, zero value otherwise. -func (o *MaintenanceEvent) GetNotBefore() string { - if o == nil || o.NotBefore == nil { - var ret string - return ret - } - return *o.NotBefore -} - -// GetNotBeforeOk returns a tuple with the NotBefore field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *MaintenanceEvent) GetNotBeforeOk() (string, bool) { - if o == nil || o.NotBefore == nil { - var ret string - return ret, false - } - return *o.NotBefore, true -} - -// HasNotBefore returns a boolean if a field has been set. -func (o *MaintenanceEvent) HasNotBefore() bool { - if o != nil && o.NotBefore != nil { - return true - } - - return false -} - -// SetNotBefore gets a reference to the given string and assigns it to the NotBefore field. -func (o *MaintenanceEvent) SetNotBefore(v string) { - o.NotBefore = &v -} - -type NullableMaintenanceEvent struct { - Value MaintenanceEvent - ExplicitNull bool -} - -func (v NullableMaintenanceEvent) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableMaintenanceEvent) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_nat_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_nat_service.go deleted file mode 100644 index c641d0606..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_nat_service.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NatService Information about the NAT service. -type NatService struct { - // The ID of the NAT service. - NatServiceId *string `json:"NatServiceId,omitempty"` - // The ID of the Net in which the NAT service is. - NetId *string `json:"NetId,omitempty"` - // Information about the External IP address or addresses (EIPs) associated with the NAT service. - PublicIps *[]PublicIpLight `json:"PublicIps,omitempty"` - // The state of the NAT service (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` - // The ID of the Subnet in which the NAT service is. - SubnetId *string `json:"SubnetId,omitempty"` - // One or more tags associated with the NAT service. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. -func (o *NatService) GetNatServiceId() string { - if o == nil || o.NatServiceId == nil { - var ret string - return ret - } - return *o.NatServiceId -} - -// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetNatServiceIdOk() (string, bool) { - if o == nil || o.NatServiceId == nil { - var ret string - return ret, false - } - return *o.NatServiceId, true -} - -// HasNatServiceId returns a boolean if a field has been set. -func (o *NatService) HasNatServiceId() bool { - if o != nil && o.NatServiceId != nil { - return true - } - - return false -} - -// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. -func (o *NatService) SetNatServiceId(v string) { - o.NatServiceId = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *NatService) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *NatService) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *NatService) SetNetId(v string) { - o.NetId = &v -} - -// GetPublicIps returns the PublicIps field value if set, zero value otherwise. -func (o *NatService) GetPublicIps() []PublicIpLight { - if o == nil || o.PublicIps == nil { - var ret []PublicIpLight - return ret - } - return *o.PublicIps -} - -// GetPublicIpsOk returns a tuple with the PublicIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetPublicIpsOk() ([]PublicIpLight, bool) { - if o == nil || o.PublicIps == nil { - var ret []PublicIpLight - return ret, false - } - return *o.PublicIps, true -} - -// HasPublicIps returns a boolean if a field has been set. -func (o *NatService) HasPublicIps() bool { - if o != nil && o.PublicIps != nil { - return true - } - - return false -} - -// SetPublicIps gets a reference to the given []PublicIpLight and assigns it to the PublicIps field. -func (o *NatService) SetPublicIps(v []PublicIpLight) { - o.PublicIps = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *NatService) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *NatService) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *NatService) SetState(v string) { - o.State = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *NatService) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *NatService) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *NatService) SetSubnetId(v string) { - o.SubnetId = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *NatService) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NatService) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *NatService) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *NatService) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableNatService struct { - Value NatService - ExplicitNull bool -} - -func (v NullableNatService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNatService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_net.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_net.go deleted file mode 100644 index 413d483bb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_net.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Net Information about the Net. -type Net struct { - // The ID of the DHCP options set (or `default` if you want to associate the default one). - DhcpOptionsSetId *string `json:"DhcpOptionsSetId,omitempty"` - // The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // The ID of the Net. - NetId *string `json:"NetId,omitempty"` - // The state of the Net (`pending` \\| `available`). - State *string `json:"State,omitempty"` - // One or more tags associated with the Net. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The VM tenancy in a Net. - Tenancy *string `json:"Tenancy,omitempty"` -} - -// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value if set, zero value otherwise. -func (o *Net) GetDhcpOptionsSetId() string { - if o == nil || o.DhcpOptionsSetId == nil { - var ret string - return ret - } - return *o.DhcpOptionsSetId -} - -// GetDhcpOptionsSetIdOk returns a tuple with the DhcpOptionsSetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetDhcpOptionsSetIdOk() (string, bool) { - if o == nil || o.DhcpOptionsSetId == nil { - var ret string - return ret, false - } - return *o.DhcpOptionsSetId, true -} - -// HasDhcpOptionsSetId returns a boolean if a field has been set. -func (o *Net) HasDhcpOptionsSetId() bool { - if o != nil && o.DhcpOptionsSetId != nil { - return true - } - - return false -} - -// SetDhcpOptionsSetId gets a reference to the given string and assigns it to the DhcpOptionsSetId field. -func (o *Net) SetDhcpOptionsSetId(v string) { - o.DhcpOptionsSetId = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *Net) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *Net) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *Net) SetIpRange(v string) { - o.IpRange = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *Net) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *Net) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *Net) SetNetId(v string) { - o.NetId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Net) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Net) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Net) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Net) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Net) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Net) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetTenancy returns the Tenancy field value if set, zero value otherwise. -func (o *Net) GetTenancy() string { - if o == nil || o.Tenancy == nil { - var ret string - return ret - } - return *o.Tenancy -} - -// GetTenancyOk returns a tuple with the Tenancy field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Net) GetTenancyOk() (string, bool) { - if o == nil || o.Tenancy == nil { - var ret string - return ret, false - } - return *o.Tenancy, true -} - -// HasTenancy returns a boolean if a field has been set. -func (o *Net) HasTenancy() bool { - if o != nil && o.Tenancy != nil { - return true - } - - return false -} - -// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. -func (o *Net) SetTenancy(v string) { - o.Tenancy = &v -} - -type NullableNet struct { - Value Net - ExplicitNull bool -} - -func (v NullableNet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_access_point.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_net_access_point.go deleted file mode 100644 index 9714640ac..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_access_point.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NetAccessPoint Information about the Net access point. -type NetAccessPoint struct { - // The ID of the Net access point. - NetAccessPointId *string `json:"NetAccessPointId,omitempty"` - // The ID of the Net with which the Net access point is associated. - NetId *string `json:"NetId,omitempty"` - // The ID of the route tables associated with the Net access point. - RouteTableIds *[]string `json:"RouteTableIds,omitempty"` - // The name of the prefix list corresponding to the service with which the Net access point is associated. - ServiceName *string `json:"ServiceName,omitempty"` - // The state of the Net access point (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` - // One or more tags associated with the Net access point. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetNetAccessPointId returns the NetAccessPointId field value if set, zero value otherwise. -func (o *NetAccessPoint) GetNetAccessPointId() string { - if o == nil || o.NetAccessPointId == nil { - var ret string - return ret - } - return *o.NetAccessPointId -} - -// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetNetAccessPointIdOk() (string, bool) { - if o == nil || o.NetAccessPointId == nil { - var ret string - return ret, false - } - return *o.NetAccessPointId, true -} - -// HasNetAccessPointId returns a boolean if a field has been set. -func (o *NetAccessPoint) HasNetAccessPointId() bool { - if o != nil && o.NetAccessPointId != nil { - return true - } - - return false -} - -// SetNetAccessPointId gets a reference to the given string and assigns it to the NetAccessPointId field. -func (o *NetAccessPoint) SetNetAccessPointId(v string) { - o.NetAccessPointId = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *NetAccessPoint) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *NetAccessPoint) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *NetAccessPoint) SetNetId(v string) { - o.NetId = &v -} - -// GetRouteTableIds returns the RouteTableIds field value if set, zero value otherwise. -func (o *NetAccessPoint) GetRouteTableIds() []string { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret - } - return *o.RouteTableIds -} - -// GetRouteTableIdsOk returns a tuple with the RouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetRouteTableIdsOk() ([]string, bool) { - if o == nil || o.RouteTableIds == nil { - var ret []string - return ret, false - } - return *o.RouteTableIds, true -} - -// HasRouteTableIds returns a boolean if a field has been set. -func (o *NetAccessPoint) HasRouteTableIds() bool { - if o != nil && o.RouteTableIds != nil { - return true - } - - return false -} - -// SetRouteTableIds gets a reference to the given []string and assigns it to the RouteTableIds field. -func (o *NetAccessPoint) SetRouteTableIds(v []string) { - o.RouteTableIds = &v -} - -// GetServiceName returns the ServiceName field value if set, zero value otherwise. -func (o *NetAccessPoint) GetServiceName() string { - if o == nil || o.ServiceName == nil { - var ret string - return ret - } - return *o.ServiceName -} - -// GetServiceNameOk returns a tuple with the ServiceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetServiceNameOk() (string, bool) { - if o == nil || o.ServiceName == nil { - var ret string - return ret, false - } - return *o.ServiceName, true -} - -// HasServiceName returns a boolean if a field has been set. -func (o *NetAccessPoint) HasServiceName() bool { - if o != nil && o.ServiceName != nil { - return true - } - - return false -} - -// SetServiceName gets a reference to the given string and assigns it to the ServiceName field. -func (o *NetAccessPoint) SetServiceName(v string) { - o.ServiceName = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *NetAccessPoint) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *NetAccessPoint) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *NetAccessPoint) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *NetAccessPoint) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetAccessPoint) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *NetAccessPoint) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *NetAccessPoint) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableNetAccessPoint struct { - Value NetAccessPoint - ExplicitNull bool -} - -func (v NullableNetAccessPoint) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNetAccessPoint) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering.go deleted file mode 100644 index 4a623c146..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering.go +++ /dev/null @@ -1,215 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NetPeering Information about the Net peering connection. -type NetPeering struct { - AccepterNet *AccepterNet `json:"AccepterNet,omitempty"` - // The ID of the Net peering connection. - NetPeeringId *string `json:"NetPeeringId,omitempty"` - SourceNet *SourceNet `json:"SourceNet,omitempty"` - State *NetPeeringState `json:"State,omitempty"` - // One or more tags associated with the Net peering connection. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAccepterNet returns the AccepterNet field value if set, zero value otherwise. -func (o *NetPeering) GetAccepterNet() AccepterNet { - if o == nil || o.AccepterNet == nil { - var ret AccepterNet - return ret - } - return *o.AccepterNet -} - -// GetAccepterNetOk returns a tuple with the AccepterNet field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeering) GetAccepterNetOk() (AccepterNet, bool) { - if o == nil || o.AccepterNet == nil { - var ret AccepterNet - return ret, false - } - return *o.AccepterNet, true -} - -// HasAccepterNet returns a boolean if a field has been set. -func (o *NetPeering) HasAccepterNet() bool { - if o != nil && o.AccepterNet != nil { - return true - } - - return false -} - -// SetAccepterNet gets a reference to the given AccepterNet and assigns it to the AccepterNet field. -func (o *NetPeering) SetAccepterNet(v AccepterNet) { - o.AccepterNet = &v -} - -// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. -func (o *NetPeering) GetNetPeeringId() string { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret - } - return *o.NetPeeringId -} - -// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeering) GetNetPeeringIdOk() (string, bool) { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret, false - } - return *o.NetPeeringId, true -} - -// HasNetPeeringId returns a boolean if a field has been set. -func (o *NetPeering) HasNetPeeringId() bool { - if o != nil && o.NetPeeringId != nil { - return true - } - - return false -} - -// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. -func (o *NetPeering) SetNetPeeringId(v string) { - o.NetPeeringId = &v -} - -// GetSourceNet returns the SourceNet field value if set, zero value otherwise. -func (o *NetPeering) GetSourceNet() SourceNet { - if o == nil || o.SourceNet == nil { - var ret SourceNet - return ret - } - return *o.SourceNet -} - -// GetSourceNetOk returns a tuple with the SourceNet field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeering) GetSourceNetOk() (SourceNet, bool) { - if o == nil || o.SourceNet == nil { - var ret SourceNet - return ret, false - } - return *o.SourceNet, true -} - -// HasSourceNet returns a boolean if a field has been set. -func (o *NetPeering) HasSourceNet() bool { - if o != nil && o.SourceNet != nil { - return true - } - - return false -} - -// SetSourceNet gets a reference to the given SourceNet and assigns it to the SourceNet field. -func (o *NetPeering) SetSourceNet(v SourceNet) { - o.SourceNet = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *NetPeering) GetState() NetPeeringState { - if o == nil || o.State == nil { - var ret NetPeeringState - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeering) GetStateOk() (NetPeeringState, bool) { - if o == nil || o.State == nil { - var ret NetPeeringState - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *NetPeering) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given NetPeeringState and assigns it to the State field. -func (o *NetPeering) SetState(v NetPeeringState) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *NetPeering) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeering) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *NetPeering) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *NetPeering) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableNetPeering struct { - Value NetPeering - ExplicitNull bool -} - -func (v NullableNetPeering) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNetPeering) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering_state.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering_state.go deleted file mode 100644 index e3d700dbf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_peering_state.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NetPeeringState Information about the state of the Net peering connection. -type NetPeeringState struct { - // Additional information about the state of the Net peering connection. - Message *string `json:"Message,omitempty"` - // The state of the Net peering connection (`pending-acceptance` \\| `active` \\| `rejected` \\| `failed` \\| `expired` \\| `deleted`). - Name *string `json:"Name,omitempty"` -} - -// GetMessage returns the Message field value if set, zero value otherwise. -func (o *NetPeeringState) GetMessage() string { - if o == nil || o.Message == nil { - var ret string - return ret - } - return *o.Message -} - -// GetMessageOk returns a tuple with the Message field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeeringState) GetMessageOk() (string, bool) { - if o == nil || o.Message == nil { - var ret string - return ret, false - } - return *o.Message, true -} - -// HasMessage returns a boolean if a field has been set. -func (o *NetPeeringState) HasMessage() bool { - if o != nil && o.Message != nil { - return true - } - - return false -} - -// SetMessage gets a reference to the given string and assigns it to the Message field. -func (o *NetPeeringState) SetMessage(v string) { - o.Message = &v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *NetPeeringState) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetPeeringState) GetNameOk() (string, bool) { - if o == nil || o.Name == nil { - var ret string - return ret, false - } - return *o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *NetPeeringState) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *NetPeeringState) SetName(v string) { - o.Name = &v -} - -type NullableNetPeeringState struct { - Value NetPeeringState - ExplicitNull bool -} - -func (v NullableNetPeeringState) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNetPeeringState) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_to_virtual_gateway_link.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_net_to_virtual_gateway_link.go deleted file mode 100644 index dc5a17120..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_net_to_virtual_gateway_link.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NetToVirtualGatewayLink Information about the attachment. -type NetToVirtualGatewayLink struct { - // The ID of the Net to which the virtual gateway is attached. - NetId *string `json:"NetId,omitempty"` - // The state of the attachment (`attaching` \\| `attached` \\| `detaching` \\| `detached`). - State *string `json:"State,omitempty"` -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *NetToVirtualGatewayLink) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetToVirtualGatewayLink) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *NetToVirtualGatewayLink) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *NetToVirtualGatewayLink) SetNetId(v string) { - o.NetId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *NetToVirtualGatewayLink) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NetToVirtualGatewayLink) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *NetToVirtualGatewayLink) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *NetToVirtualGatewayLink) SetState(v string) { - o.State = &v -} - -type NullableNetToVirtualGatewayLink struct { - Value NetToVirtualGatewayLink - ExplicitNull bool -} - -func (v NullableNetToVirtualGatewayLink) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNetToVirtualGatewayLink) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_nic.go deleted file mode 100644 index 32f00f1ab..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic.go +++ /dev/null @@ -1,566 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Nic Information about the NIC. -type Nic struct { - // The account ID of the owner of the NIC. - AccountId *string `json:"AccountId,omitempty"` - // The description of the NIC. - Description *string `json:"Description,omitempty"` - // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` - LinkNic *LinkNic `json:"LinkNic,omitempty"` - LinkPublicIp *LinkPublicIp `json:"LinkPublicIp,omitempty"` - // The Media Access Control (MAC) address of the NIC. - MacAddress *string `json:"MacAddress,omitempty"` - // The ID of the Net for the NIC. - NetId *string `json:"NetId,omitempty"` - // The ID of the NIC. - NicId *string `json:"NicId,omitempty"` - // The name of the private DNS. - PrivateDnsName *string `json:"PrivateDnsName,omitempty"` - // The private IP addresses of the NIC. - PrivateIps *[]PrivateIp `json:"PrivateIps,omitempty"` - // One or more IDs of security groups for the NIC. - SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` - // The state of the NIC (`available` \\| `attaching` \\| `in-use` \\| `detaching`). - State *string `json:"State,omitempty"` - // The ID of the Subnet. - SubnetId *string `json:"SubnetId,omitempty"` - // The Subregion in which the NIC is located. - SubregionName *string `json:"SubregionName,omitempty"` - // One or more tags associated with the NIC. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Nic) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Nic) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Nic) SetAccountId(v string) { - o.AccountId = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *Nic) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *Nic) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *Nic) SetDescription(v string) { - o.Description = &v -} - -// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. -func (o *Nic) GetIsSourceDestChecked() bool { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret - } - return *o.IsSourceDestChecked -} - -// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetIsSourceDestCheckedOk() (bool, bool) { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret, false - } - return *o.IsSourceDestChecked, true -} - -// HasIsSourceDestChecked returns a boolean if a field has been set. -func (o *Nic) HasIsSourceDestChecked() bool { - if o != nil && o.IsSourceDestChecked != nil { - return true - } - - return false -} - -// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. -func (o *Nic) SetIsSourceDestChecked(v bool) { - o.IsSourceDestChecked = &v -} - -// GetLinkNic returns the LinkNic field value if set, zero value otherwise. -func (o *Nic) GetLinkNic() LinkNic { - if o == nil || o.LinkNic == nil { - var ret LinkNic - return ret - } - return *o.LinkNic -} - -// GetLinkNicOk returns a tuple with the LinkNic field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetLinkNicOk() (LinkNic, bool) { - if o == nil || o.LinkNic == nil { - var ret LinkNic - return ret, false - } - return *o.LinkNic, true -} - -// HasLinkNic returns a boolean if a field has been set. -func (o *Nic) HasLinkNic() bool { - if o != nil && o.LinkNic != nil { - return true - } - - return false -} - -// SetLinkNic gets a reference to the given LinkNic and assigns it to the LinkNic field. -func (o *Nic) SetLinkNic(v LinkNic) { - o.LinkNic = &v -} - -// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. -func (o *Nic) GetLinkPublicIp() LinkPublicIp { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIp - return ret - } - return *o.LinkPublicIp -} - -// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetLinkPublicIpOk() (LinkPublicIp, bool) { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIp - return ret, false - } - return *o.LinkPublicIp, true -} - -// HasLinkPublicIp returns a boolean if a field has been set. -func (o *Nic) HasLinkPublicIp() bool { - if o != nil && o.LinkPublicIp != nil { - return true - } - - return false -} - -// SetLinkPublicIp gets a reference to the given LinkPublicIp and assigns it to the LinkPublicIp field. -func (o *Nic) SetLinkPublicIp(v LinkPublicIp) { - o.LinkPublicIp = &v -} - -// GetMacAddress returns the MacAddress field value if set, zero value otherwise. -func (o *Nic) GetMacAddress() string { - if o == nil || o.MacAddress == nil { - var ret string - return ret - } - return *o.MacAddress -} - -// GetMacAddressOk returns a tuple with the MacAddress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetMacAddressOk() (string, bool) { - if o == nil || o.MacAddress == nil { - var ret string - return ret, false - } - return *o.MacAddress, true -} - -// HasMacAddress returns a boolean if a field has been set. -func (o *Nic) HasMacAddress() bool { - if o != nil && o.MacAddress != nil { - return true - } - - return false -} - -// SetMacAddress gets a reference to the given string and assigns it to the MacAddress field. -func (o *Nic) SetMacAddress(v string) { - o.MacAddress = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *Nic) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *Nic) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *Nic) SetNetId(v string) { - o.NetId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *Nic) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *Nic) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *Nic) SetNicId(v string) { - o.NicId = &v -} - -// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. -func (o *Nic) GetPrivateDnsName() string { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret - } - return *o.PrivateDnsName -} - -// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetPrivateDnsNameOk() (string, bool) { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret, false - } - return *o.PrivateDnsName, true -} - -// HasPrivateDnsName returns a boolean if a field has been set. -func (o *Nic) HasPrivateDnsName() bool { - if o != nil && o.PrivateDnsName != nil { - return true - } - - return false -} - -// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. -func (o *Nic) SetPrivateDnsName(v string) { - o.PrivateDnsName = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *Nic) GetPrivateIps() []PrivateIp { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIp - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetPrivateIpsOk() ([]PrivateIp, bool) { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIp - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *Nic) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []PrivateIp and assigns it to the PrivateIps field. -func (o *Nic) SetPrivateIps(v []PrivateIp) { - o.PrivateIps = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *Nic) GetSecurityGroups() []SecurityGroupLight { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetSecurityGroupsOk() ([]SecurityGroupLight, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *Nic) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. -func (o *Nic) SetSecurityGroups(v []SecurityGroupLight) { - o.SecurityGroups = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Nic) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Nic) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Nic) SetState(v string) { - o.State = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *Nic) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *Nic) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *Nic) SetSubnetId(v string) { - o.SubnetId = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *Nic) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *Nic) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *Nic) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Nic) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Nic) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Nic) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Nic) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableNic struct { - Value Nic - ExplicitNull bool -} - -func (v NullableNic) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNic) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_for_vm_creation.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_for_vm_creation.go deleted file mode 100644 index 09d382d5d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_for_vm_creation.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NicForVmCreation Information about the network interface card (NIC) when creating a virtual machine (VM). -type NicForVmCreation struct { - // If `true`, the NIC is deleted when the VM is terminated. You can specify `true` only if you create a NIC when creating a VM. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // The description of the NIC, if you are creating a NIC when creating the VM. - Description *string `json:"Description,omitempty"` - // The index of the VM device for the NIC attachment (between 0 and 7, both included). This parameter is required if you create a NIC when creating the VM. - DeviceNumber *int64 `json:"DeviceNumber,omitempty"` - // The ID of the NIC, if you are attaching an existing NIC when creating a VM. - NicId *string `json:"NicId,omitempty"` - // One or more private IP addresses to assign to the NIC, if you create a NIC when creating a VM. Only one private IP address can be the primary private IP address. - PrivateIps *[]PrivateIpLight `json:"PrivateIps,omitempty"` - // The number of secondary private IP addresses, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP address in the `PrivateIps` parameter. - SecondaryPrivateIpCount *int64 `json:"SecondaryPrivateIpCount,omitempty"` - // One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` - // The ID of the Subnet for the NIC, if you create a NIC when creating a VM. - SubnetId *string `json:"SubnetId,omitempty"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *NicForVmCreation) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *NicForVmCreation) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *NicForVmCreation) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *NicForVmCreation) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *NicForVmCreation) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *NicForVmCreation) SetDescription(v string) { - o.Description = &v -} - -// GetDeviceNumber returns the DeviceNumber field value if set, zero value otherwise. -func (o *NicForVmCreation) GetDeviceNumber() int64 { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret - } - return *o.DeviceNumber -} - -// GetDeviceNumberOk returns a tuple with the DeviceNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetDeviceNumberOk() (int64, bool) { - if o == nil || o.DeviceNumber == nil { - var ret int64 - return ret, false - } - return *o.DeviceNumber, true -} - -// HasDeviceNumber returns a boolean if a field has been set. -func (o *NicForVmCreation) HasDeviceNumber() bool { - if o != nil && o.DeviceNumber != nil { - return true - } - - return false -} - -// SetDeviceNumber gets a reference to the given int64 and assigns it to the DeviceNumber field. -func (o *NicForVmCreation) SetDeviceNumber(v int64) { - o.DeviceNumber = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *NicForVmCreation) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *NicForVmCreation) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *NicForVmCreation) SetNicId(v string) { - o.NicId = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *NicForVmCreation) GetPrivateIps() []PrivateIpLight { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLight - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetPrivateIpsOk() ([]PrivateIpLight, bool) { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLight - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *NicForVmCreation) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []PrivateIpLight and assigns it to the PrivateIps field. -func (o *NicForVmCreation) SetPrivateIps(v []PrivateIpLight) { - o.PrivateIps = &v -} - -// GetSecondaryPrivateIpCount returns the SecondaryPrivateIpCount field value if set, zero value otherwise. -func (o *NicForVmCreation) GetSecondaryPrivateIpCount() int64 { - if o == nil || o.SecondaryPrivateIpCount == nil { - var ret int64 - return ret - } - return *o.SecondaryPrivateIpCount -} - -// GetSecondaryPrivateIpCountOk returns a tuple with the SecondaryPrivateIpCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetSecondaryPrivateIpCountOk() (int64, bool) { - if o == nil || o.SecondaryPrivateIpCount == nil { - var ret int64 - return ret, false - } - return *o.SecondaryPrivateIpCount, true -} - -// HasSecondaryPrivateIpCount returns a boolean if a field has been set. -func (o *NicForVmCreation) HasSecondaryPrivateIpCount() bool { - if o != nil && o.SecondaryPrivateIpCount != nil { - return true - } - - return false -} - -// SetSecondaryPrivateIpCount gets a reference to the given int64 and assigns it to the SecondaryPrivateIpCount field. -func (o *NicForVmCreation) SetSecondaryPrivateIpCount(v int64) { - o.SecondaryPrivateIpCount = &v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *NicForVmCreation) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *NicForVmCreation) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *NicForVmCreation) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *NicForVmCreation) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicForVmCreation) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *NicForVmCreation) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *NicForVmCreation) SetSubnetId(v string) { - o.SubnetId = &v -} - -type NullableNicForVmCreation struct { - Value NicForVmCreation - ExplicitNull bool -} - -func (v NullableNicForVmCreation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNicForVmCreation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_light.go deleted file mode 100644 index 64c2a75c2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_nic_light.go +++ /dev/null @@ -1,496 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// NicLight Information about the network interface card (NIC). -type NicLight struct { - // The account ID of the owner of the NIC. - AccountId *string `json:"AccountId,omitempty"` - // The description of the NIC. - Description *string `json:"Description,omitempty"` - // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` - LinkNic *LinkNicLight `json:"LinkNic,omitempty"` - LinkPublicIp *LinkPublicIpLightForVm `json:"LinkPublicIp,omitempty"` - // The Media Access Control (MAC) address of the NIC. - MacAddress *string `json:"MacAddress,omitempty"` - // The ID of the Net for the NIC. - NetId *string `json:"NetId,omitempty"` - // The ID of the NIC. - NicId *string `json:"NicId,omitempty"` - // The name of the private DNS. - PrivateDnsName *string `json:"PrivateDnsName,omitempty"` - // The private IP address or addresses of the NIC. - PrivateIps *[]PrivateIpLightForVm `json:"PrivateIps,omitempty"` - // One or more IDs of security groups for the NIC. - SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` - // The state of the NIC (`available` \\| `attaching` \\| `in-use` \\| `detaching`). - State *string `json:"State,omitempty"` - // The ID of the Subnet for the NIC. - SubnetId *string `json:"SubnetId,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *NicLight) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *NicLight) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *NicLight) SetAccountId(v string) { - o.AccountId = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *NicLight) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *NicLight) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *NicLight) SetDescription(v string) { - o.Description = &v -} - -// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. -func (o *NicLight) GetIsSourceDestChecked() bool { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret - } - return *o.IsSourceDestChecked -} - -// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetIsSourceDestCheckedOk() (bool, bool) { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret, false - } - return *o.IsSourceDestChecked, true -} - -// HasIsSourceDestChecked returns a boolean if a field has been set. -func (o *NicLight) HasIsSourceDestChecked() bool { - if o != nil && o.IsSourceDestChecked != nil { - return true - } - - return false -} - -// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. -func (o *NicLight) SetIsSourceDestChecked(v bool) { - o.IsSourceDestChecked = &v -} - -// GetLinkNic returns the LinkNic field value if set, zero value otherwise. -func (o *NicLight) GetLinkNic() LinkNicLight { - if o == nil || o.LinkNic == nil { - var ret LinkNicLight - return ret - } - return *o.LinkNic -} - -// GetLinkNicOk returns a tuple with the LinkNic field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetLinkNicOk() (LinkNicLight, bool) { - if o == nil || o.LinkNic == nil { - var ret LinkNicLight - return ret, false - } - return *o.LinkNic, true -} - -// HasLinkNic returns a boolean if a field has been set. -func (o *NicLight) HasLinkNic() bool { - if o != nil && o.LinkNic != nil { - return true - } - - return false -} - -// SetLinkNic gets a reference to the given LinkNicLight and assigns it to the LinkNic field. -func (o *NicLight) SetLinkNic(v LinkNicLight) { - o.LinkNic = &v -} - -// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. -func (o *NicLight) GetLinkPublicIp() LinkPublicIpLightForVm { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIpLightForVm - return ret - } - return *o.LinkPublicIp -} - -// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetLinkPublicIpOk() (LinkPublicIpLightForVm, bool) { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIpLightForVm - return ret, false - } - return *o.LinkPublicIp, true -} - -// HasLinkPublicIp returns a boolean if a field has been set. -func (o *NicLight) HasLinkPublicIp() bool { - if o != nil && o.LinkPublicIp != nil { - return true - } - - return false -} - -// SetLinkPublicIp gets a reference to the given LinkPublicIpLightForVm and assigns it to the LinkPublicIp field. -func (o *NicLight) SetLinkPublicIp(v LinkPublicIpLightForVm) { - o.LinkPublicIp = &v -} - -// GetMacAddress returns the MacAddress field value if set, zero value otherwise. -func (o *NicLight) GetMacAddress() string { - if o == nil || o.MacAddress == nil { - var ret string - return ret - } - return *o.MacAddress -} - -// GetMacAddressOk returns a tuple with the MacAddress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetMacAddressOk() (string, bool) { - if o == nil || o.MacAddress == nil { - var ret string - return ret, false - } - return *o.MacAddress, true -} - -// HasMacAddress returns a boolean if a field has been set. -func (o *NicLight) HasMacAddress() bool { - if o != nil && o.MacAddress != nil { - return true - } - - return false -} - -// SetMacAddress gets a reference to the given string and assigns it to the MacAddress field. -func (o *NicLight) SetMacAddress(v string) { - o.MacAddress = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *NicLight) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *NicLight) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *NicLight) SetNetId(v string) { - o.NetId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *NicLight) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *NicLight) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *NicLight) SetNicId(v string) { - o.NicId = &v -} - -// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. -func (o *NicLight) GetPrivateDnsName() string { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret - } - return *o.PrivateDnsName -} - -// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetPrivateDnsNameOk() (string, bool) { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret, false - } - return *o.PrivateDnsName, true -} - -// HasPrivateDnsName returns a boolean if a field has been set. -func (o *NicLight) HasPrivateDnsName() bool { - if o != nil && o.PrivateDnsName != nil { - return true - } - - return false -} - -// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. -func (o *NicLight) SetPrivateDnsName(v string) { - o.PrivateDnsName = &v -} - -// GetPrivateIps returns the PrivateIps field value if set, zero value otherwise. -func (o *NicLight) GetPrivateIps() []PrivateIpLightForVm { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLightForVm - return ret - } - return *o.PrivateIps -} - -// GetPrivateIpsOk returns a tuple with the PrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetPrivateIpsOk() ([]PrivateIpLightForVm, bool) { - if o == nil || o.PrivateIps == nil { - var ret []PrivateIpLightForVm - return ret, false - } - return *o.PrivateIps, true -} - -// HasPrivateIps returns a boolean if a field has been set. -func (o *NicLight) HasPrivateIps() bool { - if o != nil && o.PrivateIps != nil { - return true - } - - return false -} - -// SetPrivateIps gets a reference to the given []PrivateIpLightForVm and assigns it to the PrivateIps field. -func (o *NicLight) SetPrivateIps(v []PrivateIpLightForVm) { - o.PrivateIps = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *NicLight) GetSecurityGroups() []SecurityGroupLight { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetSecurityGroupsOk() ([]SecurityGroupLight, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *NicLight) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. -func (o *NicLight) SetSecurityGroups(v []SecurityGroupLight) { - o.SecurityGroups = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *NicLight) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *NicLight) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *NicLight) SetState(v string) { - o.State = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *NicLight) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *NicLight) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *NicLight) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *NicLight) SetSubnetId(v string) { - o.SubnetId = &v -} - -type NullableNicLight struct { - Value NicLight - ExplicitNull bool -} - -func (v NullableNicLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableNicLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_api_key.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_api_key.go deleted file mode 100644 index 410a92118..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_api_key.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// OsuApiKey Information about the OSU API key. -type OsuApiKey struct { - // The API key of the OSU account that enables you to access the bucket. - ApiKeyId *string `json:"ApiKeyId,omitempty"` - // The secret key of the OSU account that enables you to access the bucket. - SecretKey *string `json:"SecretKey,omitempty"` -} - -// GetApiKeyId returns the ApiKeyId field value if set, zero value otherwise. -func (o *OsuApiKey) GetApiKeyId() string { - if o == nil || o.ApiKeyId == nil { - var ret string - return ret - } - return *o.ApiKeyId -} - -// GetApiKeyIdOk returns a tuple with the ApiKeyId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *OsuApiKey) GetApiKeyIdOk() (string, bool) { - if o == nil || o.ApiKeyId == nil { - var ret string - return ret, false - } - return *o.ApiKeyId, true -} - -// HasApiKeyId returns a boolean if a field has been set. -func (o *OsuApiKey) HasApiKeyId() bool { - if o != nil && o.ApiKeyId != nil { - return true - } - - return false -} - -// SetApiKeyId gets a reference to the given string and assigns it to the ApiKeyId field. -func (o *OsuApiKey) SetApiKeyId(v string) { - o.ApiKeyId = &v -} - -// GetSecretKey returns the SecretKey field value if set, zero value otherwise. -func (o *OsuApiKey) GetSecretKey() string { - if o == nil || o.SecretKey == nil { - var ret string - return ret - } - return *o.SecretKey -} - -// GetSecretKeyOk returns a tuple with the SecretKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *OsuApiKey) GetSecretKeyOk() (string, bool) { - if o == nil || o.SecretKey == nil { - var ret string - return ret, false - } - return *o.SecretKey, true -} - -// HasSecretKey returns a boolean if a field has been set. -func (o *OsuApiKey) HasSecretKey() bool { - if o != nil && o.SecretKey != nil { - return true - } - - return false -} - -// SetSecretKey gets a reference to the given string and assigns it to the SecretKey field. -func (o *OsuApiKey) SetSecretKey(v string) { - o.SecretKey = &v -} - -type NullableOsuApiKey struct { - Value OsuApiKey - ExplicitNull bool -} - -func (v NullableOsuApiKey) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableOsuApiKey) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_export.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_export.go deleted file mode 100644 index 7a25eac86..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_osu_export.go +++ /dev/null @@ -1,181 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// OsuExport Information about the OSU export. -type OsuExport struct { - // The format of the export disk (`qcow2` \\| `vdi` \\| `vmdk`). - DiskImageFormat string `json:"DiskImageFormat"` - OsuApiKey *OsuApiKey `json:"OsuApiKey,omitempty"` - // The name of the OSU bucket you want to export the object to. - OsuBucket string `json:"OsuBucket"` - // The URL of the manifest file. - OsuManifestUrl *string `json:"OsuManifestUrl,omitempty"` - // The prefix for the key of the OSU object. This key follows this format: `prefix + object_export_task_id + '.' + disk_image_format`. - OsuPrefix *string `json:"OsuPrefix,omitempty"` -} - -// GetDiskImageFormat returns the DiskImageFormat field value -func (o *OsuExport) GetDiskImageFormat() string { - if o == nil { - var ret string - return ret - } - - return o.DiskImageFormat -} - -// SetDiskImageFormat sets field value -func (o *OsuExport) SetDiskImageFormat(v string) { - o.DiskImageFormat = v -} - -// GetOsuApiKey returns the OsuApiKey field value if set, zero value otherwise. -func (o *OsuExport) GetOsuApiKey() OsuApiKey { - if o == nil || o.OsuApiKey == nil { - var ret OsuApiKey - return ret - } - return *o.OsuApiKey -} - -// GetOsuApiKeyOk returns a tuple with the OsuApiKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *OsuExport) GetOsuApiKeyOk() (OsuApiKey, bool) { - if o == nil || o.OsuApiKey == nil { - var ret OsuApiKey - return ret, false - } - return *o.OsuApiKey, true -} - -// HasOsuApiKey returns a boolean if a field has been set. -func (o *OsuExport) HasOsuApiKey() bool { - if o != nil && o.OsuApiKey != nil { - return true - } - - return false -} - -// SetOsuApiKey gets a reference to the given OsuApiKey and assigns it to the OsuApiKey field. -func (o *OsuExport) SetOsuApiKey(v OsuApiKey) { - o.OsuApiKey = &v -} - -// GetOsuBucket returns the OsuBucket field value -func (o *OsuExport) GetOsuBucket() string { - if o == nil { - var ret string - return ret - } - - return o.OsuBucket -} - -// SetOsuBucket sets field value -func (o *OsuExport) SetOsuBucket(v string) { - o.OsuBucket = v -} - -// GetOsuManifestUrl returns the OsuManifestUrl field value if set, zero value otherwise. -func (o *OsuExport) GetOsuManifestUrl() string { - if o == nil || o.OsuManifestUrl == nil { - var ret string - return ret - } - return *o.OsuManifestUrl -} - -// GetOsuManifestUrlOk returns a tuple with the OsuManifestUrl field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *OsuExport) GetOsuManifestUrlOk() (string, bool) { - if o == nil || o.OsuManifestUrl == nil { - var ret string - return ret, false - } - return *o.OsuManifestUrl, true -} - -// HasOsuManifestUrl returns a boolean if a field has been set. -func (o *OsuExport) HasOsuManifestUrl() bool { - if o != nil && o.OsuManifestUrl != nil { - return true - } - - return false -} - -// SetOsuManifestUrl gets a reference to the given string and assigns it to the OsuManifestUrl field. -func (o *OsuExport) SetOsuManifestUrl(v string) { - o.OsuManifestUrl = &v -} - -// GetOsuPrefix returns the OsuPrefix field value if set, zero value otherwise. -func (o *OsuExport) GetOsuPrefix() string { - if o == nil || o.OsuPrefix == nil { - var ret string - return ret - } - return *o.OsuPrefix -} - -// GetOsuPrefixOk returns a tuple with the OsuPrefix field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *OsuExport) GetOsuPrefixOk() (string, bool) { - if o == nil || o.OsuPrefix == nil { - var ret string - return ret, false - } - return *o.OsuPrefix, true -} - -// HasOsuPrefix returns a boolean if a field has been set. -func (o *OsuExport) HasOsuPrefix() bool { - if o != nil && o.OsuPrefix != nil { - return true - } - - return false -} - -// SetOsuPrefix gets a reference to the given string and assigns it to the OsuPrefix field. -func (o *OsuExport) SetOsuPrefix(v string) { - o.OsuPrefix = &v -} - -type NullableOsuExport struct { - Value OsuExport - ExplicitNull bool -} - -func (v NullableOsuExport) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableOsuExport) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource.go deleted file mode 100644 index 7ae34f07e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PermissionsOnResource Information about the users who have permissions for the resource. -type PermissionsOnResource struct { - // The account ID of one or more users who have permissions for the resource. - AccountIds *[]string `json:"AccountIds,omitempty"` - // If `true`, the resource is public. If `false`, the resource is private. - GlobalPermission *bool `json:"GlobalPermission,omitempty"` -} - -// GetAccountIds returns the AccountIds field value if set, zero value otherwise. -func (o *PermissionsOnResource) GetAccountIds() []string { - if o == nil || o.AccountIds == nil { - var ret []string - return ret - } - return *o.AccountIds -} - -// GetAccountIdsOk returns a tuple with the AccountIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PermissionsOnResource) GetAccountIdsOk() ([]string, bool) { - if o == nil || o.AccountIds == nil { - var ret []string - return ret, false - } - return *o.AccountIds, true -} - -// HasAccountIds returns a boolean if a field has been set. -func (o *PermissionsOnResource) HasAccountIds() bool { - if o != nil && o.AccountIds != nil { - return true - } - - return false -} - -// SetAccountIds gets a reference to the given []string and assigns it to the AccountIds field. -func (o *PermissionsOnResource) SetAccountIds(v []string) { - o.AccountIds = &v -} - -// GetGlobalPermission returns the GlobalPermission field value if set, zero value otherwise. -func (o *PermissionsOnResource) GetGlobalPermission() bool { - if o == nil || o.GlobalPermission == nil { - var ret bool - return ret - } - return *o.GlobalPermission -} - -// GetGlobalPermissionOk returns a tuple with the GlobalPermission field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PermissionsOnResource) GetGlobalPermissionOk() (bool, bool) { - if o == nil || o.GlobalPermission == nil { - var ret bool - return ret, false - } - return *o.GlobalPermission, true -} - -// HasGlobalPermission returns a boolean if a field has been set. -func (o *PermissionsOnResource) HasGlobalPermission() bool { - if o != nil && o.GlobalPermission != nil { - return true - } - - return false -} - -// SetGlobalPermission gets a reference to the given bool and assigns it to the GlobalPermission field. -func (o *PermissionsOnResource) SetGlobalPermission(v bool) { - o.GlobalPermission = &v -} - -type NullablePermissionsOnResource struct { - Value PermissionsOnResource - ExplicitNull bool -} - -func (v NullablePermissionsOnResource) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePermissionsOnResource) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource_creation.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource_creation.go deleted file mode 100644 index e55dab858..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_permissions_on_resource_creation.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PermissionsOnResourceCreation Information about the permissions for the resource. -type PermissionsOnResourceCreation struct { - Additions *PermissionsOnResource `json:"Additions,omitempty"` - Removals *PermissionsOnResource `json:"Removals,omitempty"` -} - -// GetAdditions returns the Additions field value if set, zero value otherwise. -func (o *PermissionsOnResourceCreation) GetAdditions() PermissionsOnResource { - if o == nil || o.Additions == nil { - var ret PermissionsOnResource - return ret - } - return *o.Additions -} - -// GetAdditionsOk returns a tuple with the Additions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PermissionsOnResourceCreation) GetAdditionsOk() (PermissionsOnResource, bool) { - if o == nil || o.Additions == nil { - var ret PermissionsOnResource - return ret, false - } - return *o.Additions, true -} - -// HasAdditions returns a boolean if a field has been set. -func (o *PermissionsOnResourceCreation) HasAdditions() bool { - if o != nil && o.Additions != nil { - return true - } - - return false -} - -// SetAdditions gets a reference to the given PermissionsOnResource and assigns it to the Additions field. -func (o *PermissionsOnResourceCreation) SetAdditions(v PermissionsOnResource) { - o.Additions = &v -} - -// GetRemovals returns the Removals field value if set, zero value otherwise. -func (o *PermissionsOnResourceCreation) GetRemovals() PermissionsOnResource { - if o == nil || o.Removals == nil { - var ret PermissionsOnResource - return ret - } - return *o.Removals -} - -// GetRemovalsOk returns a tuple with the Removals field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PermissionsOnResourceCreation) GetRemovalsOk() (PermissionsOnResource, bool) { - if o == nil || o.Removals == nil { - var ret PermissionsOnResource - return ret, false - } - return *o.Removals, true -} - -// HasRemovals returns a boolean if a field has been set. -func (o *PermissionsOnResourceCreation) HasRemovals() bool { - if o != nil && o.Removals != nil { - return true - } - - return false -} - -// SetRemovals gets a reference to the given PermissionsOnResource and assigns it to the Removals field. -func (o *PermissionsOnResourceCreation) SetRemovals(v PermissionsOnResource) { - o.Removals = &v -} - -type NullablePermissionsOnResourceCreation struct { - Value PermissionsOnResourceCreation - ExplicitNull bool -} - -func (v NullablePermissionsOnResourceCreation) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePermissionsOnResourceCreation) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_placement.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_placement.go deleted file mode 100644 index 1f67c81d3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_placement.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Placement Information about the placement of the VM. -type Placement struct { - // The name of the Subregion. - SubregionName *string `json:"SubregionName,omitempty"` - // The tenancy of the VM (`default` \\| `dedicated`). - Tenancy *string `json:"Tenancy,omitempty"` -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *Placement) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Placement) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *Placement) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *Placement) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetTenancy returns the Tenancy field value if set, zero value otherwise. -func (o *Placement) GetTenancy() string { - if o == nil || o.Tenancy == nil { - var ret string - return ret - } - return *o.Tenancy -} - -// GetTenancyOk returns a tuple with the Tenancy field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Placement) GetTenancyOk() (string, bool) { - if o == nil || o.Tenancy == nil { - var ret string - return ret, false - } - return *o.Tenancy, true -} - -// HasTenancy returns a boolean if a field has been set. -func (o *Placement) HasTenancy() bool { - if o != nil && o.Tenancy != nil { - return true - } - - return false -} - -// SetTenancy gets a reference to the given string and assigns it to the Tenancy field. -func (o *Placement) SetTenancy(v string) { - o.Tenancy = &v -} - -type NullablePlacement struct { - Value Placement - ExplicitNull bool -} - -func (v NullablePlacement) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePlacement) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip.go deleted file mode 100644 index 34ebcf958..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip.go +++ /dev/null @@ -1,182 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PrivateIp Information about the private IP. -type PrivateIp struct { - // If `true`, the IP address is the primary private IP address of the NIC. - IsPrimary *bool `json:"IsPrimary,omitempty"` - LinkPublicIp *LinkPublicIp `json:"LinkPublicIp,omitempty"` - // The name of the private DNS. - PrivateDnsName *string `json:"PrivateDnsName,omitempty"` - // The private IP address of the NIC. - PrivateIp *string `json:"PrivateIp,omitempty"` -} - -// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. -func (o *PrivateIp) GetIsPrimary() bool { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret - } - return *o.IsPrimary -} - -// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIp) GetIsPrimaryOk() (bool, bool) { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret, false - } - return *o.IsPrimary, true -} - -// HasIsPrimary returns a boolean if a field has been set. -func (o *PrivateIp) HasIsPrimary() bool { - if o != nil && o.IsPrimary != nil { - return true - } - - return false -} - -// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. -func (o *PrivateIp) SetIsPrimary(v bool) { - o.IsPrimary = &v -} - -// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. -func (o *PrivateIp) GetLinkPublicIp() LinkPublicIp { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIp - return ret - } - return *o.LinkPublicIp -} - -// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIp) GetLinkPublicIpOk() (LinkPublicIp, bool) { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIp - return ret, false - } - return *o.LinkPublicIp, true -} - -// HasLinkPublicIp returns a boolean if a field has been set. -func (o *PrivateIp) HasLinkPublicIp() bool { - if o != nil && o.LinkPublicIp != nil { - return true - } - - return false -} - -// SetLinkPublicIp gets a reference to the given LinkPublicIp and assigns it to the LinkPublicIp field. -func (o *PrivateIp) SetLinkPublicIp(v LinkPublicIp) { - o.LinkPublicIp = &v -} - -// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. -func (o *PrivateIp) GetPrivateDnsName() string { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret - } - return *o.PrivateDnsName -} - -// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIp) GetPrivateDnsNameOk() (string, bool) { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret, false - } - return *o.PrivateDnsName, true -} - -// HasPrivateDnsName returns a boolean if a field has been set. -func (o *PrivateIp) HasPrivateDnsName() bool { - if o != nil && o.PrivateDnsName != nil { - return true - } - - return false -} - -// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. -func (o *PrivateIp) SetPrivateDnsName(v string) { - o.PrivateDnsName = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *PrivateIp) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIp) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *PrivateIp) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *PrivateIp) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -type NullablePrivateIp struct { - Value PrivateIp - ExplicitNull bool -} - -func (v NullablePrivateIp) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePrivateIp) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light.go deleted file mode 100644 index cd76233ef..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PrivateIpLight Information about the private IP. -type PrivateIpLight struct { - // If `true`, the IP address is the primary private IP address of the NIC. - IsPrimary *bool `json:"IsPrimary,omitempty"` - // The private IP address of the NIC. - PrivateIp *string `json:"PrivateIp,omitempty"` -} - -// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. -func (o *PrivateIpLight) GetIsPrimary() bool { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret - } - return *o.IsPrimary -} - -// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLight) GetIsPrimaryOk() (bool, bool) { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret, false - } - return *o.IsPrimary, true -} - -// HasIsPrimary returns a boolean if a field has been set. -func (o *PrivateIpLight) HasIsPrimary() bool { - if o != nil && o.IsPrimary != nil { - return true - } - - return false -} - -// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. -func (o *PrivateIpLight) SetIsPrimary(v bool) { - o.IsPrimary = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *PrivateIpLight) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLight) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *PrivateIpLight) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *PrivateIpLight) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -type NullablePrivateIpLight struct { - Value PrivateIpLight - ExplicitNull bool -} - -func (v NullablePrivateIpLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePrivateIpLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light_for_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light_for_vm.go deleted file mode 100644 index 0e91bade8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_private_ip_light_for_vm.go +++ /dev/null @@ -1,182 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PrivateIpLightForVm Information about the private IP of the NIC. -type PrivateIpLightForVm struct { - // If `true`, the IP address is the primary private IP address of the NIC. - IsPrimary *bool `json:"IsPrimary,omitempty"` - LinkPublicIp *LinkPublicIpLightForVm `json:"LinkPublicIp,omitempty"` - // The name of the private DNS. - PrivateDnsName *string `json:"PrivateDnsName,omitempty"` - // The private IP address. - PrivateIp *string `json:"PrivateIp,omitempty"` -} - -// GetIsPrimary returns the IsPrimary field value if set, zero value otherwise. -func (o *PrivateIpLightForVm) GetIsPrimary() bool { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret - } - return *o.IsPrimary -} - -// GetIsPrimaryOk returns a tuple with the IsPrimary field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLightForVm) GetIsPrimaryOk() (bool, bool) { - if o == nil || o.IsPrimary == nil { - var ret bool - return ret, false - } - return *o.IsPrimary, true -} - -// HasIsPrimary returns a boolean if a field has been set. -func (o *PrivateIpLightForVm) HasIsPrimary() bool { - if o != nil && o.IsPrimary != nil { - return true - } - - return false -} - -// SetIsPrimary gets a reference to the given bool and assigns it to the IsPrimary field. -func (o *PrivateIpLightForVm) SetIsPrimary(v bool) { - o.IsPrimary = &v -} - -// GetLinkPublicIp returns the LinkPublicIp field value if set, zero value otherwise. -func (o *PrivateIpLightForVm) GetLinkPublicIp() LinkPublicIpLightForVm { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIpLightForVm - return ret - } - return *o.LinkPublicIp -} - -// GetLinkPublicIpOk returns a tuple with the LinkPublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLightForVm) GetLinkPublicIpOk() (LinkPublicIpLightForVm, bool) { - if o == nil || o.LinkPublicIp == nil { - var ret LinkPublicIpLightForVm - return ret, false - } - return *o.LinkPublicIp, true -} - -// HasLinkPublicIp returns a boolean if a field has been set. -func (o *PrivateIpLightForVm) HasLinkPublicIp() bool { - if o != nil && o.LinkPublicIp != nil { - return true - } - - return false -} - -// SetLinkPublicIp gets a reference to the given LinkPublicIpLightForVm and assigns it to the LinkPublicIp field. -func (o *PrivateIpLightForVm) SetLinkPublicIp(v LinkPublicIpLightForVm) { - o.LinkPublicIp = &v -} - -// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. -func (o *PrivateIpLightForVm) GetPrivateDnsName() string { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret - } - return *o.PrivateDnsName -} - -// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLightForVm) GetPrivateDnsNameOk() (string, bool) { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret, false - } - return *o.PrivateDnsName, true -} - -// HasPrivateDnsName returns a boolean if a field has been set. -func (o *PrivateIpLightForVm) HasPrivateDnsName() bool { - if o != nil && o.PrivateDnsName != nil { - return true - } - - return false -} - -// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. -func (o *PrivateIpLightForVm) SetPrivateDnsName(v string) { - o.PrivateDnsName = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *PrivateIpLightForVm) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PrivateIpLightForVm) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *PrivateIpLightForVm) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *PrivateIpLightForVm) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -type NullablePrivateIpLightForVm struct { - Value PrivateIpLightForVm - ExplicitNull bool -} - -func (v NullablePrivateIpLightForVm) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePrivateIpLightForVm) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_product_type.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_product_type.go deleted file mode 100644 index 2fb523745..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_product_type.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ProductType Information about the product type. -type ProductType struct { - // The description of the product type. - Description *string `json:"Description,omitempty"` - // The ID of the product type. - ProductTypeId *string `json:"ProductTypeId,omitempty"` - // The vendor of the product type. - Vendor *string `json:"Vendor,omitempty"` -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *ProductType) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ProductType) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *ProductType) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *ProductType) SetDescription(v string) { - o.Description = &v -} - -// GetProductTypeId returns the ProductTypeId field value if set, zero value otherwise. -func (o *ProductType) GetProductTypeId() string { - if o == nil || o.ProductTypeId == nil { - var ret string - return ret - } - return *o.ProductTypeId -} - -// GetProductTypeIdOk returns a tuple with the ProductTypeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ProductType) GetProductTypeIdOk() (string, bool) { - if o == nil || o.ProductTypeId == nil { - var ret string - return ret, false - } - return *o.ProductTypeId, true -} - -// HasProductTypeId returns a boolean if a field has been set. -func (o *ProductType) HasProductTypeId() bool { - if o != nil && o.ProductTypeId != nil { - return true - } - - return false -} - -// SetProductTypeId gets a reference to the given string and assigns it to the ProductTypeId field. -func (o *ProductType) SetProductTypeId(v string) { - o.ProductTypeId = &v -} - -// GetVendor returns the Vendor field value if set, zero value otherwise. -func (o *ProductType) GetVendor() string { - if o == nil || o.Vendor == nil { - var ret string - return ret - } - return *o.Vendor -} - -// GetVendorOk returns a tuple with the Vendor field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ProductType) GetVendorOk() (string, bool) { - if o == nil || o.Vendor == nil { - var ret string - return ret, false - } - return *o.Vendor, true -} - -// HasVendor returns a boolean if a field has been set. -func (o *ProductType) HasVendor() bool { - if o != nil && o.Vendor != nil { - return true - } - - return false -} - -// SetVendor gets a reference to the given string and assigns it to the Vendor field. -func (o *ProductType) SetVendor(v string) { - o.Vendor = &v -} - -type NullableProductType struct { - Value ProductType - ExplicitNull bool -} - -func (v NullableProductType) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableProductType) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip.go deleted file mode 100644 index 673b586d0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PublicIp Information about the public IP. -type PublicIp struct { - // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` - // The account ID of the owner of the NIC. - NicAccountId *string `json:"NicAccountId,omitempty"` - // The ID of the NIC the EIP is associated with (if any). - NicId *string `json:"NicId,omitempty"` - // The private IP address associated with the EIP. - PrivateIp *string `json:"PrivateIp,omitempty"` - // The External IP address (EIP) associated with the NAT service. - PublicIp *string `json:"PublicIp,omitempty"` - // The allocation ID of the EIP associated with the NAT service. - PublicIpId *string `json:"PublicIpId,omitempty"` - // One or more tags associated with the EIP. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the VM the External IP (EIP) is associated with (if any). - VmId *string `json:"VmId,omitempty"` -} - -// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. -func (o *PublicIp) GetLinkPublicIpId() string { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret - } - return *o.LinkPublicIpId -} - -// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetLinkPublicIpIdOk() (string, bool) { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret, false - } - return *o.LinkPublicIpId, true -} - -// HasLinkPublicIpId returns a boolean if a field has been set. -func (o *PublicIp) HasLinkPublicIpId() bool { - if o != nil && o.LinkPublicIpId != nil { - return true - } - - return false -} - -// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. -func (o *PublicIp) SetLinkPublicIpId(v string) { - o.LinkPublicIpId = &v -} - -// GetNicAccountId returns the NicAccountId field value if set, zero value otherwise. -func (o *PublicIp) GetNicAccountId() string { - if o == nil || o.NicAccountId == nil { - var ret string - return ret - } - return *o.NicAccountId -} - -// GetNicAccountIdOk returns a tuple with the NicAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetNicAccountIdOk() (string, bool) { - if o == nil || o.NicAccountId == nil { - var ret string - return ret, false - } - return *o.NicAccountId, true -} - -// HasNicAccountId returns a boolean if a field has been set. -func (o *PublicIp) HasNicAccountId() bool { - if o != nil && o.NicAccountId != nil { - return true - } - - return false -} - -// SetNicAccountId gets a reference to the given string and assigns it to the NicAccountId field. -func (o *PublicIp) SetNicAccountId(v string) { - o.NicAccountId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *PublicIp) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *PublicIp) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *PublicIp) SetNicId(v string) { - o.NicId = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *PublicIp) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *PublicIp) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *PublicIp) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *PublicIp) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *PublicIp) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *PublicIp) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. -func (o *PublicIp) GetPublicIpId() string { - if o == nil || o.PublicIpId == nil { - var ret string - return ret - } - return *o.PublicIpId -} - -// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetPublicIpIdOk() (string, bool) { - if o == nil || o.PublicIpId == nil { - var ret string - return ret, false - } - return *o.PublicIpId, true -} - -// HasPublicIpId returns a boolean if a field has been set. -func (o *PublicIp) HasPublicIpId() bool { - if o != nil && o.PublicIpId != nil { - return true - } - - return false -} - -// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. -func (o *PublicIp) SetPublicIpId(v string) { - o.PublicIpId = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *PublicIp) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *PublicIp) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *PublicIp) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *PublicIp) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIp) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *PublicIp) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *PublicIp) SetVmId(v string) { - o.VmId = &v -} - -type NullablePublicIp struct { - Value PublicIp - ExplicitNull bool -} - -func (v NullablePublicIp) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePublicIp) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip_light.go deleted file mode 100644 index 0e10b6b3f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_public_ip_light.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// PublicIpLight Information about the public IP. -type PublicIpLight struct { - // The External IP address (EIP) associated with the NAT service. - PublicIp *string `json:"PublicIp,omitempty"` - // The allocation ID of the EIP associated with the NAT service. - PublicIpId *string `json:"PublicIpId,omitempty"` -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *PublicIpLight) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIpLight) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *PublicIpLight) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *PublicIpLight) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetPublicIpId returns the PublicIpId field value if set, zero value otherwise. -func (o *PublicIpLight) GetPublicIpId() string { - if o == nil || o.PublicIpId == nil { - var ret string - return ret - } - return *o.PublicIpId -} - -// GetPublicIpIdOk returns a tuple with the PublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *PublicIpLight) GetPublicIpIdOk() (string, bool) { - if o == nil || o.PublicIpId == nil { - var ret string - return ret, false - } - return *o.PublicIpId, true -} - -// HasPublicIpId returns a boolean if a field has been set. -func (o *PublicIpLight) HasPublicIpId() bool { - if o != nil && o.PublicIpId != nil { - return true - } - - return false -} - -// SetPublicIpId gets a reference to the given string and assigns it to the PublicIpId field. -func (o *PublicIpLight) SetPublicIpId(v string) { - o.PublicIpId = &v -} - -type NullablePublicIpLight struct { - Value PublicIpLight - ExplicitNull bool -} - -func (v NullablePublicIpLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullablePublicIpLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_quota.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_quota.go deleted file mode 100644 index ccafdf02e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_quota.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Quota Information about the quota. -type Quota struct { - // The account ID of the owner of the quotas. - AccountId *string `json:"AccountId,omitempty"` - // The description of the quota. - Description *string `json:"Description,omitempty"` - // The maximum value of the quota for the 3DS OUTSCALE user account (if there is no limit, `0`). - MaxValue *int64 `json:"MaxValue,omitempty"` - // The unique name of the quota. - Name *string `json:"Name,omitempty"` - // The group name of the quota. - QuotaCollection *string `json:"QuotaCollection,omitempty"` - // The description of the quota. - ShortDescription *string `json:"ShortDescription,omitempty"` - // The limit value currently used by the 3DS OUTSCALE user account. - UsedValue *int64 `json:"UsedValue,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Quota) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Quota) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Quota) SetAccountId(v string) { - o.AccountId = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *Quota) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *Quota) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *Quota) SetDescription(v string) { - o.Description = &v -} - -// GetMaxValue returns the MaxValue field value if set, zero value otherwise. -func (o *Quota) GetMaxValue() int64 { - if o == nil || o.MaxValue == nil { - var ret int64 - return ret - } - return *o.MaxValue -} - -// GetMaxValueOk returns a tuple with the MaxValue field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetMaxValueOk() (int64, bool) { - if o == nil || o.MaxValue == nil { - var ret int64 - return ret, false - } - return *o.MaxValue, true -} - -// HasMaxValue returns a boolean if a field has been set. -func (o *Quota) HasMaxValue() bool { - if o != nil && o.MaxValue != nil { - return true - } - - return false -} - -// SetMaxValue gets a reference to the given int64 and assigns it to the MaxValue field. -func (o *Quota) SetMaxValue(v int64) { - o.MaxValue = &v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *Quota) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetNameOk() (string, bool) { - if o == nil || o.Name == nil { - var ret string - return ret, false - } - return *o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *Quota) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *Quota) SetName(v string) { - o.Name = &v -} - -// GetQuotaCollection returns the QuotaCollection field value if set, zero value otherwise. -func (o *Quota) GetQuotaCollection() string { - if o == nil || o.QuotaCollection == nil { - var ret string - return ret - } - return *o.QuotaCollection -} - -// GetQuotaCollectionOk returns a tuple with the QuotaCollection field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetQuotaCollectionOk() (string, bool) { - if o == nil || o.QuotaCollection == nil { - var ret string - return ret, false - } - return *o.QuotaCollection, true -} - -// HasQuotaCollection returns a boolean if a field has been set. -func (o *Quota) HasQuotaCollection() bool { - if o != nil && o.QuotaCollection != nil { - return true - } - - return false -} - -// SetQuotaCollection gets a reference to the given string and assigns it to the QuotaCollection field. -func (o *Quota) SetQuotaCollection(v string) { - o.QuotaCollection = &v -} - -// GetShortDescription returns the ShortDescription field value if set, zero value otherwise. -func (o *Quota) GetShortDescription() string { - if o == nil || o.ShortDescription == nil { - var ret string - return ret - } - return *o.ShortDescription -} - -// GetShortDescriptionOk returns a tuple with the ShortDescription field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetShortDescriptionOk() (string, bool) { - if o == nil || o.ShortDescription == nil { - var ret string - return ret, false - } - return *o.ShortDescription, true -} - -// HasShortDescription returns a boolean if a field has been set. -func (o *Quota) HasShortDescription() bool { - if o != nil && o.ShortDescription != nil { - return true - } - - return false -} - -// SetShortDescription gets a reference to the given string and assigns it to the ShortDescription field. -func (o *Quota) SetShortDescription(v string) { - o.ShortDescription = &v -} - -// GetUsedValue returns the UsedValue field value if set, zero value otherwise. -func (o *Quota) GetUsedValue() int64 { - if o == nil || o.UsedValue == nil { - var ret int64 - return ret - } - return *o.UsedValue -} - -// GetUsedValueOk returns a tuple with the UsedValue field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Quota) GetUsedValueOk() (int64, bool) { - if o == nil || o.UsedValue == nil { - var ret int64 - return ret, false - } - return *o.UsedValue, true -} - -// HasUsedValue returns a boolean if a field has been set. -func (o *Quota) HasUsedValue() bool { - if o != nil && o.UsedValue != nil { - return true - } - - return false -} - -// SetUsedValue gets a reference to the given int64 and assigns it to the UsedValue field. -func (o *Quota) SetUsedValue(v int64) { - o.UsedValue = &v -} - -type NullableQuota struct { - Value Quota - ExplicitNull bool -} - -func (v NullableQuota) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableQuota) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_quota_types.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_quota_types.go deleted file mode 100644 index 59ebd9cbf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_quota_types.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// QuotaTypes One or more quotas. -type QuotaTypes struct { - // The resource ID if it is a resource-specific quota, `global` if it is not. - QuotaType *string `json:"QuotaType,omitempty"` - // One or more quotas associated with the user. - Quotas *[]Quota `json:"Quotas,omitempty"` -} - -// GetQuotaType returns the QuotaType field value if set, zero value otherwise. -func (o *QuotaTypes) GetQuotaType() string { - if o == nil || o.QuotaType == nil { - var ret string - return ret - } - return *o.QuotaType -} - -// GetQuotaTypeOk returns a tuple with the QuotaType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *QuotaTypes) GetQuotaTypeOk() (string, bool) { - if o == nil || o.QuotaType == nil { - var ret string - return ret, false - } - return *o.QuotaType, true -} - -// HasQuotaType returns a boolean if a field has been set. -func (o *QuotaTypes) HasQuotaType() bool { - if o != nil && o.QuotaType != nil { - return true - } - - return false -} - -// SetQuotaType gets a reference to the given string and assigns it to the QuotaType field. -func (o *QuotaTypes) SetQuotaType(v string) { - o.QuotaType = &v -} - -// GetQuotas returns the Quotas field value if set, zero value otherwise. -func (o *QuotaTypes) GetQuotas() []Quota { - if o == nil || o.Quotas == nil { - var ret []Quota - return ret - } - return *o.Quotas -} - -// GetQuotasOk returns a tuple with the Quotas field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *QuotaTypes) GetQuotasOk() ([]Quota, bool) { - if o == nil || o.Quotas == nil { - var ret []Quota - return ret, false - } - return *o.Quotas, true -} - -// HasQuotas returns a boolean if a field has been set. -func (o *QuotaTypes) HasQuotas() bool { - if o != nil && o.Quotas != nil { - return true - } - - return false -} - -// SetQuotas gets a reference to the given []Quota and assigns it to the Quotas field. -func (o *QuotaTypes) SetQuotas(v []Quota) { - o.Quotas = &v -} - -type NullableQuotaTypes struct { - Value QuotaTypes - ExplicitNull bool -} - -func (v NullableQuotaTypes) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableQuotaTypes) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_request.go deleted file mode 100644 index aefcea0dc..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_request.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAccessKeysRequest struct for ReadAccessKeysRequest -type ReadAccessKeysRequest struct { - Filters *FiltersAccessKeys `json:"Filters,omitempty"` -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadAccessKeysRequest) GetFilters() FiltersAccessKeys { - if o == nil || o.Filters == nil { - var ret FiltersAccessKeys - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccessKeysRequest) GetFiltersOk() (FiltersAccessKeys, bool) { - if o == nil || o.Filters == nil { - var ret FiltersAccessKeys - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadAccessKeysRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersAccessKeys and assigns it to the Filters field. -func (o *ReadAccessKeysRequest) SetFilters(v FiltersAccessKeys) { - o.Filters = &v -} - -type NullableReadAccessKeysRequest struct { - Value ReadAccessKeysRequest - ExplicitNull bool -} - -func (v NullableReadAccessKeysRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAccessKeysRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_response.go deleted file mode 100644 index d6fd06605..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_access_keys_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAccessKeysResponse struct for ReadAccessKeysResponse -type ReadAccessKeysResponse struct { - // A list of access keys. - AccessKeys *[]AccessKey `json:"AccessKeys,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccessKeys returns the AccessKeys field value if set, zero value otherwise. -func (o *ReadAccessKeysResponse) GetAccessKeys() []AccessKey { - if o == nil || o.AccessKeys == nil { - var ret []AccessKey - return ret - } - return *o.AccessKeys -} - -// GetAccessKeysOk returns a tuple with the AccessKeys field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccessKeysResponse) GetAccessKeysOk() ([]AccessKey, bool) { - if o == nil || o.AccessKeys == nil { - var ret []AccessKey - return ret, false - } - return *o.AccessKeys, true -} - -// HasAccessKeys returns a boolean if a field has been set. -func (o *ReadAccessKeysResponse) HasAccessKeys() bool { - if o != nil && o.AccessKeys != nil { - return true - } - - return false -} - -// SetAccessKeys gets a reference to the given []AccessKey and assigns it to the AccessKeys field. -func (o *ReadAccessKeysResponse) SetAccessKeys(v []AccessKey) { - o.AccessKeys = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadAccessKeysResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccessKeysResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadAccessKeysResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadAccessKeysResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadAccessKeysResponse struct { - Value ReadAccessKeysResponse - ExplicitNull bool -} - -func (v NullableReadAccessKeysResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAccessKeysResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_request.go deleted file mode 100644 index b67a533ab..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAccountsRequest struct for ReadAccountsRequest -type ReadAccountsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadAccountsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccountsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadAccountsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadAccountsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableReadAccountsRequest struct { - Value ReadAccountsRequest - ExplicitNull bool -} - -func (v NullableReadAccountsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAccountsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_response.go deleted file mode 100644 index e672a137e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_accounts_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAccountsResponse struct for ReadAccountsResponse -type ReadAccountsResponse struct { - // The list of the accounts. - Accounts *[]Account `json:"Accounts,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccounts returns the Accounts field value if set, zero value otherwise. -func (o *ReadAccountsResponse) GetAccounts() []Account { - if o == nil || o.Accounts == nil { - var ret []Account - return ret - } - return *o.Accounts -} - -// GetAccountsOk returns a tuple with the Accounts field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccountsResponse) GetAccountsOk() ([]Account, bool) { - if o == nil || o.Accounts == nil { - var ret []Account - return ret, false - } - return *o.Accounts, true -} - -// HasAccounts returns a boolean if a field has been set. -func (o *ReadAccountsResponse) HasAccounts() bool { - if o != nil && o.Accounts != nil { - return true - } - - return false -} - -// SetAccounts gets a reference to the given []Account and assigns it to the Accounts field. -func (o *ReadAccountsResponse) SetAccounts(v []Account) { - o.Accounts = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadAccountsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAccountsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadAccountsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadAccountsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadAccountsResponse struct { - Value ReadAccountsResponse - ExplicitNull bool -} - -func (v NullableReadAccountsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAccountsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_request.go deleted file mode 100644 index c09cced0b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAdminPasswordRequest struct for ReadAdminPasswordRequest -type ReadAdminPasswordRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the VM. - VmId string `json:"VmId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadAdminPasswordRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAdminPasswordRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadAdminPasswordRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadAdminPasswordRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmId returns the VmId field value -func (o *ReadAdminPasswordRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *ReadAdminPasswordRequest) SetVmId(v string) { - o.VmId = v -} - -type NullableReadAdminPasswordRequest struct { - Value ReadAdminPasswordRequest - ExplicitNull bool -} - -func (v NullableReadAdminPasswordRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAdminPasswordRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_response.go deleted file mode 100644 index 58bf121f0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_admin_password_response.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadAdminPasswordResponse struct for ReadAdminPasswordResponse -type ReadAdminPasswordResponse struct { - // The password of the VM. After the first boot, returns an empty string. - AdminPassword *string `json:"AdminPassword,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` -} - -// GetAdminPassword returns the AdminPassword field value if set, zero value otherwise. -func (o *ReadAdminPasswordResponse) GetAdminPassword() string { - if o == nil || o.AdminPassword == nil { - var ret string - return ret - } - return *o.AdminPassword -} - -// GetAdminPasswordOk returns a tuple with the AdminPassword field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAdminPasswordResponse) GetAdminPasswordOk() (string, bool) { - if o == nil || o.AdminPassword == nil { - var ret string - return ret, false - } - return *o.AdminPassword, true -} - -// HasAdminPassword returns a boolean if a field has been set. -func (o *ReadAdminPasswordResponse) HasAdminPassword() bool { - if o != nil && o.AdminPassword != nil { - return true - } - - return false -} - -// SetAdminPassword gets a reference to the given string and assigns it to the AdminPassword field. -func (o *ReadAdminPasswordResponse) SetAdminPassword(v string) { - o.AdminPassword = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadAdminPasswordResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAdminPasswordResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadAdminPasswordResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadAdminPasswordResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *ReadAdminPasswordResponse) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadAdminPasswordResponse) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *ReadAdminPasswordResponse) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *ReadAdminPasswordResponse) SetVmId(v string) { - o.VmId = &v -} - -type NullableReadAdminPasswordResponse struct { - Value ReadAdminPasswordResponse - ExplicitNull bool -} - -func (v NullableReadAdminPasswordResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadAdminPasswordResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_request.go deleted file mode 100644 index f45a12903..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_request.go +++ /dev/null @@ -1,216 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadApiLogsRequest struct for ReadApiLogsRequest -type ReadApiLogsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersApiLog `json:"Filters,omitempty"` - // The token to request the next page of results. - NextPageToken *string `json:"NextPageToken,omitempty"` - // The maximum number of items returned in a single page. By default, 100. - ResultsPerPage *int64 `json:"ResultsPerPage,omitempty"` - With *With `json:"With,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadApiLogsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadApiLogsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadApiLogsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadApiLogsRequest) GetFilters() FiltersApiLog { - if o == nil || o.Filters == nil { - var ret FiltersApiLog - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsRequest) GetFiltersOk() (FiltersApiLog, bool) { - if o == nil || o.Filters == nil { - var ret FiltersApiLog - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadApiLogsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersApiLog and assigns it to the Filters field. -func (o *ReadApiLogsRequest) SetFilters(v FiltersApiLog) { - o.Filters = &v -} - -// GetNextPageToken returns the NextPageToken field value if set, zero value otherwise. -func (o *ReadApiLogsRequest) GetNextPageToken() string { - if o == nil || o.NextPageToken == nil { - var ret string - return ret - } - return *o.NextPageToken -} - -// GetNextPageTokenOk returns a tuple with the NextPageToken field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsRequest) GetNextPageTokenOk() (string, bool) { - if o == nil || o.NextPageToken == nil { - var ret string - return ret, false - } - return *o.NextPageToken, true -} - -// HasNextPageToken returns a boolean if a field has been set. -func (o *ReadApiLogsRequest) HasNextPageToken() bool { - if o != nil && o.NextPageToken != nil { - return true - } - - return false -} - -// SetNextPageToken gets a reference to the given string and assigns it to the NextPageToken field. -func (o *ReadApiLogsRequest) SetNextPageToken(v string) { - o.NextPageToken = &v -} - -// GetResultsPerPage returns the ResultsPerPage field value if set, zero value otherwise. -func (o *ReadApiLogsRequest) GetResultsPerPage() int64 { - if o == nil || o.ResultsPerPage == nil { - var ret int64 - return ret - } - return *o.ResultsPerPage -} - -// GetResultsPerPageOk returns a tuple with the ResultsPerPage field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsRequest) GetResultsPerPageOk() (int64, bool) { - if o == nil || o.ResultsPerPage == nil { - var ret int64 - return ret, false - } - return *o.ResultsPerPage, true -} - -// HasResultsPerPage returns a boolean if a field has been set. -func (o *ReadApiLogsRequest) HasResultsPerPage() bool { - if o != nil && o.ResultsPerPage != nil { - return true - } - - return false -} - -// SetResultsPerPage gets a reference to the given int64 and assigns it to the ResultsPerPage field. -func (o *ReadApiLogsRequest) SetResultsPerPage(v int64) { - o.ResultsPerPage = &v -} - -// GetWith returns the With field value if set, zero value otherwise. -func (o *ReadApiLogsRequest) GetWith() With { - if o == nil || o.With == nil { - var ret With - return ret - } - return *o.With -} - -// GetWithOk returns a tuple with the With field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsRequest) GetWithOk() (With, bool) { - if o == nil || o.With == nil { - var ret With - return ret, false - } - return *o.With, true -} - -// HasWith returns a boolean if a field has been set. -func (o *ReadApiLogsRequest) HasWith() bool { - if o != nil && o.With != nil { - return true - } - - return false -} - -// SetWith gets a reference to the given With and assigns it to the With field. -func (o *ReadApiLogsRequest) SetWith(v With) { - o.With = &v -} - -type NullableReadApiLogsRequest struct { - Value ReadApiLogsRequest - ExplicitNull bool -} - -func (v NullableReadApiLogsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadApiLogsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_response.go deleted file mode 100644 index 9c8ce781f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_api_logs_response.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadApiLogsResponse struct for ReadApiLogsResponse -type ReadApiLogsResponse struct { - // Information displayed in one or more API logs. - Logs *[]Log `json:"Logs,omitempty"` - // The token to request the next page of results. - NextPageToken *string `json:"NextPageToken,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLogs returns the Logs field value if set, zero value otherwise. -func (o *ReadApiLogsResponse) GetLogs() []Log { - if o == nil || o.Logs == nil { - var ret []Log - return ret - } - return *o.Logs -} - -// GetLogsOk returns a tuple with the Logs field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsResponse) GetLogsOk() ([]Log, bool) { - if o == nil || o.Logs == nil { - var ret []Log - return ret, false - } - return *o.Logs, true -} - -// HasLogs returns a boolean if a field has been set. -func (o *ReadApiLogsResponse) HasLogs() bool { - if o != nil && o.Logs != nil { - return true - } - - return false -} - -// SetLogs gets a reference to the given []Log and assigns it to the Logs field. -func (o *ReadApiLogsResponse) SetLogs(v []Log) { - o.Logs = &v -} - -// GetNextPageToken returns the NextPageToken field value if set, zero value otherwise. -func (o *ReadApiLogsResponse) GetNextPageToken() string { - if o == nil || o.NextPageToken == nil { - var ret string - return ret - } - return *o.NextPageToken -} - -// GetNextPageTokenOk returns a tuple with the NextPageToken field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsResponse) GetNextPageTokenOk() (string, bool) { - if o == nil || o.NextPageToken == nil { - var ret string - return ret, false - } - return *o.NextPageToken, true -} - -// HasNextPageToken returns a boolean if a field has been set. -func (o *ReadApiLogsResponse) HasNextPageToken() bool { - if o != nil && o.NextPageToken != nil { - return true - } - - return false -} - -// SetNextPageToken gets a reference to the given string and assigns it to the NextPageToken field. -func (o *ReadApiLogsResponse) SetNextPageToken(v string) { - o.NextPageToken = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadApiLogsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadApiLogsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadApiLogsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadApiLogsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadApiLogsResponse struct { - Value ReadApiLogsResponse - ExplicitNull bool -} - -func (v NullableReadApiLogsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadApiLogsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_request.go deleted file mode 100644 index d720d1c1a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadClientGatewaysRequest struct for ReadClientGatewaysRequest -type ReadClientGatewaysRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersClientGateway `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadClientGatewaysRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadClientGatewaysRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadClientGatewaysRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadClientGatewaysRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadClientGatewaysRequest) GetFilters() FiltersClientGateway { - if o == nil || o.Filters == nil { - var ret FiltersClientGateway - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadClientGatewaysRequest) GetFiltersOk() (FiltersClientGateway, bool) { - if o == nil || o.Filters == nil { - var ret FiltersClientGateway - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadClientGatewaysRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersClientGateway and assigns it to the Filters field. -func (o *ReadClientGatewaysRequest) SetFilters(v FiltersClientGateway) { - o.Filters = &v -} - -type NullableReadClientGatewaysRequest struct { - Value ReadClientGatewaysRequest - ExplicitNull bool -} - -func (v NullableReadClientGatewaysRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadClientGatewaysRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_response.go deleted file mode 100644 index 19cd2a681..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_client_gateways_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadClientGatewaysResponse struct for ReadClientGatewaysResponse -type ReadClientGatewaysResponse struct { - // Information about one or more client gateways. - ClientGateways *[]ClientGateway `json:"ClientGateways,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetClientGateways returns the ClientGateways field value if set, zero value otherwise. -func (o *ReadClientGatewaysResponse) GetClientGateways() []ClientGateway { - if o == nil || o.ClientGateways == nil { - var ret []ClientGateway - return ret - } - return *o.ClientGateways -} - -// GetClientGatewaysOk returns a tuple with the ClientGateways field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadClientGatewaysResponse) GetClientGatewaysOk() ([]ClientGateway, bool) { - if o == nil || o.ClientGateways == nil { - var ret []ClientGateway - return ret, false - } - return *o.ClientGateways, true -} - -// HasClientGateways returns a boolean if a field has been set. -func (o *ReadClientGatewaysResponse) HasClientGateways() bool { - if o != nil && o.ClientGateways != nil { - return true - } - - return false -} - -// SetClientGateways gets a reference to the given []ClientGateway and assigns it to the ClientGateways field. -func (o *ReadClientGatewaysResponse) SetClientGateways(v []ClientGateway) { - o.ClientGateways = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadClientGatewaysResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadClientGatewaysResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadClientGatewaysResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadClientGatewaysResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadClientGatewaysResponse struct { - Value ReadClientGatewaysResponse - ExplicitNull bool -} - -func (v NullableReadClientGatewaysResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadClientGatewaysResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_request.go deleted file mode 100644 index ba913a097..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadConsoleOutputRequest struct for ReadConsoleOutputRequest -type ReadConsoleOutputRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the VM. - VmId string `json:"VmId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadConsoleOutputRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsoleOutputRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadConsoleOutputRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadConsoleOutputRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmId returns the VmId field value -func (o *ReadConsoleOutputRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *ReadConsoleOutputRequest) SetVmId(v string) { - o.VmId = v -} - -type NullableReadConsoleOutputRequest struct { - Value ReadConsoleOutputRequest - ExplicitNull bool -} - -func (v NullableReadConsoleOutputRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadConsoleOutputRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_response.go deleted file mode 100644 index 4480c3c09..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_console_output_response.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadConsoleOutputResponse struct for ReadConsoleOutputResponse -type ReadConsoleOutputResponse struct { - // The Base64-encoded output of the console. If a command line tool is used, the output is decoded by the tool. - ConsoleOutput *string `json:"ConsoleOutput,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` -} - -// GetConsoleOutput returns the ConsoleOutput field value if set, zero value otherwise. -func (o *ReadConsoleOutputResponse) GetConsoleOutput() string { - if o == nil || o.ConsoleOutput == nil { - var ret string - return ret - } - return *o.ConsoleOutput -} - -// GetConsoleOutputOk returns a tuple with the ConsoleOutput field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsoleOutputResponse) GetConsoleOutputOk() (string, bool) { - if o == nil || o.ConsoleOutput == nil { - var ret string - return ret, false - } - return *o.ConsoleOutput, true -} - -// HasConsoleOutput returns a boolean if a field has been set. -func (o *ReadConsoleOutputResponse) HasConsoleOutput() bool { - if o != nil && o.ConsoleOutput != nil { - return true - } - - return false -} - -// SetConsoleOutput gets a reference to the given string and assigns it to the ConsoleOutput field. -func (o *ReadConsoleOutputResponse) SetConsoleOutput(v string) { - o.ConsoleOutput = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadConsoleOutputResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsoleOutputResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadConsoleOutputResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadConsoleOutputResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *ReadConsoleOutputResponse) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsoleOutputResponse) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *ReadConsoleOutputResponse) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *ReadConsoleOutputResponse) SetVmId(v string) { - o.VmId = &v -} - -type NullableReadConsoleOutputResponse struct { - Value ReadConsoleOutputResponse - ExplicitNull bool -} - -func (v NullableReadConsoleOutputResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadConsoleOutputResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_request.go deleted file mode 100644 index 34ffecb3e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadConsumptionAccountRequest struct for ReadConsumptionAccountRequest -type ReadConsumptionAccountRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The beginning of the time period, in ISO-8601 format with the date only (for example, `2017-06-14` or `2017-06-14T00:00:00Z`). - FromDate string `json:"FromDate"` - // The end of the time period, in ISO-8601 format with the date only (for example, `2017-06-30` or `2017-06-30T00:00:00Z`). - ToDate string `json:"ToDate"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadConsumptionAccountRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsumptionAccountRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadConsumptionAccountRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadConsumptionAccountRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFromDate returns the FromDate field value -func (o *ReadConsumptionAccountRequest) GetFromDate() string { - if o == nil { - var ret string - return ret - } - - return o.FromDate -} - -// SetFromDate sets field value -func (o *ReadConsumptionAccountRequest) SetFromDate(v string) { - o.FromDate = v -} - -// GetToDate returns the ToDate field value -func (o *ReadConsumptionAccountRequest) GetToDate() string { - if o == nil { - var ret string - return ret - } - - return o.ToDate -} - -// SetToDate sets field value -func (o *ReadConsumptionAccountRequest) SetToDate(v string) { - o.ToDate = v -} - -type NullableReadConsumptionAccountRequest struct { - Value ReadConsumptionAccountRequest - ExplicitNull bool -} - -func (v NullableReadConsumptionAccountRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadConsumptionAccountRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_response.go deleted file mode 100644 index b99e8efc0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_consumption_account_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadConsumptionAccountResponse struct for ReadConsumptionAccountResponse -type ReadConsumptionAccountResponse struct { - // Information about the resources consumed during the specified time period. - ConsumptionEntries *[]ConsumptionEntry `json:"ConsumptionEntries,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetConsumptionEntries returns the ConsumptionEntries field value if set, zero value otherwise. -func (o *ReadConsumptionAccountResponse) GetConsumptionEntries() []ConsumptionEntry { - if o == nil || o.ConsumptionEntries == nil { - var ret []ConsumptionEntry - return ret - } - return *o.ConsumptionEntries -} - -// GetConsumptionEntriesOk returns a tuple with the ConsumptionEntries field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsumptionAccountResponse) GetConsumptionEntriesOk() ([]ConsumptionEntry, bool) { - if o == nil || o.ConsumptionEntries == nil { - var ret []ConsumptionEntry - return ret, false - } - return *o.ConsumptionEntries, true -} - -// HasConsumptionEntries returns a boolean if a field has been set. -func (o *ReadConsumptionAccountResponse) HasConsumptionEntries() bool { - if o != nil && o.ConsumptionEntries != nil { - return true - } - - return false -} - -// SetConsumptionEntries gets a reference to the given []ConsumptionEntry and assigns it to the ConsumptionEntries field. -func (o *ReadConsumptionAccountResponse) SetConsumptionEntries(v []ConsumptionEntry) { - o.ConsumptionEntries = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadConsumptionAccountResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadConsumptionAccountResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadConsumptionAccountResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadConsumptionAccountResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadConsumptionAccountResponse struct { - Value ReadConsumptionAccountResponse - ExplicitNull bool -} - -func (v NullableReadConsumptionAccountResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadConsumptionAccountResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_request.go deleted file mode 100644 index 6fd2696d2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDhcpOptionsRequest struct for ReadDhcpOptionsRequest -type ReadDhcpOptionsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersDhcpOptions `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadDhcpOptionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDhcpOptionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadDhcpOptionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadDhcpOptionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadDhcpOptionsRequest) GetFilters() FiltersDhcpOptions { - if o == nil || o.Filters == nil { - var ret FiltersDhcpOptions - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDhcpOptionsRequest) GetFiltersOk() (FiltersDhcpOptions, bool) { - if o == nil || o.Filters == nil { - var ret FiltersDhcpOptions - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadDhcpOptionsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersDhcpOptions and assigns it to the Filters field. -func (o *ReadDhcpOptionsRequest) SetFilters(v FiltersDhcpOptions) { - o.Filters = &v -} - -type NullableReadDhcpOptionsRequest struct { - Value ReadDhcpOptionsRequest - ExplicitNull bool -} - -func (v NullableReadDhcpOptionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDhcpOptionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_response.go deleted file mode 100644 index e983350d1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_dhcp_options_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDhcpOptionsResponse struct for ReadDhcpOptionsResponse -type ReadDhcpOptionsResponse struct { - // Information about one or more DHCP options sets. - DhcpOptionsSets *[]DhcpOptionsSet `json:"DhcpOptionsSets,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDhcpOptionsSets returns the DhcpOptionsSets field value if set, zero value otherwise. -func (o *ReadDhcpOptionsResponse) GetDhcpOptionsSets() []DhcpOptionsSet { - if o == nil || o.DhcpOptionsSets == nil { - var ret []DhcpOptionsSet - return ret - } - return *o.DhcpOptionsSets -} - -// GetDhcpOptionsSetsOk returns a tuple with the DhcpOptionsSets field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDhcpOptionsResponse) GetDhcpOptionsSetsOk() ([]DhcpOptionsSet, bool) { - if o == nil || o.DhcpOptionsSets == nil { - var ret []DhcpOptionsSet - return ret, false - } - return *o.DhcpOptionsSets, true -} - -// HasDhcpOptionsSets returns a boolean if a field has been set. -func (o *ReadDhcpOptionsResponse) HasDhcpOptionsSets() bool { - if o != nil && o.DhcpOptionsSets != nil { - return true - } - - return false -} - -// SetDhcpOptionsSets gets a reference to the given []DhcpOptionsSet and assigns it to the DhcpOptionsSets field. -func (o *ReadDhcpOptionsResponse) SetDhcpOptionsSets(v []DhcpOptionsSet) { - o.DhcpOptionsSets = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadDhcpOptionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDhcpOptionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadDhcpOptionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadDhcpOptionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadDhcpOptionsResponse struct { - Value ReadDhcpOptionsResponse - ExplicitNull bool -} - -func (v NullableReadDhcpOptionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDhcpOptionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_request.go deleted file mode 100644 index 87f06df9a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDirectLinkInterfacesRequest struct for ReadDirectLinkInterfacesRequest -type ReadDirectLinkInterfacesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersDirectLinkInterface `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadDirectLinkInterfacesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinkInterfacesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadDirectLinkInterfacesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadDirectLinkInterfacesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadDirectLinkInterfacesRequest) GetFilters() FiltersDirectLinkInterface { - if o == nil || o.Filters == nil { - var ret FiltersDirectLinkInterface - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinkInterfacesRequest) GetFiltersOk() (FiltersDirectLinkInterface, bool) { - if o == nil || o.Filters == nil { - var ret FiltersDirectLinkInterface - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadDirectLinkInterfacesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersDirectLinkInterface and assigns it to the Filters field. -func (o *ReadDirectLinkInterfacesRequest) SetFilters(v FiltersDirectLinkInterface) { - o.Filters = &v -} - -type NullableReadDirectLinkInterfacesRequest struct { - Value ReadDirectLinkInterfacesRequest - ExplicitNull bool -} - -func (v NullableReadDirectLinkInterfacesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDirectLinkInterfacesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_response.go deleted file mode 100644 index 55dc14bdb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_link_interfaces_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDirectLinkInterfacesResponse struct for ReadDirectLinkInterfacesResponse -type ReadDirectLinkInterfacesResponse struct { - // Information about one or more DirectLink interfaces. - DirectLinkInterfaces *[]DirectLinkInterfaces `json:"DirectLinkInterfaces,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDirectLinkInterfaces returns the DirectLinkInterfaces field value if set, zero value otherwise. -func (o *ReadDirectLinkInterfacesResponse) GetDirectLinkInterfaces() []DirectLinkInterfaces { - if o == nil || o.DirectLinkInterfaces == nil { - var ret []DirectLinkInterfaces - return ret - } - return *o.DirectLinkInterfaces -} - -// GetDirectLinkInterfacesOk returns a tuple with the DirectLinkInterfaces field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinkInterfacesResponse) GetDirectLinkInterfacesOk() ([]DirectLinkInterfaces, bool) { - if o == nil || o.DirectLinkInterfaces == nil { - var ret []DirectLinkInterfaces - return ret, false - } - return *o.DirectLinkInterfaces, true -} - -// HasDirectLinkInterfaces returns a boolean if a field has been set. -func (o *ReadDirectLinkInterfacesResponse) HasDirectLinkInterfaces() bool { - if o != nil && o.DirectLinkInterfaces != nil { - return true - } - - return false -} - -// SetDirectLinkInterfaces gets a reference to the given []DirectLinkInterfaces and assigns it to the DirectLinkInterfaces field. -func (o *ReadDirectLinkInterfacesResponse) SetDirectLinkInterfaces(v []DirectLinkInterfaces) { - o.DirectLinkInterfaces = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadDirectLinkInterfacesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinkInterfacesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadDirectLinkInterfacesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadDirectLinkInterfacesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadDirectLinkInterfacesResponse struct { - Value ReadDirectLinkInterfacesResponse - ExplicitNull bool -} - -func (v NullableReadDirectLinkInterfacesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDirectLinkInterfacesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_request.go deleted file mode 100644 index faf0a2832..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDirectLinksRequest struct for ReadDirectLinksRequest -type ReadDirectLinksRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersDirectLink `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadDirectLinksRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinksRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadDirectLinksRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadDirectLinksRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadDirectLinksRequest) GetFilters() FiltersDirectLink { - if o == nil || o.Filters == nil { - var ret FiltersDirectLink - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinksRequest) GetFiltersOk() (FiltersDirectLink, bool) { - if o == nil || o.Filters == nil { - var ret FiltersDirectLink - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadDirectLinksRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersDirectLink and assigns it to the Filters field. -func (o *ReadDirectLinksRequest) SetFilters(v FiltersDirectLink) { - o.Filters = &v -} - -type NullableReadDirectLinksRequest struct { - Value ReadDirectLinksRequest - ExplicitNull bool -} - -func (v NullableReadDirectLinksRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDirectLinksRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_response.go deleted file mode 100644 index 4fb6fb9f3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_direct_links_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadDirectLinksResponse struct for ReadDirectLinksResponse -type ReadDirectLinksResponse struct { - // Information about one or more DirectLinks. - DirectLinks *[]DirectLink `json:"DirectLinks,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetDirectLinks returns the DirectLinks field value if set, zero value otherwise. -func (o *ReadDirectLinksResponse) GetDirectLinks() []DirectLink { - if o == nil || o.DirectLinks == nil { - var ret []DirectLink - return ret - } - return *o.DirectLinks -} - -// GetDirectLinksOk returns a tuple with the DirectLinks field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinksResponse) GetDirectLinksOk() ([]DirectLink, bool) { - if o == nil || o.DirectLinks == nil { - var ret []DirectLink - return ret, false - } - return *o.DirectLinks, true -} - -// HasDirectLinks returns a boolean if a field has been set. -func (o *ReadDirectLinksResponse) HasDirectLinks() bool { - if o != nil && o.DirectLinks != nil { - return true - } - - return false -} - -// SetDirectLinks gets a reference to the given []DirectLink and assigns it to the DirectLinks field. -func (o *ReadDirectLinksResponse) SetDirectLinks(v []DirectLink) { - o.DirectLinks = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadDirectLinksResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadDirectLinksResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadDirectLinksResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadDirectLinksResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadDirectLinksResponse struct { - Value ReadDirectLinksResponse - ExplicitNull bool -} - -func (v NullableReadDirectLinksResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadDirectLinksResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_request.go deleted file mode 100644 index 007b7caef..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadFlexibleGpuCatalogRequest struct for ReadFlexibleGpuCatalogRequest -type ReadFlexibleGpuCatalogRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadFlexibleGpuCatalogRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpuCatalogRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadFlexibleGpuCatalogRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadFlexibleGpuCatalogRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableReadFlexibleGpuCatalogRequest struct { - Value ReadFlexibleGpuCatalogRequest - ExplicitNull bool -} - -func (v NullableReadFlexibleGpuCatalogRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadFlexibleGpuCatalogRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_response.go deleted file mode 100644 index e24149a6a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpu_catalog_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadFlexibleGpuCatalogResponse struct for ReadFlexibleGpuCatalogResponse -type ReadFlexibleGpuCatalogResponse struct { - // Information about one or more fGPUs available in the public catalog. - FlexibleGpuCatalog *[]FlexibleGpuCatalog `json:"FlexibleGpuCatalog,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetFlexibleGpuCatalog returns the FlexibleGpuCatalog field value if set, zero value otherwise. -func (o *ReadFlexibleGpuCatalogResponse) GetFlexibleGpuCatalog() []FlexibleGpuCatalog { - if o == nil || o.FlexibleGpuCatalog == nil { - var ret []FlexibleGpuCatalog - return ret - } - return *o.FlexibleGpuCatalog -} - -// GetFlexibleGpuCatalogOk returns a tuple with the FlexibleGpuCatalog field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpuCatalogResponse) GetFlexibleGpuCatalogOk() ([]FlexibleGpuCatalog, bool) { - if o == nil || o.FlexibleGpuCatalog == nil { - var ret []FlexibleGpuCatalog - return ret, false - } - return *o.FlexibleGpuCatalog, true -} - -// HasFlexibleGpuCatalog returns a boolean if a field has been set. -func (o *ReadFlexibleGpuCatalogResponse) HasFlexibleGpuCatalog() bool { - if o != nil && o.FlexibleGpuCatalog != nil { - return true - } - - return false -} - -// SetFlexibleGpuCatalog gets a reference to the given []FlexibleGpuCatalog and assigns it to the FlexibleGpuCatalog field. -func (o *ReadFlexibleGpuCatalogResponse) SetFlexibleGpuCatalog(v []FlexibleGpuCatalog) { - o.FlexibleGpuCatalog = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadFlexibleGpuCatalogResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpuCatalogResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadFlexibleGpuCatalogResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadFlexibleGpuCatalogResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadFlexibleGpuCatalogResponse struct { - Value ReadFlexibleGpuCatalogResponse - ExplicitNull bool -} - -func (v NullableReadFlexibleGpuCatalogResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadFlexibleGpuCatalogResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_request.go deleted file mode 100644 index 582032d6f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadFlexibleGpusRequest struct for ReadFlexibleGpusRequest -type ReadFlexibleGpusRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersFlexibleGpu `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadFlexibleGpusRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpusRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadFlexibleGpusRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadFlexibleGpusRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadFlexibleGpusRequest) GetFilters() FiltersFlexibleGpu { - if o == nil || o.Filters == nil { - var ret FiltersFlexibleGpu - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpusRequest) GetFiltersOk() (FiltersFlexibleGpu, bool) { - if o == nil || o.Filters == nil { - var ret FiltersFlexibleGpu - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadFlexibleGpusRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersFlexibleGpu and assigns it to the Filters field. -func (o *ReadFlexibleGpusRequest) SetFilters(v FiltersFlexibleGpu) { - o.Filters = &v -} - -type NullableReadFlexibleGpusRequest struct { - Value ReadFlexibleGpusRequest - ExplicitNull bool -} - -func (v NullableReadFlexibleGpusRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadFlexibleGpusRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_response.go deleted file mode 100644 index 3f7936bc4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_flexible_gpus_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadFlexibleGpusResponse struct for ReadFlexibleGpusResponse -type ReadFlexibleGpusResponse struct { - // Information about one or more fGPUs. - FlexibleGpus *[]FlexibleGpu `json:"FlexibleGpus,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetFlexibleGpus returns the FlexibleGpus field value if set, zero value otherwise. -func (o *ReadFlexibleGpusResponse) GetFlexibleGpus() []FlexibleGpu { - if o == nil || o.FlexibleGpus == nil { - var ret []FlexibleGpu - return ret - } - return *o.FlexibleGpus -} - -// GetFlexibleGpusOk returns a tuple with the FlexibleGpus field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpusResponse) GetFlexibleGpusOk() ([]FlexibleGpu, bool) { - if o == nil || o.FlexibleGpus == nil { - var ret []FlexibleGpu - return ret, false - } - return *o.FlexibleGpus, true -} - -// HasFlexibleGpus returns a boolean if a field has been set. -func (o *ReadFlexibleGpusResponse) HasFlexibleGpus() bool { - if o != nil && o.FlexibleGpus != nil { - return true - } - - return false -} - -// SetFlexibleGpus gets a reference to the given []FlexibleGpu and assigns it to the FlexibleGpus field. -func (o *ReadFlexibleGpusResponse) SetFlexibleGpus(v []FlexibleGpu) { - o.FlexibleGpus = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadFlexibleGpusResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadFlexibleGpusResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadFlexibleGpusResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadFlexibleGpusResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadFlexibleGpusResponse struct { - Value ReadFlexibleGpusResponse - ExplicitNull bool -} - -func (v NullableReadFlexibleGpusResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadFlexibleGpusResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_request.go deleted file mode 100644 index 1079c1bc7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadImageExportTasksRequest struct for ReadImageExportTasksRequest -type ReadImageExportTasksRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersExportTask `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadImageExportTasksRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImageExportTasksRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadImageExportTasksRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadImageExportTasksRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadImageExportTasksRequest) GetFilters() FiltersExportTask { - if o == nil || o.Filters == nil { - var ret FiltersExportTask - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImageExportTasksRequest) GetFiltersOk() (FiltersExportTask, bool) { - if o == nil || o.Filters == nil { - var ret FiltersExportTask - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadImageExportTasksRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersExportTask and assigns it to the Filters field. -func (o *ReadImageExportTasksRequest) SetFilters(v FiltersExportTask) { - o.Filters = &v -} - -type NullableReadImageExportTasksRequest struct { - Value ReadImageExportTasksRequest - ExplicitNull bool -} - -func (v NullableReadImageExportTasksRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadImageExportTasksRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_response.go deleted file mode 100644 index fa61c4c46..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_image_export_tasks_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadImageExportTasksResponse struct for ReadImageExportTasksResponse -type ReadImageExportTasksResponse struct { - // Information about one or more image export tasks. - ImageExportTasks *[]ImageExportTask `json:"ImageExportTasks,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetImageExportTasks returns the ImageExportTasks field value if set, zero value otherwise. -func (o *ReadImageExportTasksResponse) GetImageExportTasks() []ImageExportTask { - if o == nil || o.ImageExportTasks == nil { - var ret []ImageExportTask - return ret - } - return *o.ImageExportTasks -} - -// GetImageExportTasksOk returns a tuple with the ImageExportTasks field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImageExportTasksResponse) GetImageExportTasksOk() ([]ImageExportTask, bool) { - if o == nil || o.ImageExportTasks == nil { - var ret []ImageExportTask - return ret, false - } - return *o.ImageExportTasks, true -} - -// HasImageExportTasks returns a boolean if a field has been set. -func (o *ReadImageExportTasksResponse) HasImageExportTasks() bool { - if o != nil && o.ImageExportTasks != nil { - return true - } - - return false -} - -// SetImageExportTasks gets a reference to the given []ImageExportTask and assigns it to the ImageExportTasks field. -func (o *ReadImageExportTasksResponse) SetImageExportTasks(v []ImageExportTask) { - o.ImageExportTasks = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadImageExportTasksResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImageExportTasksResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadImageExportTasksResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadImageExportTasksResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadImageExportTasksResponse struct { - Value ReadImageExportTasksResponse - ExplicitNull bool -} - -func (v NullableReadImageExportTasksResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadImageExportTasksResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_request.go deleted file mode 100644 index 264f337b1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadImagesRequest struct for ReadImagesRequest -type ReadImagesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersImage `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadImagesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImagesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadImagesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadImagesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadImagesRequest) GetFilters() FiltersImage { - if o == nil || o.Filters == nil { - var ret FiltersImage - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImagesRequest) GetFiltersOk() (FiltersImage, bool) { - if o == nil || o.Filters == nil { - var ret FiltersImage - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadImagesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersImage and assigns it to the Filters field. -func (o *ReadImagesRequest) SetFilters(v FiltersImage) { - o.Filters = &v -} - -type NullableReadImagesRequest struct { - Value ReadImagesRequest - ExplicitNull bool -} - -func (v NullableReadImagesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadImagesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_response.go deleted file mode 100644 index a569486c6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_images_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadImagesResponse struct for ReadImagesResponse -type ReadImagesResponse struct { - // Information about one or more OMIs. - Images *[]Image `json:"Images,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetImages returns the Images field value if set, zero value otherwise. -func (o *ReadImagesResponse) GetImages() []Image { - if o == nil || o.Images == nil { - var ret []Image - return ret - } - return *o.Images -} - -// GetImagesOk returns a tuple with the Images field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImagesResponse) GetImagesOk() ([]Image, bool) { - if o == nil || o.Images == nil { - var ret []Image - return ret, false - } - return *o.Images, true -} - -// HasImages returns a boolean if a field has been set. -func (o *ReadImagesResponse) HasImages() bool { - if o != nil && o.Images != nil { - return true - } - - return false -} - -// SetImages gets a reference to the given []Image and assigns it to the Images field. -func (o *ReadImagesResponse) SetImages(v []Image) { - o.Images = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadImagesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadImagesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadImagesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadImagesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadImagesResponse struct { - Value ReadImagesResponse - ExplicitNull bool -} - -func (v NullableReadImagesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadImagesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_request.go deleted file mode 100644 index 641085ece..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadInternetServicesRequest struct for ReadInternetServicesRequest -type ReadInternetServicesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersInternetService `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadInternetServicesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadInternetServicesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadInternetServicesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadInternetServicesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadInternetServicesRequest) GetFilters() FiltersInternetService { - if o == nil || o.Filters == nil { - var ret FiltersInternetService - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadInternetServicesRequest) GetFiltersOk() (FiltersInternetService, bool) { - if o == nil || o.Filters == nil { - var ret FiltersInternetService - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadInternetServicesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersInternetService and assigns it to the Filters field. -func (o *ReadInternetServicesRequest) SetFilters(v FiltersInternetService) { - o.Filters = &v -} - -type NullableReadInternetServicesRequest struct { - Value ReadInternetServicesRequest - ExplicitNull bool -} - -func (v NullableReadInternetServicesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadInternetServicesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_response.go deleted file mode 100644 index 2db22a439..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_internet_services_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadInternetServicesResponse struct for ReadInternetServicesResponse -type ReadInternetServicesResponse struct { - // Information about one or more Internet services. - InternetServices *[]InternetService `json:"InternetServices,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetInternetServices returns the InternetServices field value if set, zero value otherwise. -func (o *ReadInternetServicesResponse) GetInternetServices() []InternetService { - if o == nil || o.InternetServices == nil { - var ret []InternetService - return ret - } - return *o.InternetServices -} - -// GetInternetServicesOk returns a tuple with the InternetServices field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadInternetServicesResponse) GetInternetServicesOk() ([]InternetService, bool) { - if o == nil || o.InternetServices == nil { - var ret []InternetService - return ret, false - } - return *o.InternetServices, true -} - -// HasInternetServices returns a boolean if a field has been set. -func (o *ReadInternetServicesResponse) HasInternetServices() bool { - if o != nil && o.InternetServices != nil { - return true - } - - return false -} - -// SetInternetServices gets a reference to the given []InternetService and assigns it to the InternetServices field. -func (o *ReadInternetServicesResponse) SetInternetServices(v []InternetService) { - o.InternetServices = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadInternetServicesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadInternetServicesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadInternetServicesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadInternetServicesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadInternetServicesResponse struct { - Value ReadInternetServicesResponse - ExplicitNull bool -} - -func (v NullableReadInternetServicesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadInternetServicesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_request.go deleted file mode 100644 index 24c69cb64..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadKeypairsRequest struct for ReadKeypairsRequest -type ReadKeypairsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersKeypair `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadKeypairsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadKeypairsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadKeypairsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadKeypairsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadKeypairsRequest) GetFilters() FiltersKeypair { - if o == nil || o.Filters == nil { - var ret FiltersKeypair - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadKeypairsRequest) GetFiltersOk() (FiltersKeypair, bool) { - if o == nil || o.Filters == nil { - var ret FiltersKeypair - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadKeypairsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersKeypair and assigns it to the Filters field. -func (o *ReadKeypairsRequest) SetFilters(v FiltersKeypair) { - o.Filters = &v -} - -type NullableReadKeypairsRequest struct { - Value ReadKeypairsRequest - ExplicitNull bool -} - -func (v NullableReadKeypairsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadKeypairsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_response.go deleted file mode 100644 index d518784c2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_keypairs_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadKeypairsResponse struct for ReadKeypairsResponse -type ReadKeypairsResponse struct { - // Information about one or more keypairs. - Keypairs *[]Keypair `json:"Keypairs,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetKeypairs returns the Keypairs field value if set, zero value otherwise. -func (o *ReadKeypairsResponse) GetKeypairs() []Keypair { - if o == nil || o.Keypairs == nil { - var ret []Keypair - return ret - } - return *o.Keypairs -} - -// GetKeypairsOk returns a tuple with the Keypairs field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadKeypairsResponse) GetKeypairsOk() ([]Keypair, bool) { - if o == nil || o.Keypairs == nil { - var ret []Keypair - return ret, false - } - return *o.Keypairs, true -} - -// HasKeypairs returns a boolean if a field has been set. -func (o *ReadKeypairsResponse) HasKeypairs() bool { - if o != nil && o.Keypairs != nil { - return true - } - - return false -} - -// SetKeypairs gets a reference to the given []Keypair and assigns it to the Keypairs field. -func (o *ReadKeypairsResponse) SetKeypairs(v []Keypair) { - o.Keypairs = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadKeypairsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadKeypairsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadKeypairsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadKeypairsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadKeypairsResponse struct { - Value ReadKeypairsResponse - ExplicitNull bool -} - -func (v NullableReadKeypairsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadKeypairsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_request.go deleted file mode 100644 index d06eb3075..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadListenerRulesRequest struct for ReadListenerRulesRequest -type ReadListenerRulesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersListenerRule `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadListenerRulesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadListenerRulesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadListenerRulesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadListenerRulesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadListenerRulesRequest) GetFilters() FiltersListenerRule { - if o == nil || o.Filters == nil { - var ret FiltersListenerRule - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadListenerRulesRequest) GetFiltersOk() (FiltersListenerRule, bool) { - if o == nil || o.Filters == nil { - var ret FiltersListenerRule - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadListenerRulesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersListenerRule and assigns it to the Filters field. -func (o *ReadListenerRulesRequest) SetFilters(v FiltersListenerRule) { - o.Filters = &v -} - -type NullableReadListenerRulesRequest struct { - Value ReadListenerRulesRequest - ExplicitNull bool -} - -func (v NullableReadListenerRulesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadListenerRulesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_response.go deleted file mode 100644 index f4370bbf5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_listener_rules_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadListenerRulesResponse struct for ReadListenerRulesResponse -type ReadListenerRulesResponse struct { - // The list of the rules to describe. - ListenerRules *[]ListenerRule `json:"ListenerRules,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetListenerRules returns the ListenerRules field value if set, zero value otherwise. -func (o *ReadListenerRulesResponse) GetListenerRules() []ListenerRule { - if o == nil || o.ListenerRules == nil { - var ret []ListenerRule - return ret - } - return *o.ListenerRules -} - -// GetListenerRulesOk returns a tuple with the ListenerRules field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadListenerRulesResponse) GetListenerRulesOk() ([]ListenerRule, bool) { - if o == nil || o.ListenerRules == nil { - var ret []ListenerRule - return ret, false - } - return *o.ListenerRules, true -} - -// HasListenerRules returns a boolean if a field has been set. -func (o *ReadListenerRulesResponse) HasListenerRules() bool { - if o != nil && o.ListenerRules != nil { - return true - } - - return false -} - -// SetListenerRules gets a reference to the given []ListenerRule and assigns it to the ListenerRules field. -func (o *ReadListenerRulesResponse) SetListenerRules(v []ListenerRule) { - o.ListenerRules = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadListenerRulesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadListenerRulesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadListenerRulesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadListenerRulesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadListenerRulesResponse struct { - Value ReadListenerRulesResponse - ExplicitNull bool -} - -func (v NullableReadListenerRulesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadListenerRulesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_request.go deleted file mode 100644 index 9690f5070..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLoadBalancerTagsRequest struct for ReadLoadBalancerTagsRequest -type ReadLoadBalancerTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more load balancer names. - LoadBalancerNames []string `json:"LoadBalancerNames"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadLoadBalancerTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancerTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadLoadBalancerTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadLoadBalancerTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerNames returns the LoadBalancerNames field value -func (o *ReadLoadBalancerTagsRequest) GetLoadBalancerNames() []string { - if o == nil { - var ret []string - return ret - } - - return o.LoadBalancerNames -} - -// SetLoadBalancerNames sets field value -func (o *ReadLoadBalancerTagsRequest) SetLoadBalancerNames(v []string) { - o.LoadBalancerNames = v -} - -type NullableReadLoadBalancerTagsRequest struct { - Value ReadLoadBalancerTagsRequest - ExplicitNull bool -} - -func (v NullableReadLoadBalancerTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLoadBalancerTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_response.go deleted file mode 100644 index 720ea4701..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancer_tags_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLoadBalancerTagsResponse struct for ReadLoadBalancerTagsResponse -type ReadLoadBalancerTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more load balancer tags. - Tags *[]LoadBalancerTag `json:"Tags,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadLoadBalancerTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancerTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadLoadBalancerTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadLoadBalancerTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *ReadLoadBalancerTagsResponse) GetTags() []LoadBalancerTag { - if o == nil || o.Tags == nil { - var ret []LoadBalancerTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancerTagsResponse) GetTagsOk() ([]LoadBalancerTag, bool) { - if o == nil || o.Tags == nil { - var ret []LoadBalancerTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *ReadLoadBalancerTagsResponse) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []LoadBalancerTag and assigns it to the Tags field. -func (o *ReadLoadBalancerTagsResponse) SetTags(v []LoadBalancerTag) { - o.Tags = &v -} - -type NullableReadLoadBalancerTagsResponse struct { - Value ReadLoadBalancerTagsResponse - ExplicitNull bool -} - -func (v NullableReadLoadBalancerTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLoadBalancerTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_request.go deleted file mode 100644 index 7960486de..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLoadBalancersRequest struct for ReadLoadBalancersRequest -type ReadLoadBalancersRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersLoadBalancer `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadLoadBalancersRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancersRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadLoadBalancersRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadLoadBalancersRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadLoadBalancersRequest) GetFilters() FiltersLoadBalancer { - if o == nil || o.Filters == nil { - var ret FiltersLoadBalancer - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancersRequest) GetFiltersOk() (FiltersLoadBalancer, bool) { - if o == nil || o.Filters == nil { - var ret FiltersLoadBalancer - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadLoadBalancersRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersLoadBalancer and assigns it to the Filters field. -func (o *ReadLoadBalancersRequest) SetFilters(v FiltersLoadBalancer) { - o.Filters = &v -} - -type NullableReadLoadBalancersRequest struct { - Value ReadLoadBalancersRequest - ExplicitNull bool -} - -func (v NullableReadLoadBalancersRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLoadBalancersRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_response.go deleted file mode 100644 index c0926f830..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_load_balancers_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLoadBalancersResponse struct for ReadLoadBalancersResponse -type ReadLoadBalancersResponse struct { - // Information about one or more load balancers. - LoadBalancers *[]LoadBalancer `json:"LoadBalancers,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancers returns the LoadBalancers field value if set, zero value otherwise. -func (o *ReadLoadBalancersResponse) GetLoadBalancers() []LoadBalancer { - if o == nil || o.LoadBalancers == nil { - var ret []LoadBalancer - return ret - } - return *o.LoadBalancers -} - -// GetLoadBalancersOk returns a tuple with the LoadBalancers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancersResponse) GetLoadBalancersOk() ([]LoadBalancer, bool) { - if o == nil || o.LoadBalancers == nil { - var ret []LoadBalancer - return ret, false - } - return *o.LoadBalancers, true -} - -// HasLoadBalancers returns a boolean if a field has been set. -func (o *ReadLoadBalancersResponse) HasLoadBalancers() bool { - if o != nil && o.LoadBalancers != nil { - return true - } - - return false -} - -// SetLoadBalancers gets a reference to the given []LoadBalancer and assigns it to the LoadBalancers field. -func (o *ReadLoadBalancersResponse) SetLoadBalancers(v []LoadBalancer) { - o.LoadBalancers = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadLoadBalancersResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLoadBalancersResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadLoadBalancersResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadLoadBalancersResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadLoadBalancersResponse struct { - Value ReadLoadBalancersResponse - ExplicitNull bool -} - -func (v NullableReadLoadBalancersResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLoadBalancersResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_request.go deleted file mode 100644 index b320669f4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLocationsRequest struct for ReadLocationsRequest -type ReadLocationsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadLocationsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLocationsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadLocationsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadLocationsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableReadLocationsRequest struct { - Value ReadLocationsRequest - ExplicitNull bool -} - -func (v NullableReadLocationsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLocationsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_response.go deleted file mode 100644 index 876c8d968..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_locations_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadLocationsResponse struct for ReadLocationsResponse -type ReadLocationsResponse struct { - // Information about one or more locations. - Locations *[]Location `json:"Locations,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLocations returns the Locations field value if set, zero value otherwise. -func (o *ReadLocationsResponse) GetLocations() []Location { - if o == nil || o.Locations == nil { - var ret []Location - return ret - } - return *o.Locations -} - -// GetLocationsOk returns a tuple with the Locations field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLocationsResponse) GetLocationsOk() ([]Location, bool) { - if o == nil || o.Locations == nil { - var ret []Location - return ret, false - } - return *o.Locations, true -} - -// HasLocations returns a boolean if a field has been set. -func (o *ReadLocationsResponse) HasLocations() bool { - if o != nil && o.Locations != nil { - return true - } - - return false -} - -// SetLocations gets a reference to the given []Location and assigns it to the Locations field. -func (o *ReadLocationsResponse) SetLocations(v []Location) { - o.Locations = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadLocationsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadLocationsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadLocationsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadLocationsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadLocationsResponse struct { - Value ReadLocationsResponse - ExplicitNull bool -} - -func (v NullableReadLocationsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadLocationsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_request.go deleted file mode 100644 index 04525bf15..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNatServicesRequest struct for ReadNatServicesRequest -type ReadNatServicesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersNatService `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNatServicesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNatServicesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNatServicesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNatServicesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNatServicesRequest) GetFilters() FiltersNatService { - if o == nil || o.Filters == nil { - var ret FiltersNatService - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNatServicesRequest) GetFiltersOk() (FiltersNatService, bool) { - if o == nil || o.Filters == nil { - var ret FiltersNatService - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNatServicesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersNatService and assigns it to the Filters field. -func (o *ReadNatServicesRequest) SetFilters(v FiltersNatService) { - o.Filters = &v -} - -type NullableReadNatServicesRequest struct { - Value ReadNatServicesRequest - ExplicitNull bool -} - -func (v NullableReadNatServicesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNatServicesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_response.go deleted file mode 100644 index 20eb7f92d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nat_services_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNatServicesResponse struct for ReadNatServicesResponse -type ReadNatServicesResponse struct { - // Information about one or more NAT services. - NatServices *[]NatService `json:"NatServices,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNatServices returns the NatServices field value if set, zero value otherwise. -func (o *ReadNatServicesResponse) GetNatServices() []NatService { - if o == nil || o.NatServices == nil { - var ret []NatService - return ret - } - return *o.NatServices -} - -// GetNatServicesOk returns a tuple with the NatServices field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNatServicesResponse) GetNatServicesOk() ([]NatService, bool) { - if o == nil || o.NatServices == nil { - var ret []NatService - return ret, false - } - return *o.NatServices, true -} - -// HasNatServices returns a boolean if a field has been set. -func (o *ReadNatServicesResponse) HasNatServices() bool { - if o != nil && o.NatServices != nil { - return true - } - - return false -} - -// SetNatServices gets a reference to the given []NatService and assigns it to the NatServices field. -func (o *ReadNatServicesResponse) SetNatServices(v []NatService) { - o.NatServices = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNatServicesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNatServicesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNatServicesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNatServicesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadNatServicesResponse struct { - Value ReadNatServicesResponse - ExplicitNull bool -} - -func (v NullableReadNatServicesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNatServicesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_request.go deleted file mode 100644 index 8a998463b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetAccessPointServicesRequest struct for ReadNetAccessPointServicesRequest -type ReadNetAccessPointServicesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersService `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNetAccessPointServicesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointServicesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNetAccessPointServicesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNetAccessPointServicesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNetAccessPointServicesRequest) GetFilters() FiltersService { - if o == nil || o.Filters == nil { - var ret FiltersService - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointServicesRequest) GetFiltersOk() (FiltersService, bool) { - if o == nil || o.Filters == nil { - var ret FiltersService - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNetAccessPointServicesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersService and assigns it to the Filters field. -func (o *ReadNetAccessPointServicesRequest) SetFilters(v FiltersService) { - o.Filters = &v -} - -type NullableReadNetAccessPointServicesRequest struct { - Value ReadNetAccessPointServicesRequest - ExplicitNull bool -} - -func (v NullableReadNetAccessPointServicesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetAccessPointServicesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_response.go deleted file mode 100644 index 75871201d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_point_services_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetAccessPointServicesResponse struct for ReadNetAccessPointServicesResponse -type ReadNetAccessPointServicesResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // The names of the services you can use for Net access points. - Services *[]Service `json:"Services,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNetAccessPointServicesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointServicesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNetAccessPointServicesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNetAccessPointServicesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetServices returns the Services field value if set, zero value otherwise. -func (o *ReadNetAccessPointServicesResponse) GetServices() []Service { - if o == nil || o.Services == nil { - var ret []Service - return ret - } - return *o.Services -} - -// GetServicesOk returns a tuple with the Services field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointServicesResponse) GetServicesOk() ([]Service, bool) { - if o == nil || o.Services == nil { - var ret []Service - return ret, false - } - return *o.Services, true -} - -// HasServices returns a boolean if a field has been set. -func (o *ReadNetAccessPointServicesResponse) HasServices() bool { - if o != nil && o.Services != nil { - return true - } - - return false -} - -// SetServices gets a reference to the given []Service and assigns it to the Services field. -func (o *ReadNetAccessPointServicesResponse) SetServices(v []Service) { - o.Services = &v -} - -type NullableReadNetAccessPointServicesResponse struct { - Value ReadNetAccessPointServicesResponse - ExplicitNull bool -} - -func (v NullableReadNetAccessPointServicesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetAccessPointServicesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_request.go deleted file mode 100644 index 867153ca2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetAccessPointsRequest struct for ReadNetAccessPointsRequest -type ReadNetAccessPointsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersNetAccessPoint `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNetAccessPointsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNetAccessPointsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNetAccessPointsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNetAccessPointsRequest) GetFilters() FiltersNetAccessPoint { - if o == nil || o.Filters == nil { - var ret FiltersNetAccessPoint - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointsRequest) GetFiltersOk() (FiltersNetAccessPoint, bool) { - if o == nil || o.Filters == nil { - var ret FiltersNetAccessPoint - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNetAccessPointsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersNetAccessPoint and assigns it to the Filters field. -func (o *ReadNetAccessPointsRequest) SetFilters(v FiltersNetAccessPoint) { - o.Filters = &v -} - -type NullableReadNetAccessPointsRequest struct { - Value ReadNetAccessPointsRequest - ExplicitNull bool -} - -func (v NullableReadNetAccessPointsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetAccessPointsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_response.go deleted file mode 100644 index 551d16ae6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_access_points_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetAccessPointsResponse struct for ReadNetAccessPointsResponse -type ReadNetAccessPointsResponse struct { - // One or more Net access points. - NetAccessPoints *[]NetAccessPoint `json:"NetAccessPoints,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetAccessPoints returns the NetAccessPoints field value if set, zero value otherwise. -func (o *ReadNetAccessPointsResponse) GetNetAccessPoints() []NetAccessPoint { - if o == nil || o.NetAccessPoints == nil { - var ret []NetAccessPoint - return ret - } - return *o.NetAccessPoints -} - -// GetNetAccessPointsOk returns a tuple with the NetAccessPoints field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointsResponse) GetNetAccessPointsOk() ([]NetAccessPoint, bool) { - if o == nil || o.NetAccessPoints == nil { - var ret []NetAccessPoint - return ret, false - } - return *o.NetAccessPoints, true -} - -// HasNetAccessPoints returns a boolean if a field has been set. -func (o *ReadNetAccessPointsResponse) HasNetAccessPoints() bool { - if o != nil && o.NetAccessPoints != nil { - return true - } - - return false -} - -// SetNetAccessPoints gets a reference to the given []NetAccessPoint and assigns it to the NetAccessPoints field. -func (o *ReadNetAccessPointsResponse) SetNetAccessPoints(v []NetAccessPoint) { - o.NetAccessPoints = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNetAccessPointsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetAccessPointsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNetAccessPointsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNetAccessPointsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadNetAccessPointsResponse struct { - Value ReadNetAccessPointsResponse - ExplicitNull bool -} - -func (v NullableReadNetAccessPointsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetAccessPointsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_request.go deleted file mode 100644 index dcc0e476d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetPeeringsRequest struct for ReadNetPeeringsRequest -type ReadNetPeeringsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersNetPeering `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNetPeeringsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetPeeringsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNetPeeringsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNetPeeringsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNetPeeringsRequest) GetFilters() FiltersNetPeering { - if o == nil || o.Filters == nil { - var ret FiltersNetPeering - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetPeeringsRequest) GetFiltersOk() (FiltersNetPeering, bool) { - if o == nil || o.Filters == nil { - var ret FiltersNetPeering - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNetPeeringsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersNetPeering and assigns it to the Filters field. -func (o *ReadNetPeeringsRequest) SetFilters(v FiltersNetPeering) { - o.Filters = &v -} - -type NullableReadNetPeeringsRequest struct { - Value ReadNetPeeringsRequest - ExplicitNull bool -} - -func (v NullableReadNetPeeringsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetPeeringsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_response.go deleted file mode 100644 index b09a40036..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_net_peerings_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetPeeringsResponse struct for ReadNetPeeringsResponse -type ReadNetPeeringsResponse struct { - // Information about one or more Net peering connections. - NetPeerings *[]NetPeering `json:"NetPeerings,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetPeerings returns the NetPeerings field value if set, zero value otherwise. -func (o *ReadNetPeeringsResponse) GetNetPeerings() []NetPeering { - if o == nil || o.NetPeerings == nil { - var ret []NetPeering - return ret - } - return *o.NetPeerings -} - -// GetNetPeeringsOk returns a tuple with the NetPeerings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetPeeringsResponse) GetNetPeeringsOk() ([]NetPeering, bool) { - if o == nil || o.NetPeerings == nil { - var ret []NetPeering - return ret, false - } - return *o.NetPeerings, true -} - -// HasNetPeerings returns a boolean if a field has been set. -func (o *ReadNetPeeringsResponse) HasNetPeerings() bool { - if o != nil && o.NetPeerings != nil { - return true - } - - return false -} - -// SetNetPeerings gets a reference to the given []NetPeering and assigns it to the NetPeerings field. -func (o *ReadNetPeeringsResponse) SetNetPeerings(v []NetPeering) { - o.NetPeerings = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNetPeeringsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetPeeringsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNetPeeringsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNetPeeringsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadNetPeeringsResponse struct { - Value ReadNetPeeringsResponse - ExplicitNull bool -} - -func (v NullableReadNetPeeringsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetPeeringsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_request.go deleted file mode 100644 index b8830ced8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetsRequest struct for ReadNetsRequest -type ReadNetsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersNet `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNetsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNetsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNetsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNetsRequest) GetFilters() FiltersNet { - if o == nil || o.Filters == nil { - var ret FiltersNet - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetsRequest) GetFiltersOk() (FiltersNet, bool) { - if o == nil || o.Filters == nil { - var ret FiltersNet - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNetsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersNet and assigns it to the Filters field. -func (o *ReadNetsRequest) SetFilters(v FiltersNet) { - o.Filters = &v -} - -type NullableReadNetsRequest struct { - Value ReadNetsRequest - ExplicitNull bool -} - -func (v NullableReadNetsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_response.go deleted file mode 100644 index 95a564e8b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nets_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNetsResponse struct for ReadNetsResponse -type ReadNetsResponse struct { - // Information about the described Nets. - Nets *[]Net `json:"Nets,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNets returns the Nets field value if set, zero value otherwise. -func (o *ReadNetsResponse) GetNets() []Net { - if o == nil || o.Nets == nil { - var ret []Net - return ret - } - return *o.Nets -} - -// GetNetsOk returns a tuple with the Nets field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetsResponse) GetNetsOk() ([]Net, bool) { - if o == nil || o.Nets == nil { - var ret []Net - return ret, false - } - return *o.Nets, true -} - -// HasNets returns a boolean if a field has been set. -func (o *ReadNetsResponse) HasNets() bool { - if o != nil && o.Nets != nil { - return true - } - - return false -} - -// SetNets gets a reference to the given []Net and assigns it to the Nets field. -func (o *ReadNetsResponse) SetNets(v []Net) { - o.Nets = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNetsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNetsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNetsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNetsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadNetsResponse struct { - Value ReadNetsResponse - ExplicitNull bool -} - -func (v NullableReadNetsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNetsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_request.go deleted file mode 100644 index bad74c988..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNicsRequest struct for ReadNicsRequest -type ReadNicsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersNic `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadNicsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNicsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadNicsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadNicsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadNicsRequest) GetFilters() FiltersNic { - if o == nil || o.Filters == nil { - var ret FiltersNic - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNicsRequest) GetFiltersOk() (FiltersNic, bool) { - if o == nil || o.Filters == nil { - var ret FiltersNic - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadNicsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersNic and assigns it to the Filters field. -func (o *ReadNicsRequest) SetFilters(v FiltersNic) { - o.Filters = &v -} - -type NullableReadNicsRequest struct { - Value ReadNicsRequest - ExplicitNull bool -} - -func (v NullableReadNicsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNicsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_response.go deleted file mode 100644 index 59aca1024..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_nics_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadNicsResponse struct for ReadNicsResponse -type ReadNicsResponse struct { - // Information about one or more NICs. - Nics *[]Nic `json:"Nics,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNics returns the Nics field value if set, zero value otherwise. -func (o *ReadNicsResponse) GetNics() []Nic { - if o == nil || o.Nics == nil { - var ret []Nic - return ret - } - return *o.Nics -} - -// GetNicsOk returns a tuple with the Nics field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNicsResponse) GetNicsOk() ([]Nic, bool) { - if o == nil || o.Nics == nil { - var ret []Nic - return ret, false - } - return *o.Nics, true -} - -// HasNics returns a boolean if a field has been set. -func (o *ReadNicsResponse) HasNics() bool { - if o != nil && o.Nics != nil { - return true - } - - return false -} - -// SetNics gets a reference to the given []Nic and assigns it to the Nics field. -func (o *ReadNicsResponse) SetNics(v []Nic) { - o.Nics = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadNicsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadNicsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadNicsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadNicsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadNicsResponse struct { - Value ReadNicsResponse - ExplicitNull bool -} - -func (v NullableReadNicsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadNicsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_request.go deleted file mode 100644 index ea51218f9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadProductTypesRequest struct for ReadProductTypesRequest -type ReadProductTypesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersProductType `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadProductTypesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadProductTypesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadProductTypesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadProductTypesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadProductTypesRequest) GetFilters() FiltersProductType { - if o == nil || o.Filters == nil { - var ret FiltersProductType - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadProductTypesRequest) GetFiltersOk() (FiltersProductType, bool) { - if o == nil || o.Filters == nil { - var ret FiltersProductType - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadProductTypesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersProductType and assigns it to the Filters field. -func (o *ReadProductTypesRequest) SetFilters(v FiltersProductType) { - o.Filters = &v -} - -type NullableReadProductTypesRequest struct { - Value ReadProductTypesRequest - ExplicitNull bool -} - -func (v NullableReadProductTypesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadProductTypesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_response.go deleted file mode 100644 index 9973ff4da..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_product_types_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadProductTypesResponse struct for ReadProductTypesResponse -type ReadProductTypesResponse struct { - // Information about one or more product types. - ProductTypes *[]ProductType `json:"ProductTypes,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetProductTypes returns the ProductTypes field value if set, zero value otherwise. -func (o *ReadProductTypesResponse) GetProductTypes() []ProductType { - if o == nil || o.ProductTypes == nil { - var ret []ProductType - return ret - } - return *o.ProductTypes -} - -// GetProductTypesOk returns a tuple with the ProductTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadProductTypesResponse) GetProductTypesOk() ([]ProductType, bool) { - if o == nil || o.ProductTypes == nil { - var ret []ProductType - return ret, false - } - return *o.ProductTypes, true -} - -// HasProductTypes returns a boolean if a field has been set. -func (o *ReadProductTypesResponse) HasProductTypes() bool { - if o != nil && o.ProductTypes != nil { - return true - } - - return false -} - -// SetProductTypes gets a reference to the given []ProductType and assigns it to the ProductTypes field. -func (o *ReadProductTypesResponse) SetProductTypes(v []ProductType) { - o.ProductTypes = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadProductTypesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadProductTypesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadProductTypesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadProductTypesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadProductTypesResponse struct { - Value ReadProductTypesResponse - ExplicitNull bool -} - -func (v NullableReadProductTypesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadProductTypesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_request.go deleted file mode 100644 index b495c7818..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadPublicIpRangesRequest struct for ReadPublicIpRangesRequest -type ReadPublicIpRangesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadPublicIpRangesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpRangesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadPublicIpRangesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadPublicIpRangesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableReadPublicIpRangesRequest struct { - Value ReadPublicIpRangesRequest - ExplicitNull bool -} - -func (v NullableReadPublicIpRangesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadPublicIpRangesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_response.go deleted file mode 100644 index fa24cde9e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ip_ranges_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadPublicIpRangesResponse struct for ReadPublicIpRangesResponse -type ReadPublicIpRangesResponse struct { - // The list of public IPv4 addresses used in the Region, in CIDR notation. - PublicIps *[]string `json:"PublicIps,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetPublicIps returns the PublicIps field value if set, zero value otherwise. -func (o *ReadPublicIpRangesResponse) GetPublicIps() []string { - if o == nil || o.PublicIps == nil { - var ret []string - return ret - } - return *o.PublicIps -} - -// GetPublicIpsOk returns a tuple with the PublicIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpRangesResponse) GetPublicIpsOk() ([]string, bool) { - if o == nil || o.PublicIps == nil { - var ret []string - return ret, false - } - return *o.PublicIps, true -} - -// HasPublicIps returns a boolean if a field has been set. -func (o *ReadPublicIpRangesResponse) HasPublicIps() bool { - if o != nil && o.PublicIps != nil { - return true - } - - return false -} - -// SetPublicIps gets a reference to the given []string and assigns it to the PublicIps field. -func (o *ReadPublicIpRangesResponse) SetPublicIps(v []string) { - o.PublicIps = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadPublicIpRangesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpRangesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadPublicIpRangesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadPublicIpRangesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadPublicIpRangesResponse struct { - Value ReadPublicIpRangesResponse - ExplicitNull bool -} - -func (v NullableReadPublicIpRangesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadPublicIpRangesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_request.go deleted file mode 100644 index 3b107cccd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadPublicIpsRequest struct for ReadPublicIpsRequest -type ReadPublicIpsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersPublicIp `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadPublicIpsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadPublicIpsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadPublicIpsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadPublicIpsRequest) GetFilters() FiltersPublicIp { - if o == nil || o.Filters == nil { - var ret FiltersPublicIp - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpsRequest) GetFiltersOk() (FiltersPublicIp, bool) { - if o == nil || o.Filters == nil { - var ret FiltersPublicIp - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadPublicIpsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersPublicIp and assigns it to the Filters field. -func (o *ReadPublicIpsRequest) SetFilters(v FiltersPublicIp) { - o.Filters = &v -} - -type NullableReadPublicIpsRequest struct { - Value ReadPublicIpsRequest - ExplicitNull bool -} - -func (v NullableReadPublicIpsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadPublicIpsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_response.go deleted file mode 100644 index 23bc80b2a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_public_ips_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadPublicIpsResponse struct for ReadPublicIpsResponse -type ReadPublicIpsResponse struct { - // Information about one or more EIPs. - PublicIps *[]PublicIp `json:"PublicIps,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetPublicIps returns the PublicIps field value if set, zero value otherwise. -func (o *ReadPublicIpsResponse) GetPublicIps() []PublicIp { - if o == nil || o.PublicIps == nil { - var ret []PublicIp - return ret - } - return *o.PublicIps -} - -// GetPublicIpsOk returns a tuple with the PublicIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpsResponse) GetPublicIpsOk() ([]PublicIp, bool) { - if o == nil || o.PublicIps == nil { - var ret []PublicIp - return ret, false - } - return *o.PublicIps, true -} - -// HasPublicIps returns a boolean if a field has been set. -func (o *ReadPublicIpsResponse) HasPublicIps() bool { - if o != nil && o.PublicIps != nil { - return true - } - - return false -} - -// SetPublicIps gets a reference to the given []PublicIp and assigns it to the PublicIps field. -func (o *ReadPublicIpsResponse) SetPublicIps(v []PublicIp) { - o.PublicIps = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadPublicIpsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadPublicIpsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadPublicIpsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadPublicIpsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadPublicIpsResponse struct { - Value ReadPublicIpsResponse - ExplicitNull bool -} - -func (v NullableReadPublicIpsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadPublicIpsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_request.go deleted file mode 100644 index c8e13bfb8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadQuotasRequest struct for ReadQuotasRequest -type ReadQuotasRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersQuota `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadQuotasRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadQuotasRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadQuotasRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadQuotasRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadQuotasRequest) GetFilters() FiltersQuota { - if o == nil || o.Filters == nil { - var ret FiltersQuota - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadQuotasRequest) GetFiltersOk() (FiltersQuota, bool) { - if o == nil || o.Filters == nil { - var ret FiltersQuota - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadQuotasRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersQuota and assigns it to the Filters field. -func (o *ReadQuotasRequest) SetFilters(v FiltersQuota) { - o.Filters = &v -} - -type NullableReadQuotasRequest struct { - Value ReadQuotasRequest - ExplicitNull bool -} - -func (v NullableReadQuotasRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadQuotasRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_response.go deleted file mode 100644 index 19da39d4a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_quotas_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadQuotasResponse struct for ReadQuotasResponse -type ReadQuotasResponse struct { - // Information about one or more quotas. - QuotaTypes *[]QuotaTypes `json:"QuotaTypes,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetQuotaTypes returns the QuotaTypes field value if set, zero value otherwise. -func (o *ReadQuotasResponse) GetQuotaTypes() []QuotaTypes { - if o == nil || o.QuotaTypes == nil { - var ret []QuotaTypes - return ret - } - return *o.QuotaTypes -} - -// GetQuotaTypesOk returns a tuple with the QuotaTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadQuotasResponse) GetQuotaTypesOk() ([]QuotaTypes, bool) { - if o == nil || o.QuotaTypes == nil { - var ret []QuotaTypes - return ret, false - } - return *o.QuotaTypes, true -} - -// HasQuotaTypes returns a boolean if a field has been set. -func (o *ReadQuotasResponse) HasQuotaTypes() bool { - if o != nil && o.QuotaTypes != nil { - return true - } - - return false -} - -// SetQuotaTypes gets a reference to the given []QuotaTypes and assigns it to the QuotaTypes field. -func (o *ReadQuotasResponse) SetQuotaTypes(v []QuotaTypes) { - o.QuotaTypes = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadQuotasResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadQuotasResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadQuotasResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadQuotasResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadQuotasResponse struct { - Value ReadQuotasResponse - ExplicitNull bool -} - -func (v NullableReadQuotasResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadQuotasResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_request.go deleted file mode 100644 index ba0393363..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_request.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadRegionsRequest struct for ReadRegionsRequest -type ReadRegionsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadRegionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRegionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadRegionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadRegionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -type NullableReadRegionsRequest struct { - Value ReadRegionsRequest - ExplicitNull bool -} - -func (v NullableReadRegionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadRegionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_response.go deleted file mode 100644 index 660c85208..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_regions_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadRegionsResponse struct for ReadRegionsResponse -type ReadRegionsResponse struct { - // Information about one or more Regions. - Regions *[]Region `json:"Regions,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetRegions returns the Regions field value if set, zero value otherwise. -func (o *ReadRegionsResponse) GetRegions() []Region { - if o == nil || o.Regions == nil { - var ret []Region - return ret - } - return *o.Regions -} - -// GetRegionsOk returns a tuple with the Regions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRegionsResponse) GetRegionsOk() ([]Region, bool) { - if o == nil || o.Regions == nil { - var ret []Region - return ret, false - } - return *o.Regions, true -} - -// HasRegions returns a boolean if a field has been set. -func (o *ReadRegionsResponse) HasRegions() bool { - if o != nil && o.Regions != nil { - return true - } - - return false -} - -// SetRegions gets a reference to the given []Region and assigns it to the Regions field. -func (o *ReadRegionsResponse) SetRegions(v []Region) { - o.Regions = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadRegionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRegionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadRegionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadRegionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadRegionsResponse struct { - Value ReadRegionsResponse - ExplicitNull bool -} - -func (v NullableReadRegionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadRegionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_request.go deleted file mode 100644 index 44c7690b2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadRouteTablesRequest struct for ReadRouteTablesRequest -type ReadRouteTablesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersRouteTable `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadRouteTablesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRouteTablesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadRouteTablesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadRouteTablesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadRouteTablesRequest) GetFilters() FiltersRouteTable { - if o == nil || o.Filters == nil { - var ret FiltersRouteTable - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRouteTablesRequest) GetFiltersOk() (FiltersRouteTable, bool) { - if o == nil || o.Filters == nil { - var ret FiltersRouteTable - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadRouteTablesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersRouteTable and assigns it to the Filters field. -func (o *ReadRouteTablesRequest) SetFilters(v FiltersRouteTable) { - o.Filters = &v -} - -type NullableReadRouteTablesRequest struct { - Value ReadRouteTablesRequest - ExplicitNull bool -} - -func (v NullableReadRouteTablesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadRouteTablesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_response.go deleted file mode 100644 index 8e675a90c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_route_tables_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadRouteTablesResponse struct for ReadRouteTablesResponse -type ReadRouteTablesResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more route tables. - RouteTables *[]RouteTable `json:"RouteTables,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadRouteTablesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRouteTablesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadRouteTablesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadRouteTablesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTables returns the RouteTables field value if set, zero value otherwise. -func (o *ReadRouteTablesResponse) GetRouteTables() []RouteTable { - if o == nil || o.RouteTables == nil { - var ret []RouteTable - return ret - } - return *o.RouteTables -} - -// GetRouteTablesOk returns a tuple with the RouteTables field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadRouteTablesResponse) GetRouteTablesOk() ([]RouteTable, bool) { - if o == nil || o.RouteTables == nil { - var ret []RouteTable - return ret, false - } - return *o.RouteTables, true -} - -// HasRouteTables returns a boolean if a field has been set. -func (o *ReadRouteTablesResponse) HasRouteTables() bool { - if o != nil && o.RouteTables != nil { - return true - } - - return false -} - -// SetRouteTables gets a reference to the given []RouteTable and assigns it to the RouteTables field. -func (o *ReadRouteTablesResponse) SetRouteTables(v []RouteTable) { - o.RouteTables = &v -} - -type NullableReadRouteTablesResponse struct { - Value ReadRouteTablesResponse - ExplicitNull bool -} - -func (v NullableReadRouteTablesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadRouteTablesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_request.go deleted file mode 100644 index ca93d4439..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_request.go +++ /dev/null @@ -1,60 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSecretAccessKeyRequest struct for ReadSecretAccessKeyRequest -type ReadSecretAccessKeyRequest struct { - // The ID of the access key. - AccessKeyId string `json:"AccessKeyId"` -} - -// GetAccessKeyId returns the AccessKeyId field value -func (o *ReadSecretAccessKeyRequest) GetAccessKeyId() string { - if o == nil { - var ret string - return ret - } - - return o.AccessKeyId -} - -// SetAccessKeyId sets field value -func (o *ReadSecretAccessKeyRequest) SetAccessKeyId(v string) { - o.AccessKeyId = v -} - -type NullableReadSecretAccessKeyRequest struct { - Value ReadSecretAccessKeyRequest - ExplicitNull bool -} - -func (v NullableReadSecretAccessKeyRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSecretAccessKeyRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_response.go deleted file mode 100644 index 22ef945a8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_secret_access_key_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSecretAccessKeyResponse struct for ReadSecretAccessKeyResponse -type ReadSecretAccessKeyResponse struct { - AccessKey *AccessKeySecretKey `json:"AccessKey,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccessKey returns the AccessKey field value if set, zero value otherwise. -func (o *ReadSecretAccessKeyResponse) GetAccessKey() AccessKeySecretKey { - if o == nil || o.AccessKey == nil { - var ret AccessKeySecretKey - return ret - } - return *o.AccessKey -} - -// GetAccessKeyOk returns a tuple with the AccessKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecretAccessKeyResponse) GetAccessKeyOk() (AccessKeySecretKey, bool) { - if o == nil || o.AccessKey == nil { - var ret AccessKeySecretKey - return ret, false - } - return *o.AccessKey, true -} - -// HasAccessKey returns a boolean if a field has been set. -func (o *ReadSecretAccessKeyResponse) HasAccessKey() bool { - if o != nil && o.AccessKey != nil { - return true - } - - return false -} - -// SetAccessKey gets a reference to the given AccessKeySecretKey and assigns it to the AccessKey field. -func (o *ReadSecretAccessKeyResponse) SetAccessKey(v AccessKeySecretKey) { - o.AccessKey = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSecretAccessKeyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecretAccessKeyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSecretAccessKeyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSecretAccessKeyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadSecretAccessKeyResponse struct { - Value ReadSecretAccessKeyResponse - ExplicitNull bool -} - -func (v NullableReadSecretAccessKeyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSecretAccessKeyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_request.go deleted file mode 100644 index dc40f183b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSecurityGroupsRequest struct for ReadSecurityGroupsRequest -type ReadSecurityGroupsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersSecurityGroup `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadSecurityGroupsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecurityGroupsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadSecurityGroupsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadSecurityGroupsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadSecurityGroupsRequest) GetFilters() FiltersSecurityGroup { - if o == nil || o.Filters == nil { - var ret FiltersSecurityGroup - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecurityGroupsRequest) GetFiltersOk() (FiltersSecurityGroup, bool) { - if o == nil || o.Filters == nil { - var ret FiltersSecurityGroup - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadSecurityGroupsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersSecurityGroup and assigns it to the Filters field. -func (o *ReadSecurityGroupsRequest) SetFilters(v FiltersSecurityGroup) { - o.Filters = &v -} - -type NullableReadSecurityGroupsRequest struct { - Value ReadSecurityGroupsRequest - ExplicitNull bool -} - -func (v NullableReadSecurityGroupsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSecurityGroupsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_response.go deleted file mode 100644 index 81b349a9b..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_security_groups_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSecurityGroupsResponse struct for ReadSecurityGroupsResponse -type ReadSecurityGroupsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more security groups. - SecurityGroups *[]SecurityGroup `json:"SecurityGroups,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSecurityGroupsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecurityGroupsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSecurityGroupsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSecurityGroupsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *ReadSecurityGroupsResponse) GetSecurityGroups() []SecurityGroup { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroup - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSecurityGroupsResponse) GetSecurityGroupsOk() ([]SecurityGroup, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroup - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *ReadSecurityGroupsResponse) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []SecurityGroup and assigns it to the SecurityGroups field. -func (o *ReadSecurityGroupsResponse) SetSecurityGroups(v []SecurityGroup) { - o.SecurityGroups = &v -} - -type NullableReadSecurityGroupsResponse struct { - Value ReadSecurityGroupsResponse - ExplicitNull bool -} - -func (v NullableReadSecurityGroupsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSecurityGroupsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_request.go deleted file mode 100644 index d2d6610f9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadServerCertificatesRequest struct for ReadServerCertificatesRequest -type ReadServerCertificatesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersServerCertificate `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadServerCertificatesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadServerCertificatesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadServerCertificatesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadServerCertificatesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadServerCertificatesRequest) GetFilters() FiltersServerCertificate { - if o == nil || o.Filters == nil { - var ret FiltersServerCertificate - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadServerCertificatesRequest) GetFiltersOk() (FiltersServerCertificate, bool) { - if o == nil || o.Filters == nil { - var ret FiltersServerCertificate - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadServerCertificatesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersServerCertificate and assigns it to the Filters field. -func (o *ReadServerCertificatesRequest) SetFilters(v FiltersServerCertificate) { - o.Filters = &v -} - -type NullableReadServerCertificatesRequest struct { - Value ReadServerCertificatesRequest - ExplicitNull bool -} - -func (v NullableReadServerCertificatesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadServerCertificatesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_response.go deleted file mode 100644 index 25cf7430c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_server_certificates_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadServerCertificatesResponse struct for ReadServerCertificatesResponse -type ReadServerCertificatesResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more server certificates. - ServerCertificates *[]ServerCertificate `json:"ServerCertificates,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadServerCertificatesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadServerCertificatesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadServerCertificatesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadServerCertificatesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetServerCertificates returns the ServerCertificates field value if set, zero value otherwise. -func (o *ReadServerCertificatesResponse) GetServerCertificates() []ServerCertificate { - if o == nil || o.ServerCertificates == nil { - var ret []ServerCertificate - return ret - } - return *o.ServerCertificates -} - -// GetServerCertificatesOk returns a tuple with the ServerCertificates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadServerCertificatesResponse) GetServerCertificatesOk() ([]ServerCertificate, bool) { - if o == nil || o.ServerCertificates == nil { - var ret []ServerCertificate - return ret, false - } - return *o.ServerCertificates, true -} - -// HasServerCertificates returns a boolean if a field has been set. -func (o *ReadServerCertificatesResponse) HasServerCertificates() bool { - if o != nil && o.ServerCertificates != nil { - return true - } - - return false -} - -// SetServerCertificates gets a reference to the given []ServerCertificate and assigns it to the ServerCertificates field. -func (o *ReadServerCertificatesResponse) SetServerCertificates(v []ServerCertificate) { - o.ServerCertificates = &v -} - -type NullableReadServerCertificatesResponse struct { - Value ReadServerCertificatesResponse - ExplicitNull bool -} - -func (v NullableReadServerCertificatesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadServerCertificatesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_request.go deleted file mode 100644 index e797f25b1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSnapshotExportTasksRequest struct for ReadSnapshotExportTasksRequest -type ReadSnapshotExportTasksRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersExportTask `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadSnapshotExportTasksRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotExportTasksRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadSnapshotExportTasksRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadSnapshotExportTasksRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadSnapshotExportTasksRequest) GetFilters() FiltersExportTask { - if o == nil || o.Filters == nil { - var ret FiltersExportTask - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotExportTasksRequest) GetFiltersOk() (FiltersExportTask, bool) { - if o == nil || o.Filters == nil { - var ret FiltersExportTask - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadSnapshotExportTasksRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersExportTask and assigns it to the Filters field. -func (o *ReadSnapshotExportTasksRequest) SetFilters(v FiltersExportTask) { - o.Filters = &v -} - -type NullableReadSnapshotExportTasksRequest struct { - Value ReadSnapshotExportTasksRequest - ExplicitNull bool -} - -func (v NullableReadSnapshotExportTasksRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSnapshotExportTasksRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_response.go deleted file mode 100644 index 5a1dca26c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshot_export_tasks_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSnapshotExportTasksResponse struct for ReadSnapshotExportTasksResponse -type ReadSnapshotExportTasksResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more snapshot export tasks. - SnapshotExportTasks *[]SnapshotExportTask `json:"SnapshotExportTasks,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSnapshotExportTasksResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotExportTasksResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSnapshotExportTasksResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSnapshotExportTasksResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSnapshotExportTasks returns the SnapshotExportTasks field value if set, zero value otherwise. -func (o *ReadSnapshotExportTasksResponse) GetSnapshotExportTasks() []SnapshotExportTask { - if o == nil || o.SnapshotExportTasks == nil { - var ret []SnapshotExportTask - return ret - } - return *o.SnapshotExportTasks -} - -// GetSnapshotExportTasksOk returns a tuple with the SnapshotExportTasks field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotExportTasksResponse) GetSnapshotExportTasksOk() ([]SnapshotExportTask, bool) { - if o == nil || o.SnapshotExportTasks == nil { - var ret []SnapshotExportTask - return ret, false - } - return *o.SnapshotExportTasks, true -} - -// HasSnapshotExportTasks returns a boolean if a field has been set. -func (o *ReadSnapshotExportTasksResponse) HasSnapshotExportTasks() bool { - if o != nil && o.SnapshotExportTasks != nil { - return true - } - - return false -} - -// SetSnapshotExportTasks gets a reference to the given []SnapshotExportTask and assigns it to the SnapshotExportTasks field. -func (o *ReadSnapshotExportTasksResponse) SetSnapshotExportTasks(v []SnapshotExportTask) { - o.SnapshotExportTasks = &v -} - -type NullableReadSnapshotExportTasksResponse struct { - Value ReadSnapshotExportTasksResponse - ExplicitNull bool -} - -func (v NullableReadSnapshotExportTasksResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSnapshotExportTasksResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_request.go deleted file mode 100644 index 1fc215b0e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSnapshotsRequest struct for ReadSnapshotsRequest -type ReadSnapshotsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersSnapshot `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadSnapshotsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadSnapshotsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadSnapshotsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadSnapshotsRequest) GetFilters() FiltersSnapshot { - if o == nil || o.Filters == nil { - var ret FiltersSnapshot - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotsRequest) GetFiltersOk() (FiltersSnapshot, bool) { - if o == nil || o.Filters == nil { - var ret FiltersSnapshot - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadSnapshotsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersSnapshot and assigns it to the Filters field. -func (o *ReadSnapshotsRequest) SetFilters(v FiltersSnapshot) { - o.Filters = &v -} - -type NullableReadSnapshotsRequest struct { - Value ReadSnapshotsRequest - ExplicitNull bool -} - -func (v NullableReadSnapshotsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSnapshotsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_response.go deleted file mode 100644 index 13f02566a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_snapshots_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSnapshotsResponse struct for ReadSnapshotsResponse -type ReadSnapshotsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more snapshots and their permissions. - Snapshots *[]Snapshot `json:"Snapshots,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSnapshotsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSnapshotsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSnapshotsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSnapshots returns the Snapshots field value if set, zero value otherwise. -func (o *ReadSnapshotsResponse) GetSnapshots() []Snapshot { - if o == nil || o.Snapshots == nil { - var ret []Snapshot - return ret - } - return *o.Snapshots -} - -// GetSnapshotsOk returns a tuple with the Snapshots field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSnapshotsResponse) GetSnapshotsOk() ([]Snapshot, bool) { - if o == nil || o.Snapshots == nil { - var ret []Snapshot - return ret, false - } - return *o.Snapshots, true -} - -// HasSnapshots returns a boolean if a field has been set. -func (o *ReadSnapshotsResponse) HasSnapshots() bool { - if o != nil && o.Snapshots != nil { - return true - } - - return false -} - -// SetSnapshots gets a reference to the given []Snapshot and assigns it to the Snapshots field. -func (o *ReadSnapshotsResponse) SetSnapshots(v []Snapshot) { - o.Snapshots = &v -} - -type NullableReadSnapshotsResponse struct { - Value ReadSnapshotsResponse - ExplicitNull bool -} - -func (v NullableReadSnapshotsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSnapshotsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_request.go deleted file mode 100644 index 17ecc75bb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSubnetsRequest struct for ReadSubnetsRequest -type ReadSubnetsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersSubnet `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadSubnetsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubnetsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadSubnetsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadSubnetsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadSubnetsRequest) GetFilters() FiltersSubnet { - if o == nil || o.Filters == nil { - var ret FiltersSubnet - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubnetsRequest) GetFiltersOk() (FiltersSubnet, bool) { - if o == nil || o.Filters == nil { - var ret FiltersSubnet - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadSubnetsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersSubnet and assigns it to the Filters field. -func (o *ReadSubnetsRequest) SetFilters(v FiltersSubnet) { - o.Filters = &v -} - -type NullableReadSubnetsRequest struct { - Value ReadSubnetsRequest - ExplicitNull bool -} - -func (v NullableReadSubnetsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSubnetsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_response.go deleted file mode 100644 index e8de626ad..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subnets_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSubnetsResponse struct for ReadSubnetsResponse -type ReadSubnetsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more Subnets. - Subnets *[]Subnet `json:"Subnets,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSubnetsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubnetsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSubnetsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSubnetsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSubnets returns the Subnets field value if set, zero value otherwise. -func (o *ReadSubnetsResponse) GetSubnets() []Subnet { - if o == nil || o.Subnets == nil { - var ret []Subnet - return ret - } - return *o.Subnets -} - -// GetSubnetsOk returns a tuple with the Subnets field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubnetsResponse) GetSubnetsOk() ([]Subnet, bool) { - if o == nil || o.Subnets == nil { - var ret []Subnet - return ret, false - } - return *o.Subnets, true -} - -// HasSubnets returns a boolean if a field has been set. -func (o *ReadSubnetsResponse) HasSubnets() bool { - if o != nil && o.Subnets != nil { - return true - } - - return false -} - -// SetSubnets gets a reference to the given []Subnet and assigns it to the Subnets field. -func (o *ReadSubnetsResponse) SetSubnets(v []Subnet) { - o.Subnets = &v -} - -type NullableReadSubnetsResponse struct { - Value ReadSubnetsResponse - ExplicitNull bool -} - -func (v NullableReadSubnetsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSubnetsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_request.go deleted file mode 100644 index 008e1373d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSubregionsRequest struct for ReadSubregionsRequest -type ReadSubregionsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersSubregion `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadSubregionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubregionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadSubregionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadSubregionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadSubregionsRequest) GetFilters() FiltersSubregion { - if o == nil || o.Filters == nil { - var ret FiltersSubregion - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubregionsRequest) GetFiltersOk() (FiltersSubregion, bool) { - if o == nil || o.Filters == nil { - var ret FiltersSubregion - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadSubregionsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersSubregion and assigns it to the Filters field. -func (o *ReadSubregionsRequest) SetFilters(v FiltersSubregion) { - o.Filters = &v -} - -type NullableReadSubregionsRequest struct { - Value ReadSubregionsRequest - ExplicitNull bool -} - -func (v NullableReadSubregionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSubregionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_response.go deleted file mode 100644 index 3ec16f340..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_subregions_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadSubregionsResponse struct for ReadSubregionsResponse -type ReadSubregionsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more Subregions. - Subregions *[]Subregion `json:"Subregions,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadSubregionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubregionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadSubregionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadSubregionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSubregions returns the Subregions field value if set, zero value otherwise. -func (o *ReadSubregionsResponse) GetSubregions() []Subregion { - if o == nil || o.Subregions == nil { - var ret []Subregion - return ret - } - return *o.Subregions -} - -// GetSubregionsOk returns a tuple with the Subregions field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadSubregionsResponse) GetSubregionsOk() ([]Subregion, bool) { - if o == nil || o.Subregions == nil { - var ret []Subregion - return ret, false - } - return *o.Subregions, true -} - -// HasSubregions returns a boolean if a field has been set. -func (o *ReadSubregionsResponse) HasSubregions() bool { - if o != nil && o.Subregions != nil { - return true - } - - return false -} - -// SetSubregions gets a reference to the given []Subregion and assigns it to the Subregions field. -func (o *ReadSubregionsResponse) SetSubregions(v []Subregion) { - o.Subregions = &v -} - -type NullableReadSubregionsResponse struct { - Value ReadSubregionsResponse - ExplicitNull bool -} - -func (v NullableReadSubregionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadSubregionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_request.go deleted file mode 100644 index 939176eb3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadTagsRequest struct for ReadTagsRequest -type ReadTagsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersTag `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadTagsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadTagsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadTagsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadTagsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadTagsRequest) GetFilters() FiltersTag { - if o == nil || o.Filters == nil { - var ret FiltersTag - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadTagsRequest) GetFiltersOk() (FiltersTag, bool) { - if o == nil || o.Filters == nil { - var ret FiltersTag - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadTagsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersTag and assigns it to the Filters field. -func (o *ReadTagsRequest) SetFilters(v FiltersTag) { - o.Filters = &v -} - -type NullableReadTagsRequest struct { - Value ReadTagsRequest - ExplicitNull bool -} - -func (v NullableReadTagsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadTagsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_response.go deleted file mode 100644 index 2276e32f4..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_tags_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadTagsResponse struct for ReadTagsResponse -type ReadTagsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more tags. - Tags *[]Tag `json:"Tags,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadTagsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadTagsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadTagsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadTagsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *ReadTagsResponse) GetTags() []Tag { - if o == nil || o.Tags == nil { - var ret []Tag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadTagsResponse) GetTagsOk() ([]Tag, bool) { - if o == nil || o.Tags == nil { - var ret []Tag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *ReadTagsResponse) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []Tag and assigns it to the Tags field. -func (o *ReadTagsResponse) SetTags(v []Tag) { - o.Tags = &v -} - -type NullableReadTagsResponse struct { - Value ReadTagsResponse - ExplicitNull bool -} - -func (v NullableReadTagsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadTagsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_request.go deleted file mode 100644 index 02c15cacf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVirtualGatewaysRequest struct for ReadVirtualGatewaysRequest -type ReadVirtualGatewaysRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVirtualGateway `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVirtualGatewaysRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVirtualGatewaysRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVirtualGatewaysRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVirtualGatewaysRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVirtualGatewaysRequest) GetFilters() FiltersVirtualGateway { - if o == nil || o.Filters == nil { - var ret FiltersVirtualGateway - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVirtualGatewaysRequest) GetFiltersOk() (FiltersVirtualGateway, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVirtualGateway - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVirtualGatewaysRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVirtualGateway and assigns it to the Filters field. -func (o *ReadVirtualGatewaysRequest) SetFilters(v FiltersVirtualGateway) { - o.Filters = &v -} - -type NullableReadVirtualGatewaysRequest struct { - Value ReadVirtualGatewaysRequest - ExplicitNull bool -} - -func (v NullableReadVirtualGatewaysRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVirtualGatewaysRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_response.go deleted file mode 100644 index 717c9222a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_virtual_gateways_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVirtualGatewaysResponse struct for ReadVirtualGatewaysResponse -type ReadVirtualGatewaysResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more virtual gateways. - VirtualGateways *[]VirtualGateway `json:"VirtualGateways,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVirtualGatewaysResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVirtualGatewaysResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVirtualGatewaysResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVirtualGatewaysResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVirtualGateways returns the VirtualGateways field value if set, zero value otherwise. -func (o *ReadVirtualGatewaysResponse) GetVirtualGateways() []VirtualGateway { - if o == nil || o.VirtualGateways == nil { - var ret []VirtualGateway - return ret - } - return *o.VirtualGateways -} - -// GetVirtualGatewaysOk returns a tuple with the VirtualGateways field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVirtualGatewaysResponse) GetVirtualGatewaysOk() ([]VirtualGateway, bool) { - if o == nil || o.VirtualGateways == nil { - var ret []VirtualGateway - return ret, false - } - return *o.VirtualGateways, true -} - -// HasVirtualGateways returns a boolean if a field has been set. -func (o *ReadVirtualGatewaysResponse) HasVirtualGateways() bool { - if o != nil && o.VirtualGateways != nil { - return true - } - - return false -} - -// SetVirtualGateways gets a reference to the given []VirtualGateway and assigns it to the VirtualGateways field. -func (o *ReadVirtualGatewaysResponse) SetVirtualGateways(v []VirtualGateway) { - o.VirtualGateways = &v -} - -type NullableReadVirtualGatewaysResponse struct { - Value ReadVirtualGatewaysResponse - ExplicitNull bool -} - -func (v NullableReadVirtualGatewaysResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVirtualGatewaysResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_request.go deleted file mode 100644 index 5ecc80fdf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmTypesRequest struct for ReadVmTypesRequest -type ReadVmTypesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVmType `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVmTypesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmTypesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVmTypesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVmTypesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVmTypesRequest) GetFilters() FiltersVmType { - if o == nil || o.Filters == nil { - var ret FiltersVmType - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmTypesRequest) GetFiltersOk() (FiltersVmType, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVmType - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVmTypesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVmType and assigns it to the Filters field. -func (o *ReadVmTypesRequest) SetFilters(v FiltersVmType) { - o.Filters = &v -} - -type NullableReadVmTypesRequest struct { - Value ReadVmTypesRequest - ExplicitNull bool -} - -func (v NullableReadVmTypesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmTypesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_response.go deleted file mode 100644 index b0b034b64..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vm_types_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmTypesResponse struct for ReadVmTypesResponse -type ReadVmTypesResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more VM types. - VmTypes *[]VmType `json:"VmTypes,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVmTypesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmTypesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVmTypesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVmTypesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVmTypes returns the VmTypes field value if set, zero value otherwise. -func (o *ReadVmTypesResponse) GetVmTypes() []VmType { - if o == nil || o.VmTypes == nil { - var ret []VmType - return ret - } - return *o.VmTypes -} - -// GetVmTypesOk returns a tuple with the VmTypes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmTypesResponse) GetVmTypesOk() ([]VmType, bool) { - if o == nil || o.VmTypes == nil { - var ret []VmType - return ret, false - } - return *o.VmTypes, true -} - -// HasVmTypes returns a boolean if a field has been set. -func (o *ReadVmTypesResponse) HasVmTypes() bool { - if o != nil && o.VmTypes != nil { - return true - } - - return false -} - -// SetVmTypes gets a reference to the given []VmType and assigns it to the VmTypes field. -func (o *ReadVmTypesResponse) SetVmTypes(v []VmType) { - o.VmTypes = &v -} - -type NullableReadVmTypesResponse struct { - Value ReadVmTypesResponse - ExplicitNull bool -} - -func (v NullableReadVmTypesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmTypesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_request.go deleted file mode 100644 index 08d78c8ef..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsHealthRequest struct for ReadVmsHealthRequest -type ReadVmsHealthRequest struct { - // One or more IDs of back-end VMs. - BackendVmIds *[]string `json:"BackendVmIds,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer. - LoadBalancerName string `json:"LoadBalancerName"` -} - -// GetBackendVmIds returns the BackendVmIds field value if set, zero value otherwise. -func (o *ReadVmsHealthRequest) GetBackendVmIds() []string { - if o == nil || o.BackendVmIds == nil { - var ret []string - return ret - } - return *o.BackendVmIds -} - -// GetBackendVmIdsOk returns a tuple with the BackendVmIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsHealthRequest) GetBackendVmIdsOk() ([]string, bool) { - if o == nil || o.BackendVmIds == nil { - var ret []string - return ret, false - } - return *o.BackendVmIds, true -} - -// HasBackendVmIds returns a boolean if a field has been set. -func (o *ReadVmsHealthRequest) HasBackendVmIds() bool { - if o != nil && o.BackendVmIds != nil { - return true - } - - return false -} - -// SetBackendVmIds gets a reference to the given []string and assigns it to the BackendVmIds field. -func (o *ReadVmsHealthRequest) SetBackendVmIds(v []string) { - o.BackendVmIds = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVmsHealthRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsHealthRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVmsHealthRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVmsHealthRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *ReadVmsHealthRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *ReadVmsHealthRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -type NullableReadVmsHealthRequest struct { - Value ReadVmsHealthRequest - ExplicitNull bool -} - -func (v NullableReadVmsHealthRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsHealthRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_response.go deleted file mode 100644 index 30ca98217..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_health_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsHealthResponse struct for ReadVmsHealthResponse -type ReadVmsHealthResponse struct { - // Information about the health of one or more back-end VMs. - BackendVmHealth *[]BackendVmHealth `json:"BackendVmHealth,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetBackendVmHealth returns the BackendVmHealth field value if set, zero value otherwise. -func (o *ReadVmsHealthResponse) GetBackendVmHealth() []BackendVmHealth { - if o == nil || o.BackendVmHealth == nil { - var ret []BackendVmHealth - return ret - } - return *o.BackendVmHealth -} - -// GetBackendVmHealthOk returns a tuple with the BackendVmHealth field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsHealthResponse) GetBackendVmHealthOk() ([]BackendVmHealth, bool) { - if o == nil || o.BackendVmHealth == nil { - var ret []BackendVmHealth - return ret, false - } - return *o.BackendVmHealth, true -} - -// HasBackendVmHealth returns a boolean if a field has been set. -func (o *ReadVmsHealthResponse) HasBackendVmHealth() bool { - if o != nil && o.BackendVmHealth != nil { - return true - } - - return false -} - -// SetBackendVmHealth gets a reference to the given []BackendVmHealth and assigns it to the BackendVmHealth field. -func (o *ReadVmsHealthResponse) SetBackendVmHealth(v []BackendVmHealth) { - o.BackendVmHealth = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVmsHealthResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsHealthResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVmsHealthResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVmsHealthResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableReadVmsHealthResponse struct { - Value ReadVmsHealthResponse - ExplicitNull bool -} - -func (v NullableReadVmsHealthResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsHealthResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_request.go deleted file mode 100644 index be18f8af5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsRequest struct for ReadVmsRequest -type ReadVmsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVm `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVmsRequest) GetFilters() FiltersVm { - if o == nil || o.Filters == nil { - var ret FiltersVm - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsRequest) GetFiltersOk() (FiltersVm, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVm - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVmsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVm and assigns it to the Filters field. -func (o *ReadVmsRequest) SetFilters(v FiltersVm) { - o.Filters = &v -} - -type NullableReadVmsRequest struct { - Value ReadVmsRequest - ExplicitNull bool -} - -func (v NullableReadVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_response.go deleted file mode 100644 index 94a35b2f2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsResponse struct for ReadVmsResponse -type ReadVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more VMs. - Vms *[]Vm `json:"Vms,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVms returns the Vms field value if set, zero value otherwise. -func (o *ReadVmsResponse) GetVms() []Vm { - if o == nil || o.Vms == nil { - var ret []Vm - return ret - } - return *o.Vms -} - -// GetVmsOk returns a tuple with the Vms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsResponse) GetVmsOk() ([]Vm, bool) { - if o == nil || o.Vms == nil { - var ret []Vm - return ret, false - } - return *o.Vms, true -} - -// HasVms returns a boolean if a field has been set. -func (o *ReadVmsResponse) HasVms() bool { - if o != nil && o.Vms != nil { - return true - } - - return false -} - -// SetVms gets a reference to the given []Vm and assigns it to the Vms field. -func (o *ReadVmsResponse) SetVms(v []Vm) { - o.Vms = &v -} - -type NullableReadVmsResponse struct { - Value ReadVmsResponse - ExplicitNull bool -} - -func (v NullableReadVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_request.go deleted file mode 100644 index 5d6768d2f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_request.go +++ /dev/null @@ -1,147 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsStateRequest struct for ReadVmsStateRequest -type ReadVmsStateRequest struct { - // If `true`, includes the status of all VMs. By default or if set to `false`, only includes the status of running VMs. - AllVms *bool `json:"AllVms,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVmsState `json:"Filters,omitempty"` -} - -// GetAllVms returns the AllVms field value if set, zero value otherwise. -func (o *ReadVmsStateRequest) GetAllVms() bool { - if o == nil || o.AllVms == nil { - var ret bool - return ret - } - return *o.AllVms -} - -// GetAllVmsOk returns a tuple with the AllVms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsStateRequest) GetAllVmsOk() (bool, bool) { - if o == nil || o.AllVms == nil { - var ret bool - return ret, false - } - return *o.AllVms, true -} - -// HasAllVms returns a boolean if a field has been set. -func (o *ReadVmsStateRequest) HasAllVms() bool { - if o != nil && o.AllVms != nil { - return true - } - - return false -} - -// SetAllVms gets a reference to the given bool and assigns it to the AllVms field. -func (o *ReadVmsStateRequest) SetAllVms(v bool) { - o.AllVms = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVmsStateRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsStateRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVmsStateRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVmsStateRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVmsStateRequest) GetFilters() FiltersVmsState { - if o == nil || o.Filters == nil { - var ret FiltersVmsState - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsStateRequest) GetFiltersOk() (FiltersVmsState, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVmsState - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVmsStateRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVmsState and assigns it to the Filters field. -func (o *ReadVmsStateRequest) SetFilters(v FiltersVmsState) { - o.Filters = &v -} - -type NullableReadVmsStateRequest struct { - Value ReadVmsStateRequest - ExplicitNull bool -} - -func (v NullableReadVmsStateRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsStateRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_response.go deleted file mode 100644 index e91d51617..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vms_state_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVmsStateResponse struct for ReadVmsStateResponse -type ReadVmsStateResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more VM states. - VmStates *[]VmStates `json:"VmStates,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVmsStateResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsStateResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVmsStateResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVmsStateResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVmStates returns the VmStates field value if set, zero value otherwise. -func (o *ReadVmsStateResponse) GetVmStates() []VmStates { - if o == nil || o.VmStates == nil { - var ret []VmStates - return ret - } - return *o.VmStates -} - -// GetVmStatesOk returns a tuple with the VmStates field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVmsStateResponse) GetVmStatesOk() ([]VmStates, bool) { - if o == nil || o.VmStates == nil { - var ret []VmStates - return ret, false - } - return *o.VmStates, true -} - -// HasVmStates returns a boolean if a field has been set. -func (o *ReadVmsStateResponse) HasVmStates() bool { - if o != nil && o.VmStates != nil { - return true - } - - return false -} - -// SetVmStates gets a reference to the given []VmStates and assigns it to the VmStates field. -func (o *ReadVmsStateResponse) SetVmStates(v []VmStates) { - o.VmStates = &v -} - -type NullableReadVmsStateResponse struct { - Value ReadVmsStateResponse - ExplicitNull bool -} - -func (v NullableReadVmsStateResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVmsStateResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_request.go deleted file mode 100644 index 68d2d25c6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVolumesRequest struct for ReadVolumesRequest -type ReadVolumesRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVolume `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVolumesRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVolumesRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVolumesRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVolumesRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVolumesRequest) GetFilters() FiltersVolume { - if o == nil || o.Filters == nil { - var ret FiltersVolume - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVolumesRequest) GetFiltersOk() (FiltersVolume, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVolume - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVolumesRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVolume and assigns it to the Filters field. -func (o *ReadVolumesRequest) SetFilters(v FiltersVolume) { - o.Filters = &v -} - -type NullableReadVolumesRequest struct { - Value ReadVolumesRequest - ExplicitNull bool -} - -func (v NullableReadVolumesRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVolumesRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_response.go deleted file mode 100644 index 3c519f344..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_volumes_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVolumesResponse struct for ReadVolumesResponse -type ReadVolumesResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more volumes. - Volumes *[]Volume `json:"Volumes,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVolumesResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVolumesResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVolumesResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVolumesResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVolumes returns the Volumes field value if set, zero value otherwise. -func (o *ReadVolumesResponse) GetVolumes() []Volume { - if o == nil || o.Volumes == nil { - var ret []Volume - return ret - } - return *o.Volumes -} - -// GetVolumesOk returns a tuple with the Volumes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVolumesResponse) GetVolumesOk() ([]Volume, bool) { - if o == nil || o.Volumes == nil { - var ret []Volume - return ret, false - } - return *o.Volumes, true -} - -// HasVolumes returns a boolean if a field has been set. -func (o *ReadVolumesResponse) HasVolumes() bool { - if o != nil && o.Volumes != nil { - return true - } - - return false -} - -// SetVolumes gets a reference to the given []Volume and assigns it to the Volumes field. -func (o *ReadVolumesResponse) SetVolumes(v []Volume) { - o.Volumes = &v -} - -type NullableReadVolumesResponse struct { - Value ReadVolumesResponse - ExplicitNull bool -} - -func (v NullableReadVolumesResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVolumesResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_request.go deleted file mode 100644 index 0518a8112..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVpnConnectionsRequest struct for ReadVpnConnectionsRequest -type ReadVpnConnectionsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - Filters *FiltersVpnConnection `json:"Filters,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ReadVpnConnectionsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVpnConnectionsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ReadVpnConnectionsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ReadVpnConnectionsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFilters returns the Filters field value if set, zero value otherwise. -func (o *ReadVpnConnectionsRequest) GetFilters() FiltersVpnConnection { - if o == nil || o.Filters == nil { - var ret FiltersVpnConnection - return ret - } - return *o.Filters -} - -// GetFiltersOk returns a tuple with the Filters field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVpnConnectionsRequest) GetFiltersOk() (FiltersVpnConnection, bool) { - if o == nil || o.Filters == nil { - var ret FiltersVpnConnection - return ret, false - } - return *o.Filters, true -} - -// HasFilters returns a boolean if a field has been set. -func (o *ReadVpnConnectionsRequest) HasFilters() bool { - if o != nil && o.Filters != nil { - return true - } - - return false -} - -// SetFilters gets a reference to the given FiltersVpnConnection and assigns it to the Filters field. -func (o *ReadVpnConnectionsRequest) SetFilters(v FiltersVpnConnection) { - o.Filters = &v -} - -type NullableReadVpnConnectionsRequest struct { - Value ReadVpnConnectionsRequest - ExplicitNull bool -} - -func (v NullableReadVpnConnectionsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVpnConnectionsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_response.go deleted file mode 100644 index 471d5f3f1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_read_vpn_connections_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ReadVpnConnectionsResponse struct for ReadVpnConnectionsResponse -type ReadVpnConnectionsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more VPN connections. - VpnConnections *[]VpnConnection `json:"VpnConnections,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ReadVpnConnectionsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVpnConnectionsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ReadVpnConnectionsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ReadVpnConnectionsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVpnConnections returns the VpnConnections field value if set, zero value otherwise. -func (o *ReadVpnConnectionsResponse) GetVpnConnections() []VpnConnection { - if o == nil || o.VpnConnections == nil { - var ret []VpnConnection - return ret - } - return *o.VpnConnections -} - -// GetVpnConnectionsOk returns a tuple with the VpnConnections field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ReadVpnConnectionsResponse) GetVpnConnectionsOk() ([]VpnConnection, bool) { - if o == nil || o.VpnConnections == nil { - var ret []VpnConnection - return ret, false - } - return *o.VpnConnections, true -} - -// HasVpnConnections returns a boolean if a field has been set. -func (o *ReadVpnConnectionsResponse) HasVpnConnections() bool { - if o != nil && o.VpnConnections != nil { - return true - } - - return false -} - -// SetVpnConnections gets a reference to the given []VpnConnection and assigns it to the VpnConnections field. -func (o *ReadVpnConnectionsResponse) SetVpnConnections(v []VpnConnection) { - o.VpnConnections = &v -} - -type NullableReadVpnConnectionsResponse struct { - Value ReadVpnConnectionsResponse - ExplicitNull bool -} - -func (v NullableReadVpnConnectionsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableReadVpnConnectionsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_request.go deleted file mode 100644 index 8b1176573..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RebootVmsRequest struct for RebootVmsRequest -type RebootVmsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more IDs of the VMs you want to reboot. - VmIds []string `json:"VmIds"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *RebootVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RebootVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *RebootVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *RebootVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmIds returns the VmIds field value -func (o *RebootVmsRequest) GetVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.VmIds -} - -// SetVmIds sets field value -func (o *RebootVmsRequest) SetVmIds(v []string) { - o.VmIds = v -} - -type NullableRebootVmsRequest struct { - Value RebootVmsRequest - ExplicitNull bool -} - -func (v NullableRebootVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRebootVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_response.go deleted file mode 100644 index 2e933162d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reboot_vms_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RebootVmsResponse struct for RebootVmsResponse -type RebootVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *RebootVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RebootVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *RebootVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *RebootVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableRebootVmsResponse struct { - Value RebootVmsResponse - ExplicitNull bool -} - -func (v NullableRebootVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRebootVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_region.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_region.go deleted file mode 100644 index 26c5a9ef2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_region.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Region Information about the Region. -type Region struct { - // The hostname of the gateway to access the Region. - Endpoint *string `json:"Endpoint,omitempty"` - // The administrative name of the Region. - RegionName *string `json:"RegionName,omitempty"` -} - -// GetEndpoint returns the Endpoint field value if set, zero value otherwise. -func (o *Region) GetEndpoint() string { - if o == nil || o.Endpoint == nil { - var ret string - return ret - } - return *o.Endpoint -} - -// GetEndpointOk returns a tuple with the Endpoint field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Region) GetEndpointOk() (string, bool) { - if o == nil || o.Endpoint == nil { - var ret string - return ret, false - } - return *o.Endpoint, true -} - -// HasEndpoint returns a boolean if a field has been set. -func (o *Region) HasEndpoint() bool { - if o != nil && o.Endpoint != nil { - return true - } - - return false -} - -// SetEndpoint gets a reference to the given string and assigns it to the Endpoint field. -func (o *Region) SetEndpoint(v string) { - o.Endpoint = &v -} - -// GetRegionName returns the RegionName field value if set, zero value otherwise. -func (o *Region) GetRegionName() string { - if o == nil || o.RegionName == nil { - var ret string - return ret - } - return *o.RegionName -} - -// GetRegionNameOk returns a tuple with the RegionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Region) GetRegionNameOk() (string, bool) { - if o == nil || o.RegionName == nil { - var ret string - return ret, false - } - return *o.RegionName, true -} - -// HasRegionName returns a boolean if a field has been set. -func (o *Region) HasRegionName() bool { - if o != nil && o.RegionName != nil { - return true - } - - return false -} - -// SetRegionName gets a reference to the given string and assigns it to the RegionName field. -func (o *Region) SetRegionName(v string) { - o.RegionName = &v -} - -type NullableRegion struct { - Value Region - ExplicitNull bool -} - -func (v NullableRegion) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRegion) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_request.go deleted file mode 100644 index 27e8b2524..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RegisterVmsInLoadBalancerRequest struct for RegisterVmsInLoadBalancerRequest -type RegisterVmsInLoadBalancerRequest struct { - // One or more IDs of back-end VMs.
Specifying the same ID several times has no effect as each back-end VM has equal weight. - BackendVmIds []string `json:"BackendVmIds"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the load balancer. - LoadBalancerName string `json:"LoadBalancerName"` -} - -// GetBackendVmIds returns the BackendVmIds field value -func (o *RegisterVmsInLoadBalancerRequest) GetBackendVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.BackendVmIds -} - -// SetBackendVmIds sets field value -func (o *RegisterVmsInLoadBalancerRequest) SetBackendVmIds(v []string) { - o.BackendVmIds = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *RegisterVmsInLoadBalancerRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RegisterVmsInLoadBalancerRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *RegisterVmsInLoadBalancerRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *RegisterVmsInLoadBalancerRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *RegisterVmsInLoadBalancerRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *RegisterVmsInLoadBalancerRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -type NullableRegisterVmsInLoadBalancerRequest struct { - Value RegisterVmsInLoadBalancerRequest - ExplicitNull bool -} - -func (v NullableRegisterVmsInLoadBalancerRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRegisterVmsInLoadBalancerRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_response.go deleted file mode 100644 index be9a4382f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_register_vms_in_load_balancer_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RegisterVmsInLoadBalancerResponse struct for RegisterVmsInLoadBalancerResponse -type RegisterVmsInLoadBalancerResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *RegisterVmsInLoadBalancerResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RegisterVmsInLoadBalancerResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *RegisterVmsInLoadBalancerResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *RegisterVmsInLoadBalancerResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableRegisterVmsInLoadBalancerResponse struct { - Value RegisterVmsInLoadBalancerResponse - ExplicitNull bool -} - -func (v NullableRegisterVmsInLoadBalancerResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRegisterVmsInLoadBalancerResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_request.go deleted file mode 100644 index bf2c5682c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RejectNetPeeringRequest struct for RejectNetPeeringRequest -type RejectNetPeeringRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net peering connection you want to reject. - NetPeeringId string `json:"NetPeeringId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *RejectNetPeeringRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RejectNetPeeringRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *RejectNetPeeringRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *RejectNetPeeringRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetPeeringId returns the NetPeeringId field value -func (o *RejectNetPeeringRequest) GetNetPeeringId() string { - if o == nil { - var ret string - return ret - } - - return o.NetPeeringId -} - -// SetNetPeeringId sets field value -func (o *RejectNetPeeringRequest) SetNetPeeringId(v string) { - o.NetPeeringId = v -} - -type NullableRejectNetPeeringRequest struct { - Value RejectNetPeeringRequest - ExplicitNull bool -} - -func (v NullableRejectNetPeeringRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRejectNetPeeringRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_response.go deleted file mode 100644 index db194a406..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reject_net_peering_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RejectNetPeeringResponse struct for RejectNetPeeringResponse -type RejectNetPeeringResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *RejectNetPeeringResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RejectNetPeeringResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *RejectNetPeeringResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *RejectNetPeeringResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableRejectNetPeeringResponse struct { - Value RejectNetPeeringResponse - ExplicitNull bool -} - -func (v NullableRejectNetPeeringResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRejectNetPeeringResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_request.go deleted file mode 100644 index 3e9996aa7..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ResetAccountPasswordRequest struct for ResetAccountPasswordRequest -type ResetAccountPasswordRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The new password for the account. - Password string `json:"Password"` - // The token you received at the email address provided for the account. - Token string `json:"Token"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *ResetAccountPasswordRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ResetAccountPasswordRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *ResetAccountPasswordRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *ResetAccountPasswordRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPassword returns the Password field value -func (o *ResetAccountPasswordRequest) GetPassword() string { - if o == nil { - var ret string - return ret - } - - return o.Password -} - -// SetPassword sets field value -func (o *ResetAccountPasswordRequest) SetPassword(v string) { - o.Password = v -} - -// GetToken returns the Token field value -func (o *ResetAccountPasswordRequest) GetToken() string { - if o == nil { - var ret string - return ret - } - - return o.Token -} - -// SetToken sets field value -func (o *ResetAccountPasswordRequest) SetToken(v string) { - o.Token = v -} - -type NullableResetAccountPasswordRequest struct { - Value ResetAccountPasswordRequest - ExplicitNull bool -} - -func (v NullableResetAccountPasswordRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableResetAccountPasswordRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_response.go deleted file mode 100644 index edf0a1f41..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_reset_account_password_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ResetAccountPasswordResponse struct for ResetAccountPasswordResponse -type ResetAccountPasswordResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *ResetAccountPasswordResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ResetAccountPasswordResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *ResetAccountPasswordResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *ResetAccountPasswordResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableResetAccountPasswordResponse struct { - Value ResetAccountPasswordResponse - ExplicitNull bool -} - -func (v NullableResetAccountPasswordResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableResetAccountPasswordResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_load_balancer_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_load_balancer_tag.go deleted file mode 100644 index 5b69c6aa1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_load_balancer_tag.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ResourceLoadBalancerTag Information about the tag. -type ResourceLoadBalancerTag struct { - // The key of the tag, with a minimum of 1 character. - Key *string `json:"Key,omitempty"` -} - -// GetKey returns the Key field value if set, zero value otherwise. -func (o *ResourceLoadBalancerTag) GetKey() string { - if o == nil || o.Key == nil { - var ret string - return ret - } - return *o.Key -} - -// GetKeyOk returns a tuple with the Key field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ResourceLoadBalancerTag) GetKeyOk() (string, bool) { - if o == nil || o.Key == nil { - var ret string - return ret, false - } - return *o.Key, true -} - -// HasKey returns a boolean if a field has been set. -func (o *ResourceLoadBalancerTag) HasKey() bool { - if o != nil && o.Key != nil { - return true - } - - return false -} - -// SetKey gets a reference to the given string and assigns it to the Key field. -func (o *ResourceLoadBalancerTag) SetKey(v string) { - o.Key = &v -} - -type NullableResourceLoadBalancerTag struct { - Value ResourceLoadBalancerTag - ExplicitNull bool -} - -func (v NullableResourceLoadBalancerTag) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableResourceLoadBalancerTag) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_tag.go deleted file mode 100644 index 56a992c58..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_resource_tag.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ResourceTag Information about the tag. -type ResourceTag struct { - // The key of the tag, with a minimum of 1 character. - Key string `json:"Key"` - // The value of the tag, between 0 and 255 characters. - Value string `json:"Value"` -} - -// GetKey returns the Key field value -func (o *ResourceTag) GetKey() string { - if o == nil { - var ret string - return ret - } - - return o.Key -} - -// SetKey sets field value -func (o *ResourceTag) SetKey(v string) { - o.Key = v -} - -// GetValue returns the Value field value -func (o *ResourceTag) GetValue() string { - if o == nil { - var ret string - return ret - } - - return o.Value -} - -// SetValue sets field value -func (o *ResourceTag) SetValue(v string) { - o.Value = v -} - -type NullableResourceTag struct { - Value ResourceTag - ExplicitNull bool -} - -func (v NullableResourceTag) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableResourceTag) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_response_context.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_response_context.go deleted file mode 100644 index 5492a2172..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_response_context.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ResponseContext Information about the context of the response. -type ResponseContext struct { - // The ID of the request. - RequestId *string `json:"RequestId,omitempty"` -} - -// GetRequestId returns the RequestId field value if set, zero value otherwise. -func (o *ResponseContext) GetRequestId() string { - if o == nil || o.RequestId == nil { - var ret string - return ret - } - return *o.RequestId -} - -// GetRequestIdOk returns a tuple with the RequestId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ResponseContext) GetRequestIdOk() (string, bool) { - if o == nil || o.RequestId == nil { - var ret string - return ret, false - } - return *o.RequestId, true -} - -// HasRequestId returns a boolean if a field has been set. -func (o *ResponseContext) HasRequestId() bool { - if o != nil && o.RequestId != nil { - return true - } - - return false -} - -// SetRequestId gets a reference to the given string and assigns it to the RequestId field. -func (o *ResponseContext) SetRequestId(v string) { - o.RequestId = &v -} - -type NullableResponseContext struct { - Value ResponseContext - ExplicitNull bool -} - -func (v NullableResponseContext) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableResponseContext) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_route.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_route.go deleted file mode 100644 index 56c981180..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_route.go +++ /dev/null @@ -1,428 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Route Information about the route. -type Route struct { - // The method used to create the route. - CreationMethod *string `json:"CreationMethod,omitempty"` - // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - DestinationIpRange *string `json:"DestinationIpRange,omitempty"` - // The ID of the 3DS OUTSCALE service. - DestinationServiceId *string `json:"DestinationServiceId,omitempty"` - // The ID of the Internet service or virtual gateway attached to the Net. - GatewayId *string `json:"GatewayId,omitempty"` - // The ID of a NAT service attached to the Net. - NatServiceId *string `json:"NatServiceId,omitempty"` - // The ID of the Net access point. - NetAccessPointId *string `json:"NetAccessPointId,omitempty"` - // The ID of the Net peering connection. - NetPeeringId *string `json:"NetPeeringId,omitempty"` - // The ID of the NIC. - NicId *string `json:"NicId,omitempty"` - // The state of a route in the route table (`active` \\| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - State *string `json:"State,omitempty"` - // The account ID of the owner of the VM. - VmAccountId *string `json:"VmAccountId,omitempty"` - // The ID of a VM specified in a route in the table. - VmId *string `json:"VmId,omitempty"` -} - -// GetCreationMethod returns the CreationMethod field value if set, zero value otherwise. -func (o *Route) GetCreationMethod() string { - if o == nil || o.CreationMethod == nil { - var ret string - return ret - } - return *o.CreationMethod -} - -// GetCreationMethodOk returns a tuple with the CreationMethod field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetCreationMethodOk() (string, bool) { - if o == nil || o.CreationMethod == nil { - var ret string - return ret, false - } - return *o.CreationMethod, true -} - -// HasCreationMethod returns a boolean if a field has been set. -func (o *Route) HasCreationMethod() bool { - if o != nil && o.CreationMethod != nil { - return true - } - - return false -} - -// SetCreationMethod gets a reference to the given string and assigns it to the CreationMethod field. -func (o *Route) SetCreationMethod(v string) { - o.CreationMethod = &v -} - -// GetDestinationIpRange returns the DestinationIpRange field value if set, zero value otherwise. -func (o *Route) GetDestinationIpRange() string { - if o == nil || o.DestinationIpRange == nil { - var ret string - return ret - } - return *o.DestinationIpRange -} - -// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetDestinationIpRangeOk() (string, bool) { - if o == nil || o.DestinationIpRange == nil { - var ret string - return ret, false - } - return *o.DestinationIpRange, true -} - -// HasDestinationIpRange returns a boolean if a field has been set. -func (o *Route) HasDestinationIpRange() bool { - if o != nil && o.DestinationIpRange != nil { - return true - } - - return false -} - -// SetDestinationIpRange gets a reference to the given string and assigns it to the DestinationIpRange field. -func (o *Route) SetDestinationIpRange(v string) { - o.DestinationIpRange = &v -} - -// GetDestinationServiceId returns the DestinationServiceId field value if set, zero value otherwise. -func (o *Route) GetDestinationServiceId() string { - if o == nil || o.DestinationServiceId == nil { - var ret string - return ret - } - return *o.DestinationServiceId -} - -// GetDestinationServiceIdOk returns a tuple with the DestinationServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetDestinationServiceIdOk() (string, bool) { - if o == nil || o.DestinationServiceId == nil { - var ret string - return ret, false - } - return *o.DestinationServiceId, true -} - -// HasDestinationServiceId returns a boolean if a field has been set. -func (o *Route) HasDestinationServiceId() bool { - if o != nil && o.DestinationServiceId != nil { - return true - } - - return false -} - -// SetDestinationServiceId gets a reference to the given string and assigns it to the DestinationServiceId field. -func (o *Route) SetDestinationServiceId(v string) { - o.DestinationServiceId = &v -} - -// GetGatewayId returns the GatewayId field value if set, zero value otherwise. -func (o *Route) GetGatewayId() string { - if o == nil || o.GatewayId == nil { - var ret string - return ret - } - return *o.GatewayId -} - -// GetGatewayIdOk returns a tuple with the GatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetGatewayIdOk() (string, bool) { - if o == nil || o.GatewayId == nil { - var ret string - return ret, false - } - return *o.GatewayId, true -} - -// HasGatewayId returns a boolean if a field has been set. -func (o *Route) HasGatewayId() bool { - if o != nil && o.GatewayId != nil { - return true - } - - return false -} - -// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. -func (o *Route) SetGatewayId(v string) { - o.GatewayId = &v -} - -// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. -func (o *Route) GetNatServiceId() string { - if o == nil || o.NatServiceId == nil { - var ret string - return ret - } - return *o.NatServiceId -} - -// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetNatServiceIdOk() (string, bool) { - if o == nil || o.NatServiceId == nil { - var ret string - return ret, false - } - return *o.NatServiceId, true -} - -// HasNatServiceId returns a boolean if a field has been set. -func (o *Route) HasNatServiceId() bool { - if o != nil && o.NatServiceId != nil { - return true - } - - return false -} - -// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. -func (o *Route) SetNatServiceId(v string) { - o.NatServiceId = &v -} - -// GetNetAccessPointId returns the NetAccessPointId field value if set, zero value otherwise. -func (o *Route) GetNetAccessPointId() string { - if o == nil || o.NetAccessPointId == nil { - var ret string - return ret - } - return *o.NetAccessPointId -} - -// GetNetAccessPointIdOk returns a tuple with the NetAccessPointId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetNetAccessPointIdOk() (string, bool) { - if o == nil || o.NetAccessPointId == nil { - var ret string - return ret, false - } - return *o.NetAccessPointId, true -} - -// HasNetAccessPointId returns a boolean if a field has been set. -func (o *Route) HasNetAccessPointId() bool { - if o != nil && o.NetAccessPointId != nil { - return true - } - - return false -} - -// SetNetAccessPointId gets a reference to the given string and assigns it to the NetAccessPointId field. -func (o *Route) SetNetAccessPointId(v string) { - o.NetAccessPointId = &v -} - -// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. -func (o *Route) GetNetPeeringId() string { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret - } - return *o.NetPeeringId -} - -// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetNetPeeringIdOk() (string, bool) { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret, false - } - return *o.NetPeeringId, true -} - -// HasNetPeeringId returns a boolean if a field has been set. -func (o *Route) HasNetPeeringId() bool { - if o != nil && o.NetPeeringId != nil { - return true - } - - return false -} - -// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. -func (o *Route) SetNetPeeringId(v string) { - o.NetPeeringId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *Route) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *Route) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *Route) SetNicId(v string) { - o.NicId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Route) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Route) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Route) SetState(v string) { - o.State = &v -} - -// GetVmAccountId returns the VmAccountId field value if set, zero value otherwise. -func (o *Route) GetVmAccountId() string { - if o == nil || o.VmAccountId == nil { - var ret string - return ret - } - return *o.VmAccountId -} - -// GetVmAccountIdOk returns a tuple with the VmAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetVmAccountIdOk() (string, bool) { - if o == nil || o.VmAccountId == nil { - var ret string - return ret, false - } - return *o.VmAccountId, true -} - -// HasVmAccountId returns a boolean if a field has been set. -func (o *Route) HasVmAccountId() bool { - if o != nil && o.VmAccountId != nil { - return true - } - - return false -} - -// SetVmAccountId gets a reference to the given string and assigns it to the VmAccountId field. -func (o *Route) SetVmAccountId(v string) { - o.VmAccountId = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *Route) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Route) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *Route) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *Route) SetVmId(v string) { - o.VmId = &v -} - -type NullableRoute struct { - Value Route - ExplicitNull bool -} - -func (v NullableRoute) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRoute) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_route_light.go deleted file mode 100644 index 239c83eb1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_light.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RouteLight Information about the route. -type RouteLight struct { - // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - DestinationIpRange *string `json:"DestinationIpRange,omitempty"` - // The type of route (always `static`). - RouteType *string `json:"RouteType,omitempty"` - // The current state of the static route (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value if set, zero value otherwise. -func (o *RouteLight) GetDestinationIpRange() string { - if o == nil || o.DestinationIpRange == nil { - var ret string - return ret - } - return *o.DestinationIpRange -} - -// GetDestinationIpRangeOk returns a tuple with the DestinationIpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteLight) GetDestinationIpRangeOk() (string, bool) { - if o == nil || o.DestinationIpRange == nil { - var ret string - return ret, false - } - return *o.DestinationIpRange, true -} - -// HasDestinationIpRange returns a boolean if a field has been set. -func (o *RouteLight) HasDestinationIpRange() bool { - if o != nil && o.DestinationIpRange != nil { - return true - } - - return false -} - -// SetDestinationIpRange gets a reference to the given string and assigns it to the DestinationIpRange field. -func (o *RouteLight) SetDestinationIpRange(v string) { - o.DestinationIpRange = &v -} - -// GetRouteType returns the RouteType field value if set, zero value otherwise. -func (o *RouteLight) GetRouteType() string { - if o == nil || o.RouteType == nil { - var ret string - return ret - } - return *o.RouteType -} - -// GetRouteTypeOk returns a tuple with the RouteType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteLight) GetRouteTypeOk() (string, bool) { - if o == nil || o.RouteType == nil { - var ret string - return ret, false - } - return *o.RouteType, true -} - -// HasRouteType returns a boolean if a field has been set. -func (o *RouteLight) HasRouteType() bool { - if o != nil && o.RouteType != nil { - return true - } - - return false -} - -// SetRouteType gets a reference to the given string and assigns it to the RouteType field. -func (o *RouteLight) SetRouteType(v string) { - o.RouteType = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *RouteLight) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteLight) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *RouteLight) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *RouteLight) SetState(v string) { - o.State = &v -} - -type NullableRouteLight struct { - Value RouteLight - ExplicitNull bool -} - -func (v NullableRouteLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRouteLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_propagating_virtual_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_route_propagating_virtual_gateway.go deleted file mode 100644 index 043519a15..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_propagating_virtual_gateway.go +++ /dev/null @@ -1,78 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RoutePropagatingVirtualGateway Information about the route propagating virtual gateway. -type RoutePropagatingVirtualGateway struct { - // The ID of the virtual gateway. - VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. -func (o *RoutePropagatingVirtualGateway) GetVirtualGatewayId() string { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret - } - return *o.VirtualGatewayId -} - -// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RoutePropagatingVirtualGateway) GetVirtualGatewayIdOk() (string, bool) { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret, false - } - return *o.VirtualGatewayId, true -} - -// HasVirtualGatewayId returns a boolean if a field has been set. -func (o *RoutePropagatingVirtualGateway) HasVirtualGatewayId() bool { - if o != nil && o.VirtualGatewayId != nil { - return true - } - - return false -} - -// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. -func (o *RoutePropagatingVirtualGateway) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = &v -} - -type NullableRoutePropagatingVirtualGateway struct { - Value RoutePropagatingVirtualGateway - ExplicitNull bool -} - -func (v NullableRoutePropagatingVirtualGateway) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRoutePropagatingVirtualGateway) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_table.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_route_table.go deleted file mode 100644 index 9ab0ef8d2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_route_table.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// RouteTable Information about the route table. -type RouteTable struct { - // One or more associations between the route table and Subnets. - LinkRouteTables *[]LinkRouteTable `json:"LinkRouteTables,omitempty"` - // The ID of the Net for the route table. - NetId *string `json:"NetId,omitempty"` - // Information about virtual gateways propagating routes. - RoutePropagatingVirtualGateways *[]RoutePropagatingVirtualGateway `json:"RoutePropagatingVirtualGateways,omitempty"` - // The ID of the route table. - RouteTableId *string `json:"RouteTableId,omitempty"` - // One or more routes in the route table. - Routes *[]Route `json:"Routes,omitempty"` - // One or more tags associated with the route table. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetLinkRouteTables returns the LinkRouteTables field value if set, zero value otherwise. -func (o *RouteTable) GetLinkRouteTables() []LinkRouteTable { - if o == nil || o.LinkRouteTables == nil { - var ret []LinkRouteTable - return ret - } - return *o.LinkRouteTables -} - -// GetLinkRouteTablesOk returns a tuple with the LinkRouteTables field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetLinkRouteTablesOk() ([]LinkRouteTable, bool) { - if o == nil || o.LinkRouteTables == nil { - var ret []LinkRouteTable - return ret, false - } - return *o.LinkRouteTables, true -} - -// HasLinkRouteTables returns a boolean if a field has been set. -func (o *RouteTable) HasLinkRouteTables() bool { - if o != nil && o.LinkRouteTables != nil { - return true - } - - return false -} - -// SetLinkRouteTables gets a reference to the given []LinkRouteTable and assigns it to the LinkRouteTables field. -func (o *RouteTable) SetLinkRouteTables(v []LinkRouteTable) { - o.LinkRouteTables = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *RouteTable) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *RouteTable) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *RouteTable) SetNetId(v string) { - o.NetId = &v -} - -// GetRoutePropagatingVirtualGateways returns the RoutePropagatingVirtualGateways field value if set, zero value otherwise. -func (o *RouteTable) GetRoutePropagatingVirtualGateways() []RoutePropagatingVirtualGateway { - if o == nil || o.RoutePropagatingVirtualGateways == nil { - var ret []RoutePropagatingVirtualGateway - return ret - } - return *o.RoutePropagatingVirtualGateways -} - -// GetRoutePropagatingVirtualGatewaysOk returns a tuple with the RoutePropagatingVirtualGateways field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetRoutePropagatingVirtualGatewaysOk() ([]RoutePropagatingVirtualGateway, bool) { - if o == nil || o.RoutePropagatingVirtualGateways == nil { - var ret []RoutePropagatingVirtualGateway - return ret, false - } - return *o.RoutePropagatingVirtualGateways, true -} - -// HasRoutePropagatingVirtualGateways returns a boolean if a field has been set. -func (o *RouteTable) HasRoutePropagatingVirtualGateways() bool { - if o != nil && o.RoutePropagatingVirtualGateways != nil { - return true - } - - return false -} - -// SetRoutePropagatingVirtualGateways gets a reference to the given []RoutePropagatingVirtualGateway and assigns it to the RoutePropagatingVirtualGateways field. -func (o *RouteTable) SetRoutePropagatingVirtualGateways(v []RoutePropagatingVirtualGateway) { - o.RoutePropagatingVirtualGateways = &v -} - -// GetRouteTableId returns the RouteTableId field value if set, zero value otherwise. -func (o *RouteTable) GetRouteTableId() string { - if o == nil || o.RouteTableId == nil { - var ret string - return ret - } - return *o.RouteTableId -} - -// GetRouteTableIdOk returns a tuple with the RouteTableId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetRouteTableIdOk() (string, bool) { - if o == nil || o.RouteTableId == nil { - var ret string - return ret, false - } - return *o.RouteTableId, true -} - -// HasRouteTableId returns a boolean if a field has been set. -func (o *RouteTable) HasRouteTableId() bool { - if o != nil && o.RouteTableId != nil { - return true - } - - return false -} - -// SetRouteTableId gets a reference to the given string and assigns it to the RouteTableId field. -func (o *RouteTable) SetRouteTableId(v string) { - o.RouteTableId = &v -} - -// GetRoutes returns the Routes field value if set, zero value otherwise. -func (o *RouteTable) GetRoutes() []Route { - if o == nil || o.Routes == nil { - var ret []Route - return ret - } - return *o.Routes -} - -// GetRoutesOk returns a tuple with the Routes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetRoutesOk() ([]Route, bool) { - if o == nil || o.Routes == nil { - var ret []Route - return ret, false - } - return *o.Routes, true -} - -// HasRoutes returns a boolean if a field has been set. -func (o *RouteTable) HasRoutes() bool { - if o != nil && o.Routes != nil { - return true - } - - return false -} - -// SetRoutes gets a reference to the given []Route and assigns it to the Routes field. -func (o *RouteTable) SetRoutes(v []Route) { - o.Routes = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *RouteTable) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *RouteTable) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *RouteTable) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *RouteTable) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableRouteTable struct { - Value RouteTable - ExplicitNull bool -} - -func (v NullableRouteTable) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableRouteTable) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group.go deleted file mode 100644 index 7176763a6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SecurityGroup Information about the security group. -type SecurityGroup struct { - // The account ID of a user that has been granted permission. - AccountId *string `json:"AccountId,omitempty"` - // The description of the security group. - Description *string `json:"Description,omitempty"` - // The inbound rules associated with the security group. - InboundRules *[]SecurityGroupRule `json:"InboundRules,omitempty"` - // The ID of the Net for the security group. - NetId *string `json:"NetId,omitempty"` - // The outbound rules associated with the security group. - OutboundRules *[]SecurityGroupRule `json:"OutboundRules,omitempty"` - // The ID of the security group. - SecurityGroupId *string `json:"SecurityGroupId,omitempty"` - // (Public Cloud only) The name of the security group. - SecurityGroupName *string `json:"SecurityGroupName,omitempty"` - // One or more tags associated with the security group. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *SecurityGroup) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *SecurityGroup) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *SecurityGroup) SetAccountId(v string) { - o.AccountId = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *SecurityGroup) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *SecurityGroup) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *SecurityGroup) SetDescription(v string) { - o.Description = &v -} - -// GetInboundRules returns the InboundRules field value if set, zero value otherwise. -func (o *SecurityGroup) GetInboundRules() []SecurityGroupRule { - if o == nil || o.InboundRules == nil { - var ret []SecurityGroupRule - return ret - } - return *o.InboundRules -} - -// GetInboundRulesOk returns a tuple with the InboundRules field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetInboundRulesOk() ([]SecurityGroupRule, bool) { - if o == nil || o.InboundRules == nil { - var ret []SecurityGroupRule - return ret, false - } - return *o.InboundRules, true -} - -// HasInboundRules returns a boolean if a field has been set. -func (o *SecurityGroup) HasInboundRules() bool { - if o != nil && o.InboundRules != nil { - return true - } - - return false -} - -// SetInboundRules gets a reference to the given []SecurityGroupRule and assigns it to the InboundRules field. -func (o *SecurityGroup) SetInboundRules(v []SecurityGroupRule) { - o.InboundRules = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *SecurityGroup) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *SecurityGroup) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *SecurityGroup) SetNetId(v string) { - o.NetId = &v -} - -// GetOutboundRules returns the OutboundRules field value if set, zero value otherwise. -func (o *SecurityGroup) GetOutboundRules() []SecurityGroupRule { - if o == nil || o.OutboundRules == nil { - var ret []SecurityGroupRule - return ret - } - return *o.OutboundRules -} - -// GetOutboundRulesOk returns a tuple with the OutboundRules field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetOutboundRulesOk() ([]SecurityGroupRule, bool) { - if o == nil || o.OutboundRules == nil { - var ret []SecurityGroupRule - return ret, false - } - return *o.OutboundRules, true -} - -// HasOutboundRules returns a boolean if a field has been set. -func (o *SecurityGroup) HasOutboundRules() bool { - if o != nil && o.OutboundRules != nil { - return true - } - - return false -} - -// SetOutboundRules gets a reference to the given []SecurityGroupRule and assigns it to the OutboundRules field. -func (o *SecurityGroup) SetOutboundRules(v []SecurityGroupRule) { - o.OutboundRules = &v -} - -// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. -func (o *SecurityGroup) GetSecurityGroupId() string { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret - } - return *o.SecurityGroupId -} - -// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetSecurityGroupIdOk() (string, bool) { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret, false - } - return *o.SecurityGroupId, true -} - -// HasSecurityGroupId returns a boolean if a field has been set. -func (o *SecurityGroup) HasSecurityGroupId() bool { - if o != nil && o.SecurityGroupId != nil { - return true - } - - return false -} - -// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. -func (o *SecurityGroup) SetSecurityGroupId(v string) { - o.SecurityGroupId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. -func (o *SecurityGroup) GetSecurityGroupName() string { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret - } - return *o.SecurityGroupName -} - -// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetSecurityGroupNameOk() (string, bool) { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret, false - } - return *o.SecurityGroupName, true -} - -// HasSecurityGroupName returns a boolean if a field has been set. -func (o *SecurityGroup) HasSecurityGroupName() bool { - if o != nil && o.SecurityGroupName != nil { - return true - } - - return false -} - -// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. -func (o *SecurityGroup) SetSecurityGroupName(v string) { - o.SecurityGroupName = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *SecurityGroup) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroup) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *SecurityGroup) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *SecurityGroup) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableSecurityGroup struct { - Value SecurityGroup - ExplicitNull bool -} - -func (v NullableSecurityGroup) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSecurityGroup) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_light.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_light.go deleted file mode 100644 index 5d9aea2ae..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_light.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SecurityGroupLight Information about the security group. -type SecurityGroupLight struct { - // The ID of the security group. - SecurityGroupId *string `json:"SecurityGroupId,omitempty"` - // (Public Cloud only) The name of the security group. - SecurityGroupName *string `json:"SecurityGroupName,omitempty"` -} - -// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. -func (o *SecurityGroupLight) GetSecurityGroupId() string { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret - } - return *o.SecurityGroupId -} - -// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupLight) GetSecurityGroupIdOk() (string, bool) { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret, false - } - return *o.SecurityGroupId, true -} - -// HasSecurityGroupId returns a boolean if a field has been set. -func (o *SecurityGroupLight) HasSecurityGroupId() bool { - if o != nil && o.SecurityGroupId != nil { - return true - } - - return false -} - -// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. -func (o *SecurityGroupLight) SetSecurityGroupId(v string) { - o.SecurityGroupId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. -func (o *SecurityGroupLight) GetSecurityGroupName() string { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret - } - return *o.SecurityGroupName -} - -// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupLight) GetSecurityGroupNameOk() (string, bool) { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret, false - } - return *o.SecurityGroupName, true -} - -// HasSecurityGroupName returns a boolean if a field has been set. -func (o *SecurityGroupLight) HasSecurityGroupName() bool { - if o != nil && o.SecurityGroupName != nil { - return true - } - - return false -} - -// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. -func (o *SecurityGroupLight) SetSecurityGroupName(v string) { - o.SecurityGroupName = &v -} - -type NullableSecurityGroupLight struct { - Value SecurityGroupLight - ExplicitNull bool -} - -func (v NullableSecurityGroupLight) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSecurityGroupLight) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_rule.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_rule.go deleted file mode 100644 index 20192ad22..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_group_rule.go +++ /dev/null @@ -1,253 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SecurityGroupRule Information about the security group rule. -type SecurityGroupRule struct { - // The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - FromPortRange *int64 `json:"FromPortRange,omitempty"` - // The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - IpProtocol *string `json:"IpProtocol,omitempty"` - // One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - IpRanges *[]string `json:"IpRanges,omitempty"` - // Information about one or more members of a security group. - SecurityGroupsMembers *[]SecurityGroupsMember `json:"SecurityGroupsMembers,omitempty"` - // One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](#readnetaccesspointservices). - ServiceIds *[]string `json:"ServiceIds,omitempty"` - // The end of the port range for the TCP and UDP protocols, or an ICMP type number. - ToPortRange *int64 `json:"ToPortRange,omitempty"` -} - -// GetFromPortRange returns the FromPortRange field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetFromPortRange() int64 { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret - } - return *o.FromPortRange -} - -// GetFromPortRangeOk returns a tuple with the FromPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetFromPortRangeOk() (int64, bool) { - if o == nil || o.FromPortRange == nil { - var ret int64 - return ret, false - } - return *o.FromPortRange, true -} - -// HasFromPortRange returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasFromPortRange() bool { - if o != nil && o.FromPortRange != nil { - return true - } - - return false -} - -// SetFromPortRange gets a reference to the given int64 and assigns it to the FromPortRange field. -func (o *SecurityGroupRule) SetFromPortRange(v int64) { - o.FromPortRange = &v -} - -// GetIpProtocol returns the IpProtocol field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetIpProtocol() string { - if o == nil || o.IpProtocol == nil { - var ret string - return ret - } - return *o.IpProtocol -} - -// GetIpProtocolOk returns a tuple with the IpProtocol field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetIpProtocolOk() (string, bool) { - if o == nil || o.IpProtocol == nil { - var ret string - return ret, false - } - return *o.IpProtocol, true -} - -// HasIpProtocol returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasIpProtocol() bool { - if o != nil && o.IpProtocol != nil { - return true - } - - return false -} - -// SetIpProtocol gets a reference to the given string and assigns it to the IpProtocol field. -func (o *SecurityGroupRule) SetIpProtocol(v string) { - o.IpProtocol = &v -} - -// GetIpRanges returns the IpRanges field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetIpRanges() []string { - if o == nil || o.IpRanges == nil { - var ret []string - return ret - } - return *o.IpRanges -} - -// GetIpRangesOk returns a tuple with the IpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetIpRangesOk() ([]string, bool) { - if o == nil || o.IpRanges == nil { - var ret []string - return ret, false - } - return *o.IpRanges, true -} - -// HasIpRanges returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasIpRanges() bool { - if o != nil && o.IpRanges != nil { - return true - } - - return false -} - -// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. -func (o *SecurityGroupRule) SetIpRanges(v []string) { - o.IpRanges = &v -} - -// GetSecurityGroupsMembers returns the SecurityGroupsMembers field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetSecurityGroupsMembers() []SecurityGroupsMember { - if o == nil || o.SecurityGroupsMembers == nil { - var ret []SecurityGroupsMember - return ret - } - return *o.SecurityGroupsMembers -} - -// GetSecurityGroupsMembersOk returns a tuple with the SecurityGroupsMembers field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetSecurityGroupsMembersOk() ([]SecurityGroupsMember, bool) { - if o == nil || o.SecurityGroupsMembers == nil { - var ret []SecurityGroupsMember - return ret, false - } - return *o.SecurityGroupsMembers, true -} - -// HasSecurityGroupsMembers returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasSecurityGroupsMembers() bool { - if o != nil && o.SecurityGroupsMembers != nil { - return true - } - - return false -} - -// SetSecurityGroupsMembers gets a reference to the given []SecurityGroupsMember and assigns it to the SecurityGroupsMembers field. -func (o *SecurityGroupRule) SetSecurityGroupsMembers(v []SecurityGroupsMember) { - o.SecurityGroupsMembers = &v -} - -// GetServiceIds returns the ServiceIds field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetServiceIds() []string { - if o == nil || o.ServiceIds == nil { - var ret []string - return ret - } - return *o.ServiceIds -} - -// GetServiceIdsOk returns a tuple with the ServiceIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetServiceIdsOk() ([]string, bool) { - if o == nil || o.ServiceIds == nil { - var ret []string - return ret, false - } - return *o.ServiceIds, true -} - -// HasServiceIds returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasServiceIds() bool { - if o != nil && o.ServiceIds != nil { - return true - } - - return false -} - -// SetServiceIds gets a reference to the given []string and assigns it to the ServiceIds field. -func (o *SecurityGroupRule) SetServiceIds(v []string) { - o.ServiceIds = &v -} - -// GetToPortRange returns the ToPortRange field value if set, zero value otherwise. -func (o *SecurityGroupRule) GetToPortRange() int64 { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret - } - return *o.ToPortRange -} - -// GetToPortRangeOk returns a tuple with the ToPortRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupRule) GetToPortRangeOk() (int64, bool) { - if o == nil || o.ToPortRange == nil { - var ret int64 - return ret, false - } - return *o.ToPortRange, true -} - -// HasToPortRange returns a boolean if a field has been set. -func (o *SecurityGroupRule) HasToPortRange() bool { - if o != nil && o.ToPortRange != nil { - return true - } - - return false -} - -// SetToPortRange gets a reference to the given int64 and assigns it to the ToPortRange field. -func (o *SecurityGroupRule) SetToPortRange(v int64) { - o.ToPortRange = &v -} - -type NullableSecurityGroupRule struct { - Value SecurityGroupRule - ExplicitNull bool -} - -func (v NullableSecurityGroupRule) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSecurityGroupRule) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_groups_member.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_security_groups_member.go deleted file mode 100644 index f088d46ad..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_security_groups_member.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SecurityGroupsMember Information about the member of a security group. -type SecurityGroupsMember struct { - // The account ID of a user. - AccountId *string `json:"AccountId,omitempty"` - // The ID of the security group. - SecurityGroupId *string `json:"SecurityGroupId,omitempty"` - // (Public Cloud only) The name of the security group. - SecurityGroupName *string `json:"SecurityGroupName,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *SecurityGroupsMember) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupsMember) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *SecurityGroupsMember) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *SecurityGroupsMember) SetAccountId(v string) { - o.AccountId = &v -} - -// GetSecurityGroupId returns the SecurityGroupId field value if set, zero value otherwise. -func (o *SecurityGroupsMember) GetSecurityGroupId() string { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret - } - return *o.SecurityGroupId -} - -// GetSecurityGroupIdOk returns a tuple with the SecurityGroupId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupsMember) GetSecurityGroupIdOk() (string, bool) { - if o == nil || o.SecurityGroupId == nil { - var ret string - return ret, false - } - return *o.SecurityGroupId, true -} - -// HasSecurityGroupId returns a boolean if a field has been set. -func (o *SecurityGroupsMember) HasSecurityGroupId() bool { - if o != nil && o.SecurityGroupId != nil { - return true - } - - return false -} - -// SetSecurityGroupId gets a reference to the given string and assigns it to the SecurityGroupId field. -func (o *SecurityGroupsMember) SetSecurityGroupId(v string) { - o.SecurityGroupId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. -func (o *SecurityGroupsMember) GetSecurityGroupName() string { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret - } - return *o.SecurityGroupName -} - -// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SecurityGroupsMember) GetSecurityGroupNameOk() (string, bool) { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret, false - } - return *o.SecurityGroupName, true -} - -// HasSecurityGroupName returns a boolean if a field has been set. -func (o *SecurityGroupsMember) HasSecurityGroupName() bool { - if o != nil && o.SecurityGroupName != nil { - return true - } - - return false -} - -// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. -func (o *SecurityGroupsMember) SetSecurityGroupName(v string) { - o.SecurityGroupName = &v -} - -type NullableSecurityGroupsMember struct { - Value SecurityGroupsMember - ExplicitNull bool -} - -func (v NullableSecurityGroupsMember) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSecurityGroupsMember) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_request.go deleted file mode 100644 index 16bd44838..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SendResetPasswordEmailRequest struct for SendResetPasswordEmailRequest -type SendResetPasswordEmailRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The email address provided for the account. - Email string `json:"Email"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *SendResetPasswordEmailRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SendResetPasswordEmailRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *SendResetPasswordEmailRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *SendResetPasswordEmailRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetEmail returns the Email field value -func (o *SendResetPasswordEmailRequest) GetEmail() string { - if o == nil { - var ret string - return ret - } - - return o.Email -} - -// SetEmail sets field value -func (o *SendResetPasswordEmailRequest) SetEmail(v string) { - o.Email = v -} - -type NullableSendResetPasswordEmailRequest struct { - Value SendResetPasswordEmailRequest - ExplicitNull bool -} - -func (v NullableSendResetPasswordEmailRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSendResetPasswordEmailRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_response.go deleted file mode 100644 index 2feebba60..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_send_reset_password_email_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SendResetPasswordEmailResponse struct for SendResetPasswordEmailResponse -type SendResetPasswordEmailResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *SendResetPasswordEmailResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SendResetPasswordEmailResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *SendResetPasswordEmailResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *SendResetPasswordEmailResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableSendResetPasswordEmailResponse struct { - Value SendResetPasswordEmailResponse - ExplicitNull bool -} - -func (v NullableSendResetPasswordEmailResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSendResetPasswordEmailResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_server_certificate.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_server_certificate.go deleted file mode 100644 index 1a628a654..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_server_certificate.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// ServerCertificate Information about the server certificate. -type ServerCertificate struct { - // The date at which the server certificate expires. - ExpirationDate *string `json:"ExpirationDate,omitempty"` - // The ID of the server certificate. - Id *string `json:"Id,omitempty"` - // The name of the server certificate. - Name *string `json:"Name,omitempty"` - // The path to the server certificate. - Path *string `json:"Path,omitempty"` - // The date at which the server certificate has been uploaded. - UploadDate *string `json:"UploadDate,omitempty"` -} - -// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. -func (o *ServerCertificate) GetExpirationDate() string { - if o == nil || o.ExpirationDate == nil { - var ret string - return ret - } - return *o.ExpirationDate -} - -// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ServerCertificate) GetExpirationDateOk() (string, bool) { - if o == nil || o.ExpirationDate == nil { - var ret string - return ret, false - } - return *o.ExpirationDate, true -} - -// HasExpirationDate returns a boolean if a field has been set. -func (o *ServerCertificate) HasExpirationDate() bool { - if o != nil && o.ExpirationDate != nil { - return true - } - - return false -} - -// SetExpirationDate gets a reference to the given string and assigns it to the ExpirationDate field. -func (o *ServerCertificate) SetExpirationDate(v string) { - o.ExpirationDate = &v -} - -// GetId returns the Id field value if set, zero value otherwise. -func (o *ServerCertificate) GetId() string { - if o == nil || o.Id == nil { - var ret string - return ret - } - return *o.Id -} - -// GetIdOk returns a tuple with the Id field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ServerCertificate) GetIdOk() (string, bool) { - if o == nil || o.Id == nil { - var ret string - return ret, false - } - return *o.Id, true -} - -// HasId returns a boolean if a field has been set. -func (o *ServerCertificate) HasId() bool { - if o != nil && o.Id != nil { - return true - } - - return false -} - -// SetId gets a reference to the given string and assigns it to the Id field. -func (o *ServerCertificate) SetId(v string) { - o.Id = &v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *ServerCertificate) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ServerCertificate) GetNameOk() (string, bool) { - if o == nil || o.Name == nil { - var ret string - return ret, false - } - return *o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *ServerCertificate) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *ServerCertificate) SetName(v string) { - o.Name = &v -} - -// GetPath returns the Path field value if set, zero value otherwise. -func (o *ServerCertificate) GetPath() string { - if o == nil || o.Path == nil { - var ret string - return ret - } - return *o.Path -} - -// GetPathOk returns a tuple with the Path field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ServerCertificate) GetPathOk() (string, bool) { - if o == nil || o.Path == nil { - var ret string - return ret, false - } - return *o.Path, true -} - -// HasPath returns a boolean if a field has been set. -func (o *ServerCertificate) HasPath() bool { - if o != nil && o.Path != nil { - return true - } - - return false -} - -// SetPath gets a reference to the given string and assigns it to the Path field. -func (o *ServerCertificate) SetPath(v string) { - o.Path = &v -} - -// GetUploadDate returns the UploadDate field value if set, zero value otherwise. -func (o *ServerCertificate) GetUploadDate() string { - if o == nil || o.UploadDate == nil { - var ret string - return ret - } - return *o.UploadDate -} - -// GetUploadDateOk returns a tuple with the UploadDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *ServerCertificate) GetUploadDateOk() (string, bool) { - if o == nil || o.UploadDate == nil { - var ret string - return ret, false - } - return *o.UploadDate, true -} - -// HasUploadDate returns a boolean if a field has been set. -func (o *ServerCertificate) HasUploadDate() bool { - if o != nil && o.UploadDate != nil { - return true - } - - return false -} - -// SetUploadDate gets a reference to the given string and assigns it to the UploadDate field. -func (o *ServerCertificate) SetUploadDate(v string) { - o.UploadDate = &v -} - -type NullableServerCertificate struct { - Value ServerCertificate - ExplicitNull bool -} - -func (v NullableServerCertificate) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableServerCertificate) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_service.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_service.go deleted file mode 100644 index 0a9c5752c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_service.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Service Information about the service. -type Service struct { - // The list of network prefixes used by the service, in CIDR notation. - IpRanges *[]string `json:"IpRanges,omitempty"` - // The ID of the service. - ServiceId *string `json:"ServiceId,omitempty"` - // The name of the prefix list, which identifies the 3DS OUTSCALE service it is associated with. - ServiceName *string `json:"ServiceName,omitempty"` -} - -// GetIpRanges returns the IpRanges field value if set, zero value otherwise. -func (o *Service) GetIpRanges() []string { - if o == nil || o.IpRanges == nil { - var ret []string - return ret - } - return *o.IpRanges -} - -// GetIpRangesOk returns a tuple with the IpRanges field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Service) GetIpRangesOk() ([]string, bool) { - if o == nil || o.IpRanges == nil { - var ret []string - return ret, false - } - return *o.IpRanges, true -} - -// HasIpRanges returns a boolean if a field has been set. -func (o *Service) HasIpRanges() bool { - if o != nil && o.IpRanges != nil { - return true - } - - return false -} - -// SetIpRanges gets a reference to the given []string and assigns it to the IpRanges field. -func (o *Service) SetIpRanges(v []string) { - o.IpRanges = &v -} - -// GetServiceId returns the ServiceId field value if set, zero value otherwise. -func (o *Service) GetServiceId() string { - if o == nil || o.ServiceId == nil { - var ret string - return ret - } - return *o.ServiceId -} - -// GetServiceIdOk returns a tuple with the ServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Service) GetServiceIdOk() (string, bool) { - if o == nil || o.ServiceId == nil { - var ret string - return ret, false - } - return *o.ServiceId, true -} - -// HasServiceId returns a boolean if a field has been set. -func (o *Service) HasServiceId() bool { - if o != nil && o.ServiceId != nil { - return true - } - - return false -} - -// SetServiceId gets a reference to the given string and assigns it to the ServiceId field. -func (o *Service) SetServiceId(v string) { - o.ServiceId = &v -} - -// GetServiceName returns the ServiceName field value if set, zero value otherwise. -func (o *Service) GetServiceName() string { - if o == nil || o.ServiceName == nil { - var ret string - return ret - } - return *o.ServiceName -} - -// GetServiceNameOk returns a tuple with the ServiceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Service) GetServiceNameOk() (string, bool) { - if o == nil || o.ServiceName == nil { - var ret string - return ret, false - } - return *o.ServiceName, true -} - -// HasServiceName returns a boolean if a field has been set. -func (o *Service) HasServiceName() bool { - if o != nil && o.ServiceName != nil { - return true - } - - return false -} - -// SetServiceName gets a reference to the given string and assigns it to the ServiceName field. -func (o *Service) SetServiceName(v string) { - o.ServiceName = &v -} - -type NullableService struct { - Value Service - ExplicitNull bool -} - -func (v NullableService) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableService) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot.go deleted file mode 100644 index 1df1ea4ab..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot.go +++ /dev/null @@ -1,392 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Snapshot Information about the snapshot. -type Snapshot struct { - // The account alias of the owner of the snapshot. - AccountAlias *string `json:"AccountAlias,omitempty"` - // The account ID of the owner of the snapshot. - AccountId *string `json:"AccountId,omitempty"` - // The description of the snapshot. - Description *string `json:"Description,omitempty"` - PermissionsToCreateVolume *PermissionsOnResource `json:"PermissionsToCreateVolume,omitempty"` - // The progress of the snapshot, as a percentage. - Progress *int64 `json:"Progress,omitempty"` - // The ID of the snapshot. - SnapshotId *string `json:"SnapshotId,omitempty"` - // The state of the snapshot (`in-queue` \\| `completed` \\| `error`). - State *string `json:"State,omitempty"` - // One or more tags associated with the snapshot. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the volume used to create the snapshot. - VolumeId *string `json:"VolumeId,omitempty"` - // The size of the volume used to create the snapshot, in gibibytes (GiB). - VolumeSize *int64 `json:"VolumeSize,omitempty"` -} - -// GetAccountAlias returns the AccountAlias field value if set, zero value otherwise. -func (o *Snapshot) GetAccountAlias() string { - if o == nil || o.AccountAlias == nil { - var ret string - return ret - } - return *o.AccountAlias -} - -// GetAccountAliasOk returns a tuple with the AccountAlias field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetAccountAliasOk() (string, bool) { - if o == nil || o.AccountAlias == nil { - var ret string - return ret, false - } - return *o.AccountAlias, true -} - -// HasAccountAlias returns a boolean if a field has been set. -func (o *Snapshot) HasAccountAlias() bool { - if o != nil && o.AccountAlias != nil { - return true - } - - return false -} - -// SetAccountAlias gets a reference to the given string and assigns it to the AccountAlias field. -func (o *Snapshot) SetAccountAlias(v string) { - o.AccountAlias = &v -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *Snapshot) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *Snapshot) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *Snapshot) SetAccountId(v string) { - o.AccountId = &v -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *Snapshot) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *Snapshot) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *Snapshot) SetDescription(v string) { - o.Description = &v -} - -// GetPermissionsToCreateVolume returns the PermissionsToCreateVolume field value if set, zero value otherwise. -func (o *Snapshot) GetPermissionsToCreateVolume() PermissionsOnResource { - if o == nil || o.PermissionsToCreateVolume == nil { - var ret PermissionsOnResource - return ret - } - return *o.PermissionsToCreateVolume -} - -// GetPermissionsToCreateVolumeOk returns a tuple with the PermissionsToCreateVolume field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetPermissionsToCreateVolumeOk() (PermissionsOnResource, bool) { - if o == nil || o.PermissionsToCreateVolume == nil { - var ret PermissionsOnResource - return ret, false - } - return *o.PermissionsToCreateVolume, true -} - -// HasPermissionsToCreateVolume returns a boolean if a field has been set. -func (o *Snapshot) HasPermissionsToCreateVolume() bool { - if o != nil && o.PermissionsToCreateVolume != nil { - return true - } - - return false -} - -// SetPermissionsToCreateVolume gets a reference to the given PermissionsOnResource and assigns it to the PermissionsToCreateVolume field. -func (o *Snapshot) SetPermissionsToCreateVolume(v PermissionsOnResource) { - o.PermissionsToCreateVolume = &v -} - -// GetProgress returns the Progress field value if set, zero value otherwise. -func (o *Snapshot) GetProgress() int64 { - if o == nil || o.Progress == nil { - var ret int64 - return ret - } - return *o.Progress -} - -// GetProgressOk returns a tuple with the Progress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetProgressOk() (int64, bool) { - if o == nil || o.Progress == nil { - var ret int64 - return ret, false - } - return *o.Progress, true -} - -// HasProgress returns a boolean if a field has been set. -func (o *Snapshot) HasProgress() bool { - if o != nil && o.Progress != nil { - return true - } - - return false -} - -// SetProgress gets a reference to the given int64 and assigns it to the Progress field. -func (o *Snapshot) SetProgress(v int64) { - o.Progress = &v -} - -// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. -func (o *Snapshot) GetSnapshotId() string { - if o == nil || o.SnapshotId == nil { - var ret string - return ret - } - return *o.SnapshotId -} - -// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetSnapshotIdOk() (string, bool) { - if o == nil || o.SnapshotId == nil { - var ret string - return ret, false - } - return *o.SnapshotId, true -} - -// HasSnapshotId returns a boolean if a field has been set. -func (o *Snapshot) HasSnapshotId() bool { - if o != nil && o.SnapshotId != nil { - return true - } - - return false -} - -// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. -func (o *Snapshot) SetSnapshotId(v string) { - o.SnapshotId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Snapshot) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Snapshot) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Snapshot) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Snapshot) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Snapshot) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Snapshot) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *Snapshot) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *Snapshot) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *Snapshot) SetVolumeId(v string) { - o.VolumeId = &v -} - -// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. -func (o *Snapshot) GetVolumeSize() int64 { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret - } - return *o.VolumeSize -} - -// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Snapshot) GetVolumeSizeOk() (int64, bool) { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret, false - } - return *o.VolumeSize, true -} - -// HasVolumeSize returns a boolean if a field has been set. -func (o *Snapshot) HasVolumeSize() bool { - if o != nil && o.VolumeSize != nil { - return true - } - - return false -} - -// SetVolumeSize gets a reference to the given int64 and assigns it to the VolumeSize field. -func (o *Snapshot) SetVolumeSize(v int64) { - o.VolumeSize = &v -} - -type NullableSnapshot struct { - Value Snapshot - ExplicitNull bool -} - -func (v NullableSnapshot) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSnapshot) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot_export_task.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot_export_task.go deleted file mode 100644 index 92204ac79..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_snapshot_export_task.go +++ /dev/null @@ -1,287 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SnapshotExportTask Information about the snapshot export task. -type SnapshotExportTask struct { - // If the snapshot export task fails, an error message appears. - Comment *string `json:"Comment,omitempty"` - OsuExport *OsuExport `json:"OsuExport,omitempty"` - // The progress of the snapshot export task, as a percentage. - Progress *int64 `json:"Progress,omitempty"` - // The ID of the snapshot to be exported. - SnapshotId *string `json:"SnapshotId,omitempty"` - // The state of the snapshot export task (`pending` \\| `active` \\| `completed` \\| `failed`). - State *string `json:"State,omitempty"` - // One or more tags associated with the snapshot export task. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the snapshot export task. - TaskId *string `json:"TaskId,omitempty"` -} - -// GetComment returns the Comment field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetComment() string { - if o == nil || o.Comment == nil { - var ret string - return ret - } - return *o.Comment -} - -// GetCommentOk returns a tuple with the Comment field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetCommentOk() (string, bool) { - if o == nil || o.Comment == nil { - var ret string - return ret, false - } - return *o.Comment, true -} - -// HasComment returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasComment() bool { - if o != nil && o.Comment != nil { - return true - } - - return false -} - -// SetComment gets a reference to the given string and assigns it to the Comment field. -func (o *SnapshotExportTask) SetComment(v string) { - o.Comment = &v -} - -// GetOsuExport returns the OsuExport field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetOsuExport() OsuExport { - if o == nil || o.OsuExport == nil { - var ret OsuExport - return ret - } - return *o.OsuExport -} - -// GetOsuExportOk returns a tuple with the OsuExport field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetOsuExportOk() (OsuExport, bool) { - if o == nil || o.OsuExport == nil { - var ret OsuExport - return ret, false - } - return *o.OsuExport, true -} - -// HasOsuExport returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasOsuExport() bool { - if o != nil && o.OsuExport != nil { - return true - } - - return false -} - -// SetOsuExport gets a reference to the given OsuExport and assigns it to the OsuExport field. -func (o *SnapshotExportTask) SetOsuExport(v OsuExport) { - o.OsuExport = &v -} - -// GetProgress returns the Progress field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetProgress() int64 { - if o == nil || o.Progress == nil { - var ret int64 - return ret - } - return *o.Progress -} - -// GetProgressOk returns a tuple with the Progress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetProgressOk() (int64, bool) { - if o == nil || o.Progress == nil { - var ret int64 - return ret, false - } - return *o.Progress, true -} - -// HasProgress returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasProgress() bool { - if o != nil && o.Progress != nil { - return true - } - - return false -} - -// SetProgress gets a reference to the given int64 and assigns it to the Progress field. -func (o *SnapshotExportTask) SetProgress(v int64) { - o.Progress = &v -} - -// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetSnapshotId() string { - if o == nil || o.SnapshotId == nil { - var ret string - return ret - } - return *o.SnapshotId -} - -// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetSnapshotIdOk() (string, bool) { - if o == nil || o.SnapshotId == nil { - var ret string - return ret, false - } - return *o.SnapshotId, true -} - -// HasSnapshotId returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasSnapshotId() bool { - if o != nil && o.SnapshotId != nil { - return true - } - - return false -} - -// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. -func (o *SnapshotExportTask) SetSnapshotId(v string) { - o.SnapshotId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *SnapshotExportTask) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *SnapshotExportTask) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetTaskId returns the TaskId field value if set, zero value otherwise. -func (o *SnapshotExportTask) GetTaskId() string { - if o == nil || o.TaskId == nil { - var ret string - return ret - } - return *o.TaskId -} - -// GetTaskIdOk returns a tuple with the TaskId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SnapshotExportTask) GetTaskIdOk() (string, bool) { - if o == nil || o.TaskId == nil { - var ret string - return ret, false - } - return *o.TaskId, true -} - -// HasTaskId returns a boolean if a field has been set. -func (o *SnapshotExportTask) HasTaskId() bool { - if o != nil && o.TaskId != nil { - return true - } - - return false -} - -// SetTaskId gets a reference to the given string and assigns it to the TaskId field. -func (o *SnapshotExportTask) SetTaskId(v string) { - o.TaskId = &v -} - -type NullableSnapshotExportTask struct { - Value SnapshotExportTask - ExplicitNull bool -} - -func (v NullableSnapshotExportTask) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSnapshotExportTask) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_source_net.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_source_net.go deleted file mode 100644 index 3bdce9fb3..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_source_net.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SourceNet Information about the source Net. -type SourceNet struct { - // The account ID of the owner of the source Net. - AccountId *string `json:"AccountId,omitempty"` - // The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // The ID of the source Net. - NetId *string `json:"NetId,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *SourceNet) GetAccountId() string { - if o == nil || o.AccountId == nil { - var ret string - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SourceNet) GetAccountIdOk() (string, bool) { - if o == nil || o.AccountId == nil { - var ret string - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *SourceNet) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given string and assigns it to the AccountId field. -func (o *SourceNet) SetAccountId(v string) { - o.AccountId = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *SourceNet) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SourceNet) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *SourceNet) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *SourceNet) SetIpRange(v string) { - o.IpRange = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *SourceNet) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SourceNet) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *SourceNet) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *SourceNet) SetNetId(v string) { - o.NetId = &v -} - -type NullableSourceNet struct { - Value SourceNet - ExplicitNull bool -} - -func (v NullableSourceNet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSourceNet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_source_security_group.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_source_security_group.go deleted file mode 100644 index 1bdfe83ec..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_source_security_group.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// SourceSecurityGroup Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. -type SourceSecurityGroup struct { - // The account ID of the owner of the security group. - SecurityGroupAccountId *string `json:"SecurityGroupAccountId,omitempty"` - // (Public Cloud only) The name of the security group. - SecurityGroupName *string `json:"SecurityGroupName,omitempty"` -} - -// GetSecurityGroupAccountId returns the SecurityGroupAccountId field value if set, zero value otherwise. -func (o *SourceSecurityGroup) GetSecurityGroupAccountId() string { - if o == nil || o.SecurityGroupAccountId == nil { - var ret string - return ret - } - return *o.SecurityGroupAccountId -} - -// GetSecurityGroupAccountIdOk returns a tuple with the SecurityGroupAccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SourceSecurityGroup) GetSecurityGroupAccountIdOk() (string, bool) { - if o == nil || o.SecurityGroupAccountId == nil { - var ret string - return ret, false - } - return *o.SecurityGroupAccountId, true -} - -// HasSecurityGroupAccountId returns a boolean if a field has been set. -func (o *SourceSecurityGroup) HasSecurityGroupAccountId() bool { - if o != nil && o.SecurityGroupAccountId != nil { - return true - } - - return false -} - -// SetSecurityGroupAccountId gets a reference to the given string and assigns it to the SecurityGroupAccountId field. -func (o *SourceSecurityGroup) SetSecurityGroupAccountId(v string) { - o.SecurityGroupAccountId = &v -} - -// GetSecurityGroupName returns the SecurityGroupName field value if set, zero value otherwise. -func (o *SourceSecurityGroup) GetSecurityGroupName() string { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret - } - return *o.SecurityGroupName -} - -// GetSecurityGroupNameOk returns a tuple with the SecurityGroupName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *SourceSecurityGroup) GetSecurityGroupNameOk() (string, bool) { - if o == nil || o.SecurityGroupName == nil { - var ret string - return ret, false - } - return *o.SecurityGroupName, true -} - -// HasSecurityGroupName returns a boolean if a field has been set. -func (o *SourceSecurityGroup) HasSecurityGroupName() bool { - if o != nil && o.SecurityGroupName != nil { - return true - } - - return false -} - -// SetSecurityGroupName gets a reference to the given string and assigns it to the SecurityGroupName field. -func (o *SourceSecurityGroup) SetSecurityGroupName(v string) { - o.SecurityGroupName = &v -} - -type NullableSourceSecurityGroup struct { - Value SourceSecurityGroup - ExplicitNull bool -} - -func (v NullableSourceSecurityGroup) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSourceSecurityGroup) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_request.go deleted file mode 100644 index ede1ea8ac..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// StartVmsRequest struct for StartVmsRequest -type StartVmsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // One or more IDs of VMs. - VmIds []string `json:"VmIds"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *StartVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StartVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *StartVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *StartVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetVmIds returns the VmIds field value -func (o *StartVmsRequest) GetVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.VmIds -} - -// SetVmIds sets field value -func (o *StartVmsRequest) SetVmIds(v []string) { - o.VmIds = v -} - -type NullableStartVmsRequest struct { - Value StartVmsRequest - ExplicitNull bool -} - -func (v NullableStartVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableStartVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_response.go deleted file mode 100644 index 88393f4f5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_start_vms_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// StartVmsResponse struct for StartVmsResponse -type StartVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more started VMs. - Vms *[]VmState `json:"Vms,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *StartVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StartVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *StartVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *StartVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVms returns the Vms field value if set, zero value otherwise. -func (o *StartVmsResponse) GetVms() []VmState { - if o == nil || o.Vms == nil { - var ret []VmState - return ret - } - return *o.Vms -} - -// GetVmsOk returns a tuple with the Vms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StartVmsResponse) GetVmsOk() ([]VmState, bool) { - if o == nil || o.Vms == nil { - var ret []VmState - return ret, false - } - return *o.Vms, true -} - -// HasVms returns a boolean if a field has been set. -func (o *StartVmsResponse) HasVms() bool { - if o != nil && o.Vms != nil { - return true - } - - return false -} - -// SetVms gets a reference to the given []VmState and assigns it to the Vms field. -func (o *StartVmsResponse) SetVms(v []VmState) { - o.Vms = &v -} - -type NullableStartVmsResponse struct { - Value StartVmsResponse - ExplicitNull bool -} - -func (v NullableStartVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableStartVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_state_comment.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_state_comment.go deleted file mode 100644 index 97a6e30ee..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_state_comment.go +++ /dev/null @@ -1,113 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// StateComment Information about the change of state. -type StateComment struct { - // The code of the change of state. - StateCode *string `json:"StateCode,omitempty"` - // A message explaining the change of state. - StateMessage *string `json:"StateMessage,omitempty"` -} - -// GetStateCode returns the StateCode field value if set, zero value otherwise. -func (o *StateComment) GetStateCode() string { - if o == nil || o.StateCode == nil { - var ret string - return ret - } - return *o.StateCode -} - -// GetStateCodeOk returns a tuple with the StateCode field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StateComment) GetStateCodeOk() (string, bool) { - if o == nil || o.StateCode == nil { - var ret string - return ret, false - } - return *o.StateCode, true -} - -// HasStateCode returns a boolean if a field has been set. -func (o *StateComment) HasStateCode() bool { - if o != nil && o.StateCode != nil { - return true - } - - return false -} - -// SetStateCode gets a reference to the given string and assigns it to the StateCode field. -func (o *StateComment) SetStateCode(v string) { - o.StateCode = &v -} - -// GetStateMessage returns the StateMessage field value if set, zero value otherwise. -func (o *StateComment) GetStateMessage() string { - if o == nil || o.StateMessage == nil { - var ret string - return ret - } - return *o.StateMessage -} - -// GetStateMessageOk returns a tuple with the StateMessage field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StateComment) GetStateMessageOk() (string, bool) { - if o == nil || o.StateMessage == nil { - var ret string - return ret, false - } - return *o.StateMessage, true -} - -// HasStateMessage returns a boolean if a field has been set. -func (o *StateComment) HasStateMessage() bool { - if o != nil && o.StateMessage != nil { - return true - } - - return false -} - -// SetStateMessage gets a reference to the given string and assigns it to the StateMessage field. -func (o *StateComment) SetStateMessage(v string) { - o.StateMessage = &v -} - -type NullableStateComment struct { - Value StateComment - ExplicitNull bool -} - -func (v NullableStateComment) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableStateComment) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_request.go deleted file mode 100644 index a1cdb68ca..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// StopVmsRequest struct for StopVmsRequest -type StopVmsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // Forces the VM to stop. - ForceStop *bool `json:"ForceStop,omitempty"` - // One or more IDs of VMs. - VmIds []string `json:"VmIds"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *StopVmsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StopVmsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *StopVmsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *StopVmsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetForceStop returns the ForceStop field value if set, zero value otherwise. -func (o *StopVmsRequest) GetForceStop() bool { - if o == nil || o.ForceStop == nil { - var ret bool - return ret - } - return *o.ForceStop -} - -// GetForceStopOk returns a tuple with the ForceStop field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StopVmsRequest) GetForceStopOk() (bool, bool) { - if o == nil || o.ForceStop == nil { - var ret bool - return ret, false - } - return *o.ForceStop, true -} - -// HasForceStop returns a boolean if a field has been set. -func (o *StopVmsRequest) HasForceStop() bool { - if o != nil && o.ForceStop != nil { - return true - } - - return false -} - -// SetForceStop gets a reference to the given bool and assigns it to the ForceStop field. -func (o *StopVmsRequest) SetForceStop(v bool) { - o.ForceStop = &v -} - -// GetVmIds returns the VmIds field value -func (o *StopVmsRequest) GetVmIds() []string { - if o == nil { - var ret []string - return ret - } - - return o.VmIds -} - -// SetVmIds sets field value -func (o *StopVmsRequest) SetVmIds(v []string) { - o.VmIds = v -} - -type NullableStopVmsRequest struct { - Value StopVmsRequest - ExplicitNull bool -} - -func (v NullableStopVmsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableStopVmsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_response.go deleted file mode 100644 index 47b9f73bd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_stop_vms_response.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// StopVmsResponse struct for StopVmsResponse -type StopVmsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - // Information about one or more stopped VMs. - Vms *[]VmState `json:"Vms,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *StopVmsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StopVmsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *StopVmsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *StopVmsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVms returns the Vms field value if set, zero value otherwise. -func (o *StopVmsResponse) GetVms() []VmState { - if o == nil || o.Vms == nil { - var ret []VmState - return ret - } - return *o.Vms -} - -// GetVmsOk returns a tuple with the Vms field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *StopVmsResponse) GetVmsOk() ([]VmState, bool) { - if o == nil || o.Vms == nil { - var ret []VmState - return ret, false - } - return *o.Vms, true -} - -// HasVms returns a boolean if a field has been set. -func (o *StopVmsResponse) HasVms() bool { - if o != nil && o.Vms != nil { - return true - } - - return false -} - -// SetVms gets a reference to the given []VmState and assigns it to the Vms field. -func (o *StopVmsResponse) SetVms(v []VmState) { - o.Vms = &v -} - -type NullableStopVmsResponse struct { - Value StopVmsResponse - ExplicitNull bool -} - -func (v NullableStopVmsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableStopVmsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_subnet.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_subnet.go deleted file mode 100644 index 5ab2bca30..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_subnet.go +++ /dev/null @@ -1,323 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Subnet Information about the Subnet. -type Subnet struct { - // The number of available IP addresses in the Subnets. - AvailableIpsCount *int64 `json:"AvailableIpsCount,omitempty"` - // The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). - IpRange *string `json:"IpRange,omitempty"` - // If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. - MapPublicIpOnLaunch *bool `json:"MapPublicIpOnLaunch,omitempty"` - // The ID of the Net in which the Subnet is. - NetId *string `json:"NetId,omitempty"` - // The state of the Subnet (`pending` \\| `available`). - State *string `json:"State,omitempty"` - // The ID of the Subnet. - SubnetId *string `json:"SubnetId,omitempty"` - // The name of the Subregion in which the Subnet is located. - SubregionName *string `json:"SubregionName,omitempty"` - // One or more tags associated with the Subnet. - Tags *[]ResourceTag `json:"Tags,omitempty"` -} - -// GetAvailableIpsCount returns the AvailableIpsCount field value if set, zero value otherwise. -func (o *Subnet) GetAvailableIpsCount() int64 { - if o == nil || o.AvailableIpsCount == nil { - var ret int64 - return ret - } - return *o.AvailableIpsCount -} - -// GetAvailableIpsCountOk returns a tuple with the AvailableIpsCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetAvailableIpsCountOk() (int64, bool) { - if o == nil || o.AvailableIpsCount == nil { - var ret int64 - return ret, false - } - return *o.AvailableIpsCount, true -} - -// HasAvailableIpsCount returns a boolean if a field has been set. -func (o *Subnet) HasAvailableIpsCount() bool { - if o != nil && o.AvailableIpsCount != nil { - return true - } - - return false -} - -// SetAvailableIpsCount gets a reference to the given int64 and assigns it to the AvailableIpsCount field. -func (o *Subnet) SetAvailableIpsCount(v int64) { - o.AvailableIpsCount = &v -} - -// GetIpRange returns the IpRange field value if set, zero value otherwise. -func (o *Subnet) GetIpRange() string { - if o == nil || o.IpRange == nil { - var ret string - return ret - } - return *o.IpRange -} - -// GetIpRangeOk returns a tuple with the IpRange field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetIpRangeOk() (string, bool) { - if o == nil || o.IpRange == nil { - var ret string - return ret, false - } - return *o.IpRange, true -} - -// HasIpRange returns a boolean if a field has been set. -func (o *Subnet) HasIpRange() bool { - if o != nil && o.IpRange != nil { - return true - } - - return false -} - -// SetIpRange gets a reference to the given string and assigns it to the IpRange field. -func (o *Subnet) SetIpRange(v string) { - o.IpRange = &v -} - -// GetMapPublicIpOnLaunch returns the MapPublicIpOnLaunch field value if set, zero value otherwise. -func (o *Subnet) GetMapPublicIpOnLaunch() bool { - if o == nil || o.MapPublicIpOnLaunch == nil { - var ret bool - return ret - } - return *o.MapPublicIpOnLaunch -} - -// GetMapPublicIpOnLaunchOk returns a tuple with the MapPublicIpOnLaunch field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetMapPublicIpOnLaunchOk() (bool, bool) { - if o == nil || o.MapPublicIpOnLaunch == nil { - var ret bool - return ret, false - } - return *o.MapPublicIpOnLaunch, true -} - -// HasMapPublicIpOnLaunch returns a boolean if a field has been set. -func (o *Subnet) HasMapPublicIpOnLaunch() bool { - if o != nil && o.MapPublicIpOnLaunch != nil { - return true - } - - return false -} - -// SetMapPublicIpOnLaunch gets a reference to the given bool and assigns it to the MapPublicIpOnLaunch field. -func (o *Subnet) SetMapPublicIpOnLaunch(v bool) { - o.MapPublicIpOnLaunch = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *Subnet) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *Subnet) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *Subnet) SetNetId(v string) { - o.NetId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Subnet) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Subnet) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Subnet) SetState(v string) { - o.State = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *Subnet) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *Subnet) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *Subnet) SetSubnetId(v string) { - o.SubnetId = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *Subnet) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *Subnet) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *Subnet) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Subnet) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subnet) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Subnet) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Subnet) SetTags(v []ResourceTag) { - o.Tags = &v -} - -type NullableSubnet struct { - Value Subnet - ExplicitNull bool -} - -func (v NullableSubnet) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSubnet) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_subregion.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_subregion.go deleted file mode 100644 index 2ded02c56..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_subregion.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Subregion Information about the Subregion. -type Subregion struct { - // The name of the Region containing the Subregion. - RegionName *string `json:"RegionName,omitempty"` - // The state of the Subregion (`available` \\| `information` \\| `impaired` \\| `unavailable`). - State *string `json:"State,omitempty"` - // The name of the Subregion. - SubregionName *string `json:"SubregionName,omitempty"` -} - -// GetRegionName returns the RegionName field value if set, zero value otherwise. -func (o *Subregion) GetRegionName() string { - if o == nil || o.RegionName == nil { - var ret string - return ret - } - return *o.RegionName -} - -// GetRegionNameOk returns a tuple with the RegionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subregion) GetRegionNameOk() (string, bool) { - if o == nil || o.RegionName == nil { - var ret string - return ret, false - } - return *o.RegionName, true -} - -// HasRegionName returns a boolean if a field has been set. -func (o *Subregion) HasRegionName() bool { - if o != nil && o.RegionName != nil { - return true - } - - return false -} - -// SetRegionName gets a reference to the given string and assigns it to the RegionName field. -func (o *Subregion) SetRegionName(v string) { - o.RegionName = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Subregion) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subregion) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Subregion) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Subregion) SetState(v string) { - o.State = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *Subregion) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Subregion) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *Subregion) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *Subregion) SetSubregionName(v string) { - o.SubregionName = &v -} - -type NullableSubregion struct { - Value Subregion - ExplicitNull bool -} - -func (v NullableSubregion) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableSubregion) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_tag.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_tag.go deleted file mode 100644 index a9cfd83df..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_tag.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Tag Information about the tag. -type Tag struct { - // The key of the tag, with a minimum of 1 character. - Key *string `json:"Key,omitempty"` - // The ID of the resource. - ResourceId *string `json:"ResourceId,omitempty"` - // The type of the resource. - ResourceType *string `json:"ResourceType,omitempty"` - // The value of the tag, between 0 and 255 characters. - Value *string `json:"Value,omitempty"` -} - -// GetKey returns the Key field value if set, zero value otherwise. -func (o *Tag) GetKey() string { - if o == nil || o.Key == nil { - var ret string - return ret - } - return *o.Key -} - -// GetKeyOk returns a tuple with the Key field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Tag) GetKeyOk() (string, bool) { - if o == nil || o.Key == nil { - var ret string - return ret, false - } - return *o.Key, true -} - -// HasKey returns a boolean if a field has been set. -func (o *Tag) HasKey() bool { - if o != nil && o.Key != nil { - return true - } - - return false -} - -// SetKey gets a reference to the given string and assigns it to the Key field. -func (o *Tag) SetKey(v string) { - o.Key = &v -} - -// GetResourceId returns the ResourceId field value if set, zero value otherwise. -func (o *Tag) GetResourceId() string { - if o == nil || o.ResourceId == nil { - var ret string - return ret - } - return *o.ResourceId -} - -// GetResourceIdOk returns a tuple with the ResourceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Tag) GetResourceIdOk() (string, bool) { - if o == nil || o.ResourceId == nil { - var ret string - return ret, false - } - return *o.ResourceId, true -} - -// HasResourceId returns a boolean if a field has been set. -func (o *Tag) HasResourceId() bool { - if o != nil && o.ResourceId != nil { - return true - } - - return false -} - -// SetResourceId gets a reference to the given string and assigns it to the ResourceId field. -func (o *Tag) SetResourceId(v string) { - o.ResourceId = &v -} - -// GetResourceType returns the ResourceType field value if set, zero value otherwise. -func (o *Tag) GetResourceType() string { - if o == nil || o.ResourceType == nil { - var ret string - return ret - } - return *o.ResourceType -} - -// GetResourceTypeOk returns a tuple with the ResourceType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Tag) GetResourceTypeOk() (string, bool) { - if o == nil || o.ResourceType == nil { - var ret string - return ret, false - } - return *o.ResourceType, true -} - -// HasResourceType returns a boolean if a field has been set. -func (o *Tag) HasResourceType() bool { - if o != nil && o.ResourceType != nil { - return true - } - - return false -} - -// SetResourceType gets a reference to the given string and assigns it to the ResourceType field. -func (o *Tag) SetResourceType(v string) { - o.ResourceType = &v -} - -// GetValue returns the Value field value if set, zero value otherwise. -func (o *Tag) GetValue() string { - if o == nil || o.Value == nil { - var ret string - return ret - } - return *o.Value -} - -// GetValueOk returns a tuple with the Value field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Tag) GetValueOk() (string, bool) { - if o == nil || o.Value == nil { - var ret string - return ret, false - } - return *o.Value, true -} - -// HasValue returns a boolean if a field has been set. -func (o *Tag) HasValue() bool { - if o != nil && o.Value != nil { - return true - } - - return false -} - -// SetValue gets a reference to the given string and assigns it to the Value field. -func (o *Tag) SetValue(v string) { - o.Value = &v -} - -type NullableTag struct { - Value Tag - ExplicitNull bool -} - -func (v NullableTag) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableTag) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_request.go deleted file mode 100644 index 02b9a9dbd..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkFlexibleGpuRequest struct for UnlinkFlexibleGpuRequest -type UnlinkFlexibleGpuRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the fGPU you want to detach from your VM. - FlexibleGpuId string `json:"FlexibleGpuId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkFlexibleGpuRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkFlexibleGpuRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkFlexibleGpuRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkFlexibleGpuRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlexibleGpuId returns the FlexibleGpuId field value -func (o *UnlinkFlexibleGpuRequest) GetFlexibleGpuId() string { - if o == nil { - var ret string - return ret - } - - return o.FlexibleGpuId -} - -// SetFlexibleGpuId sets field value -func (o *UnlinkFlexibleGpuRequest) SetFlexibleGpuId(v string) { - o.FlexibleGpuId = v -} - -type NullableUnlinkFlexibleGpuRequest struct { - Value UnlinkFlexibleGpuRequest - ExplicitNull bool -} - -func (v NullableUnlinkFlexibleGpuRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkFlexibleGpuRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_response.go deleted file mode 100644 index 192b0c7d6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_flexible_gpu_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkFlexibleGpuResponse struct for UnlinkFlexibleGpuResponse -type UnlinkFlexibleGpuResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkFlexibleGpuResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkFlexibleGpuResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkFlexibleGpuResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkFlexibleGpuResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkFlexibleGpuResponse struct { - Value UnlinkFlexibleGpuResponse - ExplicitNull bool -} - -func (v NullableUnlinkFlexibleGpuResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkFlexibleGpuResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_request.go deleted file mode 100644 index 2b2b42279..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkInternetServiceRequest struct for UnlinkInternetServiceRequest -type UnlinkInternetServiceRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Internet service you want to detach. - InternetServiceId string `json:"InternetServiceId"` - // The ID of the Net from which you want to detach the Internet service. - NetId string `json:"NetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkInternetServiceRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkInternetServiceRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkInternetServiceRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkInternetServiceRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetInternetServiceId returns the InternetServiceId field value -func (o *UnlinkInternetServiceRequest) GetInternetServiceId() string { - if o == nil { - var ret string - return ret - } - - return o.InternetServiceId -} - -// SetInternetServiceId sets field value -func (o *UnlinkInternetServiceRequest) SetInternetServiceId(v string) { - o.InternetServiceId = v -} - -// GetNetId returns the NetId field value -func (o *UnlinkInternetServiceRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *UnlinkInternetServiceRequest) SetNetId(v string) { - o.NetId = v -} - -type NullableUnlinkInternetServiceRequest struct { - Value UnlinkInternetServiceRequest - ExplicitNull bool -} - -func (v NullableUnlinkInternetServiceRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkInternetServiceRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_response.go deleted file mode 100644 index 2dfc8736f..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_internet_service_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkInternetServiceResponse struct for UnlinkInternetServiceResponse -type UnlinkInternetServiceResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkInternetServiceResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkInternetServiceResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkInternetServiceResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkInternetServiceResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkInternetServiceResponse struct { - Value UnlinkInternetServiceResponse - ExplicitNull bool -} - -func (v NullableUnlinkInternetServiceResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkInternetServiceResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_request.go deleted file mode 100644 index c26a41f7c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkNicRequest struct for UnlinkNicRequest -type UnlinkNicRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the attachment operation. - LinkNicId string `json:"LinkNicId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkNicRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkNicRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkNicRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkNicRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLinkNicId returns the LinkNicId field value -func (o *UnlinkNicRequest) GetLinkNicId() string { - if o == nil { - var ret string - return ret - } - - return o.LinkNicId -} - -// SetLinkNicId sets field value -func (o *UnlinkNicRequest) SetLinkNicId(v string) { - o.LinkNicId = v -} - -type NullableUnlinkNicRequest struct { - Value UnlinkNicRequest - ExplicitNull bool -} - -func (v NullableUnlinkNicRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkNicRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_response.go deleted file mode 100644 index 568c69607..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_nic_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkNicResponse struct for UnlinkNicResponse -type UnlinkNicResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkNicResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkNicResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkNicResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkNicResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkNicResponse struct { - Value UnlinkNicResponse - ExplicitNull bool -} - -func (v NullableUnlinkNicResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkNicResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_request.go deleted file mode 100644 index ccb15a122..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkPrivateIpsRequest struct for UnlinkPrivateIpsRequest -type UnlinkPrivateIpsRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the NIC. - NicId string `json:"NicId"` - // One or more secondary private IP addresses you want to unassign from the NIC. - PrivateIps []string `json:"PrivateIps"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkPrivateIpsRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPrivateIpsRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkPrivateIpsRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkPrivateIpsRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNicId returns the NicId field value -func (o *UnlinkPrivateIpsRequest) GetNicId() string { - if o == nil { - var ret string - return ret - } - - return o.NicId -} - -// SetNicId sets field value -func (o *UnlinkPrivateIpsRequest) SetNicId(v string) { - o.NicId = v -} - -// GetPrivateIps returns the PrivateIps field value -func (o *UnlinkPrivateIpsRequest) GetPrivateIps() []string { - if o == nil { - var ret []string - return ret - } - - return o.PrivateIps -} - -// SetPrivateIps sets field value -func (o *UnlinkPrivateIpsRequest) SetPrivateIps(v []string) { - o.PrivateIps = v -} - -type NullableUnlinkPrivateIpsRequest struct { - Value UnlinkPrivateIpsRequest - ExplicitNull bool -} - -func (v NullableUnlinkPrivateIpsRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkPrivateIpsRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_response.go deleted file mode 100644 index 07eca73d6..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_private_ips_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkPrivateIpsResponse struct for UnlinkPrivateIpsResponse -type UnlinkPrivateIpsResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkPrivateIpsResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPrivateIpsResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkPrivateIpsResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkPrivateIpsResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkPrivateIpsResponse struct { - Value UnlinkPrivateIpsResponse - ExplicitNull bool -} - -func (v NullableUnlinkPrivateIpsResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkPrivateIpsResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_request.go deleted file mode 100644 index 27d11f64d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_request.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkPublicIpRequest struct for UnlinkPublicIpRequest -type UnlinkPublicIpRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - LinkPublicIpId *string `json:"LinkPublicIpId,omitempty"` - // The External IP address. In the public Cloud, this parameter is required. - PublicIp *string `json:"PublicIp,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkPublicIpRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPublicIpRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkPublicIpRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkPublicIpRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLinkPublicIpId returns the LinkPublicIpId field value if set, zero value otherwise. -func (o *UnlinkPublicIpRequest) GetLinkPublicIpId() string { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret - } - return *o.LinkPublicIpId -} - -// GetLinkPublicIpIdOk returns a tuple with the LinkPublicIpId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPublicIpRequest) GetLinkPublicIpIdOk() (string, bool) { - if o == nil || o.LinkPublicIpId == nil { - var ret string - return ret, false - } - return *o.LinkPublicIpId, true -} - -// HasLinkPublicIpId returns a boolean if a field has been set. -func (o *UnlinkPublicIpRequest) HasLinkPublicIpId() bool { - if o != nil && o.LinkPublicIpId != nil { - return true - } - - return false -} - -// SetLinkPublicIpId gets a reference to the given string and assigns it to the LinkPublicIpId field. -func (o *UnlinkPublicIpRequest) SetLinkPublicIpId(v string) { - o.LinkPublicIpId = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *UnlinkPublicIpRequest) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPublicIpRequest) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *UnlinkPublicIpRequest) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *UnlinkPublicIpRequest) SetPublicIp(v string) { - o.PublicIp = &v -} - -type NullableUnlinkPublicIpRequest struct { - Value UnlinkPublicIpRequest - ExplicitNull bool -} - -func (v NullableUnlinkPublicIpRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkPublicIpRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_response.go deleted file mode 100644 index adfd7fbe9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_public_ip_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkPublicIpResponse struct for UnlinkPublicIpResponse -type UnlinkPublicIpResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkPublicIpResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkPublicIpResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkPublicIpResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkPublicIpResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkPublicIpResponse struct { - Value UnlinkPublicIpResponse - ExplicitNull bool -} - -func (v NullableUnlinkPublicIpResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkPublicIpResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_request.go deleted file mode 100644 index 4744ff1cc..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_request.go +++ /dev/null @@ -1,95 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkRouteTableRequest struct for UnlinkRouteTableRequest -type UnlinkRouteTableRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the association between the route table and the Subnet. - LinkRouteTableId string `json:"LinkRouteTableId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkRouteTableRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkRouteTableRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkRouteTableRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkRouteTableRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLinkRouteTableId returns the LinkRouteTableId field value -func (o *UnlinkRouteTableRequest) GetLinkRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.LinkRouteTableId -} - -// SetLinkRouteTableId sets field value -func (o *UnlinkRouteTableRequest) SetLinkRouteTableId(v string) { - o.LinkRouteTableId = v -} - -type NullableUnlinkRouteTableRequest struct { - Value UnlinkRouteTableRequest - ExplicitNull bool -} - -func (v NullableUnlinkRouteTableRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkRouteTableRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_response.go deleted file mode 100644 index d32c860eb..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_route_table_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkRouteTableResponse struct for UnlinkRouteTableResponse -type UnlinkRouteTableResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkRouteTableResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkRouteTableResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkRouteTableResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkRouteTableResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkRouteTableResponse struct { - Value UnlinkRouteTableResponse - ExplicitNull bool -} - -func (v NullableUnlinkRouteTableResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkRouteTableResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_request.go deleted file mode 100644 index 96e228a3a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkVirtualGatewayRequest struct for UnlinkVirtualGatewayRequest -type UnlinkVirtualGatewayRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net from which you want to detach the virtual gateway. - NetId string `json:"NetId"` - // The ID of the virtual gateway. - VirtualGatewayId string `json:"VirtualGatewayId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkVirtualGatewayRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkVirtualGatewayRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkVirtualGatewayRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkVirtualGatewayRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *UnlinkVirtualGatewayRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *UnlinkVirtualGatewayRequest) SetNetId(v string) { - o.NetId = v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *UnlinkVirtualGatewayRequest) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *UnlinkVirtualGatewayRequest) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -type NullableUnlinkVirtualGatewayRequest struct { - Value UnlinkVirtualGatewayRequest - ExplicitNull bool -} - -func (v NullableUnlinkVirtualGatewayRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkVirtualGatewayRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_response.go deleted file mode 100644 index 0b7fc5e83..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_virtual_gateway_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkVirtualGatewayResponse struct for UnlinkVirtualGatewayResponse -type UnlinkVirtualGatewayResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkVirtualGatewayResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkVirtualGatewayResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkVirtualGatewayResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkVirtualGatewayResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkVirtualGatewayResponse struct { - Value UnlinkVirtualGatewayResponse - ExplicitNull bool -} - -func (v NullableUnlinkVirtualGatewayResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkVirtualGatewayResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_request.go deleted file mode 100644 index 458dc5147..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkVolumeRequest struct for UnlinkVolumeRequest -type UnlinkVolumeRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // Forces the detachment of the volume in case of previous failure. Important: This action may damage your data or file systems. - ForceUnlink *bool `json:"ForceUnlink,omitempty"` - // The ID of the volume you want to detach. - VolumeId string `json:"VolumeId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UnlinkVolumeRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkVolumeRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UnlinkVolumeRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UnlinkVolumeRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetForceUnlink returns the ForceUnlink field value if set, zero value otherwise. -func (o *UnlinkVolumeRequest) GetForceUnlink() bool { - if o == nil || o.ForceUnlink == nil { - var ret bool - return ret - } - return *o.ForceUnlink -} - -// GetForceUnlinkOk returns a tuple with the ForceUnlink field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkVolumeRequest) GetForceUnlinkOk() (bool, bool) { - if o == nil || o.ForceUnlink == nil { - var ret bool - return ret, false - } - return *o.ForceUnlink, true -} - -// HasForceUnlink returns a boolean if a field has been set. -func (o *UnlinkVolumeRequest) HasForceUnlink() bool { - if o != nil && o.ForceUnlink != nil { - return true - } - - return false -} - -// SetForceUnlink gets a reference to the given bool and assigns it to the ForceUnlink field. -func (o *UnlinkVolumeRequest) SetForceUnlink(v bool) { - o.ForceUnlink = &v -} - -// GetVolumeId returns the VolumeId field value -func (o *UnlinkVolumeRequest) GetVolumeId() string { - if o == nil { - var ret string - return ret - } - - return o.VolumeId -} - -// SetVolumeId sets field value -func (o *UnlinkVolumeRequest) SetVolumeId(v string) { - o.VolumeId = v -} - -type NullableUnlinkVolumeRequest struct { - Value UnlinkVolumeRequest - ExplicitNull bool -} - -func (v NullableUnlinkVolumeRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkVolumeRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_response.go deleted file mode 100644 index 88c0d4434..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_unlink_volume_response.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UnlinkVolumeResponse struct for UnlinkVolumeResponse -type UnlinkVolumeResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UnlinkVolumeResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UnlinkVolumeResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UnlinkVolumeResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UnlinkVolumeResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUnlinkVolumeResponse struct { - Value UnlinkVolumeResponse - ExplicitNull bool -} - -func (v NullableUnlinkVolumeResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUnlinkVolumeResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_request.go deleted file mode 100644 index c2fd0e869..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_request.go +++ /dev/null @@ -1,77 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateAccessKeyRequest struct for UpdateAccessKeyRequest -type UpdateAccessKeyRequest struct { - // The ID of the access key. - AccessKeyId string `json:"AccessKeyId"` - // The new state for the access key (`active` \\| `inactive`). - State string `json:"State"` -} - -// GetAccessKeyId returns the AccessKeyId field value -func (o *UpdateAccessKeyRequest) GetAccessKeyId() string { - if o == nil { - var ret string - return ret - } - - return o.AccessKeyId -} - -// SetAccessKeyId sets field value -func (o *UpdateAccessKeyRequest) SetAccessKeyId(v string) { - o.AccessKeyId = v -} - -// GetState returns the State field value -func (o *UpdateAccessKeyRequest) GetState() string { - if o == nil { - var ret string - return ret - } - - return o.State -} - -// SetState sets field value -func (o *UpdateAccessKeyRequest) SetState(v string) { - o.State = v -} - -type NullableUpdateAccessKeyRequest struct { - Value UpdateAccessKeyRequest - ExplicitNull bool -} - -func (v NullableUpdateAccessKeyRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateAccessKeyRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_response.go deleted file mode 100644 index eca0778cf..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_access_key_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateAccessKeyResponse struct for UpdateAccessKeyResponse -type UpdateAccessKeyResponse struct { - AccessKey *AccessKey `json:"AccessKey,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccessKey returns the AccessKey field value if set, zero value otherwise. -func (o *UpdateAccessKeyResponse) GetAccessKey() AccessKey { - if o == nil || o.AccessKey == nil { - var ret AccessKey - return ret - } - return *o.AccessKey -} - -// GetAccessKeyOk returns a tuple with the AccessKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccessKeyResponse) GetAccessKeyOk() (AccessKey, bool) { - if o == nil || o.AccessKey == nil { - var ret AccessKey - return ret, false - } - return *o.AccessKey, true -} - -// HasAccessKey returns a boolean if a field has been set. -func (o *UpdateAccessKeyResponse) HasAccessKey() bool { - if o != nil && o.AccessKey != nil { - return true - } - - return false -} - -// SetAccessKey gets a reference to the given AccessKey and assigns it to the AccessKey field. -func (o *UpdateAccessKeyResponse) SetAccessKey(v AccessKey) { - o.AccessKey = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateAccessKeyResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccessKeyResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateAccessKeyResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateAccessKeyResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateAccessKeyResponse struct { - Value UpdateAccessKeyResponse - ExplicitNull bool -} - -func (v NullableUpdateAccessKeyResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateAccessKeyResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_request.go deleted file mode 100644 index 2dfb44af2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_request.go +++ /dev/null @@ -1,498 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateAccountRequest struct for UpdateAccountRequest -type UpdateAccountRequest struct { - // The new city of the account owner. - City *string `json:"City,omitempty"` - // The new name of the company for the account. - CompanyName *string `json:"CompanyName,omitempty"` - // The new country of the account owner. - Country *string `json:"Country,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The new email address for the account. - Email *string `json:"Email,omitempty"` - // The new first name of the account owner. - FirstName *string `json:"FirstName,omitempty"` - // The new job title of the account owner. - JobTitle *string `json:"JobTitle,omitempty"` - // The new last name of the account owner. - LastName *string `json:"LastName,omitempty"` - // The new mobile phone number of the account owner. - MobileNumber *string `json:"MobileNumber,omitempty"` - // The new landline phone number of the account owner. - PhoneNumber *string `json:"PhoneNumber,omitempty"` - // The new state/province of the account owner. - StateProvince *string `json:"StateProvince,omitempty"` - // The new value added tax (VAT) number for the account. - VatNumber *string `json:"VatNumber,omitempty"` - // The new ZIP code of the city. - ZipCode *string `json:"ZipCode,omitempty"` -} - -// GetCity returns the City field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetCity() string { - if o == nil || o.City == nil { - var ret string - return ret - } - return *o.City -} - -// GetCityOk returns a tuple with the City field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetCityOk() (string, bool) { - if o == nil || o.City == nil { - var ret string - return ret, false - } - return *o.City, true -} - -// HasCity returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasCity() bool { - if o != nil && o.City != nil { - return true - } - - return false -} - -// SetCity gets a reference to the given string and assigns it to the City field. -func (o *UpdateAccountRequest) SetCity(v string) { - o.City = &v -} - -// GetCompanyName returns the CompanyName field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetCompanyName() string { - if o == nil || o.CompanyName == nil { - var ret string - return ret - } - return *o.CompanyName -} - -// GetCompanyNameOk returns a tuple with the CompanyName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetCompanyNameOk() (string, bool) { - if o == nil || o.CompanyName == nil { - var ret string - return ret, false - } - return *o.CompanyName, true -} - -// HasCompanyName returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasCompanyName() bool { - if o != nil && o.CompanyName != nil { - return true - } - - return false -} - -// SetCompanyName gets a reference to the given string and assigns it to the CompanyName field. -func (o *UpdateAccountRequest) SetCompanyName(v string) { - o.CompanyName = &v -} - -// GetCountry returns the Country field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetCountry() string { - if o == nil || o.Country == nil { - var ret string - return ret - } - return *o.Country -} - -// GetCountryOk returns a tuple with the Country field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetCountryOk() (string, bool) { - if o == nil || o.Country == nil { - var ret string - return ret, false - } - return *o.Country, true -} - -// HasCountry returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasCountry() bool { - if o != nil && o.Country != nil { - return true - } - - return false -} - -// SetCountry gets a reference to the given string and assigns it to the Country field. -func (o *UpdateAccountRequest) SetCountry(v string) { - o.Country = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateAccountRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetEmail returns the Email field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetEmail() string { - if o == nil || o.Email == nil { - var ret string - return ret - } - return *o.Email -} - -// GetEmailOk returns a tuple with the Email field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetEmailOk() (string, bool) { - if o == nil || o.Email == nil { - var ret string - return ret, false - } - return *o.Email, true -} - -// HasEmail returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasEmail() bool { - if o != nil && o.Email != nil { - return true - } - - return false -} - -// SetEmail gets a reference to the given string and assigns it to the Email field. -func (o *UpdateAccountRequest) SetEmail(v string) { - o.Email = &v -} - -// GetFirstName returns the FirstName field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetFirstName() string { - if o == nil || o.FirstName == nil { - var ret string - return ret - } - return *o.FirstName -} - -// GetFirstNameOk returns a tuple with the FirstName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetFirstNameOk() (string, bool) { - if o == nil || o.FirstName == nil { - var ret string - return ret, false - } - return *o.FirstName, true -} - -// HasFirstName returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasFirstName() bool { - if o != nil && o.FirstName != nil { - return true - } - - return false -} - -// SetFirstName gets a reference to the given string and assigns it to the FirstName field. -func (o *UpdateAccountRequest) SetFirstName(v string) { - o.FirstName = &v -} - -// GetJobTitle returns the JobTitle field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetJobTitle() string { - if o == nil || o.JobTitle == nil { - var ret string - return ret - } - return *o.JobTitle -} - -// GetJobTitleOk returns a tuple with the JobTitle field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetJobTitleOk() (string, bool) { - if o == nil || o.JobTitle == nil { - var ret string - return ret, false - } - return *o.JobTitle, true -} - -// HasJobTitle returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasJobTitle() bool { - if o != nil && o.JobTitle != nil { - return true - } - - return false -} - -// SetJobTitle gets a reference to the given string and assigns it to the JobTitle field. -func (o *UpdateAccountRequest) SetJobTitle(v string) { - o.JobTitle = &v -} - -// GetLastName returns the LastName field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetLastName() string { - if o == nil || o.LastName == nil { - var ret string - return ret - } - return *o.LastName -} - -// GetLastNameOk returns a tuple with the LastName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetLastNameOk() (string, bool) { - if o == nil || o.LastName == nil { - var ret string - return ret, false - } - return *o.LastName, true -} - -// HasLastName returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasLastName() bool { - if o != nil && o.LastName != nil { - return true - } - - return false -} - -// SetLastName gets a reference to the given string and assigns it to the LastName field. -func (o *UpdateAccountRequest) SetLastName(v string) { - o.LastName = &v -} - -// GetMobileNumber returns the MobileNumber field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetMobileNumber() string { - if o == nil || o.MobileNumber == nil { - var ret string - return ret - } - return *o.MobileNumber -} - -// GetMobileNumberOk returns a tuple with the MobileNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetMobileNumberOk() (string, bool) { - if o == nil || o.MobileNumber == nil { - var ret string - return ret, false - } - return *o.MobileNumber, true -} - -// HasMobileNumber returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasMobileNumber() bool { - if o != nil && o.MobileNumber != nil { - return true - } - - return false -} - -// SetMobileNumber gets a reference to the given string and assigns it to the MobileNumber field. -func (o *UpdateAccountRequest) SetMobileNumber(v string) { - o.MobileNumber = &v -} - -// GetPhoneNumber returns the PhoneNumber field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetPhoneNumber() string { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret - } - return *o.PhoneNumber -} - -// GetPhoneNumberOk returns a tuple with the PhoneNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetPhoneNumberOk() (string, bool) { - if o == nil || o.PhoneNumber == nil { - var ret string - return ret, false - } - return *o.PhoneNumber, true -} - -// HasPhoneNumber returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasPhoneNumber() bool { - if o != nil && o.PhoneNumber != nil { - return true - } - - return false -} - -// SetPhoneNumber gets a reference to the given string and assigns it to the PhoneNumber field. -func (o *UpdateAccountRequest) SetPhoneNumber(v string) { - o.PhoneNumber = &v -} - -// GetStateProvince returns the StateProvince field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetStateProvince() string { - if o == nil || o.StateProvince == nil { - var ret string - return ret - } - return *o.StateProvince -} - -// GetStateProvinceOk returns a tuple with the StateProvince field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetStateProvinceOk() (string, bool) { - if o == nil || o.StateProvince == nil { - var ret string - return ret, false - } - return *o.StateProvince, true -} - -// HasStateProvince returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasStateProvince() bool { - if o != nil && o.StateProvince != nil { - return true - } - - return false -} - -// SetStateProvince gets a reference to the given string and assigns it to the StateProvince field. -func (o *UpdateAccountRequest) SetStateProvince(v string) { - o.StateProvince = &v -} - -// GetVatNumber returns the VatNumber field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetVatNumber() string { - if o == nil || o.VatNumber == nil { - var ret string - return ret - } - return *o.VatNumber -} - -// GetVatNumberOk returns a tuple with the VatNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetVatNumberOk() (string, bool) { - if o == nil || o.VatNumber == nil { - var ret string - return ret, false - } - return *o.VatNumber, true -} - -// HasVatNumber returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasVatNumber() bool { - if o != nil && o.VatNumber != nil { - return true - } - - return false -} - -// SetVatNumber gets a reference to the given string and assigns it to the VatNumber field. -func (o *UpdateAccountRequest) SetVatNumber(v string) { - o.VatNumber = &v -} - -// GetZipCode returns the ZipCode field value if set, zero value otherwise. -func (o *UpdateAccountRequest) GetZipCode() string { - if o == nil || o.ZipCode == nil { - var ret string - return ret - } - return *o.ZipCode -} - -// GetZipCodeOk returns a tuple with the ZipCode field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountRequest) GetZipCodeOk() (string, bool) { - if o == nil || o.ZipCode == nil { - var ret string - return ret, false - } - return *o.ZipCode, true -} - -// HasZipCode returns a boolean if a field has been set. -func (o *UpdateAccountRequest) HasZipCode() bool { - if o != nil && o.ZipCode != nil { - return true - } - - return false -} - -// SetZipCode gets a reference to the given string and assigns it to the ZipCode field. -func (o *UpdateAccountRequest) SetZipCode(v string) { - o.ZipCode = &v -} - -type NullableUpdateAccountRequest struct { - Value UpdateAccountRequest - ExplicitNull bool -} - -func (v NullableUpdateAccountRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateAccountRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_response.go deleted file mode 100644 index 612ee7180..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_account_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateAccountResponse struct for UpdateAccountResponse -type UpdateAccountResponse struct { - Account *Account `json:"Account,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetAccount returns the Account field value if set, zero value otherwise. -func (o *UpdateAccountResponse) GetAccount() Account { - if o == nil || o.Account == nil { - var ret Account - return ret - } - return *o.Account -} - -// GetAccountOk returns a tuple with the Account field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountResponse) GetAccountOk() (Account, bool) { - if o == nil || o.Account == nil { - var ret Account - return ret, false - } - return *o.Account, true -} - -// HasAccount returns a boolean if a field has been set. -func (o *UpdateAccountResponse) HasAccount() bool { - if o != nil && o.Account != nil { - return true - } - - return false -} - -// SetAccount gets a reference to the given Account and assigns it to the Account field. -func (o *UpdateAccountResponse) SetAccount(v Account) { - o.Account = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateAccountResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateAccountResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateAccountResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateAccountResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateAccountResponse struct { - Value UpdateAccountResponse - ExplicitNull bool -} - -func (v NullableUpdateAccountResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateAccountResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_request.go deleted file mode 100644 index 622f20ea9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_request.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateFlexibleGpuRequest struct for UpdateFlexibleGpuRequest -type UpdateFlexibleGpuRequest struct { - // If `true`, the fGPU is deleted when the VM is terminated. - DeleteOnVmDeletion *bool `json:"DeleteOnVmDeletion,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the fGPU you want to modify. - FlexibleGpuId string `json:"FlexibleGpuId"` -} - -// GetDeleteOnVmDeletion returns the DeleteOnVmDeletion field value if set, zero value otherwise. -func (o *UpdateFlexibleGpuRequest) GetDeleteOnVmDeletion() bool { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret - } - return *o.DeleteOnVmDeletion -} - -// GetDeleteOnVmDeletionOk returns a tuple with the DeleteOnVmDeletion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateFlexibleGpuRequest) GetDeleteOnVmDeletionOk() (bool, bool) { - if o == nil || o.DeleteOnVmDeletion == nil { - var ret bool - return ret, false - } - return *o.DeleteOnVmDeletion, true -} - -// HasDeleteOnVmDeletion returns a boolean if a field has been set. -func (o *UpdateFlexibleGpuRequest) HasDeleteOnVmDeletion() bool { - if o != nil && o.DeleteOnVmDeletion != nil { - return true - } - - return false -} - -// SetDeleteOnVmDeletion gets a reference to the given bool and assigns it to the DeleteOnVmDeletion field. -func (o *UpdateFlexibleGpuRequest) SetDeleteOnVmDeletion(v bool) { - o.DeleteOnVmDeletion = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateFlexibleGpuRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateFlexibleGpuRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateFlexibleGpuRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateFlexibleGpuRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetFlexibleGpuId returns the FlexibleGpuId field value -func (o *UpdateFlexibleGpuRequest) GetFlexibleGpuId() string { - if o == nil { - var ret string - return ret - } - - return o.FlexibleGpuId -} - -// SetFlexibleGpuId sets field value -func (o *UpdateFlexibleGpuRequest) SetFlexibleGpuId(v string) { - o.FlexibleGpuId = v -} - -type NullableUpdateFlexibleGpuRequest struct { - Value UpdateFlexibleGpuRequest - ExplicitNull bool -} - -func (v NullableUpdateFlexibleGpuRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateFlexibleGpuRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_response.go deleted file mode 100644 index b03fa9f43..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_flexible_gpu_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateFlexibleGpuResponse struct for UpdateFlexibleGpuResponse -type UpdateFlexibleGpuResponse struct { - FlexibleGpu *FlexibleGpu `json:"FlexibleGpu,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetFlexibleGpu returns the FlexibleGpu field value if set, zero value otherwise. -func (o *UpdateFlexibleGpuResponse) GetFlexibleGpu() FlexibleGpu { - if o == nil || o.FlexibleGpu == nil { - var ret FlexibleGpu - return ret - } - return *o.FlexibleGpu -} - -// GetFlexibleGpuOk returns a tuple with the FlexibleGpu field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateFlexibleGpuResponse) GetFlexibleGpuOk() (FlexibleGpu, bool) { - if o == nil || o.FlexibleGpu == nil { - var ret FlexibleGpu - return ret, false - } - return *o.FlexibleGpu, true -} - -// HasFlexibleGpu returns a boolean if a field has been set. -func (o *UpdateFlexibleGpuResponse) HasFlexibleGpu() bool { - if o != nil && o.FlexibleGpu != nil { - return true - } - - return false -} - -// SetFlexibleGpu gets a reference to the given FlexibleGpu and assigns it to the FlexibleGpu field. -func (o *UpdateFlexibleGpuResponse) SetFlexibleGpu(v FlexibleGpu) { - o.FlexibleGpu = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateFlexibleGpuResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateFlexibleGpuResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateFlexibleGpuResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateFlexibleGpuResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateFlexibleGpuResponse struct { - Value UpdateFlexibleGpuResponse - ExplicitNull bool -} - -func (v NullableUpdateFlexibleGpuResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateFlexibleGpuResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_request.go deleted file mode 100644 index 250de0251..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_request.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateImageRequest struct for UpdateImageRequest -type UpdateImageRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the OMI you want to modify. - ImageId string `json:"ImageId"` - PermissionsToLaunch PermissionsOnResourceCreation `json:"PermissionsToLaunch"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateImageRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateImageRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateImageRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateImageRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetImageId returns the ImageId field value -func (o *UpdateImageRequest) GetImageId() string { - if o == nil { - var ret string - return ret - } - - return o.ImageId -} - -// SetImageId sets field value -func (o *UpdateImageRequest) SetImageId(v string) { - o.ImageId = v -} - -// GetPermissionsToLaunch returns the PermissionsToLaunch field value -func (o *UpdateImageRequest) GetPermissionsToLaunch() PermissionsOnResourceCreation { - if o == nil { - var ret PermissionsOnResourceCreation - return ret - } - - return o.PermissionsToLaunch -} - -// SetPermissionsToLaunch sets field value -func (o *UpdateImageRequest) SetPermissionsToLaunch(v PermissionsOnResourceCreation) { - o.PermissionsToLaunch = v -} - -type NullableUpdateImageRequest struct { - Value UpdateImageRequest - ExplicitNull bool -} - -func (v NullableUpdateImageRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateImageRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_response.go deleted file mode 100644 index bc556e129..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_image_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateImageResponse struct for UpdateImageResponse -type UpdateImageResponse struct { - Image *Image `json:"Image,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetImage returns the Image field value if set, zero value otherwise. -func (o *UpdateImageResponse) GetImage() Image { - if o == nil || o.Image == nil { - var ret Image - return ret - } - return *o.Image -} - -// GetImageOk returns a tuple with the Image field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateImageResponse) GetImageOk() (Image, bool) { - if o == nil || o.Image == nil { - var ret Image - return ret, false - } - return *o.Image, true -} - -// HasImage returns a boolean if a field has been set. -func (o *UpdateImageResponse) HasImage() bool { - if o != nil && o.Image != nil { - return true - } - - return false -} - -// SetImage gets a reference to the given Image and assigns it to the Image field. -func (o *UpdateImageResponse) SetImage(v Image) { - o.Image = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateImageResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateImageResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateImageResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateImageResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateImageResponse struct { - Value UpdateImageResponse - ExplicitNull bool -} - -func (v NullableUpdateImageResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateImageResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_request.go deleted file mode 100644 index 252c87dca..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_request.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateListenerRuleRequest struct for UpdateListenerRuleRequest -type UpdateListenerRuleRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. - HostPattern *string `json:"HostPattern,omitempty"` - // The name of the listener rule. - ListenerRuleName string `json:"ListenerRuleName"` - // A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~\"'@:+?]. - PathPattern *string `json:"PathPattern,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateListenerRuleRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateListenerRuleRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateListenerRuleRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateListenerRuleRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetHostPattern returns the HostPattern field value if set, zero value otherwise. -func (o *UpdateListenerRuleRequest) GetHostPattern() string { - if o == nil || o.HostPattern == nil { - var ret string - return ret - } - return *o.HostPattern -} - -// GetHostPatternOk returns a tuple with the HostPattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateListenerRuleRequest) GetHostPatternOk() (string, bool) { - if o == nil || o.HostPattern == nil { - var ret string - return ret, false - } - return *o.HostPattern, true -} - -// HasHostPattern returns a boolean if a field has been set. -func (o *UpdateListenerRuleRequest) HasHostPattern() bool { - if o != nil && o.HostPattern != nil { - return true - } - - return false -} - -// SetHostPattern gets a reference to the given string and assigns it to the HostPattern field. -func (o *UpdateListenerRuleRequest) SetHostPattern(v string) { - o.HostPattern = &v -} - -// GetListenerRuleName returns the ListenerRuleName field value -func (o *UpdateListenerRuleRequest) GetListenerRuleName() string { - if o == nil { - var ret string - return ret - } - - return o.ListenerRuleName -} - -// SetListenerRuleName sets field value -func (o *UpdateListenerRuleRequest) SetListenerRuleName(v string) { - o.ListenerRuleName = v -} - -// GetPathPattern returns the PathPattern field value if set, zero value otherwise. -func (o *UpdateListenerRuleRequest) GetPathPattern() string { - if o == nil || o.PathPattern == nil { - var ret string - return ret - } - return *o.PathPattern -} - -// GetPathPatternOk returns a tuple with the PathPattern field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateListenerRuleRequest) GetPathPatternOk() (string, bool) { - if o == nil || o.PathPattern == nil { - var ret string - return ret, false - } - return *o.PathPattern, true -} - -// HasPathPattern returns a boolean if a field has been set. -func (o *UpdateListenerRuleRequest) HasPathPattern() bool { - if o != nil && o.PathPattern != nil { - return true - } - - return false -} - -// SetPathPattern gets a reference to the given string and assigns it to the PathPattern field. -func (o *UpdateListenerRuleRequest) SetPathPattern(v string) { - o.PathPattern = &v -} - -type NullableUpdateListenerRuleRequest struct { - Value UpdateListenerRuleRequest - ExplicitNull bool -} - -func (v NullableUpdateListenerRuleRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateListenerRuleRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_response.go deleted file mode 100644 index 382a24344..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_listener_rule_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateListenerRuleResponse struct for UpdateListenerRuleResponse -type UpdateListenerRuleResponse struct { - ListenerRule *ListenerRule `json:"ListenerRule,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetListenerRule returns the ListenerRule field value if set, zero value otherwise. -func (o *UpdateListenerRuleResponse) GetListenerRule() ListenerRule { - if o == nil || o.ListenerRule == nil { - var ret ListenerRule - return ret - } - return *o.ListenerRule -} - -// GetListenerRuleOk returns a tuple with the ListenerRule field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateListenerRuleResponse) GetListenerRuleOk() (ListenerRule, bool) { - if o == nil || o.ListenerRule == nil { - var ret ListenerRule - return ret, false - } - return *o.ListenerRule, true -} - -// HasListenerRule returns a boolean if a field has been set. -func (o *UpdateListenerRuleResponse) HasListenerRule() bool { - if o != nil && o.ListenerRule != nil { - return true - } - - return false -} - -// SetListenerRule gets a reference to the given ListenerRule and assigns it to the ListenerRule field. -func (o *UpdateListenerRuleResponse) SetListenerRule(v ListenerRule) { - o.ListenerRule = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateListenerRuleResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateListenerRuleResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateListenerRuleResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateListenerRuleResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateListenerRuleResponse struct { - Value UpdateListenerRuleResponse - ExplicitNull bool -} - -func (v NullableUpdateListenerRuleResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateListenerRuleResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_request.go deleted file mode 100644 index b7fbcabb5..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_request.go +++ /dev/null @@ -1,268 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateLoadBalancerRequest struct for UpdateLoadBalancerRequest -type UpdateLoadBalancerRequest struct { - AccessLog *AccessLog `json:"AccessLog,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - HealthCheck *HealthCheck `json:"HealthCheck,omitempty"` - // The name of the load balancer. - LoadBalancerName string `json:"LoadBalancerName"` - // The port on which the load balancer is listening (between `1` and `65535`, both included). - LoadBalancerPort *int64 `json:"LoadBalancerPort,omitempty"` - // The list of policy names (must contain all the policies to be enabled). - PolicyNames *[]string `json:"PolicyNames,omitempty"` - // The Outscale Resource Name (ORN) of the SSL certificate. - ServerCertificateId *string `json:"ServerCertificateId,omitempty"` -} - -// GetAccessLog returns the AccessLog field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetAccessLog() AccessLog { - if o == nil || o.AccessLog == nil { - var ret AccessLog - return ret - } - return *o.AccessLog -} - -// GetAccessLogOk returns a tuple with the AccessLog field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetAccessLogOk() (AccessLog, bool) { - if o == nil || o.AccessLog == nil { - var ret AccessLog - return ret, false - } - return *o.AccessLog, true -} - -// HasAccessLog returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasAccessLog() bool { - if o != nil && o.AccessLog != nil { - return true - } - - return false -} - -// SetAccessLog gets a reference to the given AccessLog and assigns it to the AccessLog field. -func (o *UpdateLoadBalancerRequest) SetAccessLog(v AccessLog) { - o.AccessLog = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateLoadBalancerRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetHealthCheck returns the HealthCheck field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetHealthCheck() HealthCheck { - if o == nil || o.HealthCheck == nil { - var ret HealthCheck - return ret - } - return *o.HealthCheck -} - -// GetHealthCheckOk returns a tuple with the HealthCheck field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetHealthCheckOk() (HealthCheck, bool) { - if o == nil || o.HealthCheck == nil { - var ret HealthCheck - return ret, false - } - return *o.HealthCheck, true -} - -// HasHealthCheck returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasHealthCheck() bool { - if o != nil && o.HealthCheck != nil { - return true - } - - return false -} - -// SetHealthCheck gets a reference to the given HealthCheck and assigns it to the HealthCheck field. -func (o *UpdateLoadBalancerRequest) SetHealthCheck(v HealthCheck) { - o.HealthCheck = &v -} - -// GetLoadBalancerName returns the LoadBalancerName field value -func (o *UpdateLoadBalancerRequest) GetLoadBalancerName() string { - if o == nil { - var ret string - return ret - } - - return o.LoadBalancerName -} - -// SetLoadBalancerName sets field value -func (o *UpdateLoadBalancerRequest) SetLoadBalancerName(v string) { - o.LoadBalancerName = v -} - -// GetLoadBalancerPort returns the LoadBalancerPort field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetLoadBalancerPort() int64 { - if o == nil || o.LoadBalancerPort == nil { - var ret int64 - return ret - } - return *o.LoadBalancerPort -} - -// GetLoadBalancerPortOk returns a tuple with the LoadBalancerPort field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetLoadBalancerPortOk() (int64, bool) { - if o == nil || o.LoadBalancerPort == nil { - var ret int64 - return ret, false - } - return *o.LoadBalancerPort, true -} - -// HasLoadBalancerPort returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasLoadBalancerPort() bool { - if o != nil && o.LoadBalancerPort != nil { - return true - } - - return false -} - -// SetLoadBalancerPort gets a reference to the given int64 and assigns it to the LoadBalancerPort field. -func (o *UpdateLoadBalancerRequest) SetLoadBalancerPort(v int64) { - o.LoadBalancerPort = &v -} - -// GetPolicyNames returns the PolicyNames field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetPolicyNames() []string { - if o == nil || o.PolicyNames == nil { - var ret []string - return ret - } - return *o.PolicyNames -} - -// GetPolicyNamesOk returns a tuple with the PolicyNames field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetPolicyNamesOk() ([]string, bool) { - if o == nil || o.PolicyNames == nil { - var ret []string - return ret, false - } - return *o.PolicyNames, true -} - -// HasPolicyNames returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasPolicyNames() bool { - if o != nil && o.PolicyNames != nil { - return true - } - - return false -} - -// SetPolicyNames gets a reference to the given []string and assigns it to the PolicyNames field. -func (o *UpdateLoadBalancerRequest) SetPolicyNames(v []string) { - o.PolicyNames = &v -} - -// GetServerCertificateId returns the ServerCertificateId field value if set, zero value otherwise. -func (o *UpdateLoadBalancerRequest) GetServerCertificateId() string { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret - } - return *o.ServerCertificateId -} - -// GetServerCertificateIdOk returns a tuple with the ServerCertificateId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerRequest) GetServerCertificateIdOk() (string, bool) { - if o == nil || o.ServerCertificateId == nil { - var ret string - return ret, false - } - return *o.ServerCertificateId, true -} - -// HasServerCertificateId returns a boolean if a field has been set. -func (o *UpdateLoadBalancerRequest) HasServerCertificateId() bool { - if o != nil && o.ServerCertificateId != nil { - return true - } - - return false -} - -// SetServerCertificateId gets a reference to the given string and assigns it to the ServerCertificateId field. -func (o *UpdateLoadBalancerRequest) SetServerCertificateId(v string) { - o.ServerCertificateId = &v -} - -type NullableUpdateLoadBalancerRequest struct { - Value UpdateLoadBalancerRequest - ExplicitNull bool -} - -func (v NullableUpdateLoadBalancerRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateLoadBalancerRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_response.go deleted file mode 100644 index 0c070d538..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_load_balancer_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateLoadBalancerResponse struct for UpdateLoadBalancerResponse -type UpdateLoadBalancerResponse struct { - LoadBalancer *LoadBalancer `json:"LoadBalancer,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetLoadBalancer returns the LoadBalancer field value if set, zero value otherwise. -func (o *UpdateLoadBalancerResponse) GetLoadBalancer() LoadBalancer { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret - } - return *o.LoadBalancer -} - -// GetLoadBalancerOk returns a tuple with the LoadBalancer field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerResponse) GetLoadBalancerOk() (LoadBalancer, bool) { - if o == nil || o.LoadBalancer == nil { - var ret LoadBalancer - return ret, false - } - return *o.LoadBalancer, true -} - -// HasLoadBalancer returns a boolean if a field has been set. -func (o *UpdateLoadBalancerResponse) HasLoadBalancer() bool { - if o != nil && o.LoadBalancer != nil { - return true - } - - return false -} - -// SetLoadBalancer gets a reference to the given LoadBalancer and assigns it to the LoadBalancer field. -func (o *UpdateLoadBalancerResponse) SetLoadBalancer(v LoadBalancer) { - o.LoadBalancer = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateLoadBalancerResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateLoadBalancerResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateLoadBalancerResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateLoadBalancerResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateLoadBalancerResponse struct { - Value UpdateLoadBalancerResponse - ExplicitNull bool -} - -func (v NullableUpdateLoadBalancerResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateLoadBalancerResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_request.go deleted file mode 100644 index 1838f2264..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_request.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNetAccessPointRequest struct for UpdateNetAccessPointRequest -type UpdateNetAccessPointRequest struct { - // One or more IDs of route tables to associate with the specified Net access point. - AddRouteTableIds *[]string `json:"AddRouteTableIds,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net access point. - NetAccessPointId string `json:"NetAccessPointId"` - // One or more IDs of route tables to disassociate from the specified Net access point. - RemoveRouteTableIds *[]string `json:"RemoveRouteTableIds,omitempty"` -} - -// GetAddRouteTableIds returns the AddRouteTableIds field value if set, zero value otherwise. -func (o *UpdateNetAccessPointRequest) GetAddRouteTableIds() []string { - if o == nil || o.AddRouteTableIds == nil { - var ret []string - return ret - } - return *o.AddRouteTableIds -} - -// GetAddRouteTableIdsOk returns a tuple with the AddRouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetAccessPointRequest) GetAddRouteTableIdsOk() ([]string, bool) { - if o == nil || o.AddRouteTableIds == nil { - var ret []string - return ret, false - } - return *o.AddRouteTableIds, true -} - -// HasAddRouteTableIds returns a boolean if a field has been set. -func (o *UpdateNetAccessPointRequest) HasAddRouteTableIds() bool { - if o != nil && o.AddRouteTableIds != nil { - return true - } - - return false -} - -// SetAddRouteTableIds gets a reference to the given []string and assigns it to the AddRouteTableIds field. -func (o *UpdateNetAccessPointRequest) SetAddRouteTableIds(v []string) { - o.AddRouteTableIds = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateNetAccessPointRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetAccessPointRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateNetAccessPointRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateNetAccessPointRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetAccessPointId returns the NetAccessPointId field value -func (o *UpdateNetAccessPointRequest) GetNetAccessPointId() string { - if o == nil { - var ret string - return ret - } - - return o.NetAccessPointId -} - -// SetNetAccessPointId sets field value -func (o *UpdateNetAccessPointRequest) SetNetAccessPointId(v string) { - o.NetAccessPointId = v -} - -// GetRemoveRouteTableIds returns the RemoveRouteTableIds field value if set, zero value otherwise. -func (o *UpdateNetAccessPointRequest) GetRemoveRouteTableIds() []string { - if o == nil || o.RemoveRouteTableIds == nil { - var ret []string - return ret - } - return *o.RemoveRouteTableIds -} - -// GetRemoveRouteTableIdsOk returns a tuple with the RemoveRouteTableIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetAccessPointRequest) GetRemoveRouteTableIdsOk() ([]string, bool) { - if o == nil || o.RemoveRouteTableIds == nil { - var ret []string - return ret, false - } - return *o.RemoveRouteTableIds, true -} - -// HasRemoveRouteTableIds returns a boolean if a field has been set. -func (o *UpdateNetAccessPointRequest) HasRemoveRouteTableIds() bool { - if o != nil && o.RemoveRouteTableIds != nil { - return true - } - - return false -} - -// SetRemoveRouteTableIds gets a reference to the given []string and assigns it to the RemoveRouteTableIds field. -func (o *UpdateNetAccessPointRequest) SetRemoveRouteTableIds(v []string) { - o.RemoveRouteTableIds = &v -} - -type NullableUpdateNetAccessPointRequest struct { - Value UpdateNetAccessPointRequest - ExplicitNull bool -} - -func (v NullableUpdateNetAccessPointRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNetAccessPointRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_response.go deleted file mode 100644 index 27b4566b9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_access_point_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNetAccessPointResponse struct for UpdateNetAccessPointResponse -type UpdateNetAccessPointResponse struct { - NetAccessPoint *NetAccessPoint `json:"NetAccessPoint,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNetAccessPoint returns the NetAccessPoint field value if set, zero value otherwise. -func (o *UpdateNetAccessPointResponse) GetNetAccessPoint() NetAccessPoint { - if o == nil || o.NetAccessPoint == nil { - var ret NetAccessPoint - return ret - } - return *o.NetAccessPoint -} - -// GetNetAccessPointOk returns a tuple with the NetAccessPoint field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetAccessPointResponse) GetNetAccessPointOk() (NetAccessPoint, bool) { - if o == nil || o.NetAccessPoint == nil { - var ret NetAccessPoint - return ret, false - } - return *o.NetAccessPoint, true -} - -// HasNetAccessPoint returns a boolean if a field has been set. -func (o *UpdateNetAccessPointResponse) HasNetAccessPoint() bool { - if o != nil && o.NetAccessPoint != nil { - return true - } - - return false -} - -// SetNetAccessPoint gets a reference to the given NetAccessPoint and assigns it to the NetAccessPoint field. -func (o *UpdateNetAccessPointResponse) SetNetAccessPoint(v NetAccessPoint) { - o.NetAccessPoint = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateNetAccessPointResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetAccessPointResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateNetAccessPointResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateNetAccessPointResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateNetAccessPointResponse struct { - Value UpdateNetAccessPointResponse - ExplicitNull bool -} - -func (v NullableUpdateNetAccessPointResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNetAccessPointResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_request.go deleted file mode 100644 index ac4b201e9..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNetRequest struct for UpdateNetRequest -type UpdateNetRequest struct { - // The ID of the DHCP options set (or `default` if you want to associate the default one). - DhcpOptionsSetId string `json:"DhcpOptionsSetId"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of the Net. - NetId string `json:"NetId"` -} - -// GetDhcpOptionsSetId returns the DhcpOptionsSetId field value -func (o *UpdateNetRequest) GetDhcpOptionsSetId() string { - if o == nil { - var ret string - return ret - } - - return o.DhcpOptionsSetId -} - -// SetDhcpOptionsSetId sets field value -func (o *UpdateNetRequest) SetDhcpOptionsSetId(v string) { - o.DhcpOptionsSetId = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateNetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateNetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateNetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetNetId returns the NetId field value -func (o *UpdateNetRequest) GetNetId() string { - if o == nil { - var ret string - return ret - } - - return o.NetId -} - -// SetNetId sets field value -func (o *UpdateNetRequest) SetNetId(v string) { - o.NetId = v -} - -type NullableUpdateNetRequest struct { - Value UpdateNetRequest - ExplicitNull bool -} - -func (v NullableUpdateNetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_response.go deleted file mode 100644 index 35c1d8be2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_net_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNetResponse struct for UpdateNetResponse -type UpdateNetResponse struct { - Net *Net `json:"Net,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNet returns the Net field value if set, zero value otherwise. -func (o *UpdateNetResponse) GetNet() Net { - if o == nil || o.Net == nil { - var ret Net - return ret - } - return *o.Net -} - -// GetNetOk returns a tuple with the Net field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetResponse) GetNetOk() (Net, bool) { - if o == nil || o.Net == nil { - var ret Net - return ret, false - } - return *o.Net, true -} - -// HasNet returns a boolean if a field has been set. -func (o *UpdateNetResponse) HasNet() bool { - if o != nil && o.Net != nil { - return true - } - - return false -} - -// SetNet gets a reference to the given Net and assigns it to the Net field. -func (o *UpdateNetResponse) SetNet(v Net) { - o.Net = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateNetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateNetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateNetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateNetResponse struct { - Value UpdateNetResponse - ExplicitNull bool -} - -func (v NullableUpdateNetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_request.go deleted file mode 100644 index d2c1f2652..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_request.go +++ /dev/null @@ -1,199 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNicRequest struct for UpdateNicRequest -type UpdateNicRequest struct { - // A new description for the NIC. - Description *string `json:"Description,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - LinkNic *LinkNicToUpdate `json:"LinkNic,omitempty"` - // The ID of the NIC you want to modify. - NicId string `json:"NicId"` - // One or more IDs of security groups for the NIC.
You must specify at least one group, even if you use the default security group in the Net. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` -} - -// GetDescription returns the Description field value if set, zero value otherwise. -func (o *UpdateNicRequest) GetDescription() string { - if o == nil || o.Description == nil { - var ret string - return ret - } - return *o.Description -} - -// GetDescriptionOk returns a tuple with the Description field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicRequest) GetDescriptionOk() (string, bool) { - if o == nil || o.Description == nil { - var ret string - return ret, false - } - return *o.Description, true -} - -// HasDescription returns a boolean if a field has been set. -func (o *UpdateNicRequest) HasDescription() bool { - if o != nil && o.Description != nil { - return true - } - - return false -} - -// SetDescription gets a reference to the given string and assigns it to the Description field. -func (o *UpdateNicRequest) SetDescription(v string) { - o.Description = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateNicRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateNicRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateNicRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetLinkNic returns the LinkNic field value if set, zero value otherwise. -func (o *UpdateNicRequest) GetLinkNic() LinkNicToUpdate { - if o == nil || o.LinkNic == nil { - var ret LinkNicToUpdate - return ret - } - return *o.LinkNic -} - -// GetLinkNicOk returns a tuple with the LinkNic field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicRequest) GetLinkNicOk() (LinkNicToUpdate, bool) { - if o == nil || o.LinkNic == nil { - var ret LinkNicToUpdate - return ret, false - } - return *o.LinkNic, true -} - -// HasLinkNic returns a boolean if a field has been set. -func (o *UpdateNicRequest) HasLinkNic() bool { - if o != nil && o.LinkNic != nil { - return true - } - - return false -} - -// SetLinkNic gets a reference to the given LinkNicToUpdate and assigns it to the LinkNic field. -func (o *UpdateNicRequest) SetLinkNic(v LinkNicToUpdate) { - o.LinkNic = &v -} - -// GetNicId returns the NicId field value -func (o *UpdateNicRequest) GetNicId() string { - if o == nil { - var ret string - return ret - } - - return o.NicId -} - -// SetNicId sets field value -func (o *UpdateNicRequest) SetNicId(v string) { - o.NicId = v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *UpdateNicRequest) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicRequest) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *UpdateNicRequest) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *UpdateNicRequest) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -type NullableUpdateNicRequest struct { - Value UpdateNicRequest - ExplicitNull bool -} - -func (v NullableUpdateNicRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNicRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_response.go deleted file mode 100644 index 98a10da0a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_nic_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateNicResponse struct for UpdateNicResponse -type UpdateNicResponse struct { - Nic *Nic `json:"Nic,omitempty"` - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` -} - -// GetNic returns the Nic field value if set, zero value otherwise. -func (o *UpdateNicResponse) GetNic() Nic { - if o == nil || o.Nic == nil { - var ret Nic - return ret - } - return *o.Nic -} - -// GetNicOk returns a tuple with the Nic field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicResponse) GetNicOk() (Nic, bool) { - if o == nil || o.Nic == nil { - var ret Nic - return ret, false - } - return *o.Nic, true -} - -// HasNic returns a boolean if a field has been set. -func (o *UpdateNicResponse) HasNic() bool { - if o != nil && o.Nic != nil { - return true - } - - return false -} - -// SetNic gets a reference to the given Nic and assigns it to the Nic field. -func (o *UpdateNicResponse) SetNic(v Nic) { - o.Nic = &v -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateNicResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateNicResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateNicResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateNicResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -type NullableUpdateNicResponse struct { - Value UpdateNicResponse - ExplicitNull bool -} - -func (v NullableUpdateNicResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateNicResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_request.go deleted file mode 100644 index fc0caeb93..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_request.go +++ /dev/null @@ -1,129 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateRoutePropagationRequest struct for UpdateRoutePropagationRequest -type UpdateRoutePropagationRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // If `true`, a virtual gateway can propagate routes to a specified route table of a Net. If `false`, the propagation is disabled. - Enable bool `json:"Enable"` - // The ID of the route table. - RouteTableId string `json:"RouteTableId"` - // The ID of the virtual gateway. - VirtualGatewayId string `json:"VirtualGatewayId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateRoutePropagationRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRoutePropagationRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateRoutePropagationRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateRoutePropagationRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetEnable returns the Enable field value -func (o *UpdateRoutePropagationRequest) GetEnable() bool { - if o == nil { - var ret bool - return ret - } - - return o.Enable -} - -// SetEnable sets field value -func (o *UpdateRoutePropagationRequest) SetEnable(v bool) { - o.Enable = v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *UpdateRoutePropagationRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *UpdateRoutePropagationRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value -func (o *UpdateRoutePropagationRequest) GetVirtualGatewayId() string { - if o == nil { - var ret string - return ret - } - - return o.VirtualGatewayId -} - -// SetVirtualGatewayId sets field value -func (o *UpdateRoutePropagationRequest) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = v -} - -type NullableUpdateRoutePropagationRequest struct { - Value UpdateRoutePropagationRequest - ExplicitNull bool -} - -func (v NullableUpdateRoutePropagationRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateRoutePropagationRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_response.go deleted file mode 100644 index 9aee98a32..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_propagation_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateRoutePropagationResponse struct for UpdateRoutePropagationResponse -type UpdateRoutePropagationResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - RouteTable *RouteTable `json:"RouteTable,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateRoutePropagationResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRoutePropagationResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateRoutePropagationResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateRoutePropagationResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTable returns the RouteTable field value if set, zero value otherwise. -func (o *UpdateRoutePropagationResponse) GetRouteTable() RouteTable { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret - } - return *o.RouteTable -} - -// GetRouteTableOk returns a tuple with the RouteTable field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRoutePropagationResponse) GetRouteTableOk() (RouteTable, bool) { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret, false - } - return *o.RouteTable, true -} - -// HasRouteTable returns a boolean if a field has been set. -func (o *UpdateRoutePropagationResponse) HasRouteTable() bool { - if o != nil && o.RouteTable != nil { - return true - } - - return false -} - -// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. -func (o *UpdateRoutePropagationResponse) SetRouteTable(v RouteTable) { - o.RouteTable = &v -} - -type NullableUpdateRoutePropagationResponse struct { - Value UpdateRoutePropagationResponse - ExplicitNull bool -} - -func (v NullableUpdateRoutePropagationResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateRoutePropagationResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_request.go deleted file mode 100644 index 5b83f246c..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_request.go +++ /dev/null @@ -1,287 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateRouteRequest struct for UpdateRouteRequest -type UpdateRouteRequest struct { - // The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - DestinationIpRange string `json:"DestinationIpRange"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The ID of an Internet service or virtual gateway attached to your Net. - GatewayId *string `json:"GatewayId,omitempty"` - // The ID of a NAT service. - NatServiceId *string `json:"NatServiceId,omitempty"` - // The ID of a Net peering connection. - NetPeeringId *string `json:"NetPeeringId,omitempty"` - // The ID of a network interface card (NIC). - NicId *string `json:"NicId,omitempty"` - // The ID of the route table. - RouteTableId string `json:"RouteTableId"` - // The ID of a NAT VM in your Net. - VmId *string `json:"VmId,omitempty"` -} - -// GetDestinationIpRange returns the DestinationIpRange field value -func (o *UpdateRouteRequest) GetDestinationIpRange() string { - if o == nil { - var ret string - return ret - } - - return o.DestinationIpRange -} - -// SetDestinationIpRange sets field value -func (o *UpdateRouteRequest) SetDestinationIpRange(v string) { - o.DestinationIpRange = v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateRouteRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetGatewayId returns the GatewayId field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetGatewayId() string { - if o == nil || o.GatewayId == nil { - var ret string - return ret - } - return *o.GatewayId -} - -// GetGatewayIdOk returns a tuple with the GatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetGatewayIdOk() (string, bool) { - if o == nil || o.GatewayId == nil { - var ret string - return ret, false - } - return *o.GatewayId, true -} - -// HasGatewayId returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasGatewayId() bool { - if o != nil && o.GatewayId != nil { - return true - } - - return false -} - -// SetGatewayId gets a reference to the given string and assigns it to the GatewayId field. -func (o *UpdateRouteRequest) SetGatewayId(v string) { - o.GatewayId = &v -} - -// GetNatServiceId returns the NatServiceId field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetNatServiceId() string { - if o == nil || o.NatServiceId == nil { - var ret string - return ret - } - return *o.NatServiceId -} - -// GetNatServiceIdOk returns a tuple with the NatServiceId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetNatServiceIdOk() (string, bool) { - if o == nil || o.NatServiceId == nil { - var ret string - return ret, false - } - return *o.NatServiceId, true -} - -// HasNatServiceId returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasNatServiceId() bool { - if o != nil && o.NatServiceId != nil { - return true - } - - return false -} - -// SetNatServiceId gets a reference to the given string and assigns it to the NatServiceId field. -func (o *UpdateRouteRequest) SetNatServiceId(v string) { - o.NatServiceId = &v -} - -// GetNetPeeringId returns the NetPeeringId field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetNetPeeringId() string { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret - } - return *o.NetPeeringId -} - -// GetNetPeeringIdOk returns a tuple with the NetPeeringId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetNetPeeringIdOk() (string, bool) { - if o == nil || o.NetPeeringId == nil { - var ret string - return ret, false - } - return *o.NetPeeringId, true -} - -// HasNetPeeringId returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasNetPeeringId() bool { - if o != nil && o.NetPeeringId != nil { - return true - } - - return false -} - -// SetNetPeeringId gets a reference to the given string and assigns it to the NetPeeringId field. -func (o *UpdateRouteRequest) SetNetPeeringId(v string) { - o.NetPeeringId = &v -} - -// GetNicId returns the NicId field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetNicId() string { - if o == nil || o.NicId == nil { - var ret string - return ret - } - return *o.NicId -} - -// GetNicIdOk returns a tuple with the NicId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetNicIdOk() (string, bool) { - if o == nil || o.NicId == nil { - var ret string - return ret, false - } - return *o.NicId, true -} - -// HasNicId returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasNicId() bool { - if o != nil && o.NicId != nil { - return true - } - - return false -} - -// SetNicId gets a reference to the given string and assigns it to the NicId field. -func (o *UpdateRouteRequest) SetNicId(v string) { - o.NicId = &v -} - -// GetRouteTableId returns the RouteTableId field value -func (o *UpdateRouteRequest) GetRouteTableId() string { - if o == nil { - var ret string - return ret - } - - return o.RouteTableId -} - -// SetRouteTableId sets field value -func (o *UpdateRouteRequest) SetRouteTableId(v string) { - o.RouteTableId = v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *UpdateRouteRequest) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteRequest) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *UpdateRouteRequest) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *UpdateRouteRequest) SetVmId(v string) { - o.VmId = &v -} - -type NullableUpdateRouteRequest struct { - Value UpdateRouteRequest - ExplicitNull bool -} - -func (v NullableUpdateRouteRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateRouteRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_response.go deleted file mode 100644 index d64126d44..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_route_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateRouteResponse struct for UpdateRouteResponse -type UpdateRouteResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - RouteTable *RouteTable `json:"RouteTable,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateRouteResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateRouteResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateRouteResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetRouteTable returns the RouteTable field value if set, zero value otherwise. -func (o *UpdateRouteResponse) GetRouteTable() RouteTable { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret - } - return *o.RouteTable -} - -// GetRouteTableOk returns a tuple with the RouteTable field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateRouteResponse) GetRouteTableOk() (RouteTable, bool) { - if o == nil || o.RouteTable == nil { - var ret RouteTable - return ret, false - } - return *o.RouteTable, true -} - -// HasRouteTable returns a boolean if a field has been set. -func (o *UpdateRouteResponse) HasRouteTable() bool { - if o != nil && o.RouteTable != nil { - return true - } - - return false -} - -// SetRouteTable gets a reference to the given RouteTable and assigns it to the RouteTable field. -func (o *UpdateRouteResponse) SetRouteTable(v RouteTable) { - o.RouteTable = &v -} - -type NullableUpdateRouteResponse struct { - Value UpdateRouteResponse - ExplicitNull bool -} - -func (v NullableUpdateRouteResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateRouteResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_request.go deleted file mode 100644 index e3545957a..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_request.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateServerCertificateRequest struct for UpdateServerCertificateRequest -type UpdateServerCertificateRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // The name of the server certificate you want to modify. - Name *string `json:"Name,omitempty"` - // A new name for the server certificate. - NewName *string `json:"NewName,omitempty"` - // A new path for the server certificate. - NewPath *string `json:"NewPath,omitempty"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateServerCertificateRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateServerCertificateRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateServerCertificateRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *UpdateServerCertificateRequest) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateRequest) GetNameOk() (string, bool) { - if o == nil || o.Name == nil { - var ret string - return ret, false - } - return *o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *UpdateServerCertificateRequest) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *UpdateServerCertificateRequest) SetName(v string) { - o.Name = &v -} - -// GetNewName returns the NewName field value if set, zero value otherwise. -func (o *UpdateServerCertificateRequest) GetNewName() string { - if o == nil || o.NewName == nil { - var ret string - return ret - } - return *o.NewName -} - -// GetNewNameOk returns a tuple with the NewName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateRequest) GetNewNameOk() (string, bool) { - if o == nil || o.NewName == nil { - var ret string - return ret, false - } - return *o.NewName, true -} - -// HasNewName returns a boolean if a field has been set. -func (o *UpdateServerCertificateRequest) HasNewName() bool { - if o != nil && o.NewName != nil { - return true - } - - return false -} - -// SetNewName gets a reference to the given string and assigns it to the NewName field. -func (o *UpdateServerCertificateRequest) SetNewName(v string) { - o.NewName = &v -} - -// GetNewPath returns the NewPath field value if set, zero value otherwise. -func (o *UpdateServerCertificateRequest) GetNewPath() string { - if o == nil || o.NewPath == nil { - var ret string - return ret - } - return *o.NewPath -} - -// GetNewPathOk returns a tuple with the NewPath field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateRequest) GetNewPathOk() (string, bool) { - if o == nil || o.NewPath == nil { - var ret string - return ret, false - } - return *o.NewPath, true -} - -// HasNewPath returns a boolean if a field has been set. -func (o *UpdateServerCertificateRequest) HasNewPath() bool { - if o != nil && o.NewPath != nil { - return true - } - - return false -} - -// SetNewPath gets a reference to the given string and assigns it to the NewPath field. -func (o *UpdateServerCertificateRequest) SetNewPath(v string) { - o.NewPath = &v -} - -type NullableUpdateServerCertificateRequest struct { - Value UpdateServerCertificateRequest - ExplicitNull bool -} - -func (v NullableUpdateServerCertificateRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateServerCertificateRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_response.go deleted file mode 100644 index 9a6e73c7e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_server_certificate_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateServerCertificateResponse struct for UpdateServerCertificateResponse -type UpdateServerCertificateResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - ServerCertificate *ServerCertificate `json:"ServerCertificate,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateServerCertificateResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateServerCertificateResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateServerCertificateResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetServerCertificate returns the ServerCertificate field value if set, zero value otherwise. -func (o *UpdateServerCertificateResponse) GetServerCertificate() ServerCertificate { - if o == nil || o.ServerCertificate == nil { - var ret ServerCertificate - return ret - } - return *o.ServerCertificate -} - -// GetServerCertificateOk returns a tuple with the ServerCertificate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateServerCertificateResponse) GetServerCertificateOk() (ServerCertificate, bool) { - if o == nil || o.ServerCertificate == nil { - var ret ServerCertificate - return ret, false - } - return *o.ServerCertificate, true -} - -// HasServerCertificate returns a boolean if a field has been set. -func (o *UpdateServerCertificateResponse) HasServerCertificate() bool { - if o != nil && o.ServerCertificate != nil { - return true - } - - return false -} - -// SetServerCertificate gets a reference to the given ServerCertificate and assigns it to the ServerCertificate field. -func (o *UpdateServerCertificateResponse) SetServerCertificate(v ServerCertificate) { - o.ServerCertificate = &v -} - -type NullableUpdateServerCertificateResponse struct { - Value UpdateServerCertificateResponse - ExplicitNull bool -} - -func (v NullableUpdateServerCertificateResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateServerCertificateResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_request.go deleted file mode 100644 index 31adfc435..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_request.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateSnapshotRequest struct for UpdateSnapshotRequest -type UpdateSnapshotRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - PermissionsToCreateVolume PermissionsOnResourceCreation `json:"PermissionsToCreateVolume"` - // The ID of the snapshot. - SnapshotId string `json:"SnapshotId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateSnapshotRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSnapshotRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateSnapshotRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateSnapshotRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetPermissionsToCreateVolume returns the PermissionsToCreateVolume field value -func (o *UpdateSnapshotRequest) GetPermissionsToCreateVolume() PermissionsOnResourceCreation { - if o == nil { - var ret PermissionsOnResourceCreation - return ret - } - - return o.PermissionsToCreateVolume -} - -// SetPermissionsToCreateVolume sets field value -func (o *UpdateSnapshotRequest) SetPermissionsToCreateVolume(v PermissionsOnResourceCreation) { - o.PermissionsToCreateVolume = v -} - -// GetSnapshotId returns the SnapshotId field value -func (o *UpdateSnapshotRequest) GetSnapshotId() string { - if o == nil { - var ret string - return ret - } - - return o.SnapshotId -} - -// SetSnapshotId sets field value -func (o *UpdateSnapshotRequest) SetSnapshotId(v string) { - o.SnapshotId = v -} - -type NullableUpdateSnapshotRequest struct { - Value UpdateSnapshotRequest - ExplicitNull bool -} - -func (v NullableUpdateSnapshotRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateSnapshotRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_response.go deleted file mode 100644 index 4ed8c9d62..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_snapshot_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateSnapshotResponse struct for UpdateSnapshotResponse -type UpdateSnapshotResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Snapshot *Snapshot `json:"Snapshot,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateSnapshotResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSnapshotResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateSnapshotResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateSnapshotResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSnapshot returns the Snapshot field value if set, zero value otherwise. -func (o *UpdateSnapshotResponse) GetSnapshot() Snapshot { - if o == nil || o.Snapshot == nil { - var ret Snapshot - return ret - } - return *o.Snapshot -} - -// GetSnapshotOk returns a tuple with the Snapshot field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSnapshotResponse) GetSnapshotOk() (Snapshot, bool) { - if o == nil || o.Snapshot == nil { - var ret Snapshot - return ret, false - } - return *o.Snapshot, true -} - -// HasSnapshot returns a boolean if a field has been set. -func (o *UpdateSnapshotResponse) HasSnapshot() bool { - if o != nil && o.Snapshot != nil { - return true - } - - return false -} - -// SetSnapshot gets a reference to the given Snapshot and assigns it to the Snapshot field. -func (o *UpdateSnapshotResponse) SetSnapshot(v Snapshot) { - o.Snapshot = &v -} - -type NullableUpdateSnapshotResponse struct { - Value UpdateSnapshotResponse - ExplicitNull bool -} - -func (v NullableUpdateSnapshotResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateSnapshotResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_request.go deleted file mode 100644 index 66983c1ce..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_request.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateSubnetRequest struct for UpdateSubnetRequest -type UpdateSubnetRequest struct { - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. - MapPublicIpOnLaunch bool `json:"MapPublicIpOnLaunch"` - // The ID of the Subnet. - SubnetId string `json:"SubnetId"` -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateSubnetRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSubnetRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateSubnetRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateSubnetRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetMapPublicIpOnLaunch returns the MapPublicIpOnLaunch field value -func (o *UpdateSubnetRequest) GetMapPublicIpOnLaunch() bool { - if o == nil { - var ret bool - return ret - } - - return o.MapPublicIpOnLaunch -} - -// SetMapPublicIpOnLaunch sets field value -func (o *UpdateSubnetRequest) SetMapPublicIpOnLaunch(v bool) { - o.MapPublicIpOnLaunch = v -} - -// GetSubnetId returns the SubnetId field value -func (o *UpdateSubnetRequest) GetSubnetId() string { - if o == nil { - var ret string - return ret - } - - return o.SubnetId -} - -// SetSubnetId sets field value -func (o *UpdateSubnetRequest) SetSubnetId(v string) { - o.SubnetId = v -} - -type NullableUpdateSubnetRequest struct { - Value UpdateSubnetRequest - ExplicitNull bool -} - -func (v NullableUpdateSubnetRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateSubnetRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_response.go deleted file mode 100644 index 3c7e25212..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_subnet_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateSubnetResponse struct for UpdateSubnetResponse -type UpdateSubnetResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Subnet *Subnet `json:"Subnet,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateSubnetResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSubnetResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateSubnetResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateSubnetResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetSubnet returns the Subnet field value if set, zero value otherwise. -func (o *UpdateSubnetResponse) GetSubnet() Subnet { - if o == nil || o.Subnet == nil { - var ret Subnet - return ret - } - return *o.Subnet -} - -// GetSubnetOk returns a tuple with the Subnet field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateSubnetResponse) GetSubnetOk() (Subnet, bool) { - if o == nil || o.Subnet == nil { - var ret Subnet - return ret, false - } - return *o.Subnet, true -} - -// HasSubnet returns a boolean if a field has been set. -func (o *UpdateSubnetResponse) HasSubnet() bool { - if o != nil && o.Subnet != nil { - return true - } - - return false -} - -// SetSubnet gets a reference to the given Subnet and assigns it to the Subnet field. -func (o *UpdateSubnetResponse) SetSubnet(v Subnet) { - o.Subnet = &v -} - -type NullableUpdateSubnetResponse struct { - Value UpdateSubnetResponse - ExplicitNull bool -} - -func (v NullableUpdateSubnetResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateSubnetResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_request.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_request.go deleted file mode 100644 index eceb4bdb8..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_request.go +++ /dev/null @@ -1,445 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateVmRequest struct for UpdateVmRequest -type UpdateVmRequest struct { - // One or more block device mappings of the VM. - BlockDeviceMappings *[]BlockDeviceMappingVmUpdate `json:"BlockDeviceMappings,omitempty"` - // If `true`, the VM is optimized for BSU I/O. - BsuOptimized *bool `json:"BsuOptimized,omitempty"` - // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - DeletionProtection *bool `json:"DeletionProtection,omitempty"` - // If `true`, checks whether you have the required permissions to perform the action. - DryRun *bool `json:"DryRun,omitempty"` - // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` - // The name of the keypair.
To complete the replacement, manually replace the old public key with the new public key in the ~/.ssh/authorized_keys file located in the VM. Restart the VM to apply the change. - KeypairName *string `json:"KeypairName,omitempty"` - // The performance of the VM (`standard` \\| `high` \\| `highest`). - Performance *string `json:"Performance,omitempty"` - // One or more IDs of security groups for the VM. - SecurityGroupIds *[]string `json:"SecurityGroupIds,omitempty"` - // The Base64-encoded MIME user data. - UserData *string `json:"UserData,omitempty"` - // The ID of the VM. - VmId string `json:"VmId"` - // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. - VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` - // The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - VmType *string `json:"VmType,omitempty"` -} - -// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetBlockDeviceMappings() []BlockDeviceMappingVmUpdate { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingVmUpdate - return ret - } - return *o.BlockDeviceMappings -} - -// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetBlockDeviceMappingsOk() ([]BlockDeviceMappingVmUpdate, bool) { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingVmUpdate - return ret, false - } - return *o.BlockDeviceMappings, true -} - -// HasBlockDeviceMappings returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasBlockDeviceMappings() bool { - if o != nil && o.BlockDeviceMappings != nil { - return true - } - - return false -} - -// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingVmUpdate and assigns it to the BlockDeviceMappings field. -func (o *UpdateVmRequest) SetBlockDeviceMappings(v []BlockDeviceMappingVmUpdate) { - o.BlockDeviceMappings = &v -} - -// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetBsuOptimized() bool { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret - } - return *o.BsuOptimized -} - -// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetBsuOptimizedOk() (bool, bool) { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret, false - } - return *o.BsuOptimized, true -} - -// HasBsuOptimized returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasBsuOptimized() bool { - if o != nil && o.BsuOptimized != nil { - return true - } - - return false -} - -// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. -func (o *UpdateVmRequest) SetBsuOptimized(v bool) { - o.BsuOptimized = &v -} - -// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetDeletionProtection() bool { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret - } - return *o.DeletionProtection -} - -// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetDeletionProtectionOk() (bool, bool) { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret, false - } - return *o.DeletionProtection, true -} - -// HasDeletionProtection returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasDeletionProtection() bool { - if o != nil && o.DeletionProtection != nil { - return true - } - - return false -} - -// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. -func (o *UpdateVmRequest) SetDeletionProtection(v bool) { - o.DeletionProtection = &v -} - -// GetDryRun returns the DryRun field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetDryRun() bool { - if o == nil || o.DryRun == nil { - var ret bool - return ret - } - return *o.DryRun -} - -// GetDryRunOk returns a tuple with the DryRun field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetDryRunOk() (bool, bool) { - if o == nil || o.DryRun == nil { - var ret bool - return ret, false - } - return *o.DryRun, true -} - -// HasDryRun returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasDryRun() bool { - if o != nil && o.DryRun != nil { - return true - } - - return false -} - -// SetDryRun gets a reference to the given bool and assigns it to the DryRun field. -func (o *UpdateVmRequest) SetDryRun(v bool) { - o.DryRun = &v -} - -// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetIsSourceDestChecked() bool { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret - } - return *o.IsSourceDestChecked -} - -// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetIsSourceDestCheckedOk() (bool, bool) { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret, false - } - return *o.IsSourceDestChecked, true -} - -// HasIsSourceDestChecked returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasIsSourceDestChecked() bool { - if o != nil && o.IsSourceDestChecked != nil { - return true - } - - return false -} - -// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. -func (o *UpdateVmRequest) SetIsSourceDestChecked(v bool) { - o.IsSourceDestChecked = &v -} - -// GetKeypairName returns the KeypairName field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetKeypairName() string { - if o == nil || o.KeypairName == nil { - var ret string - return ret - } - return *o.KeypairName -} - -// GetKeypairNameOk returns a tuple with the KeypairName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetKeypairNameOk() (string, bool) { - if o == nil || o.KeypairName == nil { - var ret string - return ret, false - } - return *o.KeypairName, true -} - -// HasKeypairName returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasKeypairName() bool { - if o != nil && o.KeypairName != nil { - return true - } - - return false -} - -// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. -func (o *UpdateVmRequest) SetKeypairName(v string) { - o.KeypairName = &v -} - -// GetPerformance returns the Performance field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetPerformance() string { - if o == nil || o.Performance == nil { - var ret string - return ret - } - return *o.Performance -} - -// GetPerformanceOk returns a tuple with the Performance field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetPerformanceOk() (string, bool) { - if o == nil || o.Performance == nil { - var ret string - return ret, false - } - return *o.Performance, true -} - -// HasPerformance returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasPerformance() bool { - if o != nil && o.Performance != nil { - return true - } - - return false -} - -// SetPerformance gets a reference to the given string and assigns it to the Performance field. -func (o *UpdateVmRequest) SetPerformance(v string) { - o.Performance = &v -} - -// GetSecurityGroupIds returns the SecurityGroupIds field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetSecurityGroupIds() []string { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret - } - return *o.SecurityGroupIds -} - -// GetSecurityGroupIdsOk returns a tuple with the SecurityGroupIds field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetSecurityGroupIdsOk() ([]string, bool) { - if o == nil || o.SecurityGroupIds == nil { - var ret []string - return ret, false - } - return *o.SecurityGroupIds, true -} - -// HasSecurityGroupIds returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasSecurityGroupIds() bool { - if o != nil && o.SecurityGroupIds != nil { - return true - } - - return false -} - -// SetSecurityGroupIds gets a reference to the given []string and assigns it to the SecurityGroupIds field. -func (o *UpdateVmRequest) SetSecurityGroupIds(v []string) { - o.SecurityGroupIds = &v -} - -// GetUserData returns the UserData field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetUserData() string { - if o == nil || o.UserData == nil { - var ret string - return ret - } - return *o.UserData -} - -// GetUserDataOk returns a tuple with the UserData field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetUserDataOk() (string, bool) { - if o == nil || o.UserData == nil { - var ret string - return ret, false - } - return *o.UserData, true -} - -// HasUserData returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasUserData() bool { - if o != nil && o.UserData != nil { - return true - } - - return false -} - -// SetUserData gets a reference to the given string and assigns it to the UserData field. -func (o *UpdateVmRequest) SetUserData(v string) { - o.UserData = &v -} - -// GetVmId returns the VmId field value -func (o *UpdateVmRequest) GetVmId() string { - if o == nil { - var ret string - return ret - } - - return o.VmId -} - -// SetVmId sets field value -func (o *UpdateVmRequest) SetVmId(v string) { - o.VmId = v -} - -// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetVmInitiatedShutdownBehavior() string { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret - } - return *o.VmInitiatedShutdownBehavior -} - -// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetVmInitiatedShutdownBehaviorOk() (string, bool) { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret, false - } - return *o.VmInitiatedShutdownBehavior, true -} - -// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasVmInitiatedShutdownBehavior() bool { - if o != nil && o.VmInitiatedShutdownBehavior != nil { - return true - } - - return false -} - -// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. -func (o *UpdateVmRequest) SetVmInitiatedShutdownBehavior(v string) { - o.VmInitiatedShutdownBehavior = &v -} - -// GetVmType returns the VmType field value if set, zero value otherwise. -func (o *UpdateVmRequest) GetVmType() string { - if o == nil || o.VmType == nil { - var ret string - return ret - } - return *o.VmType -} - -// GetVmTypeOk returns a tuple with the VmType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmRequest) GetVmTypeOk() (string, bool) { - if o == nil || o.VmType == nil { - var ret string - return ret, false - } - return *o.VmType, true -} - -// HasVmType returns a boolean if a field has been set. -func (o *UpdateVmRequest) HasVmType() bool { - if o != nil && o.VmType != nil { - return true - } - - return false -} - -// SetVmType gets a reference to the given string and assigns it to the VmType field. -func (o *UpdateVmRequest) SetVmType(v string) { - o.VmType = &v -} - -type NullableUpdateVmRequest struct { - Value UpdateVmRequest - ExplicitNull bool -} - -func (v NullableUpdateVmRequest) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateVmRequest) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_response.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_response.go deleted file mode 100644 index 9f06467d1..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_update_vm_response.go +++ /dev/null @@ -1,111 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// UpdateVmResponse struct for UpdateVmResponse -type UpdateVmResponse struct { - ResponseContext *ResponseContext `json:"ResponseContext,omitempty"` - Vm *Vm `json:"Vm,omitempty"` -} - -// GetResponseContext returns the ResponseContext field value if set, zero value otherwise. -func (o *UpdateVmResponse) GetResponseContext() ResponseContext { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret - } - return *o.ResponseContext -} - -// GetResponseContextOk returns a tuple with the ResponseContext field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmResponse) GetResponseContextOk() (ResponseContext, bool) { - if o == nil || o.ResponseContext == nil { - var ret ResponseContext - return ret, false - } - return *o.ResponseContext, true -} - -// HasResponseContext returns a boolean if a field has been set. -func (o *UpdateVmResponse) HasResponseContext() bool { - if o != nil && o.ResponseContext != nil { - return true - } - - return false -} - -// SetResponseContext gets a reference to the given ResponseContext and assigns it to the ResponseContext field. -func (o *UpdateVmResponse) SetResponseContext(v ResponseContext) { - o.ResponseContext = &v -} - -// GetVm returns the Vm field value if set, zero value otherwise. -func (o *UpdateVmResponse) GetVm() Vm { - if o == nil || o.Vm == nil { - var ret Vm - return ret - } - return *o.Vm -} - -// GetVmOk returns a tuple with the Vm field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *UpdateVmResponse) GetVmOk() (Vm, bool) { - if o == nil || o.Vm == nil { - var ret Vm - return ret, false - } - return *o.Vm, true -} - -// HasVm returns a boolean if a field has been set. -func (o *UpdateVmResponse) HasVm() bool { - if o != nil && o.Vm != nil { - return true - } - - return false -} - -// SetVm gets a reference to the given Vm and assigns it to the Vm field. -func (o *UpdateVmResponse) SetVm(v Vm) { - o.Vm = &v -} - -type NullableUpdateVmResponse struct { - Value UpdateVmResponse - ExplicitNull bool -} - -func (v NullableUpdateVmResponse) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableUpdateVmResponse) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_virtual_gateway.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_virtual_gateway.go deleted file mode 100644 index b02a87c00..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_virtual_gateway.go +++ /dev/null @@ -1,218 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// VirtualGateway Information about the virtual gateway. -type VirtualGateway struct { - // The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). - ConnectionType *string `json:"ConnectionType,omitempty"` - // The Net to which the virtual gateway is attached. - NetToVirtualGatewayLinks *[]NetToVirtualGatewayLink `json:"NetToVirtualGatewayLinks,omitempty"` - // The state of the virtual gateway (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` - // One or more tags associated with the virtual gateway. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the virtual gateway. - VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` -} - -// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. -func (o *VirtualGateway) GetConnectionType() string { - if o == nil || o.ConnectionType == nil { - var ret string - return ret - } - return *o.ConnectionType -} - -// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VirtualGateway) GetConnectionTypeOk() (string, bool) { - if o == nil || o.ConnectionType == nil { - var ret string - return ret, false - } - return *o.ConnectionType, true -} - -// HasConnectionType returns a boolean if a field has been set. -func (o *VirtualGateway) HasConnectionType() bool { - if o != nil && o.ConnectionType != nil { - return true - } - - return false -} - -// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. -func (o *VirtualGateway) SetConnectionType(v string) { - o.ConnectionType = &v -} - -// GetNetToVirtualGatewayLinks returns the NetToVirtualGatewayLinks field value if set, zero value otherwise. -func (o *VirtualGateway) GetNetToVirtualGatewayLinks() []NetToVirtualGatewayLink { - if o == nil || o.NetToVirtualGatewayLinks == nil { - var ret []NetToVirtualGatewayLink - return ret - } - return *o.NetToVirtualGatewayLinks -} - -// GetNetToVirtualGatewayLinksOk returns a tuple with the NetToVirtualGatewayLinks field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VirtualGateway) GetNetToVirtualGatewayLinksOk() ([]NetToVirtualGatewayLink, bool) { - if o == nil || o.NetToVirtualGatewayLinks == nil { - var ret []NetToVirtualGatewayLink - return ret, false - } - return *o.NetToVirtualGatewayLinks, true -} - -// HasNetToVirtualGatewayLinks returns a boolean if a field has been set. -func (o *VirtualGateway) HasNetToVirtualGatewayLinks() bool { - if o != nil && o.NetToVirtualGatewayLinks != nil { - return true - } - - return false -} - -// SetNetToVirtualGatewayLinks gets a reference to the given []NetToVirtualGatewayLink and assigns it to the NetToVirtualGatewayLinks field. -func (o *VirtualGateway) SetNetToVirtualGatewayLinks(v []NetToVirtualGatewayLink) { - o.NetToVirtualGatewayLinks = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *VirtualGateway) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VirtualGateway) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *VirtualGateway) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *VirtualGateway) SetState(v string) { - o.State = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *VirtualGateway) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VirtualGateway) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *VirtualGateway) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *VirtualGateway) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. -func (o *VirtualGateway) GetVirtualGatewayId() string { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret - } - return *o.VirtualGatewayId -} - -// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VirtualGateway) GetVirtualGatewayIdOk() (string, bool) { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret, false - } - return *o.VirtualGatewayId, true -} - -// HasVirtualGatewayId returns a boolean if a field has been set. -func (o *VirtualGateway) HasVirtualGatewayId() bool { - if o != nil && o.VirtualGatewayId != nil { - return true - } - - return false -} - -// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. -func (o *VirtualGateway) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = &v -} - -type NullableVirtualGateway struct { - Value VirtualGateway - ExplicitNull bool -} - -func (v NullableVirtualGateway) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVirtualGateway) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_vm.go deleted file mode 100644 index b729d1106..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm.go +++ /dev/null @@ -1,1162 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Vm Information about the VM. -type Vm struct { - // The architecture of the VM (`i386` \\| `x86_64`). - Architecture *string `json:"Architecture,omitempty"` - // The block device mapping of the VM. - BlockDeviceMappings *[]BlockDeviceMappingCreated `json:"BlockDeviceMappings,omitempty"` - // If `true`, the VM is optimized for BSU I/O. - BsuOptimized *bool `json:"BsuOptimized,omitempty"` - // The idempotency token provided when launching the VM. - ClientToken *string `json:"ClientToken,omitempty"` - // If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - DeletionProtection *bool `json:"DeletionProtection,omitempty"` - // The hypervisor type of the VMs (`ovm` \\| `xen`). - Hypervisor *string `json:"Hypervisor,omitempty"` - // The ID of the OMI used to create the VM. - ImageId *string `json:"ImageId,omitempty"` - // (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - IsSourceDestChecked *bool `json:"IsSourceDestChecked,omitempty"` - // The name of the keypair used when launching the VM. - KeypairName *string `json:"KeypairName,omitempty"` - // The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). - LaunchNumber *int64 `json:"LaunchNumber,omitempty"` - // The ID of the Net in which the VM is running. - NetId *string `json:"NetId,omitempty"` - // The network interface cards (NICs) the VMs are attached to. - Nics *[]NicLight `json:"Nics,omitempty"` - // Indicates the operating system (OS) of the VM. - OsFamily *string `json:"OsFamily,omitempty"` - // The performance of the VM (`standard` \\| `high` \\| `highest`). - Performance *string `json:"Performance,omitempty"` - Placement *Placement `json:"Placement,omitempty"` - // The name of the private DNS. - PrivateDnsName *string `json:"PrivateDnsName,omitempty"` - // The primary private IP address of the VM. - PrivateIp *string `json:"PrivateIp,omitempty"` - // The product code associated with the OMI used to create the VM (`0001` Linux/Unix \\| `0002` Windows \\| `0004` Linux/Oracle \\| `0005` Windows 10). - ProductCodes *[]string `json:"ProductCodes,omitempty"` - // The name of the public DNS. - PublicDnsName *string `json:"PublicDnsName,omitempty"` - // The public IP address of the VM. - PublicIp *string `json:"PublicIp,omitempty"` - // The reservation ID of the VM. - ReservationId *string `json:"ReservationId,omitempty"` - // The name of the root device for the VM (for example, /dev/vda1). - RootDeviceName *string `json:"RootDeviceName,omitempty"` - // The type of root device used by the VM (always `bsu`). - RootDeviceType *string `json:"RootDeviceType,omitempty"` - // One or more security groups associated with the VM. - SecurityGroups *[]SecurityGroupLight `json:"SecurityGroups,omitempty"` - // The state of the VM (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). - State *string `json:"State,omitempty"` - // The reason explaining the current state of the VM. - StateReason *string `json:"StateReason,omitempty"` - // The ID of the Subnet for the VM. - SubnetId *string `json:"SubnetId,omitempty"` - // One or more tags associated with the VM. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The Base64-encoded MIME user data. - UserData *string `json:"UserData,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` - // The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. - VmInitiatedShutdownBehavior *string `json:"VmInitiatedShutdownBehavior,omitempty"` - // The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - VmType *string `json:"VmType,omitempty"` -} - -// GetArchitecture returns the Architecture field value if set, zero value otherwise. -func (o *Vm) GetArchitecture() string { - if o == nil || o.Architecture == nil { - var ret string - return ret - } - return *o.Architecture -} - -// GetArchitectureOk returns a tuple with the Architecture field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetArchitectureOk() (string, bool) { - if o == nil || o.Architecture == nil { - var ret string - return ret, false - } - return *o.Architecture, true -} - -// HasArchitecture returns a boolean if a field has been set. -func (o *Vm) HasArchitecture() bool { - if o != nil && o.Architecture != nil { - return true - } - - return false -} - -// SetArchitecture gets a reference to the given string and assigns it to the Architecture field. -func (o *Vm) SetArchitecture(v string) { - o.Architecture = &v -} - -// GetBlockDeviceMappings returns the BlockDeviceMappings field value if set, zero value otherwise. -func (o *Vm) GetBlockDeviceMappings() []BlockDeviceMappingCreated { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingCreated - return ret - } - return *o.BlockDeviceMappings -} - -// GetBlockDeviceMappingsOk returns a tuple with the BlockDeviceMappings field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetBlockDeviceMappingsOk() ([]BlockDeviceMappingCreated, bool) { - if o == nil || o.BlockDeviceMappings == nil { - var ret []BlockDeviceMappingCreated - return ret, false - } - return *o.BlockDeviceMappings, true -} - -// HasBlockDeviceMappings returns a boolean if a field has been set. -func (o *Vm) HasBlockDeviceMappings() bool { - if o != nil && o.BlockDeviceMappings != nil { - return true - } - - return false -} - -// SetBlockDeviceMappings gets a reference to the given []BlockDeviceMappingCreated and assigns it to the BlockDeviceMappings field. -func (o *Vm) SetBlockDeviceMappings(v []BlockDeviceMappingCreated) { - o.BlockDeviceMappings = &v -} - -// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. -func (o *Vm) GetBsuOptimized() bool { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret - } - return *o.BsuOptimized -} - -// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetBsuOptimizedOk() (bool, bool) { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret, false - } - return *o.BsuOptimized, true -} - -// HasBsuOptimized returns a boolean if a field has been set. -func (o *Vm) HasBsuOptimized() bool { - if o != nil && o.BsuOptimized != nil { - return true - } - - return false -} - -// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. -func (o *Vm) SetBsuOptimized(v bool) { - o.BsuOptimized = &v -} - -// GetClientToken returns the ClientToken field value if set, zero value otherwise. -func (o *Vm) GetClientToken() string { - if o == nil || o.ClientToken == nil { - var ret string - return ret - } - return *o.ClientToken -} - -// GetClientTokenOk returns a tuple with the ClientToken field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetClientTokenOk() (string, bool) { - if o == nil || o.ClientToken == nil { - var ret string - return ret, false - } - return *o.ClientToken, true -} - -// HasClientToken returns a boolean if a field has been set. -func (o *Vm) HasClientToken() bool { - if o != nil && o.ClientToken != nil { - return true - } - - return false -} - -// SetClientToken gets a reference to the given string and assigns it to the ClientToken field. -func (o *Vm) SetClientToken(v string) { - o.ClientToken = &v -} - -// GetDeletionProtection returns the DeletionProtection field value if set, zero value otherwise. -func (o *Vm) GetDeletionProtection() bool { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret - } - return *o.DeletionProtection -} - -// GetDeletionProtectionOk returns a tuple with the DeletionProtection field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetDeletionProtectionOk() (bool, bool) { - if o == nil || o.DeletionProtection == nil { - var ret bool - return ret, false - } - return *o.DeletionProtection, true -} - -// HasDeletionProtection returns a boolean if a field has been set. -func (o *Vm) HasDeletionProtection() bool { - if o != nil && o.DeletionProtection != nil { - return true - } - - return false -} - -// SetDeletionProtection gets a reference to the given bool and assigns it to the DeletionProtection field. -func (o *Vm) SetDeletionProtection(v bool) { - o.DeletionProtection = &v -} - -// GetHypervisor returns the Hypervisor field value if set, zero value otherwise. -func (o *Vm) GetHypervisor() string { - if o == nil || o.Hypervisor == nil { - var ret string - return ret - } - return *o.Hypervisor -} - -// GetHypervisorOk returns a tuple with the Hypervisor field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetHypervisorOk() (string, bool) { - if o == nil || o.Hypervisor == nil { - var ret string - return ret, false - } - return *o.Hypervisor, true -} - -// HasHypervisor returns a boolean if a field has been set. -func (o *Vm) HasHypervisor() bool { - if o != nil && o.Hypervisor != nil { - return true - } - - return false -} - -// SetHypervisor gets a reference to the given string and assigns it to the Hypervisor field. -func (o *Vm) SetHypervisor(v string) { - o.Hypervisor = &v -} - -// GetImageId returns the ImageId field value if set, zero value otherwise. -func (o *Vm) GetImageId() string { - if o == nil || o.ImageId == nil { - var ret string - return ret - } - return *o.ImageId -} - -// GetImageIdOk returns a tuple with the ImageId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetImageIdOk() (string, bool) { - if o == nil || o.ImageId == nil { - var ret string - return ret, false - } - return *o.ImageId, true -} - -// HasImageId returns a boolean if a field has been set. -func (o *Vm) HasImageId() bool { - if o != nil && o.ImageId != nil { - return true - } - - return false -} - -// SetImageId gets a reference to the given string and assigns it to the ImageId field. -func (o *Vm) SetImageId(v string) { - o.ImageId = &v -} - -// GetIsSourceDestChecked returns the IsSourceDestChecked field value if set, zero value otherwise. -func (o *Vm) GetIsSourceDestChecked() bool { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret - } - return *o.IsSourceDestChecked -} - -// GetIsSourceDestCheckedOk returns a tuple with the IsSourceDestChecked field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetIsSourceDestCheckedOk() (bool, bool) { - if o == nil || o.IsSourceDestChecked == nil { - var ret bool - return ret, false - } - return *o.IsSourceDestChecked, true -} - -// HasIsSourceDestChecked returns a boolean if a field has been set. -func (o *Vm) HasIsSourceDestChecked() bool { - if o != nil && o.IsSourceDestChecked != nil { - return true - } - - return false -} - -// SetIsSourceDestChecked gets a reference to the given bool and assigns it to the IsSourceDestChecked field. -func (o *Vm) SetIsSourceDestChecked(v bool) { - o.IsSourceDestChecked = &v -} - -// GetKeypairName returns the KeypairName field value if set, zero value otherwise. -func (o *Vm) GetKeypairName() string { - if o == nil || o.KeypairName == nil { - var ret string - return ret - } - return *o.KeypairName -} - -// GetKeypairNameOk returns a tuple with the KeypairName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetKeypairNameOk() (string, bool) { - if o == nil || o.KeypairName == nil { - var ret string - return ret, false - } - return *o.KeypairName, true -} - -// HasKeypairName returns a boolean if a field has been set. -func (o *Vm) HasKeypairName() bool { - if o != nil && o.KeypairName != nil { - return true - } - - return false -} - -// SetKeypairName gets a reference to the given string and assigns it to the KeypairName field. -func (o *Vm) SetKeypairName(v string) { - o.KeypairName = &v -} - -// GetLaunchNumber returns the LaunchNumber field value if set, zero value otherwise. -func (o *Vm) GetLaunchNumber() int64 { - if o == nil || o.LaunchNumber == nil { - var ret int64 - return ret - } - return *o.LaunchNumber -} - -// GetLaunchNumberOk returns a tuple with the LaunchNumber field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetLaunchNumberOk() (int64, bool) { - if o == nil || o.LaunchNumber == nil { - var ret int64 - return ret, false - } - return *o.LaunchNumber, true -} - -// HasLaunchNumber returns a boolean if a field has been set. -func (o *Vm) HasLaunchNumber() bool { - if o != nil && o.LaunchNumber != nil { - return true - } - - return false -} - -// SetLaunchNumber gets a reference to the given int64 and assigns it to the LaunchNumber field. -func (o *Vm) SetLaunchNumber(v int64) { - o.LaunchNumber = &v -} - -// GetNetId returns the NetId field value if set, zero value otherwise. -func (o *Vm) GetNetId() string { - if o == nil || o.NetId == nil { - var ret string - return ret - } - return *o.NetId -} - -// GetNetIdOk returns a tuple with the NetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetNetIdOk() (string, bool) { - if o == nil || o.NetId == nil { - var ret string - return ret, false - } - return *o.NetId, true -} - -// HasNetId returns a boolean if a field has been set. -func (o *Vm) HasNetId() bool { - if o != nil && o.NetId != nil { - return true - } - - return false -} - -// SetNetId gets a reference to the given string and assigns it to the NetId field. -func (o *Vm) SetNetId(v string) { - o.NetId = &v -} - -// GetNics returns the Nics field value if set, zero value otherwise. -func (o *Vm) GetNics() []NicLight { - if o == nil || o.Nics == nil { - var ret []NicLight - return ret - } - return *o.Nics -} - -// GetNicsOk returns a tuple with the Nics field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetNicsOk() ([]NicLight, bool) { - if o == nil || o.Nics == nil { - var ret []NicLight - return ret, false - } - return *o.Nics, true -} - -// HasNics returns a boolean if a field has been set. -func (o *Vm) HasNics() bool { - if o != nil && o.Nics != nil { - return true - } - - return false -} - -// SetNics gets a reference to the given []NicLight and assigns it to the Nics field. -func (o *Vm) SetNics(v []NicLight) { - o.Nics = &v -} - -// GetOsFamily returns the OsFamily field value if set, zero value otherwise. -func (o *Vm) GetOsFamily() string { - if o == nil || o.OsFamily == nil { - var ret string - return ret - } - return *o.OsFamily -} - -// GetOsFamilyOk returns a tuple with the OsFamily field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetOsFamilyOk() (string, bool) { - if o == nil || o.OsFamily == nil { - var ret string - return ret, false - } - return *o.OsFamily, true -} - -// HasOsFamily returns a boolean if a field has been set. -func (o *Vm) HasOsFamily() bool { - if o != nil && o.OsFamily != nil { - return true - } - - return false -} - -// SetOsFamily gets a reference to the given string and assigns it to the OsFamily field. -func (o *Vm) SetOsFamily(v string) { - o.OsFamily = &v -} - -// GetPerformance returns the Performance field value if set, zero value otherwise. -func (o *Vm) GetPerformance() string { - if o == nil || o.Performance == nil { - var ret string - return ret - } - return *o.Performance -} - -// GetPerformanceOk returns a tuple with the Performance field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPerformanceOk() (string, bool) { - if o == nil || o.Performance == nil { - var ret string - return ret, false - } - return *o.Performance, true -} - -// HasPerformance returns a boolean if a field has been set. -func (o *Vm) HasPerformance() bool { - if o != nil && o.Performance != nil { - return true - } - - return false -} - -// SetPerformance gets a reference to the given string and assigns it to the Performance field. -func (o *Vm) SetPerformance(v string) { - o.Performance = &v -} - -// GetPlacement returns the Placement field value if set, zero value otherwise. -func (o *Vm) GetPlacement() Placement { - if o == nil || o.Placement == nil { - var ret Placement - return ret - } - return *o.Placement -} - -// GetPlacementOk returns a tuple with the Placement field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPlacementOk() (Placement, bool) { - if o == nil || o.Placement == nil { - var ret Placement - return ret, false - } - return *o.Placement, true -} - -// HasPlacement returns a boolean if a field has been set. -func (o *Vm) HasPlacement() bool { - if o != nil && o.Placement != nil { - return true - } - - return false -} - -// SetPlacement gets a reference to the given Placement and assigns it to the Placement field. -func (o *Vm) SetPlacement(v Placement) { - o.Placement = &v -} - -// GetPrivateDnsName returns the PrivateDnsName field value if set, zero value otherwise. -func (o *Vm) GetPrivateDnsName() string { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret - } - return *o.PrivateDnsName -} - -// GetPrivateDnsNameOk returns a tuple with the PrivateDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPrivateDnsNameOk() (string, bool) { - if o == nil || o.PrivateDnsName == nil { - var ret string - return ret, false - } - return *o.PrivateDnsName, true -} - -// HasPrivateDnsName returns a boolean if a field has been set. -func (o *Vm) HasPrivateDnsName() bool { - if o != nil && o.PrivateDnsName != nil { - return true - } - - return false -} - -// SetPrivateDnsName gets a reference to the given string and assigns it to the PrivateDnsName field. -func (o *Vm) SetPrivateDnsName(v string) { - o.PrivateDnsName = &v -} - -// GetPrivateIp returns the PrivateIp field value if set, zero value otherwise. -func (o *Vm) GetPrivateIp() string { - if o == nil || o.PrivateIp == nil { - var ret string - return ret - } - return *o.PrivateIp -} - -// GetPrivateIpOk returns a tuple with the PrivateIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPrivateIpOk() (string, bool) { - if o == nil || o.PrivateIp == nil { - var ret string - return ret, false - } - return *o.PrivateIp, true -} - -// HasPrivateIp returns a boolean if a field has been set. -func (o *Vm) HasPrivateIp() bool { - if o != nil && o.PrivateIp != nil { - return true - } - - return false -} - -// SetPrivateIp gets a reference to the given string and assigns it to the PrivateIp field. -func (o *Vm) SetPrivateIp(v string) { - o.PrivateIp = &v -} - -// GetProductCodes returns the ProductCodes field value if set, zero value otherwise. -func (o *Vm) GetProductCodes() []string { - if o == nil || o.ProductCodes == nil { - var ret []string - return ret - } - return *o.ProductCodes -} - -// GetProductCodesOk returns a tuple with the ProductCodes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetProductCodesOk() ([]string, bool) { - if o == nil || o.ProductCodes == nil { - var ret []string - return ret, false - } - return *o.ProductCodes, true -} - -// HasProductCodes returns a boolean if a field has been set. -func (o *Vm) HasProductCodes() bool { - if o != nil && o.ProductCodes != nil { - return true - } - - return false -} - -// SetProductCodes gets a reference to the given []string and assigns it to the ProductCodes field. -func (o *Vm) SetProductCodes(v []string) { - o.ProductCodes = &v -} - -// GetPublicDnsName returns the PublicDnsName field value if set, zero value otherwise. -func (o *Vm) GetPublicDnsName() string { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret - } - return *o.PublicDnsName -} - -// GetPublicDnsNameOk returns a tuple with the PublicDnsName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPublicDnsNameOk() (string, bool) { - if o == nil || o.PublicDnsName == nil { - var ret string - return ret, false - } - return *o.PublicDnsName, true -} - -// HasPublicDnsName returns a boolean if a field has been set. -func (o *Vm) HasPublicDnsName() bool { - if o != nil && o.PublicDnsName != nil { - return true - } - - return false -} - -// SetPublicDnsName gets a reference to the given string and assigns it to the PublicDnsName field. -func (o *Vm) SetPublicDnsName(v string) { - o.PublicDnsName = &v -} - -// GetPublicIp returns the PublicIp field value if set, zero value otherwise. -func (o *Vm) GetPublicIp() string { - if o == nil || o.PublicIp == nil { - var ret string - return ret - } - return *o.PublicIp -} - -// GetPublicIpOk returns a tuple with the PublicIp field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetPublicIpOk() (string, bool) { - if o == nil || o.PublicIp == nil { - var ret string - return ret, false - } - return *o.PublicIp, true -} - -// HasPublicIp returns a boolean if a field has been set. -func (o *Vm) HasPublicIp() bool { - if o != nil && o.PublicIp != nil { - return true - } - - return false -} - -// SetPublicIp gets a reference to the given string and assigns it to the PublicIp field. -func (o *Vm) SetPublicIp(v string) { - o.PublicIp = &v -} - -// GetReservationId returns the ReservationId field value if set, zero value otherwise. -func (o *Vm) GetReservationId() string { - if o == nil || o.ReservationId == nil { - var ret string - return ret - } - return *o.ReservationId -} - -// GetReservationIdOk returns a tuple with the ReservationId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetReservationIdOk() (string, bool) { - if o == nil || o.ReservationId == nil { - var ret string - return ret, false - } - return *o.ReservationId, true -} - -// HasReservationId returns a boolean if a field has been set. -func (o *Vm) HasReservationId() bool { - if o != nil && o.ReservationId != nil { - return true - } - - return false -} - -// SetReservationId gets a reference to the given string and assigns it to the ReservationId field. -func (o *Vm) SetReservationId(v string) { - o.ReservationId = &v -} - -// GetRootDeviceName returns the RootDeviceName field value if set, zero value otherwise. -func (o *Vm) GetRootDeviceName() string { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret - } - return *o.RootDeviceName -} - -// GetRootDeviceNameOk returns a tuple with the RootDeviceName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetRootDeviceNameOk() (string, bool) { - if o == nil || o.RootDeviceName == nil { - var ret string - return ret, false - } - return *o.RootDeviceName, true -} - -// HasRootDeviceName returns a boolean if a field has been set. -func (o *Vm) HasRootDeviceName() bool { - if o != nil && o.RootDeviceName != nil { - return true - } - - return false -} - -// SetRootDeviceName gets a reference to the given string and assigns it to the RootDeviceName field. -func (o *Vm) SetRootDeviceName(v string) { - o.RootDeviceName = &v -} - -// GetRootDeviceType returns the RootDeviceType field value if set, zero value otherwise. -func (o *Vm) GetRootDeviceType() string { - if o == nil || o.RootDeviceType == nil { - var ret string - return ret - } - return *o.RootDeviceType -} - -// GetRootDeviceTypeOk returns a tuple with the RootDeviceType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetRootDeviceTypeOk() (string, bool) { - if o == nil || o.RootDeviceType == nil { - var ret string - return ret, false - } - return *o.RootDeviceType, true -} - -// HasRootDeviceType returns a boolean if a field has been set. -func (o *Vm) HasRootDeviceType() bool { - if o != nil && o.RootDeviceType != nil { - return true - } - - return false -} - -// SetRootDeviceType gets a reference to the given string and assigns it to the RootDeviceType field. -func (o *Vm) SetRootDeviceType(v string) { - o.RootDeviceType = &v -} - -// GetSecurityGroups returns the SecurityGroups field value if set, zero value otherwise. -func (o *Vm) GetSecurityGroups() []SecurityGroupLight { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret - } - return *o.SecurityGroups -} - -// GetSecurityGroupsOk returns a tuple with the SecurityGroups field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetSecurityGroupsOk() ([]SecurityGroupLight, bool) { - if o == nil || o.SecurityGroups == nil { - var ret []SecurityGroupLight - return ret, false - } - return *o.SecurityGroups, true -} - -// HasSecurityGroups returns a boolean if a field has been set. -func (o *Vm) HasSecurityGroups() bool { - if o != nil && o.SecurityGroups != nil { - return true - } - - return false -} - -// SetSecurityGroups gets a reference to the given []SecurityGroupLight and assigns it to the SecurityGroups field. -func (o *Vm) SetSecurityGroups(v []SecurityGroupLight) { - o.SecurityGroups = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Vm) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Vm) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Vm) SetState(v string) { - o.State = &v -} - -// GetStateReason returns the StateReason field value if set, zero value otherwise. -func (o *Vm) GetStateReason() string { - if o == nil || o.StateReason == nil { - var ret string - return ret - } - return *o.StateReason -} - -// GetStateReasonOk returns a tuple with the StateReason field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetStateReasonOk() (string, bool) { - if o == nil || o.StateReason == nil { - var ret string - return ret, false - } - return *o.StateReason, true -} - -// HasStateReason returns a boolean if a field has been set. -func (o *Vm) HasStateReason() bool { - if o != nil && o.StateReason != nil { - return true - } - - return false -} - -// SetStateReason gets a reference to the given string and assigns it to the StateReason field. -func (o *Vm) SetStateReason(v string) { - o.StateReason = &v -} - -// GetSubnetId returns the SubnetId field value if set, zero value otherwise. -func (o *Vm) GetSubnetId() string { - if o == nil || o.SubnetId == nil { - var ret string - return ret - } - return *o.SubnetId -} - -// GetSubnetIdOk returns a tuple with the SubnetId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetSubnetIdOk() (string, bool) { - if o == nil || o.SubnetId == nil { - var ret string - return ret, false - } - return *o.SubnetId, true -} - -// HasSubnetId returns a boolean if a field has been set. -func (o *Vm) HasSubnetId() bool { - if o != nil && o.SubnetId != nil { - return true - } - - return false -} - -// SetSubnetId gets a reference to the given string and assigns it to the SubnetId field. -func (o *Vm) SetSubnetId(v string) { - o.SubnetId = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Vm) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Vm) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Vm) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetUserData returns the UserData field value if set, zero value otherwise. -func (o *Vm) GetUserData() string { - if o == nil || o.UserData == nil { - var ret string - return ret - } - return *o.UserData -} - -// GetUserDataOk returns a tuple with the UserData field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetUserDataOk() (string, bool) { - if o == nil || o.UserData == nil { - var ret string - return ret, false - } - return *o.UserData, true -} - -// HasUserData returns a boolean if a field has been set. -func (o *Vm) HasUserData() bool { - if o != nil && o.UserData != nil { - return true - } - - return false -} - -// SetUserData gets a reference to the given string and assigns it to the UserData field. -func (o *Vm) SetUserData(v string) { - o.UserData = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *Vm) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *Vm) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *Vm) SetVmId(v string) { - o.VmId = &v -} - -// GetVmInitiatedShutdownBehavior returns the VmInitiatedShutdownBehavior field value if set, zero value otherwise. -func (o *Vm) GetVmInitiatedShutdownBehavior() string { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret - } - return *o.VmInitiatedShutdownBehavior -} - -// GetVmInitiatedShutdownBehaviorOk returns a tuple with the VmInitiatedShutdownBehavior field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetVmInitiatedShutdownBehaviorOk() (string, bool) { - if o == nil || o.VmInitiatedShutdownBehavior == nil { - var ret string - return ret, false - } - return *o.VmInitiatedShutdownBehavior, true -} - -// HasVmInitiatedShutdownBehavior returns a boolean if a field has been set. -func (o *Vm) HasVmInitiatedShutdownBehavior() bool { - if o != nil && o.VmInitiatedShutdownBehavior != nil { - return true - } - - return false -} - -// SetVmInitiatedShutdownBehavior gets a reference to the given string and assigns it to the VmInitiatedShutdownBehavior field. -func (o *Vm) SetVmInitiatedShutdownBehavior(v string) { - o.VmInitiatedShutdownBehavior = &v -} - -// GetVmType returns the VmType field value if set, zero value otherwise. -func (o *Vm) GetVmType() string { - if o == nil || o.VmType == nil { - var ret string - return ret - } - return *o.VmType -} - -// GetVmTypeOk returns a tuple with the VmType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Vm) GetVmTypeOk() (string, bool) { - if o == nil || o.VmType == nil { - var ret string - return ret, false - } - return *o.VmType, true -} - -// HasVmType returns a boolean if a field has been set. -func (o *Vm) HasVmType() bool { - if o != nil && o.VmType != nil { - return true - } - - return false -} - -// SetVmType gets a reference to the given string and assigns it to the VmType field. -func (o *Vm) SetVmType(v string) { - o.VmType = &v -} - -type NullableVm struct { - Value Vm - ExplicitNull bool -} - -func (v NullableVm) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVm) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_state.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_state.go deleted file mode 100644 index ec30fd5f2..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_state.go +++ /dev/null @@ -1,148 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// VmState Information about the state of the VM. -type VmState struct { - // The current state of the VM (`InService` \\| `OutOfService` \\| `Unknown`). - CurrentState *string `json:"CurrentState,omitempty"` - // The previous state of the VM (`InService` \\| `OutOfService` \\| `Unknown`). - PreviousState *string `json:"PreviousState,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` -} - -// GetCurrentState returns the CurrentState field value if set, zero value otherwise. -func (o *VmState) GetCurrentState() string { - if o == nil || o.CurrentState == nil { - var ret string - return ret - } - return *o.CurrentState -} - -// GetCurrentStateOk returns a tuple with the CurrentState field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmState) GetCurrentStateOk() (string, bool) { - if o == nil || o.CurrentState == nil { - var ret string - return ret, false - } - return *o.CurrentState, true -} - -// HasCurrentState returns a boolean if a field has been set. -func (o *VmState) HasCurrentState() bool { - if o != nil && o.CurrentState != nil { - return true - } - - return false -} - -// SetCurrentState gets a reference to the given string and assigns it to the CurrentState field. -func (o *VmState) SetCurrentState(v string) { - o.CurrentState = &v -} - -// GetPreviousState returns the PreviousState field value if set, zero value otherwise. -func (o *VmState) GetPreviousState() string { - if o == nil || o.PreviousState == nil { - var ret string - return ret - } - return *o.PreviousState -} - -// GetPreviousStateOk returns a tuple with the PreviousState field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmState) GetPreviousStateOk() (string, bool) { - if o == nil || o.PreviousState == nil { - var ret string - return ret, false - } - return *o.PreviousState, true -} - -// HasPreviousState returns a boolean if a field has been set. -func (o *VmState) HasPreviousState() bool { - if o != nil && o.PreviousState != nil { - return true - } - - return false -} - -// SetPreviousState gets a reference to the given string and assigns it to the PreviousState field. -func (o *VmState) SetPreviousState(v string) { - o.PreviousState = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *VmState) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmState) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *VmState) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *VmState) SetVmId(v string) { - o.VmId = &v -} - -type NullableVmState struct { - Value VmState - ExplicitNull bool -} - -func (v NullableVmState) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVmState) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_states.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_states.go deleted file mode 100644 index b807e5fd0..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_states.go +++ /dev/null @@ -1,183 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// VmStates Information about the states of the VMs. -type VmStates struct { - // One or more scheduled events associated with the VM. - MaintenanceEvents *[]MaintenanceEvent `json:"MaintenanceEvents,omitempty"` - // The name of the Subregion of the VM. - SubregionName *string `json:"SubregionName,omitempty"` - // The ID of the VM. - VmId *string `json:"VmId,omitempty"` - // The state of the VM (`pending` \\| `running` \\| `stopping` \\| `stopped` \\| `shutting-down` \\| `terminated` \\| `quarantine`). - VmState *string `json:"VmState,omitempty"` -} - -// GetMaintenanceEvents returns the MaintenanceEvents field value if set, zero value otherwise. -func (o *VmStates) GetMaintenanceEvents() []MaintenanceEvent { - if o == nil || o.MaintenanceEvents == nil { - var ret []MaintenanceEvent - return ret - } - return *o.MaintenanceEvents -} - -// GetMaintenanceEventsOk returns a tuple with the MaintenanceEvents field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmStates) GetMaintenanceEventsOk() ([]MaintenanceEvent, bool) { - if o == nil || o.MaintenanceEvents == nil { - var ret []MaintenanceEvent - return ret, false - } - return *o.MaintenanceEvents, true -} - -// HasMaintenanceEvents returns a boolean if a field has been set. -func (o *VmStates) HasMaintenanceEvents() bool { - if o != nil && o.MaintenanceEvents != nil { - return true - } - - return false -} - -// SetMaintenanceEvents gets a reference to the given []MaintenanceEvent and assigns it to the MaintenanceEvents field. -func (o *VmStates) SetMaintenanceEvents(v []MaintenanceEvent) { - o.MaintenanceEvents = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *VmStates) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmStates) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *VmStates) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *VmStates) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetVmId returns the VmId field value if set, zero value otherwise. -func (o *VmStates) GetVmId() string { - if o == nil || o.VmId == nil { - var ret string - return ret - } - return *o.VmId -} - -// GetVmIdOk returns a tuple with the VmId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmStates) GetVmIdOk() (string, bool) { - if o == nil || o.VmId == nil { - var ret string - return ret, false - } - return *o.VmId, true -} - -// HasVmId returns a boolean if a field has been set. -func (o *VmStates) HasVmId() bool { - if o != nil && o.VmId != nil { - return true - } - - return false -} - -// SetVmId gets a reference to the given string and assigns it to the VmId field. -func (o *VmStates) SetVmId(v string) { - o.VmId = &v -} - -// GetVmState returns the VmState field value if set, zero value otherwise. -func (o *VmStates) GetVmState() string { - if o == nil || o.VmState == nil { - var ret string - return ret - } - return *o.VmState -} - -// GetVmStateOk returns a tuple with the VmState field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmStates) GetVmStateOk() (string, bool) { - if o == nil || o.VmState == nil { - var ret string - return ret, false - } - return *o.VmState, true -} - -// HasVmState returns a boolean if a field has been set. -func (o *VmStates) HasVmState() bool { - if o != nil && o.VmState != nil { - return true - } - - return false -} - -// SetVmState gets a reference to the given string and assigns it to the VmState field. -func (o *VmStates) SetVmState(v string) { - o.VmState = &v -} - -type NullableVmStates struct { - Value VmStates - ExplicitNull bool -} - -func (v NullableVmStates) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVmStates) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_type.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_type.go deleted file mode 100644 index e89791599..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_vm_type.go +++ /dev/null @@ -1,288 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// VmType Information about the VM type. -type VmType struct { - // Indicates whether the VM is optimized for BSU I/O. - BsuOptimized *bool `json:"BsuOptimized,omitempty"` - // The maximum number of private IP addresses per network interface card (NIC). - MaxPrivateIps *int64 `json:"MaxPrivateIps,omitempty"` - // The amount of memory, in gibibytes. - MemorySize *float32 `json:"MemorySize,omitempty"` - // The number of vCores. - VcoreCount *int64 `json:"VcoreCount,omitempty"` - // The name of the VM type. - VmTypeName *string `json:"VmTypeName,omitempty"` - // The maximum number of ephemeral storage disks. - VolumeCount *int64 `json:"VolumeCount,omitempty"` - // The size of one ephemeral storage disk, in gibibytes (GiB). - VolumeSize *int64 `json:"VolumeSize,omitempty"` -} - -// GetBsuOptimized returns the BsuOptimized field value if set, zero value otherwise. -func (o *VmType) GetBsuOptimized() bool { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret - } - return *o.BsuOptimized -} - -// GetBsuOptimizedOk returns a tuple with the BsuOptimized field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetBsuOptimizedOk() (bool, bool) { - if o == nil || o.BsuOptimized == nil { - var ret bool - return ret, false - } - return *o.BsuOptimized, true -} - -// HasBsuOptimized returns a boolean if a field has been set. -func (o *VmType) HasBsuOptimized() bool { - if o != nil && o.BsuOptimized != nil { - return true - } - - return false -} - -// SetBsuOptimized gets a reference to the given bool and assigns it to the BsuOptimized field. -func (o *VmType) SetBsuOptimized(v bool) { - o.BsuOptimized = &v -} - -// GetMaxPrivateIps returns the MaxPrivateIps field value if set, zero value otherwise. -func (o *VmType) GetMaxPrivateIps() int64 { - if o == nil || o.MaxPrivateIps == nil { - var ret int64 - return ret - } - return *o.MaxPrivateIps -} - -// GetMaxPrivateIpsOk returns a tuple with the MaxPrivateIps field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetMaxPrivateIpsOk() (int64, bool) { - if o == nil || o.MaxPrivateIps == nil { - var ret int64 - return ret, false - } - return *o.MaxPrivateIps, true -} - -// HasMaxPrivateIps returns a boolean if a field has been set. -func (o *VmType) HasMaxPrivateIps() bool { - if o != nil && o.MaxPrivateIps != nil { - return true - } - - return false -} - -// SetMaxPrivateIps gets a reference to the given int64 and assigns it to the MaxPrivateIps field. -func (o *VmType) SetMaxPrivateIps(v int64) { - o.MaxPrivateIps = &v -} - -// GetMemorySize returns the MemorySize field value if set, zero value otherwise. -func (o *VmType) GetMemorySize() float32 { - if o == nil || o.MemorySize == nil { - var ret float32 - return ret - } - return *o.MemorySize -} - -// GetMemorySizeOk returns a tuple with the MemorySize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetMemorySizeOk() (float32, bool) { - if o == nil || o.MemorySize == nil { - var ret float32 - return ret, false - } - return *o.MemorySize, true -} - -// HasMemorySize returns a boolean if a field has been set. -func (o *VmType) HasMemorySize() bool { - if o != nil && o.MemorySize != nil { - return true - } - - return false -} - -// SetMemorySize gets a reference to the given float32 and assigns it to the MemorySize field. -func (o *VmType) SetMemorySize(v float32) { - o.MemorySize = &v -} - -// GetVcoreCount returns the VcoreCount field value if set, zero value otherwise. -func (o *VmType) GetVcoreCount() int64 { - if o == nil || o.VcoreCount == nil { - var ret int64 - return ret - } - return *o.VcoreCount -} - -// GetVcoreCountOk returns a tuple with the VcoreCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetVcoreCountOk() (int64, bool) { - if o == nil || o.VcoreCount == nil { - var ret int64 - return ret, false - } - return *o.VcoreCount, true -} - -// HasVcoreCount returns a boolean if a field has been set. -func (o *VmType) HasVcoreCount() bool { - if o != nil && o.VcoreCount != nil { - return true - } - - return false -} - -// SetVcoreCount gets a reference to the given int64 and assigns it to the VcoreCount field. -func (o *VmType) SetVcoreCount(v int64) { - o.VcoreCount = &v -} - -// GetVmTypeName returns the VmTypeName field value if set, zero value otherwise. -func (o *VmType) GetVmTypeName() string { - if o == nil || o.VmTypeName == nil { - var ret string - return ret - } - return *o.VmTypeName -} - -// GetVmTypeNameOk returns a tuple with the VmTypeName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetVmTypeNameOk() (string, bool) { - if o == nil || o.VmTypeName == nil { - var ret string - return ret, false - } - return *o.VmTypeName, true -} - -// HasVmTypeName returns a boolean if a field has been set. -func (o *VmType) HasVmTypeName() bool { - if o != nil && o.VmTypeName != nil { - return true - } - - return false -} - -// SetVmTypeName gets a reference to the given string and assigns it to the VmTypeName field. -func (o *VmType) SetVmTypeName(v string) { - o.VmTypeName = &v -} - -// GetVolumeCount returns the VolumeCount field value if set, zero value otherwise. -func (o *VmType) GetVolumeCount() int64 { - if o == nil || o.VolumeCount == nil { - var ret int64 - return ret - } - return *o.VolumeCount -} - -// GetVolumeCountOk returns a tuple with the VolumeCount field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetVolumeCountOk() (int64, bool) { - if o == nil || o.VolumeCount == nil { - var ret int64 - return ret, false - } - return *o.VolumeCount, true -} - -// HasVolumeCount returns a boolean if a field has been set. -func (o *VmType) HasVolumeCount() bool { - if o != nil && o.VolumeCount != nil { - return true - } - - return false -} - -// SetVolumeCount gets a reference to the given int64 and assigns it to the VolumeCount field. -func (o *VmType) SetVolumeCount(v int64) { - o.VolumeCount = &v -} - -// GetVolumeSize returns the VolumeSize field value if set, zero value otherwise. -func (o *VmType) GetVolumeSize() int64 { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret - } - return *o.VolumeSize -} - -// GetVolumeSizeOk returns a tuple with the VolumeSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VmType) GetVolumeSizeOk() (int64, bool) { - if o == nil || o.VolumeSize == nil { - var ret int64 - return ret, false - } - return *o.VolumeSize, true -} - -// HasVolumeSize returns a boolean if a field has been set. -func (o *VmType) HasVolumeSize() bool { - if o != nil && o.VolumeSize != nil { - return true - } - - return false -} - -// SetVolumeSize gets a reference to the given int64 and assigns it to the VolumeSize field. -func (o *VmType) SetVolumeSize(v int64) { - o.VolumeSize = &v -} - -type NullableVmType struct { - Value VmType - ExplicitNull bool -} - -func (v NullableVmType) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVmType) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_volume.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_volume.go deleted file mode 100644 index ac846b176..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_volume.go +++ /dev/null @@ -1,358 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// Volume Information about the volume. -type Volume struct { - // The number of I/O operations per second (IOPS):
- For `io1` volumes, the number of provisioned IOPS
- For `gp2` volumes, the baseline performance of the volume - Iops *int64 `json:"Iops,omitempty"` - // Information about your volume attachment. - LinkedVolumes *[]LinkedVolume `json:"LinkedVolumes,omitempty"` - // The size of the volume, in gibibytes (GiB). - Size *int64 `json:"Size,omitempty"` - // The snapshot from which the volume was created. - SnapshotId *string `json:"SnapshotId,omitempty"` - // The state of the volume (`creating` \\| `available` \\| `in-use` \\| `deleting` \\| `error`). - State *string `json:"State,omitempty"` - // The Subregion in which the volume was created. - SubregionName *string `json:"SubregionName,omitempty"` - // One or more tags associated with the volume. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the volume. - VolumeId *string `json:"VolumeId,omitempty"` - // The type of the volume (`standard` \\| `gp2` \\| `io1`). - VolumeType *string `json:"VolumeType,omitempty"` -} - -// GetIops returns the Iops field value if set, zero value otherwise. -func (o *Volume) GetIops() int64 { - if o == nil || o.Iops == nil { - var ret int64 - return ret - } - return *o.Iops -} - -// GetIopsOk returns a tuple with the Iops field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetIopsOk() (int64, bool) { - if o == nil || o.Iops == nil { - var ret int64 - return ret, false - } - return *o.Iops, true -} - -// HasIops returns a boolean if a field has been set. -func (o *Volume) HasIops() bool { - if o != nil && o.Iops != nil { - return true - } - - return false -} - -// SetIops gets a reference to the given int64 and assigns it to the Iops field. -func (o *Volume) SetIops(v int64) { - o.Iops = &v -} - -// GetLinkedVolumes returns the LinkedVolumes field value if set, zero value otherwise. -func (o *Volume) GetLinkedVolumes() []LinkedVolume { - if o == nil || o.LinkedVolumes == nil { - var ret []LinkedVolume - return ret - } - return *o.LinkedVolumes -} - -// GetLinkedVolumesOk returns a tuple with the LinkedVolumes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetLinkedVolumesOk() ([]LinkedVolume, bool) { - if o == nil || o.LinkedVolumes == nil { - var ret []LinkedVolume - return ret, false - } - return *o.LinkedVolumes, true -} - -// HasLinkedVolumes returns a boolean if a field has been set. -func (o *Volume) HasLinkedVolumes() bool { - if o != nil && o.LinkedVolumes != nil { - return true - } - - return false -} - -// SetLinkedVolumes gets a reference to the given []LinkedVolume and assigns it to the LinkedVolumes field. -func (o *Volume) SetLinkedVolumes(v []LinkedVolume) { - o.LinkedVolumes = &v -} - -// GetSize returns the Size field value if set, zero value otherwise. -func (o *Volume) GetSize() int64 { - if o == nil || o.Size == nil { - var ret int64 - return ret - } - return *o.Size -} - -// GetSizeOk returns a tuple with the Size field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetSizeOk() (int64, bool) { - if o == nil || o.Size == nil { - var ret int64 - return ret, false - } - return *o.Size, true -} - -// HasSize returns a boolean if a field has been set. -func (o *Volume) HasSize() bool { - if o != nil && o.Size != nil { - return true - } - - return false -} - -// SetSize gets a reference to the given int64 and assigns it to the Size field. -func (o *Volume) SetSize(v int64) { - o.Size = &v -} - -// GetSnapshotId returns the SnapshotId field value if set, zero value otherwise. -func (o *Volume) GetSnapshotId() string { - if o == nil || o.SnapshotId == nil { - var ret string - return ret - } - return *o.SnapshotId -} - -// GetSnapshotIdOk returns a tuple with the SnapshotId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetSnapshotIdOk() (string, bool) { - if o == nil || o.SnapshotId == nil { - var ret string - return ret, false - } - return *o.SnapshotId, true -} - -// HasSnapshotId returns a boolean if a field has been set. -func (o *Volume) HasSnapshotId() bool { - if o != nil && o.SnapshotId != nil { - return true - } - - return false -} - -// SetSnapshotId gets a reference to the given string and assigns it to the SnapshotId field. -func (o *Volume) SetSnapshotId(v string) { - o.SnapshotId = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *Volume) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *Volume) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *Volume) SetState(v string) { - o.State = &v -} - -// GetSubregionName returns the SubregionName field value if set, zero value otherwise. -func (o *Volume) GetSubregionName() string { - if o == nil || o.SubregionName == nil { - var ret string - return ret - } - return *o.SubregionName -} - -// GetSubregionNameOk returns a tuple with the SubregionName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetSubregionNameOk() (string, bool) { - if o == nil || o.SubregionName == nil { - var ret string - return ret, false - } - return *o.SubregionName, true -} - -// HasSubregionName returns a boolean if a field has been set. -func (o *Volume) HasSubregionName() bool { - if o != nil && o.SubregionName != nil { - return true - } - - return false -} - -// SetSubregionName gets a reference to the given string and assigns it to the SubregionName field. -func (o *Volume) SetSubregionName(v string) { - o.SubregionName = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *Volume) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *Volume) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *Volume) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetVolumeId returns the VolumeId field value if set, zero value otherwise. -func (o *Volume) GetVolumeId() string { - if o == nil || o.VolumeId == nil { - var ret string - return ret - } - return *o.VolumeId -} - -// GetVolumeIdOk returns a tuple with the VolumeId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetVolumeIdOk() (string, bool) { - if o == nil || o.VolumeId == nil { - var ret string - return ret, false - } - return *o.VolumeId, true -} - -// HasVolumeId returns a boolean if a field has been set. -func (o *Volume) HasVolumeId() bool { - if o != nil && o.VolumeId != nil { - return true - } - - return false -} - -// SetVolumeId gets a reference to the given string and assigns it to the VolumeId field. -func (o *Volume) SetVolumeId(v string) { - o.VolumeId = &v -} - -// GetVolumeType returns the VolumeType field value if set, zero value otherwise. -func (o *Volume) GetVolumeType() string { - if o == nil || o.VolumeType == nil { - var ret string - return ret - } - return *o.VolumeType -} - -// GetVolumeTypeOk returns a tuple with the VolumeType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *Volume) GetVolumeTypeOk() (string, bool) { - if o == nil || o.VolumeType == nil { - var ret string - return ret, false - } - return *o.VolumeType, true -} - -// HasVolumeType returns a boolean if a field has been set. -func (o *Volume) HasVolumeType() bool { - if o != nil && o.VolumeType != nil { - return true - } - - return false -} - -// SetVolumeType gets a reference to the given string and assigns it to the VolumeType field. -func (o *Volume) SetVolumeType(v string) { - o.VolumeType = &v -} - -type NullableVolume struct { - Value Volume - ExplicitNull bool -} - -func (v NullableVolume) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVolume) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_vpn_connection.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_vpn_connection.go deleted file mode 100644 index 40bd3cd6d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_vpn_connection.go +++ /dev/null @@ -1,358 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// VpnConnection Information about a VPN connection. -type VpnConnection struct { - // The configuration to apply to the client gateway to establish the VPN connection, in XML format. - ClientGatewayConfiguration *string `json:"ClientGatewayConfiguration,omitempty"` - // The ID of the client gateway used on the client end of the connection. - ClientGatewayId *string `json:"ClientGatewayId,omitempty"` - // The type of VPN connection (always `ipsec.1`). - ConnectionType *string `json:"ConnectionType,omitempty"` - // Information about one or more static routes associated with the VPN connection, if any. - Routes *[]RouteLight `json:"Routes,omitempty"` - // The state of the VPN connection (`pending` \\| `available` \\| `deleting` \\| `deleted`). - State *string `json:"State,omitempty"` - // If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - StaticRoutesOnly *bool `json:"StaticRoutesOnly,omitempty"` - // One or more tags associated with the VPN connection. - Tags *[]ResourceTag `json:"Tags,omitempty"` - // The ID of the virtual gateway used on the 3DS OUTSCALE end of the connection. - VirtualGatewayId *string `json:"VirtualGatewayId,omitempty"` - // The ID of the VPN connection. - VpnConnectionId *string `json:"VpnConnectionId,omitempty"` -} - -// GetClientGatewayConfiguration returns the ClientGatewayConfiguration field value if set, zero value otherwise. -func (o *VpnConnection) GetClientGatewayConfiguration() string { - if o == nil || o.ClientGatewayConfiguration == nil { - var ret string - return ret - } - return *o.ClientGatewayConfiguration -} - -// GetClientGatewayConfigurationOk returns a tuple with the ClientGatewayConfiguration field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetClientGatewayConfigurationOk() (string, bool) { - if o == nil || o.ClientGatewayConfiguration == nil { - var ret string - return ret, false - } - return *o.ClientGatewayConfiguration, true -} - -// HasClientGatewayConfiguration returns a boolean if a field has been set. -func (o *VpnConnection) HasClientGatewayConfiguration() bool { - if o != nil && o.ClientGatewayConfiguration != nil { - return true - } - - return false -} - -// SetClientGatewayConfiguration gets a reference to the given string and assigns it to the ClientGatewayConfiguration field. -func (o *VpnConnection) SetClientGatewayConfiguration(v string) { - o.ClientGatewayConfiguration = &v -} - -// GetClientGatewayId returns the ClientGatewayId field value if set, zero value otherwise. -func (o *VpnConnection) GetClientGatewayId() string { - if o == nil || o.ClientGatewayId == nil { - var ret string - return ret - } - return *o.ClientGatewayId -} - -// GetClientGatewayIdOk returns a tuple with the ClientGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetClientGatewayIdOk() (string, bool) { - if o == nil || o.ClientGatewayId == nil { - var ret string - return ret, false - } - return *o.ClientGatewayId, true -} - -// HasClientGatewayId returns a boolean if a field has been set. -func (o *VpnConnection) HasClientGatewayId() bool { - if o != nil && o.ClientGatewayId != nil { - return true - } - - return false -} - -// SetClientGatewayId gets a reference to the given string and assigns it to the ClientGatewayId field. -func (o *VpnConnection) SetClientGatewayId(v string) { - o.ClientGatewayId = &v -} - -// GetConnectionType returns the ConnectionType field value if set, zero value otherwise. -func (o *VpnConnection) GetConnectionType() string { - if o == nil || o.ConnectionType == nil { - var ret string - return ret - } - return *o.ConnectionType -} - -// GetConnectionTypeOk returns a tuple with the ConnectionType field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetConnectionTypeOk() (string, bool) { - if o == nil || o.ConnectionType == nil { - var ret string - return ret, false - } - return *o.ConnectionType, true -} - -// HasConnectionType returns a boolean if a field has been set. -func (o *VpnConnection) HasConnectionType() bool { - if o != nil && o.ConnectionType != nil { - return true - } - - return false -} - -// SetConnectionType gets a reference to the given string and assigns it to the ConnectionType field. -func (o *VpnConnection) SetConnectionType(v string) { - o.ConnectionType = &v -} - -// GetRoutes returns the Routes field value if set, zero value otherwise. -func (o *VpnConnection) GetRoutes() []RouteLight { - if o == nil || o.Routes == nil { - var ret []RouteLight - return ret - } - return *o.Routes -} - -// GetRoutesOk returns a tuple with the Routes field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetRoutesOk() ([]RouteLight, bool) { - if o == nil || o.Routes == nil { - var ret []RouteLight - return ret, false - } - return *o.Routes, true -} - -// HasRoutes returns a boolean if a field has been set. -func (o *VpnConnection) HasRoutes() bool { - if o != nil && o.Routes != nil { - return true - } - - return false -} - -// SetRoutes gets a reference to the given []RouteLight and assigns it to the Routes field. -func (o *VpnConnection) SetRoutes(v []RouteLight) { - o.Routes = &v -} - -// GetState returns the State field value if set, zero value otherwise. -func (o *VpnConnection) GetState() string { - if o == nil || o.State == nil { - var ret string - return ret - } - return *o.State -} - -// GetStateOk returns a tuple with the State field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetStateOk() (string, bool) { - if o == nil || o.State == nil { - var ret string - return ret, false - } - return *o.State, true -} - -// HasState returns a boolean if a field has been set. -func (o *VpnConnection) HasState() bool { - if o != nil && o.State != nil { - return true - } - - return false -} - -// SetState gets a reference to the given string and assigns it to the State field. -func (o *VpnConnection) SetState(v string) { - o.State = &v -} - -// GetStaticRoutesOnly returns the StaticRoutesOnly field value if set, zero value otherwise. -func (o *VpnConnection) GetStaticRoutesOnly() bool { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret - } - return *o.StaticRoutesOnly -} - -// GetStaticRoutesOnlyOk returns a tuple with the StaticRoutesOnly field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetStaticRoutesOnlyOk() (bool, bool) { - if o == nil || o.StaticRoutesOnly == nil { - var ret bool - return ret, false - } - return *o.StaticRoutesOnly, true -} - -// HasStaticRoutesOnly returns a boolean if a field has been set. -func (o *VpnConnection) HasStaticRoutesOnly() bool { - if o != nil && o.StaticRoutesOnly != nil { - return true - } - - return false -} - -// SetStaticRoutesOnly gets a reference to the given bool and assigns it to the StaticRoutesOnly field. -func (o *VpnConnection) SetStaticRoutesOnly(v bool) { - o.StaticRoutesOnly = &v -} - -// GetTags returns the Tags field value if set, zero value otherwise. -func (o *VpnConnection) GetTags() []ResourceTag { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret - } - return *o.Tags -} - -// GetTagsOk returns a tuple with the Tags field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetTagsOk() ([]ResourceTag, bool) { - if o == nil || o.Tags == nil { - var ret []ResourceTag - return ret, false - } - return *o.Tags, true -} - -// HasTags returns a boolean if a field has been set. -func (o *VpnConnection) HasTags() bool { - if o != nil && o.Tags != nil { - return true - } - - return false -} - -// SetTags gets a reference to the given []ResourceTag and assigns it to the Tags field. -func (o *VpnConnection) SetTags(v []ResourceTag) { - o.Tags = &v -} - -// GetVirtualGatewayId returns the VirtualGatewayId field value if set, zero value otherwise. -func (o *VpnConnection) GetVirtualGatewayId() string { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret - } - return *o.VirtualGatewayId -} - -// GetVirtualGatewayIdOk returns a tuple with the VirtualGatewayId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetVirtualGatewayIdOk() (string, bool) { - if o == nil || o.VirtualGatewayId == nil { - var ret string - return ret, false - } - return *o.VirtualGatewayId, true -} - -// HasVirtualGatewayId returns a boolean if a field has been set. -func (o *VpnConnection) HasVirtualGatewayId() bool { - if o != nil && o.VirtualGatewayId != nil { - return true - } - - return false -} - -// SetVirtualGatewayId gets a reference to the given string and assigns it to the VirtualGatewayId field. -func (o *VpnConnection) SetVirtualGatewayId(v string) { - o.VirtualGatewayId = &v -} - -// GetVpnConnectionId returns the VpnConnectionId field value if set, zero value otherwise. -func (o *VpnConnection) GetVpnConnectionId() string { - if o == nil || o.VpnConnectionId == nil { - var ret string - return ret - } - return *o.VpnConnectionId -} - -// GetVpnConnectionIdOk returns a tuple with the VpnConnectionId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *VpnConnection) GetVpnConnectionIdOk() (string, bool) { - if o == nil || o.VpnConnectionId == nil { - var ret string - return ret, false - } - return *o.VpnConnectionId, true -} - -// HasVpnConnectionId returns a boolean if a field has been set. -func (o *VpnConnection) HasVpnConnectionId() bool { - if o != nil && o.VpnConnectionId != nil { - return true - } - - return false -} - -// SetVpnConnectionId gets a reference to the given string and assigns it to the VpnConnectionId field. -func (o *VpnConnection) SetVpnConnectionId(v string) { - o.VpnConnectionId = &v -} - -type NullableVpnConnection struct { - Value VpnConnection - ExplicitNull bool -} - -func (v NullableVpnConnection) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableVpnConnection) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/model_with.go b/vendor/github.com/marinsalinas/osc-sdk-go/model_with.go deleted file mode 100644 index 91c1a5197..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/model_with.go +++ /dev/null @@ -1,603 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" -) - -// With The information to be displayed in the API logs to retrieve. -type With struct { - // If set to `true`, the account ID is displayed in the logs. - AccountId *bool `json:"AccountId,omitempty"` - // If set to `true`, the duration of the call is displayed each log. - CallDuration *bool `json:"CallDuration,omitempty"` - // If set to `true`, the API key used for the query is displayed each log. - QueryAccessKey *bool `json:"QueryAccessKey,omitempty"` - // If set to `true`, the name of the API service used by the call is displayed in each log (`oapi` \\| `fcu` \\| `lbu` \\| `directlink` \\| `eim` \\| `icu`). - QueryApiName *bool `json:"QueryApiName,omitempty"` - // If set to `true`, the version of the API service used by the call is displayed in each log. - QueryApiVersion *bool `json:"QueryApiVersion,omitempty"` - // If set to `true`, the name of the call is displayed in each log. - QueryCallName *bool `json:"QueryCallName,omitempty"` - // If set to `true`, the date of the call is displayed in each log. - QueryDate *bool `json:"QueryDate,omitempty"` - // If set to `true`, the query header RAW is displayed in each log. - QueryHeaderRaw *bool `json:"QueryHeaderRaw,omitempty"` - // If set to `true`, the query header size is displayed in each log. - QueryHeaderSize *bool `json:"QueryHeaderSize,omitempty"` - // If set to `true`, the IP address used to make to query is displayed in each log. - QueryIpAddress *bool `json:"QueryIpAddress,omitempty"` - // If set to `true`, the query payload raw is displayed in each log. - QueryPayloadRaw *bool `json:"QueryPayloadRaw,omitempty"` - // If set to `true`, the query payload size is displayed in each log. - QueryPayloadSize *bool `json:"QueryPayloadSize,omitempty"` - // If set to `true`, the user agent used to make the HTTP request is displayed in each log. - QueryUserAgent *bool `json:"QueryUserAgent,omitempty"` - // By default ot if set to `true`, the ID of the call is displayed in each log. - RequestId *bool `json:"RequestId,omitempty"` - // If set to `true`, the size of the response (in bytes) is displayed in each log. - ResponseSize *bool `json:"ResponseSize,omitempty"` - // If set to `true`, the HTTP code provided by the response is displayed in each log. - ResponseStatusCode *bool `json:"ResponseStatusCode,omitempty"` -} - -// GetAccountId returns the AccountId field value if set, zero value otherwise. -func (o *With) GetAccountId() bool { - if o == nil || o.AccountId == nil { - var ret bool - return ret - } - return *o.AccountId -} - -// GetAccountIdOk returns a tuple with the AccountId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetAccountIdOk() (bool, bool) { - if o == nil || o.AccountId == nil { - var ret bool - return ret, false - } - return *o.AccountId, true -} - -// HasAccountId returns a boolean if a field has been set. -func (o *With) HasAccountId() bool { - if o != nil && o.AccountId != nil { - return true - } - - return false -} - -// SetAccountId gets a reference to the given bool and assigns it to the AccountId field. -func (o *With) SetAccountId(v bool) { - o.AccountId = &v -} - -// GetCallDuration returns the CallDuration field value if set, zero value otherwise. -func (o *With) GetCallDuration() bool { - if o == nil || o.CallDuration == nil { - var ret bool - return ret - } - return *o.CallDuration -} - -// GetCallDurationOk returns a tuple with the CallDuration field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetCallDurationOk() (bool, bool) { - if o == nil || o.CallDuration == nil { - var ret bool - return ret, false - } - return *o.CallDuration, true -} - -// HasCallDuration returns a boolean if a field has been set. -func (o *With) HasCallDuration() bool { - if o != nil && o.CallDuration != nil { - return true - } - - return false -} - -// SetCallDuration gets a reference to the given bool and assigns it to the CallDuration field. -func (o *With) SetCallDuration(v bool) { - o.CallDuration = &v -} - -// GetQueryAccessKey returns the QueryAccessKey field value if set, zero value otherwise. -func (o *With) GetQueryAccessKey() bool { - if o == nil || o.QueryAccessKey == nil { - var ret bool - return ret - } - return *o.QueryAccessKey -} - -// GetQueryAccessKeyOk returns a tuple with the QueryAccessKey field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryAccessKeyOk() (bool, bool) { - if o == nil || o.QueryAccessKey == nil { - var ret bool - return ret, false - } - return *o.QueryAccessKey, true -} - -// HasQueryAccessKey returns a boolean if a field has been set. -func (o *With) HasQueryAccessKey() bool { - if o != nil && o.QueryAccessKey != nil { - return true - } - - return false -} - -// SetQueryAccessKey gets a reference to the given bool and assigns it to the QueryAccessKey field. -func (o *With) SetQueryAccessKey(v bool) { - o.QueryAccessKey = &v -} - -// GetQueryApiName returns the QueryApiName field value if set, zero value otherwise. -func (o *With) GetQueryApiName() bool { - if o == nil || o.QueryApiName == nil { - var ret bool - return ret - } - return *o.QueryApiName -} - -// GetQueryApiNameOk returns a tuple with the QueryApiName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryApiNameOk() (bool, bool) { - if o == nil || o.QueryApiName == nil { - var ret bool - return ret, false - } - return *o.QueryApiName, true -} - -// HasQueryApiName returns a boolean if a field has been set. -func (o *With) HasQueryApiName() bool { - if o != nil && o.QueryApiName != nil { - return true - } - - return false -} - -// SetQueryApiName gets a reference to the given bool and assigns it to the QueryApiName field. -func (o *With) SetQueryApiName(v bool) { - o.QueryApiName = &v -} - -// GetQueryApiVersion returns the QueryApiVersion field value if set, zero value otherwise. -func (o *With) GetQueryApiVersion() bool { - if o == nil || o.QueryApiVersion == nil { - var ret bool - return ret - } - return *o.QueryApiVersion -} - -// GetQueryApiVersionOk returns a tuple with the QueryApiVersion field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryApiVersionOk() (bool, bool) { - if o == nil || o.QueryApiVersion == nil { - var ret bool - return ret, false - } - return *o.QueryApiVersion, true -} - -// HasQueryApiVersion returns a boolean if a field has been set. -func (o *With) HasQueryApiVersion() bool { - if o != nil && o.QueryApiVersion != nil { - return true - } - - return false -} - -// SetQueryApiVersion gets a reference to the given bool and assigns it to the QueryApiVersion field. -func (o *With) SetQueryApiVersion(v bool) { - o.QueryApiVersion = &v -} - -// GetQueryCallName returns the QueryCallName field value if set, zero value otherwise. -func (o *With) GetQueryCallName() bool { - if o == nil || o.QueryCallName == nil { - var ret bool - return ret - } - return *o.QueryCallName -} - -// GetQueryCallNameOk returns a tuple with the QueryCallName field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryCallNameOk() (bool, bool) { - if o == nil || o.QueryCallName == nil { - var ret bool - return ret, false - } - return *o.QueryCallName, true -} - -// HasQueryCallName returns a boolean if a field has been set. -func (o *With) HasQueryCallName() bool { - if o != nil && o.QueryCallName != nil { - return true - } - - return false -} - -// SetQueryCallName gets a reference to the given bool and assigns it to the QueryCallName field. -func (o *With) SetQueryCallName(v bool) { - o.QueryCallName = &v -} - -// GetQueryDate returns the QueryDate field value if set, zero value otherwise. -func (o *With) GetQueryDate() bool { - if o == nil || o.QueryDate == nil { - var ret bool - return ret - } - return *o.QueryDate -} - -// GetQueryDateOk returns a tuple with the QueryDate field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryDateOk() (bool, bool) { - if o == nil || o.QueryDate == nil { - var ret bool - return ret, false - } - return *o.QueryDate, true -} - -// HasQueryDate returns a boolean if a field has been set. -func (o *With) HasQueryDate() bool { - if o != nil && o.QueryDate != nil { - return true - } - - return false -} - -// SetQueryDate gets a reference to the given bool and assigns it to the QueryDate field. -func (o *With) SetQueryDate(v bool) { - o.QueryDate = &v -} - -// GetQueryHeaderRaw returns the QueryHeaderRaw field value if set, zero value otherwise. -func (o *With) GetQueryHeaderRaw() bool { - if o == nil || o.QueryHeaderRaw == nil { - var ret bool - return ret - } - return *o.QueryHeaderRaw -} - -// GetQueryHeaderRawOk returns a tuple with the QueryHeaderRaw field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryHeaderRawOk() (bool, bool) { - if o == nil || o.QueryHeaderRaw == nil { - var ret bool - return ret, false - } - return *o.QueryHeaderRaw, true -} - -// HasQueryHeaderRaw returns a boolean if a field has been set. -func (o *With) HasQueryHeaderRaw() bool { - if o != nil && o.QueryHeaderRaw != nil { - return true - } - - return false -} - -// SetQueryHeaderRaw gets a reference to the given bool and assigns it to the QueryHeaderRaw field. -func (o *With) SetQueryHeaderRaw(v bool) { - o.QueryHeaderRaw = &v -} - -// GetQueryHeaderSize returns the QueryHeaderSize field value if set, zero value otherwise. -func (o *With) GetQueryHeaderSize() bool { - if o == nil || o.QueryHeaderSize == nil { - var ret bool - return ret - } - return *o.QueryHeaderSize -} - -// GetQueryHeaderSizeOk returns a tuple with the QueryHeaderSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryHeaderSizeOk() (bool, bool) { - if o == nil || o.QueryHeaderSize == nil { - var ret bool - return ret, false - } - return *o.QueryHeaderSize, true -} - -// HasQueryHeaderSize returns a boolean if a field has been set. -func (o *With) HasQueryHeaderSize() bool { - if o != nil && o.QueryHeaderSize != nil { - return true - } - - return false -} - -// SetQueryHeaderSize gets a reference to the given bool and assigns it to the QueryHeaderSize field. -func (o *With) SetQueryHeaderSize(v bool) { - o.QueryHeaderSize = &v -} - -// GetQueryIpAddress returns the QueryIpAddress field value if set, zero value otherwise. -func (o *With) GetQueryIpAddress() bool { - if o == nil || o.QueryIpAddress == nil { - var ret bool - return ret - } - return *o.QueryIpAddress -} - -// GetQueryIpAddressOk returns a tuple with the QueryIpAddress field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryIpAddressOk() (bool, bool) { - if o == nil || o.QueryIpAddress == nil { - var ret bool - return ret, false - } - return *o.QueryIpAddress, true -} - -// HasQueryIpAddress returns a boolean if a field has been set. -func (o *With) HasQueryIpAddress() bool { - if o != nil && o.QueryIpAddress != nil { - return true - } - - return false -} - -// SetQueryIpAddress gets a reference to the given bool and assigns it to the QueryIpAddress field. -func (o *With) SetQueryIpAddress(v bool) { - o.QueryIpAddress = &v -} - -// GetQueryPayloadRaw returns the QueryPayloadRaw field value if set, zero value otherwise. -func (o *With) GetQueryPayloadRaw() bool { - if o == nil || o.QueryPayloadRaw == nil { - var ret bool - return ret - } - return *o.QueryPayloadRaw -} - -// GetQueryPayloadRawOk returns a tuple with the QueryPayloadRaw field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryPayloadRawOk() (bool, bool) { - if o == nil || o.QueryPayloadRaw == nil { - var ret bool - return ret, false - } - return *o.QueryPayloadRaw, true -} - -// HasQueryPayloadRaw returns a boolean if a field has been set. -func (o *With) HasQueryPayloadRaw() bool { - if o != nil && o.QueryPayloadRaw != nil { - return true - } - - return false -} - -// SetQueryPayloadRaw gets a reference to the given bool and assigns it to the QueryPayloadRaw field. -func (o *With) SetQueryPayloadRaw(v bool) { - o.QueryPayloadRaw = &v -} - -// GetQueryPayloadSize returns the QueryPayloadSize field value if set, zero value otherwise. -func (o *With) GetQueryPayloadSize() bool { - if o == nil || o.QueryPayloadSize == nil { - var ret bool - return ret - } - return *o.QueryPayloadSize -} - -// GetQueryPayloadSizeOk returns a tuple with the QueryPayloadSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryPayloadSizeOk() (bool, bool) { - if o == nil || o.QueryPayloadSize == nil { - var ret bool - return ret, false - } - return *o.QueryPayloadSize, true -} - -// HasQueryPayloadSize returns a boolean if a field has been set. -func (o *With) HasQueryPayloadSize() bool { - if o != nil && o.QueryPayloadSize != nil { - return true - } - - return false -} - -// SetQueryPayloadSize gets a reference to the given bool and assigns it to the QueryPayloadSize field. -func (o *With) SetQueryPayloadSize(v bool) { - o.QueryPayloadSize = &v -} - -// GetQueryUserAgent returns the QueryUserAgent field value if set, zero value otherwise. -func (o *With) GetQueryUserAgent() bool { - if o == nil || o.QueryUserAgent == nil { - var ret bool - return ret - } - return *o.QueryUserAgent -} - -// GetQueryUserAgentOk returns a tuple with the QueryUserAgent field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetQueryUserAgentOk() (bool, bool) { - if o == nil || o.QueryUserAgent == nil { - var ret bool - return ret, false - } - return *o.QueryUserAgent, true -} - -// HasQueryUserAgent returns a boolean if a field has been set. -func (o *With) HasQueryUserAgent() bool { - if o != nil && o.QueryUserAgent != nil { - return true - } - - return false -} - -// SetQueryUserAgent gets a reference to the given bool and assigns it to the QueryUserAgent field. -func (o *With) SetQueryUserAgent(v bool) { - o.QueryUserAgent = &v -} - -// GetRequestId returns the RequestId field value if set, zero value otherwise. -func (o *With) GetRequestId() bool { - if o == nil || o.RequestId == nil { - var ret bool - return ret - } - return *o.RequestId -} - -// GetRequestIdOk returns a tuple with the RequestId field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetRequestIdOk() (bool, bool) { - if o == nil || o.RequestId == nil { - var ret bool - return ret, false - } - return *o.RequestId, true -} - -// HasRequestId returns a boolean if a field has been set. -func (o *With) HasRequestId() bool { - if o != nil && o.RequestId != nil { - return true - } - - return false -} - -// SetRequestId gets a reference to the given bool and assigns it to the RequestId field. -func (o *With) SetRequestId(v bool) { - o.RequestId = &v -} - -// GetResponseSize returns the ResponseSize field value if set, zero value otherwise. -func (o *With) GetResponseSize() bool { - if o == nil || o.ResponseSize == nil { - var ret bool - return ret - } - return *o.ResponseSize -} - -// GetResponseSizeOk returns a tuple with the ResponseSize field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetResponseSizeOk() (bool, bool) { - if o == nil || o.ResponseSize == nil { - var ret bool - return ret, false - } - return *o.ResponseSize, true -} - -// HasResponseSize returns a boolean if a field has been set. -func (o *With) HasResponseSize() bool { - if o != nil && o.ResponseSize != nil { - return true - } - - return false -} - -// SetResponseSize gets a reference to the given bool and assigns it to the ResponseSize field. -func (o *With) SetResponseSize(v bool) { - o.ResponseSize = &v -} - -// GetResponseStatusCode returns the ResponseStatusCode field value if set, zero value otherwise. -func (o *With) GetResponseStatusCode() bool { - if o == nil || o.ResponseStatusCode == nil { - var ret bool - return ret - } - return *o.ResponseStatusCode -} - -// GetResponseStatusCodeOk returns a tuple with the ResponseStatusCode field value if set, zero value otherwise -// and a boolean to check if the value has been set. -func (o *With) GetResponseStatusCodeOk() (bool, bool) { - if o == nil || o.ResponseStatusCode == nil { - var ret bool - return ret, false - } - return *o.ResponseStatusCode, true -} - -// HasResponseStatusCode returns a boolean if a field has been set. -func (o *With) HasResponseStatusCode() bool { - if o != nil && o.ResponseStatusCode != nil { - return true - } - - return false -} - -// SetResponseStatusCode gets a reference to the given bool and assigns it to the ResponseStatusCode field. -func (o *With) SetResponseStatusCode(v bool) { - o.ResponseStatusCode = &v -} - -type NullableWith struct { - Value With - ExplicitNull bool -} - -func (v NullableWith) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableWith) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/outscale.yaml b/vendor/github.com/marinsalinas/osc-sdk-go/outscale.yaml deleted file mode 100644 index 3904c506e..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/outscale.yaml +++ /dev/null @@ -1,12339 +0,0 @@ -components: - schemas: - AcceptNetPeeringRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetPeeringId: - description: The ID of the Net peering connection you want to accept. - type: string - required: - - NetPeeringId - type: object - AcceptNetPeeringResponse: - additionalProperties: false - properties: - NetPeering: - $ref: '#/components/schemas/NetPeering' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - AccepterNet: - additionalProperties: false - description: Information about the accepter Net. - properties: - AccountId: - description: The account ID of the owner of the accepter Net. - type: string - IpRange: - description: The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - type: string - NetId: - description: The ID of the accepter Net. - type: string - type: object - AccessKey: - additionalProperties: false - description: Information about the access key. - properties: - AccessKeyId: - description: The ID of the access key. - type: string - CreationDate: - description: The date and time of creation of the access key. - format: datetime - type: string - LastModificationDate: - description: The date and time of the last modification of the access key. - format: datetime - type: string - State: - description: The state of the access key (`Active` if the key is valid for API calls, or `Inactive` if not). - type: string - type: object - AccessKeySecretKey: - additionalProperties: false - description: Information about the secret access key. - properties: - AccessKeyId: - description: The ID of the secret access key. - type: string - CreationDate: - description: The date and time of creation of the secret access key. - format: datetime - type: string - LastModificationDate: - description: The date and time of the last modification of the secret access key. - format: datetime - type: string - SecretKey: - description: The secret access key that enables you to send requests. - type: string - State: - description: The state of the secret access key (`Active` if the key is valid for API calls, or `Inactive` if not). - type: string - type: object - AccessLog: - additionalProperties: false - description: Information about access logs. - properties: - IsEnabled: - description: If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - type: boolean - OsuBucketName: - description: The name of the Object Storage Unit (OSU) bucket for the access logs. - type: string - OsuBucketPrefix: - description: The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - type: string - PublicationInterval: - description: The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). - type: long - type: object - Account: - additionalProperties: false - description: Information about the account. - properties: - AccountId: - description: The ID of the account. - type: string - City: - description: The city of the account owner. - type: string - CompanyName: - description: The name of the company for the account. - type: string - Country: - description: The country of the account owner. - type: string - CustomerId: - description: The ID of the customer. It must be 8 digits (by default, `12345678`). - type: string - Email: - description: The email address for the account. - type: string - FirstName: - description: The first name of the account owner. - type: string - JobTitle: - description: The job title of the account owner. - type: string - LastName: - description: The last name of the account owner. - type: string - MobileNumber: - description: The mobile phone number of the account owner. - type: string - PhoneNumber: - description: The landline phone number of the account owner. - type: string - StateProvince: - description: The state/province of the account. - type: string - VatNumber: - description: The value added tax (VAT) number for the account. - type: string - ZipCode: - description: The ZIP code of the city. - type: string - type: object - ApplicationStickyCookiePolicy: - additionalProperties: false - description: Information about the stickiness policy. - properties: - CookieName: - description: The name of the application cookie used for stickiness. - type: string - PolicyName: - description: The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. - type: string - type: object - BackendVmHealth: - additionalProperties: false - description: Information about the health of a back-end VM. - properties: - Description: - description: The description of the state of the back-end VM. - type: string - State: - description: The state of the back-end VM (`InService` \| `OutOfService` \| `Unknown`). - type: string - StateReason: - description: 'Information about the cause of `OutOfService` VMs.
- - Specifically, whether the cause is Elastic Load Balancing or the VM (`ELB` \| `Instance` \| `N/A`).' - type: string - VmId: - description: The ID of the back-end VM. - type: string - type: object - BlockDeviceMappingCreated: - additionalProperties: false - description: Information about the created block device mapping. - properties: - Bsu: - $ref: '#/components/schemas/BsuCreated' - DeviceName: - description: The name of the device. - type: string - type: object - BlockDeviceMappingImage: - additionalProperties: false - description: One or more parameters used to automatically set up volumes when the VM is created. - properties: - Bsu: - $ref: '#/components/schemas/BsuToCreate' - DeviceName: - description: The name of the device. - type: string - VirtualDeviceName: - description: The name of the virtual device (ephemeralN). - type: string - type: object - BlockDeviceMappingVmCreation: - additionalProperties: false - description: Information about the block device mapping. - properties: - Bsu: - $ref: '#/components/schemas/BsuToCreate' - DeviceName: - description: The name of the device. - type: string - NoDevice: - description: Removes the device which is included in the block device mapping of the OMI. - type: string - VirtualDeviceName: - description: The name of the virtual device (ephemeralN). - type: string - type: object - BlockDeviceMappingVmUpdate: - additionalProperties: false - description: Information about the block device mapping. - properties: - Bsu: - $ref: '#/components/schemas/BsuToUpdateVm' - DeviceName: - description: The name of the device. - type: string - NoDevice: - description: Removes the device which is included in the block device mapping of the OMI. - type: string - VirtualDeviceName: - description: The name of the virtual device (ephemeralN). - type: string - type: object - BsuCreated: - additionalProperties: false - description: Information about the created BSU volume. - properties: - DeleteOnVmDeletion: - description: Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - type: boolean - LinkDate: - description: The time and date of attachment of the volume to the VM. - format: date - type: string - State: - description: The state of the volume. - type: string - VolumeId: - description: The ID of the volume. - type: string - type: object - BsuToCreate: - additionalProperties: false - description: Information about the BSU volume to create. - properties: - DeleteOnVmDeletion: - description: Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - type: boolean - Iops: - description: The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - type: long - SnapshotId: - description: The ID of the snapshot used to create the volume. - type: string - VolumeSize: - description: 'The size of the volume, in gibibytes (GiB).
- - If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
- - If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one.' - type: long - VolumeType: - description: 'The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
- - For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS).' - type: string - type: object - BsuToUpdateVm: - additionalProperties: false - description: Information about the BSU volume. - properties: - DeleteOnVmDeletion: - description: If `true`, the volume is deleted when the VM is terminated. - type: boolean - VolumeId: - description: The ID of the volume. - type: string - type: object - CheckAuthenticationRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Login: - description: The email address of the account. - type: string - Password: - description: The password of the account. - type: string - type: object - CheckAuthenticationResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ClientGateway: - additionalProperties: false - description: Information about the client gateway. - properties: - BgpAsn: - description: An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. - type: long - ClientGatewayId: - description: The ID of the client gateway. - type: string - ConnectionType: - description: The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). - type: string - PublicIp: - description: The public IPv4 address of the client gateway (must be a fixed address into a NATed network). - type: string - State: - description: The state of the client gateway (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - Tags: - description: One or more tags associated with the client gateway. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - ConsumptionEntry: - additionalProperties: false - description: Information about the resources consumed during the specified time period. - properties: - Category: - description: The category of the resource (for example, `network`). - type: string - FromDate: - description: The beginning of the time period. - type: string - Operation: - description: The API call that triggered the resource consumption (for example, `RunInstances` or `CreateVolume`). - type: string - Service: - description: The service of the API call (`TinaOS-FCU`, `TinaOS-LBU`, `TinaOS-OSU` or `TinaOS-DirectLink`). - type: string - Title: - description: A description of the consumed resource. - type: string - ToDate: - description: The end of the time period. - type: string - Type: - description: The type of resource, depending on the API call. - type: string - Value: - description: The consumed amount for the resource. The unit depends on the resource type. For more information, see the `Title` element. - type: string - type: object - CreateAccessKeyResponse: - additionalProperties: false - properties: - AccessKey: - $ref: '#/components/schemas/AccessKeySecretKey' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateAccountRequest: - additionalProperties: false - properties: - City: - description: The city of the account owner. - type: string - CompanyName: - description: The name of the company for the account. - type: string - Country: - description: The country of the account owner. - type: string - CustomerId: - description: The ID of the customer. It must be 8 digits (by default, `12345678`). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Email: - description: The email address for the account. - type: string - FirstName: - description: The first name of the account owner. - type: string - JobTitle: - description: The job title of the account owner. - type: string - LastName: - description: The last name of the account owner. - type: string - MobileNumber: - description: The mobile phone number of the account owner. - type: string - PhoneNumber: - description: The landline phone number of the account owner. - type: string - StateProvince: - description: The state/province of the account. - type: string - VatNumber: - description: The value added tax (VAT) number for the account. - type: string - ZipCode: - description: The ZIP code of the city. - type: string - required: - - City - - CompanyName - - Country - - CustomerId - - Email - - FirstName - - LastName - - ZipCode - type: object - CreateAccountResponse: - additionalProperties: false - properties: - Account: - $ref: '#/components/schemas/Account' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateClientGatewayRequest: - additionalProperties: false - properties: - BgpAsn: - description: An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. The long must be within the [0;4294967295] range. By default, 65000. - type: long - ConnectionType: - description: The communication protocol used to establish tunnel with your client gateway (only `ipsec.1` is supported). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - PublicIp: - description: The public fixed IPv4 address of your client gateway. - type: string - required: - - BgpAsn - - PublicIp - - ConnectionType - type: object - CreateClientGatewayResponse: - additionalProperties: false - properties: - ClientGateway: - $ref: '#/components/schemas/ClientGateway' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateDhcpOptionsRequest: - additionalProperties: false - properties: - DomainName: - description: Specify a domain name (for example, MyCompany.com). You can specify only one domain name. - type: string - DomainNameServers: - description: The IP addresses of domain name servers. If no IP addresses are specified, the `OutscaleProvidedDNS` value is set by default. - items: - type: string - type: array - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NtpServers: - description: The IP addresses of the Network Time Protocol (NTP) servers. - items: - type: string - type: array - type: object - CreateDhcpOptionsResponse: - additionalProperties: false - properties: - DhcpOptionsSet: - $ref: '#/components/schemas/DhcpOptionsSet' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateDirectLinkInterfaceRequest: - additionalProperties: false - properties: - DirectLinkId: - description: The ID of the existing DirectLink for which you want to create the DirectLink interface. - type: string - DirectLinkInterface: - $ref: '#/components/schemas/DirectLinkInterface' - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - DirectLinkId - - DirectLinkInterface - type: object - CreateDirectLinkInterfaceResponse: - additionalProperties: false - properties: - DirectLinkInterface: - $ref: '#/components/schemas/DirectLinkInterfaces' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateDirectLinkRequest: - additionalProperties: false - properties: - Bandwidth: - description: The bandwidth of the DirectLink (`1Gbps` \| `10Gbps`). - type: string - DirectLinkName: - description: The name of the DirectLink. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Location: - description: The code of the requested location for the DirectLink, returned by the [ReadLocations](#readlocations) method. - type: string - required: - - Bandwidth - - DirectLinkName - - Location - type: object - CreateDirectLinkResponse: - additionalProperties: false - properties: - DirectLink: - $ref: '#/components/schemas/DirectLink' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateFlexibleGpuRequest: - additionalProperties: false - properties: - DeleteOnVmDeletion: - default: false - description: If `true`, the fGPU is deleted when the VM is terminated. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Generation: - description: The processor generation that the fGPU must be compatible with. If not specified, the oldest possible processor generation is selected (as provided by [ReadFlexibleGpuCatalog](#readflexiblegpucatalog) for the specified model of fGPU). - type: string - ModelName: - description: The model of fGPU you want to allocate. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - type: string - SubregionName: - description: The Subregion in which you want to create the fGPU. - type: string - required: - - ModelName - - SubregionName - type: object - CreateFlexibleGpuResponse: - additionalProperties: false - properties: - FlexibleGpu: - $ref: '#/components/schemas/FlexibleGpu' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateImageExportTaskRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ImageId: - description: The ID of the OMI to export. - type: string - OsuExport: - $ref: '#/components/schemas/OsuExport' - required: - - OsuExport - - ImageId - type: object - CreateImageExportTaskResponse: - additionalProperties: false - properties: - ImageExportTask: - $ref: '#/components/schemas/ImageExportTask' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateImageRequest: - additionalProperties: false - properties: - Architecture: - description: The architecture of the OMI (by default, `i386`). - type: string - BlockDeviceMappings: - description: One or more block device mappings. - items: - $ref: '#/components/schemas/BlockDeviceMappingImage' - type: array - Description: - description: A description for the new OMI. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FileLocation: - description: The pre-signed URL of the OMI manifest file, or the full path to the OMI stored in an OSU bucket. If you specify this parameter, a copy of the OMI is created in your account. - type: string - ImageName: - description: 'A unique name for the new OMI.
- - Constraints: 3-128 alphanumeric characters, underscores (_), spaces ( ), parentheses (()), slashes (/), periods (.), or dashes (-).' - type: string - NoReboot: - description: If `false`, the VM shuts down before creating the OMI and then reboots. If `true`, the VM does not. - type: boolean - RootDeviceName: - description: The name of the root device. - type: string - SourceImageId: - description: The ID of the OMI you want to copy. - type: string - SourceRegionName: - description: The name of the source Region, which must be the same as the Region of your account. - type: string - VmId: - description: The ID of the VM from which you want to create the OMI. - type: string - type: object - CreateImageResponse: - additionalProperties: false - properties: - Image: - $ref: '#/components/schemas/Image' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateInternetServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - CreateInternetServiceResponse: - additionalProperties: false - properties: - InternetService: - $ref: '#/components/schemas/InternetService' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateKeypairRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - KeypairName: - description: A unique name for the keypair, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). - type: string - PublicKey: - description: The public key. It must be base64-encoded. - type: string - required: - - KeypairName - type: object - CreateKeypairResponse: - additionalProperties: false - properties: - Keypair: - $ref: '#/components/schemas/KeypairCreated' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateListenerRuleRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Listener: - $ref: '#/components/schemas/LoadBalancerLight' - ListenerRule: - $ref: '#/components/schemas/ListenerRuleForCreation' - VmIds: - description: The IDs of the backend VMs. - items: - type: string - type: array - required: - - VmIds - - Listener - - ListenerRule - type: object - CreateListenerRuleResponse: - additionalProperties: false - properties: - ListenerRule: - $ref: '#/components/schemas/ListenerRule' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateLoadBalancerListenersRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Listeners: - description: One or more listeners for the load balancer. - items: - $ref: '#/components/schemas/ListenerForCreation' - type: array - LoadBalancerName: - description: The name of the load balancer for which you want to create listeners. - type: string - required: - - Listeners - - LoadBalancerName - type: object - CreateLoadBalancerListenersResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateLoadBalancerPolicyRequest: - additionalProperties: false - properties: - CookieName: - description: The name of the application cookie used for stickiness. This parameter is required if you create a stickiness policy based on an application-generated cookie. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer for which you want to create a policy. - type: string - PolicyName: - description: The name of the policy. This name must be unique and consist of alphanumeric characters and dashes (-). - type: string - PolicyType: - description: 'The type of stickiness policy you want to create: `app` or `load_balancer`.' - type: string - required: - - PolicyType - - LoadBalancerName - - PolicyName - type: object - CreateLoadBalancerPolicyResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateLoadBalancerRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Listeners: - description: One or more listeners to create. - items: - $ref: '#/components/schemas/ListenerForCreation' - type: array - LoadBalancerName: - description: The unique name of the load balancer (32 alphanumeric or hyphen characters maximum, but cannot start or end with a hyphen). - type: string - LoadBalancerType: - description: 'The type of load balancer: `internet-facing` or `internal`. Use this parameter only for load balancers in a Net.' - type: string - SecurityGroups: - description: 'One or more IDs of security groups you want to assign to the load balancer.
- - In a Net, this attribute is required. In the public Cloud, it is optional and default security groups can be applied.' - items: - type: string - type: array - Subnets: - description: One or more IDs of Subnets in your Net that you want to attach to the load balancer. - items: - type: string - type: array - SubregionNames: - description: One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `LoadBalancerType` parameter. - items: - type: string - type: array - Tags: - description: One or more tags assigned to the load balancer. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - required: - - Listeners - - LoadBalancerName - type: object - CreateLoadBalancerResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateLoadBalancerTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerNames: - description: One or more load balancer names. - items: - type: string - type: array - Tags: - description: One or more tags to add to the specified load balancers. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - required: - - LoadBalancerNames - - Tags - type: object - CreateLoadBalancerTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateNatServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - PublicIpId: - description: 'The allocation ID of the EIP to associate with the NAT service.
- - If the EIP is already associated with another resource, you must first disassociate it.' - type: string - SubnetId: - description: The ID of the Subnet in which you want to create the NAT service. - type: string - required: - - PublicIpId - - SubnetId - type: object - CreateNatServiceResponse: - additionalProperties: false - properties: - NatService: - $ref: '#/components/schemas/NatService' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateNetAccessPointRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net. - type: string - RouteTableIds: - description: One or more IDs of route tables to use for the connection. - items: - type: string - type: array - ServiceName: - description: The prefix list name corresponding to the service (for example, `com.outscale.eu-west-2.osu` for OSU). - type: string - required: - - ServiceName - - NetId - type: object - CreateNetAccessPointResponse: - additionalProperties: false - properties: - NetAccessPoint: - $ref: '#/components/schemas/NetAccessPoint' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateNetPeeringRequest: - additionalProperties: false - properties: - AccepterNetId: - description: The ID of the Net you want to connect with. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - SourceNetId: - description: The ID of the Net you send the peering request from. - type: string - required: - - AccepterNetId - - SourceNetId - type: object - CreateNetPeeringResponse: - additionalProperties: false - properties: - NetPeering: - $ref: '#/components/schemas/NetPeering' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateNetRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - IpRange: - description: The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). - type: string - Tenancy: - description: The tenancy options for the VMs (`default` if a VM created in a Net can be launched with any tenancy, `dedicated` if it can be launched with dedicated tenancy VMs running on single-tenant hardware). - type: string - required: - - IpRange - type: object - CreateNetResponse: - additionalProperties: false - properties: - Net: - $ref: '#/components/schemas/Net' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateNicRequest: - additionalProperties: false - properties: - Description: - description: A description for the NIC. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - PrivateIps: - description: 'The primary private IP address for the NIC.

- - - This IP address must be within the IP address range of the Subnet that you specify with the `SubnetId` attribute.
- - If you do not specify this attribute, a random private IP address is selected within the IP address range of the Subnet.' - items: - $ref: '#/components/schemas/PrivateIpLight' - type: array - SecurityGroupIds: - description: One or more IDs of security groups for the NIC. - items: - type: string - type: array - SubnetId: - description: The ID of the Subnet in which you want to create the NIC. - type: string - required: - - SubnetId - type: object - CreateNicResponse: - additionalProperties: false - properties: - Nic: - $ref: '#/components/schemas/Nic' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreatePublicIpRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - CreatePublicIpResponse: - additionalProperties: false - properties: - PublicIp: - $ref: '#/components/schemas/PublicIp' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateRouteRequest: - additionalProperties: false - properties: - DestinationIpRange: - description: The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - GatewayId: - description: The ID of an Internet service or virtual gateway attached to your Net. - type: string - NatServiceId: - description: The ID of a NAT service. - type: string - NetPeeringId: - description: The ID of a Net peering connection. - type: string - NicId: - description: The ID of a NIC. - type: string - RouteTableId: - description: The ID of the route table for which you want to create a route. - type: string - VmId: - description: The ID of a NAT VM in your Net (attached to exactly one NIC). - type: string - required: - - DestinationIpRange - - RouteTableId - type: object - CreateRouteResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTable: - $ref: '#/components/schemas/RouteTable' - type: object - CreateRouteTableRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net for which you want to create a route table. - type: string - required: - - NetId - type: object - CreateRouteTableResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTable: - $ref: '#/components/schemas/RouteTable' - type: object - CreateSecurityGroupRequest: - additionalProperties: false - properties: - Description: - description: A description for the security group, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net for the security group. - type: string - SecurityGroupName: - description: '(Public Cloud only) The name of the security group.
- - This name must not start with `sg-`.
- - This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed.' - type: string - required: - - Description - - SecurityGroupName - type: object - CreateSecurityGroupResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SecurityGroup: - $ref: '#/components/schemas/SecurityGroup' - type: object - CreateSecurityGroupRuleRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Flow: - description: 'The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only.' - type: string - FromPortRange: - description: The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - IpProtocol: - description: The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - type: string - IpRange: - description: The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). - type: string - Rules: - description: Information about the security group rule to create. - items: - $ref: '#/components/schemas/SecurityGroupRule' - type: array - SecurityGroupAccountIdToLink: - description: The account ID of the owner of the security group for which you want to create a rule. - type: string - SecurityGroupId: - description: The ID of the security group for which you want to create a rule. - type: string - SecurityGroupNameToLink: - description: The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. - type: string - ToPortRange: - description: The end of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - required: - - SecurityGroupId - - Flow - type: object - CreateSecurityGroupRuleResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SecurityGroup: - $ref: '#/components/schemas/SecurityGroup' - type: object - CreateServerCertificateRequest: - additionalProperties: false - properties: - Body: - description: The PEM-encoded X509 certificate. - type: string - Chain: - description: The PEM-encoded intermediate certification authorities. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Name: - description: 'A unique name for the certificate. Constraints: 1-128 alphanumeric characters, pluses (+), equals (=), commas (,), periods (.), at signs (@), minuses (-), or underscores (_).' - type: string - Path: - description: The path to the server certificate, set to a slash (/) if not specified. - type: string - PrivateKey: - description: The PEM-encoded private key matching the certificate. - type: string - required: - - Body - - PrivateKey - - Name - type: object - CreateServerCertificateResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - ServerCertificate: - $ref: '#/components/schemas/ServerCertificate' - type: object - CreateSnapshotExportTaskRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - OsuExport: - $ref: '#/components/schemas/OsuExport' - SnapshotId: - description: The ID of the snapshot to export. - type: string - required: - - OsuExport - - SnapshotId - type: object - CreateSnapshotExportTaskResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SnapshotExportTask: - $ref: '#/components/schemas/SnapshotExportTask' - type: object - CreateSnapshotRequest: - additionalProperties: false - properties: - Description: - description: A description for the snapshot. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FileLocation: - description: The pre-signed URL of the snapshot you want to import from the OSU bucket. - type: string - SnapshotSize: - description: The size of the snapshot created in your account, in bytes. This size must be exactly the same as the source snapshot one. - type: long - SourceRegionName: - description: The name of the source Region, which must be the same as the Region of your account. - type: string - SourceSnapshotId: - description: The ID of the snapshot you want to copy. - type: string - VolumeId: - description: The ID of the volume you want to create a snapshot of. - type: string - type: object - CreateSnapshotResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Snapshot: - $ref: '#/components/schemas/Snapshot' - type: object - CreateSubnetRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - IpRange: - description: The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). - type: string - NetId: - description: The ID of the Net for which you want to create a Subnet. - type: string - SubregionName: - description: The name of the Subregion in which you want to create the Subnet. - type: string - required: - - IpRange - - NetId - type: object - CreateSubnetResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Subnet: - $ref: '#/components/schemas/Subnet' - type: object - CreateTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ResourceIds: - description: One or more resource IDs. - items: - type: string - type: array - Tags: - description: One or more tags to add to the specified resources. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - required: - - ResourceIds - - Tags - type: object - CreateTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - CreateVirtualGatewayRequest: - additionalProperties: false - properties: - ConnectionType: - description: The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - ConnectionType - type: object - CreateVirtualGatewayResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VirtualGateway: - $ref: '#/components/schemas/VirtualGateway' - type: object - CreateVmsRequest: - additionalProperties: false - properties: - BlockDeviceMappings: - description: One or more block device mappings. - items: - $ref: '#/components/schemas/BlockDeviceMappingVmCreation' - type: array - BootOnCreation: - description: By default or if `true`, the VM is started on creation. If `false`, the VM is stopped on creation. - type: boolean - BsuOptimized: - description: If `true`, the VM is created with optimized BSU I/O. - type: boolean - ClientToken: - description: A unique identifier which enables you to manage the idempotency. - type: string - DeletionProtection: - description: If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ImageId: - description: The ID of the OMI used to create the VM. You can find the list of OMIs by calling the [ReadImages](#readimages) method. - type: string - KeypairName: - description: The name of the keypair. - type: string - MaxVmsCount: - description: The maximum number of VMs you want to create. If all the VMs cannot be created, the largest possible number of VMs above MinVmsCount is created. - type: long - MinVmsCount: - description: The minimum number of VMs you want to create. If this number of VMs cannot be created, no VMs are created. - type: long - Nics: - description: One or more NICs. If you specify this parameter, you must define one NIC as the primary network interface of the VM with `0` as its device number. - items: - $ref: '#/components/schemas/NicForVmCreation' - type: array - Performance: - default: high - description: The performance of the VM (`standard` \| `high` \| `highest`). - enum: - - medium - - high - - highest - type: string - Placement: - $ref: '#/components/schemas/Placement' - PrivateIps: - description: One or more private IP addresses of the VM. - items: - type: string - type: array - SecurityGroupIds: - description: One or more IDs of security group for the VMs. - items: - type: string - type: array - SecurityGroups: - description: One or more names of security groups for the VMs. - items: - type: string - type: array - SubnetId: - description: The ID of the Subnet in which you want to create the VM. - type: string - UserData: - description: Data or script used to add a specific configuration to the VM. It must be base64-encoded. - type: string - VmInitiatedShutdownBehavior: - description: The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. - type: string - VmType: - description: 'The type of VM (`tinav2.c1r2` by default).
- - For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types).' - type: string - required: - - ImageId - type: object - CreateVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vms: - description: Information about one or more created VMs. - items: - $ref: '#/components/schemas/Vm' - type: array - type: object - CreateVolumeRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Iops: - description: The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - type: long - Size: - description: 'The size of the volume, in gibibytes (GiB). The maximum allowed size for a volume is 14,901 GiB. This parameter is required if the volume is not created from a snapshot (`SnapshotId` unspecified). ' - type: long - SnapshotId: - description: The ID of the snapshot from which you want to create the volume. - type: string - SubregionName: - description: The Subregion in which you want to create the volume. - type: string - VolumeType: - description: 'The type of volume you want to create (`io1` \| `gp2` \| `standard`). If not specified, a `standard` volume is created.
- - For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS).' - type: string - required: - - SubregionName - type: object - CreateVolumeResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Volume: - $ref: '#/components/schemas/Volume' - type: object - CreateVpnConnectionRequest: - additionalProperties: false - properties: - ClientGatewayId: - description: The ID of the client gateway. - type: string - ConnectionType: - description: The type of VPN connection (only `ipsec.1` is supported). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - StaticRoutesOnly: - description: If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - type: boolean - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - required: - - ClientGatewayId - - ConnectionType - - VirtualGatewayId - type: object - CreateVpnConnectionResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VpnConnection: - $ref: '#/components/schemas/VpnConnection' - type: object - CreateVpnConnectionRouteRequest: - additionalProperties: false - properties: - DestinationIpRange: - description: The network prefix of the route, in CIDR notation (for example, 10.12.0.0/16). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VpnConnectionId: - description: The ID of the target VPN connection of the static route. - type: string - required: - - DestinationIpRange - - VpnConnectionId - type: object - CreateVpnConnectionRouteResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteAccessKeyRequest: - additionalProperties: false - properties: - AccessKeyId: - description: The ID of the access key you want to delete. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - AccessKeyId - type: object - DeleteAccessKeyResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteClientGatewayRequest: - additionalProperties: false - properties: - ClientGatewayId: - description: The ID of the client gateway you want to delete. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - ClientGatewayId - type: object - DeleteClientGatewayResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteDhcpOptionsRequest: - additionalProperties: false - properties: - DhcpOptionsSetId: - description: The ID of the DHCP options set you want to delete. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - DhcpOptionsSetId - type: object - DeleteDhcpOptionsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteDirectLinkInterfaceRequest: - additionalProperties: false - properties: - DirectLinkInterfaceId: - description: The ID of the DirectLink interface you want to delete. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - DirectLinkInterfaceId - type: object - DeleteDirectLinkInterfaceResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteDirectLinkRequest: - additionalProperties: false - properties: - DirectLinkId: - description: The ID of the DirectLink you want to delete. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - required: - - DirectLinkId - type: object - DeleteDirectLinkResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteExportTaskRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ExportTaskId: - description: The ID of the export task to delete. - type: string - required: - - ExportTaskId - type: object - DeleteExportTaskResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteFlexibleGpuRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FlexibleGpuId: - description: The ID of the fGPU you want to delete. - type: string - required: - - FlexibleGpuId - type: object - DeleteFlexibleGpuResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteImageRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ImageId: - description: The ID of the OMI you want to delete. - type: string - required: - - ImageId - type: object - DeleteImageResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteInternetServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - InternetServiceId: - description: The ID of the Internet service you want to delete. - type: string - required: - - InternetServiceId - type: object - DeleteInternetServiceResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteKeypairRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - KeypairName: - description: The name of the keypair you want to delete. - type: string - required: - - KeypairName - type: object - DeleteKeypairResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteListenerRuleRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ListenerRuleName: - description: The name of the rule you want to delete. - type: string - required: - - ListenerRuleName - type: object - DeleteListenerRuleResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteLoadBalancerListenersRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer for which you want to delete listeners. - type: string - LoadBalancerPorts: - description: One or more port numbers of the listeners you want to delete. - items: - type: long - type: array - required: - - LoadBalancerName - - LoadBalancerPorts - type: object - DeleteLoadBalancerListenersResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteLoadBalancerPolicyRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer for which you want to delete a policy. - type: string - PolicyName: - description: The name of the policy you want to delete. - type: string - required: - - LoadBalancerName - - PolicyName - type: object - DeleteLoadBalancerPolicyResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteLoadBalancerRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer you want to delete. - type: string - required: - - LoadBalancerName - type: object - DeleteLoadBalancerResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteLoadBalancerTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerNames: - description: One or more load balancer names. - items: - type: string - type: array - Tags: - description: One or more tags to delete from the load balancers. - items: - $ref: '#/components/schemas/ResourceLoadBalancerTag' - type: array - required: - - LoadBalancerNames - - Tags - type: object - DeleteLoadBalancerTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteNatServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NatServiceId: - description: The ID of the NAT service you want to delete. - type: string - required: - - NatServiceId - type: object - DeleteNatServiceResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteNetAccessPointRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetAccessPointId: - description: The ID of the Net access point. - type: string - required: - - NetAccessPointId - type: object - DeleteNetAccessPointResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteNetPeeringRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetPeeringId: - description: The ID of the Net peering connection you want to delete. - type: string - required: - - NetPeeringId - type: object - DeleteNetPeeringResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteNetRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net you want to delete. - type: string - required: - - NetId - type: object - DeleteNetResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteNicRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NicId: - description: The ID of the NIC you want to delete. - type: string - required: - - NicId - type: object - DeleteNicResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeletePublicIpRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - PublicIp: - description: The EIP. In the public Cloud, this parameter is required. - type: string - PublicIpId: - description: The ID representing the association of the EIP with the VM or the NIC. In a Net, this parameter is required. - type: string - type: object - DeletePublicIpResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteRouteRequest: - additionalProperties: false - properties: - DestinationIpRange: - description: The exact IP range for the route. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - RouteTableId: - description: The ID of the route table from which you want to delete a route. - type: string - required: - - RouteTableId - - DestinationIpRange - type: object - DeleteRouteResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTable: - $ref: '#/components/schemas/RouteTable' - type: object - DeleteRouteTableRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - RouteTableId: - description: The ID of the route table you want to delete. - type: string - required: - - RouteTableId - type: object - DeleteRouteTableResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteSecurityGroupRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - SecurityGroupId: - description: The ID of the security group you want to delete. - type: string - SecurityGroupName: - description: (Public Cloud only) The name of the security group. - type: string - type: object - DeleteSecurityGroupResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteSecurityGroupRuleRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Flow: - description: 'The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only.' - type: string - FromPortRange: - description: The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - IpProtocol: - description: The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - type: string - IpRange: - description: The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). - type: string - Rules: - description: One or more rules you want to delete from the security group. - items: - $ref: '#/components/schemas/SecurityGroupRule' - type: array - SecurityGroupAccountIdToUnlink: - description: The account ID of the owner of the security group you want to delete a rule from. - type: string - SecurityGroupId: - description: The ID of the security group you want to delete a rule from. - type: string - SecurityGroupNameToUnlink: - description: The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. - type: string - ToPortRange: - description: The end of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - required: - - SecurityGroupId - - Flow - type: object - DeleteSecurityGroupRuleResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SecurityGroup: - $ref: '#/components/schemas/SecurityGroup' - type: object - DeleteServerCertificateRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Name: - description: The name of the server certificate you want to delete. - type: string - required: - - Name - type: object - DeleteServerCertificateResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteSnapshotRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - SnapshotId: - description: The ID of the snapshot you want to delete. - type: string - required: - - SnapshotId - type: object - DeleteSnapshotResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteSubnetRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - SubnetId: - description: The ID of the Subnet you want to delete. - type: string - required: - - SubnetId - type: object - DeleteSubnetResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ResourceIds: - description: One or more resource IDs. - items: - type: string - type: array - Tags: - description: One or more tags to delete (if you set a tag value, only the tags matching exactly this value are deleted). - items: - $ref: '#/components/schemas/ResourceTag' - type: array - required: - - ResourceIds - - Tags - type: object - DeleteTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteVirtualGatewayRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VirtualGatewayId: - description: The ID of the virtual gateway you want to delete. - type: string - required: - - VirtualGatewayId - type: object - DeleteVirtualGatewayResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteVmsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - required: - - VmIds - type: object - DeleteVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vms: - description: Information about one or more terminated VMs. - items: - $ref: '#/components/schemas/VmState' - type: array - type: object - DeleteVolumeRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VolumeId: - description: The ID of the volume you want to delete. - type: string - required: - - VolumeId - type: object - DeleteVolumeResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteVpnConnectionRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VpnConnectionId: - description: The ID of the VPN connection you want to delete. - type: string - required: - - VpnConnectionId - type: object - DeleteVpnConnectionResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeleteVpnConnectionRouteRequest: - additionalProperties: false - properties: - DestinationIpRange: - description: The network prefix of the route to delete, in CIDR notation (for example, 10.12.0.0/16). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VpnConnectionId: - description: The ID of the target VPN connection of the static route to delete. - type: string - required: - - DestinationIpRange - - VpnConnectionId - type: object - DeleteVpnConnectionRouteResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DeregisterVmsInLoadBalancerRequest: - additionalProperties: false - properties: - BackendVmIds: - description: One or more IDs of back-end VMs. - items: - type: string - type: array - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer. - type: string - required: - - BackendVmIds - - LoadBalancerName - type: object - DeregisterVmsInLoadBalancerResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - DhcpOptionsSet: - additionalProperties: false - description: Information about the DHCP options set. - properties: - Default: - description: If `true`, the DHCP options set is a default one. If `false`, it is not. - type: boolean - DhcpOptionsName: - description: The name of the DHCP options set. - type: string - DhcpOptionsSetId: - description: The ID of the DHCP options set. - type: string - DomainName: - description: The domain name. - type: string - DomainNameServers: - description: One or more IP addresses for the domain name servers. - items: - type: string - type: array - NtpServers: - description: One or more IP addresses for the NTP servers. - items: - type: string - type: array - Tags: - description: One or more tags associated with the DHCP options set. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - DirectLink: - additionalProperties: false - description: Information about the DirectLink. - properties: - AccountId: - description: The account ID of the owner of the DirectLink. - type: string - Bandwidth: - description: The physical link bandwidth (either 1 Gbps or 10 Gbps). - type: string - DirectLinkId: - description: The ID of the DirectLink (for example, dxcon-xxxxxxxx). - type: string - DirectLinkName: - description: The name of the DirectLink. - type: string - Location: - description: The datacenter where the DirectLink is located. - type: string - RegionName: - description: The Region in which the DirectLink has been created. - type: string - State: - description: 'The state of the DirectLink.
- - * `requested`: The DirectLink is requested but the request has not been validated yet.
- - * `pending`: The DirectLink request has been validated. It remains in the `pending` state until you establish the physical link.
- - * `available`: The physical link is established and the connection is ready to use.
- - * `deleting`: The deletion process is in progress.
- - * `deleted`: The DirectLink is deleted.' - type: string - type: object - DirectLinkInterface: - additionalProperties: false - description: Information about the DirectLink interface. - properties: - BgpAsn: - description: The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. - type: long - BgpKey: - description: The BGP authentication key. - type: string - ClientPrivateIp: - description: The IP address on the customer's side of the DirectLink interface. - type: string - DirectLinkInterfaceName: - description: The name of the DirectLink interface. - type: string - OutscalePrivateIp: - description: The IP address on 3DS OUTSCALE's side of the DirectLink interface. - type: string - VirtualGatewayId: - description: The ID of the target virtual gateway. - type: string - Vlan: - description: The VLAN number associated with the DirectLink interface. - type: long - required: - - BgpAsn - - DirectLinkInterfaceName - - VirtualGatewayId - - Vlan - type: object - DirectLinkInterfaces: - additionalProperties: false - description: Information about the DirectLink interfaces. - properties: - AccountId: - description: The account ID of the owner of the DirectLink interface. - type: string - BgpAsn: - description: The BGP (Border Gateway Protocol) ASN (Autonomous System Number) on the customer's side of the DirectLink interface. - type: long - BgpKey: - description: The BGP authentication key. - type: string - ClientPrivateIp: - description: The IP address on the customer's side of the DirectLink interface. - type: string - DirectLinkId: - description: The ID of the DirectLink. - type: string - DirectLinkInterfaceId: - description: The ID of the DirectLink interface. - type: string - DirectLinkInterfaceName: - description: The name of the DirectLink interface. - type: string - InterfaceType: - description: The type of the DirectLink interface (always `private`). - type: string - Location: - description: The datacenter where the DirectLink interface is located. - type: string - OutscalePrivateIp: - description: The IP address on 3DS OUTSCALE's side of the DirectLink interface. - type: string - State: - description: The state of the DirectLink interface (`pending` \| `available` \| `deleting` \| `deleted` \| `confirming` \| `rejected` \| `expired`). - type: string - VirtualGatewayId: - description: The ID of the target virtual gateway. - type: string - Vlan: - description: The VLAN number associated with the DirectLink interface. - type: long - type: object - ErrorResponse: - additionalProperties: false - properties: - Errors: - description: One or more errors. - items: - $ref: '#/components/schemas/Errors' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - Errors: - additionalProperties: false - description: Information about the errors. - properties: - Code: - description: The code of the error. - type: string - Details: - description: The details of the error. - type: string - Type: - description: The type of the error. - type: string - type: object - FiltersAccessKeys: - additionalProperties: false - description: One or more filters. - properties: - AccessKeyIds: - description: The IDs of the access keys. - items: - type: string - type: array - States: - description: The states of the access keys (`active` \| `inactive`). - items: - type: string - type: array - type: object - FiltersApiLog: - additionalProperties: false - description: One or more filters. - properties: - QueryAccessKeys: - description: One or more API keys used for the query. - items: - type: string - type: array - QueryApiNames: - description: The name of one or more API services used for the query. - items: - type: string - type: array - QueryCallNames: - description: The name of one or more calls. - items: - type: string - type: array - QueryDateAfter: - description: The logs of the queries made after the date and time you specify (in ISO 8601 base or extended format). - format: date - type: string - QueryDateBefore: - description: The logs of the queries made before the date and time you specify (in ISO 8601 base or extended format). - format: date - type: string - QueryIpAddresses: - description: One or more IP addresses used for the query. - items: - type: string - type: array - QueryUserAgents: - description: One or more user agents used for the HTTP request. - items: - type: string - type: array - RequestIds: - description: One or more request IDs. - items: - type: string - type: array - ResponseStatusCodes: - description: One or more HTTP codes provided by the responses. - items: - type: long - type: array - type: object - FiltersClientGateway: - additionalProperties: false - description: One or more filters. - properties: - BgpAsns: - description: The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. - items: - type: long - type: array - ClientGatewayIds: - description: The IDs of the client gateways. - items: - type: string - type: array - ConnectionTypes: - description: The types of communication tunnels used by the client gateways (only `ipsec.1` is supported). - items: - type: string - type: array - PublicIps: - description: The public IPv4 addresses of the client gateways. - items: - type: string - type: array - States: - description: The states of the client gateways (`pending` \| `available` \| `deleting` \| `deleted`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the client gateways. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the client gateways. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the client gateways, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersDhcpOptions: - additionalProperties: false - description: One or more filters. - properties: - Default: - description: If `true`, lists all default DHCP options set. If `false`, lists all non-default DHCP options set. - type: boolean - DhcpOptionsSetIds: - description: The IDs of the DHCP options sets. - items: - type: string - type: array - DomainNameServers: - description: The domain name servers used for the DHCP options sets. - items: - type: string - type: array - DomainNames: - description: The domain names used for the DHCP options sets. - items: - type: string - type: array - NtpServers: - description: The Network Time Protocol (NTP) servers used for the DHCP options sets. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the DHCP options sets. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the DHCP options sets. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the DHCP options sets, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersDirectLink: - additionalProperties: false - description: One or more filters. - properties: - DirectLinkIds: - description: The IDs of the DirectLinks. - items: - type: string - type: array - type: object - FiltersDirectLinkInterface: - additionalProperties: false - description: One or more filters. - properties: - DirectLinkIds: - description: The IDs of the DirectLinks. - items: - type: string - type: array - DirectLinkInterfaceIds: - description: The IDs of the DirectLink interfaces. - items: - type: string - type: array - type: object - FiltersExportTask: - additionalProperties: false - description: One or more filters. - properties: - TagKeys: - description: The keys of the tags associated with the export tasks. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the export tasks. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the export tasks, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - TaskIds: - description: The IDs of the export tasks. - items: - type: string - type: array - type: object - FiltersFlexibleGpu: - additionalProperties: false - description: One or more filters. - properties: - DeleteOnVmDeletion: - description: Indicates whether the fGPU is deleted when terminating the VM. - type: boolean - FlexibleGpuIds: - description: One or more IDs of fGPUs. - items: - type: string - type: array - ModelNames: - description: One or more models of fGPUs. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - items: - type: string - type: array - States: - description: The states of the fGPUs (`allocated` \| `attaching` \| `attached` \| `detaching`). - items: - type: string - type: array - SubregionNames: - description: The Subregions where the fGPUs are located. - items: - type: string - type: array - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - type: object - FiltersImage: - additionalProperties: false - description: One or more filters. - properties: - AccountAliases: - description: The account aliases of the owners of the OMIs. - items: - type: string - type: array - AccountIds: - description: The account IDs of the owners of the OMIs. By default, all the OMIs for which you have launch permissions are described. - items: - type: string - type: array - Architectures: - description: The architectures of the OMIs (`i386` \| `x86_64`). - items: - type: string - type: array - BlockDeviceMappingDeleteOnVmDeletion: - description: Indicates whether the block device mapping is deleted when terminating the VM. - type: boolean - BlockDeviceMappingDeviceNames: - description: The device names for the volumes. - items: - type: string - type: array - BlockDeviceMappingSnapshotIds: - description: The IDs of the snapshots used to create the volumes. - items: - type: string - type: array - BlockDeviceMappingVolumeSizes: - description: The sizes of the volumes, in gibibytes (GiB). - items: - type: long - type: array - BlockDeviceMappingVolumeTypes: - description: The types of volumes (`standard` \| `gp2` \| `io1`). - items: - type: string - type: array - Descriptions: - description: The descriptions of the OMIs, provided when they were created. - items: - type: string - type: array - FileLocations: - description: The locations where the OMI files are stored on Object Storage Unit (OSU). - items: - type: string - type: array - ImageIds: - description: The IDs of the OMIs. - items: - type: string - type: array - ImageNames: - description: The names of the OMIs, provided when they were created. - items: - type: string - type: array - PermissionsToLaunchAccountIds: - description: The account IDs of the users who have launch permissions for the OMIs. - items: - type: string - type: array - PermissionsToLaunchGlobalPermission: - description: If `true`, lists all public OMIs. If `false`, lists all private OMIs. - type: boolean - RootDeviceNames: - description: The device names of the root devices (for example, `/dev/sda1`). - items: - type: string - type: array - RootDeviceTypes: - description: The types of root device used by the OMIs (always `bsu`). - items: - type: string - type: array - States: - description: The states of the OMIs (`pending` \| `available` \| `failed`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the OMIs. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the OMIs. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the OMIs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VirtualizationTypes: - description: The virtualization types (always `hvm`). - items: - type: string - type: array - type: object - FiltersInternetService: - additionalProperties: false - description: One or more filters. - properties: - InternetServiceIds: - description: The IDs of the Internet services. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the Internet services. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the Internet services. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the Internet services, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersKeypair: - additionalProperties: false - description: One or more filters. - properties: - KeypairFingerprints: - description: The fingerprints of the keypairs. - items: - type: string - type: array - KeypairNames: - description: The names of the keypairs. - items: - type: string - type: array - type: object - FiltersListenerRule: - additionalProperties: false - description: One or more filters. - properties: - ListenerRuleNames: - description: The names of the listener rules. - items: - type: string - type: array - type: object - FiltersLoadBalancer: - additionalProperties: false - description: One or more filters. - properties: - LoadBalancerNames: - description: The names of the load balancers. - items: - type: string - type: array - type: object - FiltersNatService: - additionalProperties: false - description: One or more filters. - properties: - NatServiceIds: - description: The IDs of the NAT services. - items: - type: string - type: array - NetIds: - description: The IDs of the Nets in which the NAT services are. - items: - type: string - type: array - States: - description: The states of the NAT services (`pending` \| `available` \| `deleting` \| `deleted`). - items: - type: string - type: array - SubnetIds: - description: The IDs of the Subnets in which the NAT services are. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the NAT services. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the NAT services. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the NAT services, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersNet: - additionalProperties: false - description: One or more filters. - properties: - DhcpOptionsSetIds: - description: The IDs of the DHCP options sets. - items: - type: string - type: array - IpRanges: - description: The IP ranges for the Nets, in CIDR notation (for example, 10.0.0.0/16). - items: - type: string - type: array - NetIds: - description: The IDs of the Nets. - items: - type: string - type: array - States: - description: The states of the Nets (`pending` \| `available`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the Nets. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the Nets. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the Nets, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersNetAccessPoint: - additionalProperties: false - description: One or more filters. - properties: - NetAccessPointIds: - description: The IDs of the Net access points. - items: - type: string - type: array - NetIds: - description: The IDs of the Nets. - items: - type: string - type: array - ServiceNames: - description: The names of the prefix lists corresponding to the services. For more information, see [DescribePrefixLists](#describeprefixlists) - items: - type: string - type: array - States: - description: The states of the Net access points (`pending` \| `available` \| `deleting` \| `deleted`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the Net access points. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the Net access points. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the Net access points, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersNetPeering: - additionalProperties: false - description: One or more filters. - properties: - AccepterNetAccountIds: - description: The account IDs of the owners of the peer Nets. - items: - type: string - type: array - AccepterNetIpRanges: - description: The IP ranges of the peer Nets, in CIDR notation (for example, 10.0.0.0/24). - items: - type: string - type: array - AccepterNetNetIds: - description: The IDs of the peer Nets. - items: - type: string - type: array - NetPeeringIds: - description: The IDs of the Net peering connections. - items: - type: string - type: array - SourceNetAccountIds: - description: The account IDs of the owners of the peer Nets. - items: - type: string - type: array - SourceNetIpRanges: - description: The IP ranges of the peer Nets. - items: - type: string - type: array - SourceNetNetIds: - description: The IDs of the peer Nets. - items: - type: string - type: array - StateMessages: - description: Additional information about the states of the Net peering connections. - items: - type: string - type: array - StateNames: - description: The states of the Net peering connections (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the Net peering connections. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the Net peering connections. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the Net peering connections, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersNic: - additionalProperties: false - description: One or more filters. - properties: - LinkNicSortNumbers: - description: The device numbers the NICs are attached to. - items: - type: long - type: array - LinkNicVmIds: - description: The IDs of the VMs the NICs are attached to. - items: - type: string - type: array - NicIds: - description: The IDs of the NICs. - items: - type: string - type: array - PrivateIpsPrivateIps: - description: The private IP addresses of the NICs. - items: - type: string - type: array - SubnetIds: - description: The IDs of the Subnets for the NICs. - items: - type: string - type: array - type: object - FiltersProductType: - additionalProperties: false - description: One or more filters. - properties: - ProductTypeIds: - description: The IDs of the product types. - items: - type: string - type: array - type: object - FiltersPublicIp: - additionalProperties: false - description: One or more filters. - properties: - LinkPublicIpIds: - description: The IDs representing the associations of EIPs with VMs or NICs. - items: - type: string - type: array - NicAccountIds: - description: The account IDs of the owners of the NICs. - items: - type: string - type: array - NicIds: - description: The IDs of the NICs. - items: - type: string - type: array - Placements: - description: Whether the EIPs are for use in the public Cloud or in a Net. - items: - type: string - type: array - PrivateIps: - description: The private IP addresses associated with the EIPs. - items: - type: string - type: array - PublicIpIds: - description: The IDs of the External IP addresses (EIPs). - items: - type: string - type: array - PublicIps: - description: The External IP addresses (EIPs). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the EIPs. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the EIPs. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the EIPs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VmIds: - description: The IDs of the VMs. - items: - type: string - type: array - type: object - FiltersQuota: - additionalProperties: false - description: One or more filters. - properties: - Collections: - description: The group names of the quotas. - items: - type: string - type: array - QuotaNames: - description: The names of the quotas. - items: - type: string - type: array - QuotaTypes: - description: The resource IDs if these are resource-specific quotas, `global` if they are not. - items: - type: string - type: array - ShortDescriptions: - description: The description of the quotas. - items: - type: string - type: array - type: object - FiltersRouteTable: - additionalProperties: false - description: One or more filters. - properties: - LinkRouteTableLinkRouteTableIds: - description: The IDs of the associations between the route tables and the Subnets. - items: - type: string - type: array - LinkSubnetIds: - description: The IDs of the Subnets involved in the associations. - items: - type: string - type: array - NetIds: - description: The IDs of the Nets for the route tables. - items: - type: string - type: array - RouteCreationMethods: - description: The methods used to create a route. - items: - type: string - type: array - RouteDestinationIpRanges: - description: The IP ranges specified in routes in the tables. - items: - type: string - type: array - RouteGatewayIds: - description: The IDs of the gateways specified in routes in the tables. - items: - type: string - type: array - RouteNatServiceIds: - description: The IDs of the NAT services specified in routes in the tables. - items: - type: string - type: array - RouteNetPeeringIds: - description: The IDs of the Net peering connections specified in routes in the tables. - items: - type: string - type: array - RouteStates: - description: The states of routes in the route tables (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - items: - type: string - type: array - RouteTableIds: - description: The IDs of the route tables. - items: - type: string - type: array - RouteVmIds: - description: The IDs of the VMs specified in routes in the tables. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the route tables. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the route tables. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the route tables, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersSecurityGroup: - additionalProperties: false - description: One or more filters. - properties: - AccountIds: - description: The account IDs of the owners of the security groups. - items: - type: string - type: array - SecurityGroupIds: - description: The IDs of the security groups. - items: - type: string - type: array - SecurityGroupNames: - description: The names of the security groups. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the security groups. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the security groups. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the security groups, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - type: object - FiltersServerCertificate: - additionalProperties: false - description: One or more filters. - properties: - Paths: - description: The path to the server certificate. - type: string - type: object - FiltersService: - additionalProperties: false - description: One or more filters. - properties: - ServiceIds: - description: The IDs of the services. - items: - type: string - type: array - ServiceNames: - description: The names of the prefix lists, which identify the 3DS OUTSCALE services they are associated with. - items: - type: string - type: array - type: object - FiltersSnapshot: - additionalProperties: false - description: One or more filters. - properties: - AccountAliases: - description: The account aliases of the owners of the snapshots. - items: - type: string - type: array - AccountIds: - description: The account IDs of the owners of the snapshots. - items: - type: string - type: array - Descriptions: - description: The descriptions of the snapshots. - items: - type: string - type: array - PermissionsToCreateVolumeAccountIds: - description: The account IDs of one or more users who have permissions to create volumes. - items: - type: string - type: array - PermissionsToCreateVolumeGlobalPermission: - description: If `true`, lists all public volumes. If `false`, lists all private volumes. - type: boolean - Progresses: - description: The progresses of the snapshots, as a percentage. - items: - type: long - type: array - SnapshotIds: - description: The IDs of the snapshots. - items: - type: string - type: array - States: - description: The states of the snapshots (`in-queue` \| `completed` \| `error`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the snapshots. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the snapshots. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the snapshots, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VolumeIds: - description: The IDs of the volumes used to create the snapshots. - items: - type: string - type: array - VolumeSizes: - description: The sizes of the volumes used to create the snapshots, in gibibytes (GiB). - items: - type: long - type: array - type: object - FiltersSubnet: - additionalProperties: false - description: One or more filters. - properties: - AvailableIpsCounts: - description: The number of available IPs. - items: - type: long - type: array - IpRanges: - description: The IP ranges in the Subnets, in CIDR notation (for example, 10.0.0.0/16). - items: - type: string - type: array - NetIds: - description: The IDs of the Nets in which the Subnets are. - items: - type: string - type: array - States: - description: The states of the Subnets (`pending` \| `available`). - items: - type: string - type: array - SubnetIds: - description: The IDs of the Subnets. - items: - type: string - type: array - SubregionNames: - description: The names of the Subregions in which the Subnets are located. - items: - type: string - type: array - type: object - FiltersSubregion: - additionalProperties: false - description: One or more filters. - properties: - SubregionNames: - description: The names of the Subregions. - items: - type: string - type: array - type: object - FiltersTag: - additionalProperties: false - description: One or more filters. - properties: - Keys: - description: The keys of the tags that are assigned to the resources. You can use this filter alongside the `Values` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. - items: - type: string - type: array - ResourceIds: - description: The IDs of the resources with which the tags are associated. - items: - type: string - type: array - ResourceTypes: - description: The resource type (`vm` \| `image` \| `volume` \| `snapshot` \| `public-ip` \| `security-group` \| `route-table` \| `nic` \| `net` \| `subnet` \| `net-peering` \| `net-access-point` \| `nat-service` \| `internet-service` \| `client-gateway` \| `virtual-gateway` \| `vpn-connection` \| `dhcp-options` \| `task`). - items: - type: string - type: array - Values: - description: The values of the tags that are assigned to the resources. You can use this filter alongside the `TagKeys` filter. In that case, you filter the resources corresponding to each tag, regardless of the other filter. - items: - type: string - type: array - type: object - FiltersVirtualGateway: - additionalProperties: false - description: One or more filters. - properties: - ConnectionTypes: - description: The types of the virtual gateways (only `ipsec.1` is supported). - items: - type: string - type: array - LinkNetIds: - description: The IDs of the Nets the virtual gateways are attached to. - items: - type: string - type: array - LinkStates: - description: The current states of the attachments between the virtual gateways and the Nets (`attaching` \| `attached` \| `detaching` \| `detached`). - items: - type: string - type: array - States: - description: The states of the virtual gateways (`pending` \| `available` \| `deleting` \| `deleted`). - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the virtual gateways. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the virtual gateways. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the virtual gateways, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VirtualGatewayIds: - description: The IDs of the virtual gateways. - items: - type: string - type: array - type: object - FiltersVm: - additionalProperties: false - description: One or more filters. - properties: - TagKeys: - description: The keys of the tags associated with the VMs. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the VMs. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the VMs, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - type: object - FiltersVmType: - additionalProperties: false - description: One or more filters. - properties: - BsuOptimized: - description: Indicates whether the VM is optimized for BSU I/O. - type: boolean - MemorySizes: - description: The amounts of memory, in gibibytes (GiB). - items: - format: float - type: number - type: array - VcoreCounts: - description: The numbers of vCores. - items: - type: long - type: array - VmTypeNames: - description: The names of the VM types. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - items: - type: string - type: array - VolumeCounts: - description: The maximum number of ephemeral storage disks. - items: - type: long - type: array - VolumeSizes: - description: The size of one ephemeral storage disk, in gibibytes (GiB). - items: - type: long - type: array - type: object - FiltersVmsState: - additionalProperties: false - description: One or more filters. - properties: - SubregionNames: - description: The names of the Subregions of the VMs. - items: - type: string - type: array - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - VmStates: - description: The states of the VMs (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). - items: - type: string - type: array - type: object - FiltersVolume: - additionalProperties: false - description: One or more filters. - properties: - CreationDates: - description: The dates and times at which the volumes were created. - items: - format: date - type: string - type: array - LinkVolumeDeleteOnVmDeletion: - description: Indicates whether the volumes are deleted when terminating the VMs. - type: boolean - LinkVolumeDeviceNames: - description: The VM device names. - items: - type: string - type: array - LinkVolumeLinkDates: - description: The dates and times at which the volumes were created. - items: - format: date - type: string - type: array - LinkVolumeLinkStates: - description: The attachment states of the volumes (`attaching` \| `detaching` \| `attached` \| `detached`). - items: - type: string - type: array - LinkVolumeVmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - SnapshotIds: - description: The snapshots from which the volumes were created. - items: - type: string - type: array - SubregionNames: - description: The names of the Subregions in which the volumes were created. - items: - type: string - type: array - TagKeys: - description: The keys of the tags associated with the volumes. - items: - type: string - type: array - TagValues: - description: The values of the tags associated with the volumes. - items: - type: string - type: array - Tags: - description: 'The key/value combination of the tags associated with the volumes, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}.' - items: - type: string - type: array - VolumeIds: - description: The IDs of the volumes. - items: - type: string - type: array - VolumeSizes: - description: The sizes of the volumes, in gibibytes (GiB). - items: - type: long - type: array - VolumeStates: - description: The states of the volumes (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). - items: - type: string - type: array - VolumeTypes: - description: The types of the volumes (`standard` \| `gp2` \| `io1`). - items: - type: string - type: array - type: object - FiltersVpnConnection: - additionalProperties: false - description: One or more filters. - properties: - BgpAsns: - description: The Border Gateway Protocol (BGP) Autonomous System Numbers (ASNs) of the connections. - items: - type: long - type: array - ClientGatewayIds: - description: The IDs of the client gateways. - items: - type: string - type: array - ConnectionTypes: - description: The types of the VPN connections (only `ipsec.1` is supported). - items: - type: string - type: array - RouteDestinationIpRanges: - description: The destination IP ranges. - items: - type: string - type: array - States: - description: The states of the VPN connections (`pending` \| `available` \| `deleting` \| `deleted`). - items: - type: string - type: array - StaticRoutesOnly: - description: If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - type: boolean - VirtualGatewayIds: - description: The IDs of the virtual gateways. - items: - type: string - type: array - VpnConnectionIds: - description: The IDs of the VPN connections. - items: - type: string - type: array - type: object - FlexibleGpu: - additionalProperties: false - description: Information about the flexible GPU (fGPU). - properties: - DeleteOnVmDeletion: - description: If `true`, the fGPU is deleted when the VM is terminated. - type: boolean - FlexibleGpuId: - description: The ID of the fGPU. - type: string - Generation: - description: The compatible processor generation. - type: string - ModelName: - description: The model of fGPU. For more information, see [About Flexible GPUs](https://wiki.outscale.net/display/EN/About+Flexible+GPUs). - type: string - State: - description: The state of the fGPU (`allocated` \| `attaching` \| `attached` \| `detaching`). - type: string - SubregionName: - description: The Subregion where the fGPU is located. - type: string - VmId: - description: The ID of the VM the fGPU is attached to, if any. - type: string - type: object - FlexibleGpuCatalog: - additionalProperties: false - description: Information about the flexible GPU (fGPU) that is available in the public catalog. - properties: - Generations: - description: The generations of VMs that the fGPU is compatible with. - type: string - MaxCpu: - description: The maximum number of VM vCores that the fGPU is compatible with. - type: long - MaxRam: - description: The maximum amount of VM memory that the fGPU is compatible with. - type: long - ModelName: - description: The model of fGPU. - type: string - VRam: - description: The amount of video RAM (VRAM) of the fGPU. - type: long - type: object - HealthCheck: - additionalProperties: false - description: Information about the health check configuration. - properties: - CheckInterval: - description: The number of seconds between two pings (between `5` and `600` both included). - type: long - HealthyThreshold: - description: The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - type: long - Path: - description: The path for HTTP or HTTPS requests. - type: string - Port: - description: The port number (between `1` and `65535`, both included). - type: long - Protocol: - description: The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - type: string - Timeout: - description: The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - type: long - UnhealthyThreshold: - description: The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). - type: long - required: - - CheckInterval - - HealthyThreshold - - Path - - Port - - Protocol - - Timeout - - UnhealthyThreshold - type: object - Image: - additionalProperties: false - description: Information about the OMI. - properties: - AccountAlias: - description: The account alias of the owner of the OMI. - type: string - AccountId: - description: The account ID of the owner of the OMI. - type: string - Architecture: - description: The architecture of the OMI (by default, `i386`). - type: string - BlockDeviceMappings: - description: One or more block device mappings. - items: - $ref: '#/components/schemas/BlockDeviceMappingImage' - type: array - CreationDate: - description: The date and time at which the OMI was created. - format: date - type: string - Description: - description: The description of the OMI. - type: string - FileLocation: - description: The location where the OMI file is stored on Object Storage Unit (OSU). - type: string - ImageId: - description: The ID of the OMI. - type: string - ImageName: - description: The name of the OMI. - type: string - ImageType: - description: The type of the OMI. - type: string - PermissionsToLaunch: - $ref: '#/components/schemas/PermissionsOnResource' - ProductCodes: - description: The product code associated with the OMI (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). - items: - type: string - type: array - RootDeviceName: - description: The name of the root device. - type: string - RootDeviceType: - description: The type of root device used by the OMI (always `bsu`). - type: string - State: - description: The state of the OMI (`pending` \| `available` \| `failed`). - type: string - StateComment: - $ref: '#/components/schemas/StateComment' - Tags: - description: One or more tags associated with the OMI. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - ImageExportTask: - additionalProperties: false - description: Information about the OMI export task. - properties: - Comment: - description: If the OMI export task fails, an error message appears. - type: string - ImageId: - description: The ID of the OMI to be exported. - type: string - OsuExport: - $ref: '#/components/schemas/OsuExport' - Progress: - description: The progress of the OMI export task, as a percentage. - type: long - State: - description: The state of the OMI export task (`pending/queued` \| `pending` \| `completed` \| `failed` \| `cancelled`). - type: string - Tags: - description: One or more tags associated with the image export task. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - TaskId: - description: The ID of the OMI export task. - type: string - type: object - InternetService: - additionalProperties: false - description: Information about the Internet service. - properties: - InternetServiceId: - description: The ID of the Internet service. - type: string - NetId: - description: The ID of the Net attached to the Internet service. - type: string - State: - description: The state of the attachment of the Net to the Internet service (always `available`). - type: string - Tags: - description: One or more tags associated with the Internet service. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - Keypair: - additionalProperties: false - description: Information about the keypair. - properties: - KeypairFingerprint: - description: 'If you create a keypair, the SHA-1 digest of the DER encoded private key.
- - If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716.' - type: string - KeypairName: - description: The name of the keypair. - type: string - type: object - KeypairCreated: - additionalProperties: false - description: Information about the created keypair. - properties: - KeypairFingerprint: - description: 'If you create a keypair, the SHA-1 digest of the DER encoded private key.
- - If you import a keypair, the MD5 public key fingerprint as specified in section 4 of RFC 4716.' - type: string - KeypairName: - description: The name of the keypair. - type: string - PrivateKey: - description: The private key. - type: string - type: object - LinkFlexibleGpuRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FlexibleGpuId: - description: The ID of the fGPU you want to attach. - type: string - VmId: - description: The ID of the VM you want to attach the fGPU to. - type: string - required: - - FlexibleGpuId - - VmId - type: object - LinkFlexibleGpuResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkInternetServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - InternetServiceId: - description: The ID of the Internet service you want to attach. - type: string - NetId: - description: The ID of the Net to which you want to attach the Internet service. - type: string - required: - - InternetServiceId - - NetId - type: object - LinkInternetServiceResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkNic: - additionalProperties: false - description: Information about the NIC attachment. - properties: - DeleteOnVmDeletion: - description: If `true`, the volume is deleted when the VM is terminated. - type: boolean - DeviceNumber: - description: The device index for the NIC attachment (between 1 and 7, both included). - type: long - LinkNicId: - description: The ID of the NIC to attach. - type: string - State: - description: The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - type: string - VmAccountId: - description: The account ID of the owner of the VM. - type: string - VmId: - description: The ID of the VM. - type: string - type: object - LinkNicLight: - additionalProperties: false - description: Information about the network interface card (NIC). - properties: - DeleteOnVmDeletion: - description: If `true`, the volume is deleted when the VM is terminated. - type: boolean - DeviceNumber: - description: The device index for the NIC attachment (between 1 and 7, both included). - type: long - LinkNicId: - description: The ID of the NIC to attach. - type: string - State: - description: The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - type: string - type: object - LinkNicRequest: - additionalProperties: false - properties: - DeviceNumber: - description: The index of the VM device for the NIC attachment (between 1 and 7, both included). - type: long - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NicId: - description: The ID of the NIC you want to attach. - type: string - VmId: - description: The ID of the VM to which you want to attach the NIC. - type: string - required: - - DeviceNumber - - VmId - - NicId - type: object - LinkNicResponse: - additionalProperties: false - properties: - LinkNicId: - description: The ID of the NIC attachment. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkNicToUpdate: - additionalProperties: false - description: Information about the NIC attachment. If you are modifying the `DeleteOnVmDeletion` attribute, you must specify the ID of the NIC attachment. - properties: - DeleteOnVmDeletion: - description: If `true`, the NIC is deleted when the VM is terminated. - type: boolean - LinkNicId: - description: The ID of the NIC attachment. - type: string - type: object - LinkPrivateIpsRequest: - additionalProperties: false - properties: - AllowRelink: - description: If `true`, allows an IP address that is already assigned to another NIC in the same Subnet to be assigned to the NIC you specified. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NicId: - description: The ID of the NIC. - type: string - PrivateIps: - description: The secondary private IP address or addresses you want to assign to the NIC within the IP address range of the Subnet. - items: - type: string - type: array - SecondaryPrivateIpCount: - description: The number of secondary private IP addresses to assign to the NIC. - type: long - required: - - NicId - type: object - LinkPrivateIpsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkPublicIp: - additionalProperties: false - description: Information about the EIP association. - properties: - LinkPublicIpId: - description: (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - type: string - PublicDnsName: - description: The name of the public DNS. - type: string - PublicIp: - description: The External IP address (EIP) associated with the NIC. - type: string - PublicIpAccountId: - description: The account ID of the owner of the EIP. - type: string - PublicIpId: - description: The allocation ID of the EIP. - type: string - type: object - LinkPublicIpLightForVm: - additionalProperties: false - description: Information about the EIP associated with the NIC. - properties: - PublicDnsName: - description: The name of the public DNS. - type: string - PublicIp: - description: The External IP address (EIP) associated with the NIC. - type: string - PublicIpAccountId: - description: The account ID of the owner of the EIP. - type: string - type: object - LinkPublicIpRequest: - additionalProperties: false - properties: - AllowRelink: - description: '- If `true`, allows the EIP to be associated with the VM or NIC that you specify even if it is already associated with another VM or NIC.
- - - If `false`, prevents the EIP from being associated with the VM or NIC that you specify if it is already associated with another VM or NIC.

- - - (By default, `true` in the public Cloud, `false` in a Net.)' - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NicId: - description: (Net only) The ID of the NIC. This parameter is required if the VM has more than one NIC attached. Otherwise, you need to specify the `VmId` parameter instead. You cannot specify both parameters at the same time. - type: string - PrivateIp: - description: (Net only) The primary or secondary private IP address of the specified NIC. By default, the primary private IP address. - type: string - PublicIp: - description: The EIP. In the public Cloud, this parameter is required. - type: string - PublicIpId: - description: The allocation ID of the EIP. In a Net, this parameter is required. - type: string - VmId: - description: 'The ID of the VM.
- - - In the public Cloud, this parameter is required.
- - - In a Net, this parameter is required if the VM has only one NIC. Otherwise, you need to specify the `NicId` parameter instead. You cannot specify both parameters at the same time.' - type: string - type: object - LinkPublicIpResponse: - additionalProperties: false - properties: - LinkPublicIpId: - description: (Net only) The ID representing the association of the EIP with the VM or the NIC. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkRouteTable: - additionalProperties: false - description: One or more associations between the route table and the Subnets. - properties: - LinkRouteTableId: - description: The ID of the association between the route table and the Subnet. - type: string - Main: - description: If `true`, the route table is the main one. - type: boolean - RouteTableId: - description: The ID of the route table. - type: string - SubnetId: - description: The ID of the Subnet. - type: string - type: object - LinkRouteTableRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - RouteTableId: - description: The ID of the route table. - type: string - SubnetId: - description: The ID of the Subnet. - type: string - required: - - RouteTableId - - SubnetId - type: object - LinkRouteTableResponse: - additionalProperties: false - properties: - LinkRouteTableId: - description: The ID of the association between the route table and the Subnet. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkVirtualGatewayRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net to which you want to attach the virtual gateway. - type: string - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - required: - - NetId - - VirtualGatewayId - type: object - LinkVirtualGatewayResponse: - additionalProperties: false - properties: - NetToVirtualGatewayLink: - $ref: '#/components/schemas/NetToVirtualGatewayLink' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkVolumeRequest: - additionalProperties: false - properties: - DeviceName: - description: The name of the device. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmId: - description: The ID of the VM you want to attach the volume to. - type: string - VolumeId: - description: The ID of the volume you want to attach. - type: string - required: - - DeviceName - - VmId - - VolumeId - type: object - LinkVolumeResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - LinkedVolume: - additionalProperties: false - description: Information about volume attachment. - properties: - DeleteOnVmDeletion: - description: If `true`, the volume is deleted when the VM is terminated. - type: boolean - DeviceName: - description: The name of the device. - type: string - State: - description: The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). - type: string - VmId: - description: The ID of the VM. - type: string - VolumeId: - description: The ID of the volume. - type: string - type: object - Listener: - additionalProperties: false - description: Information about the listener. - properties: - BackendPort: - description: The port on which the back-end VM is listening (between `1` and `65535`, both included). - type: long - BackendProtocol: - description: The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - type: string - LoadBalancerPort: - description: The port on which the load balancer is listening (between 1 and `65535`, both included). - type: long - LoadBalancerProtocol: - description: The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - type: string - PolicyNames: - description: The names of the policies. If there are no policies enabled, the list is empty. - items: - type: string - type: array - ServerCertificateId: - description: The ID of the server certificate. - type: string - type: object - ListenerForCreation: - additionalProperties: false - description: Information about the listener to create. - properties: - BackendPort: - description: The port on which the back-end VM is listening (between `1` and `65535`, both included). - type: long - BackendProtocol: - description: The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - type: string - LoadBalancerPort: - description: The port on which the load balancer is listening (between `1` and `65535`, both included). - type: long - LoadBalancerProtocol: - description: The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - type: string - ServerCertificateId: - description: The ID of the server certificate. - type: string - required: - - BackendPort - - LoadBalancerPort - - LoadBalancerProtocol - type: object - ListenerRule: - additionalProperties: false - description: Information about the listener rule. - properties: - Action: - description: The type of action for the rule (always `forward`). - type: string - HostNamePattern: - description: A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. - type: string - ListenerId: - description: The ID of the listener. - type: long - ListenerRuleId: - description: The ID of the listener rule. - type: long - ListenerRuleName: - description: A human-readable name for the listener rule. - type: string - PathPattern: - description: A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. - type: string - Priority: - description: The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. - type: long - VmIds: - description: The IDs of the backend VMs. - items: - type: string - type: array - type: object - ListenerRuleForCreation: - additionalProperties: false - description: Information about the listener rule. - properties: - Action: - description: The type of action for the rule (always `forward`). - type: string - HostNamePattern: - description: 'A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. ' - type: string - ListenerRuleId: - description: The ID of the listener. - type: string - ListenerRuleName: - description: A human-readable name for the listener rule. - type: string - PathPattern: - description: A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. - type: string - Priority: - description: The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. - type: long - required: - - Priority - type: object - LoadBalancer: - additionalProperties: false - description: Information about the load balancer. - properties: - AccessLog: - $ref: '#/components/schemas/AccessLog' - ApplicationStickyCookiePolicies: - description: The stickiness policies defined for the load balancer. - items: - $ref: '#/components/schemas/ApplicationStickyCookiePolicy' - type: array - BackendVmIds: - description: One or more IDs of back-end VMs for the load balancer. - items: - type: string - type: array - DnsName: - description: The DNS name of the load balancer. - type: string - HealthCheck: - $ref: '#/components/schemas/HealthCheck' - Listeners: - description: The listeners for the load balancer. - items: - $ref: '#/components/schemas/Listener' - type: array - LoadBalancerName: - description: The name of the load balancer. - type: string - LoadBalancerStickyCookiePolicies: - description: The policies defined for the load balancer. - items: - $ref: '#/components/schemas/LoadBalancerStickyCookiePolicy' - type: array - LoadBalancerType: - description: 'The type of load balancer. Valid only for load balancers in a Net.
- - If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
- - If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address.' - type: string - NetId: - description: The ID of the Net for the load balancer. - type: string - SecurityGroups: - description: One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. - items: - type: string - type: array - SourceSecurityGroup: - $ref: '#/components/schemas/SourceSecurityGroup' - Subnets: - description: The IDs of the Subnets for the load balancer. - items: - type: string - type: array - SubregionNames: - description: One or more names of Subregions for the load balancer. - items: - type: string - type: array - Tags: - description: One or more tags associated with the load balancer. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - LoadBalancerLight: - additionalProperties: false - description: Information about the load balancer. - properties: - LoadBalancerName: - description: The name of the load balancer to which the listener is attached. - type: string - LoadBalancerPort: - description: The port of load balancer on which the load balancer is listening (between `1` and `65535` both included). - type: long - required: - - LoadBalancerName - - LoadBalancerPort - type: object - LoadBalancerStickyCookiePolicy: - additionalProperties: false - description: Information about the stickiness policy. - properties: - PolicyName: - description: The name of the stickiness policy. - type: string - type: object - LoadBalancerTag: - additionalProperties: false - description: Information about the load balancer tag. - properties: - Key: - description: The key of the tag. - type: string - LoadBalancerName: - description: The name of the load balancer. - type: string - Value: - description: The value of the tag. - type: string - type: object - Location: - additionalProperties: false - description: Information about the DirectLink location. - properties: - Code: - description: The location code, to be set as the `Location` parameter of the *CreateDirectLink* method when creating a DirectLink. - type: string - Name: - description: The name and description of the location, corresponding to a datacenter. - type: string - type: object - Log: - additionalProperties: false - description: Information about the log. - properties: - AccountId: - description: The account ID. - type: string - CallDuration: - description: The duration of the call (in milliseconds). - type: long - QueryAccessKey: - description: The API key used for the query. - type: string - QueryApiName: - description: The name of the API service used by the call. - type: string - QueryApiVersion: - description: The version of the API service used by the call. - type: string - QueryCallName: - description: The name of the call. - type: string - QueryDate: - description: The date and time of the query (in ISO 8601 base or extended format). - format: date - type: string - QueryHeaderRaw: - description: The query header raw. - type: string - QueryHeaderSize: - description: The query header size. - type: long - QueryIpAddress: - description: The IP address used for the query. - type: string - QueryPayloadRaw: - description: The query payload raw. - type: string - QueryPayloadSize: - description: The query payload size. - type: long - QueryUserAgent: - description: The user agent used for the HTTP request. - type: string - RequestId: - description: The ID provided in the response. - type: string - ResponseSize: - description: The size of the response (in bytes). - type: long - ResponseStatusCode: - description: The HTTP code provided in the response. - type: long - type: object - MaintenanceEvent: - additionalProperties: false - description: Information about the maintenance event. - properties: - Code: - description: The code of the event (`system-reboot` \| `system-maintenance`). - type: string - Description: - description: The description of the event. - type: string - NotAfter: - description: The latest scheduled end time for the event. - format: date - type: string - NotBefore: - description: The earliest scheduled start time for the event. - format: date - type: string - type: object - NatService: - additionalProperties: false - description: Information about the NAT service. - properties: - NatServiceId: - description: The ID of the NAT service. - type: string - NetId: - description: The ID of the Net in which the NAT service is. - type: string - PublicIps: - description: Information about the External IP address or addresses (EIPs) associated with the NAT service. - items: - $ref: '#/components/schemas/PublicIpLight' - type: array - State: - description: The state of the NAT service (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - SubnetId: - description: The ID of the Subnet in which the NAT service is. - type: string - Tags: - description: One or more tags associated with the NAT service. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - Net: - additionalProperties: false - description: Information about the Net. - properties: - DhcpOptionsSetId: - description: The ID of the DHCP options set (or `default` if you want to associate the default one). - type: string - IpRange: - description: The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). - type: string - NetId: - description: The ID of the Net. - type: string - State: - description: The state of the Net (`pending` \| `available`). - type: string - Tags: - description: One or more tags associated with the Net. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - Tenancy: - description: The VM tenancy in a Net. - type: string - type: object - NetAccessPoint: - additionalProperties: false - description: Information about the Net access point. - properties: - NetAccessPointId: - description: The ID of the Net access point. - type: string - NetId: - description: The ID of the Net with which the Net access point is associated. - type: string - RouteTableIds: - description: The ID of the route tables associated with the Net access point. - items: - type: string - type: array - ServiceName: - description: The name of the prefix list corresponding to the service with which the Net access point is associated. - type: string - State: - description: The state of the Net access point (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - Tags: - description: One or more tags associated with the Net access point. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - NetPeering: - additionalProperties: false - description: Information about the Net peering connection. - properties: - AccepterNet: - $ref: '#/components/schemas/AccepterNet' - NetPeeringId: - description: The ID of the Net peering connection. - type: string - SourceNet: - $ref: '#/components/schemas/SourceNet' - State: - $ref: '#/components/schemas/NetPeeringState' - Tags: - description: One or more tags associated with the Net peering connection. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - NetPeeringState: - additionalProperties: false - description: Information about the state of the Net peering connection. - properties: - Message: - description: Additional information about the state of the Net peering connection. - type: string - Name: - description: The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). - type: string - type: object - NetToVirtualGatewayLink: - additionalProperties: false - description: Information about the attachment. - properties: - NetId: - description: The ID of the Net to which the virtual gateway is attached. - type: string - State: - description: The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - type: string - type: object - Nic: - additionalProperties: false - description: Information about the NIC. - properties: - AccountId: - description: The account ID of the owner of the NIC. - type: string - Description: - description: The description of the NIC. - type: string - IsSourceDestChecked: - description: (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - type: boolean - LinkNic: - $ref: '#/components/schemas/LinkNic' - LinkPublicIp: - $ref: '#/components/schemas/LinkPublicIp' - MacAddress: - description: The Media Access Control (MAC) address of the NIC. - type: string - NetId: - description: The ID of the Net for the NIC. - type: string - NicId: - description: The ID of the NIC. - type: string - PrivateDnsName: - description: The name of the private DNS. - type: string - PrivateIps: - description: The private IP addresses of the NIC. - items: - $ref: '#/components/schemas/PrivateIp' - type: array - SecurityGroups: - description: One or more IDs of security groups for the NIC. - items: - $ref: '#/components/schemas/SecurityGroupLight' - type: array - State: - description: The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). - type: string - SubnetId: - description: The ID of the Subnet. - type: string - SubregionName: - description: The Subregion in which the NIC is located. - type: string - Tags: - description: One or more tags associated with the NIC. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - NicForVmCreation: - additionalProperties: false - description: Information about the network interface card (NIC) when creating a virtual machine (VM). - properties: - DeleteOnVmDeletion: - description: If `true`, the NIC is deleted when the VM is terminated. You can specify `true` only if you create a NIC when creating a VM. - type: boolean - Description: - description: The description of the NIC, if you are creating a NIC when creating the VM. - type: string - DeviceNumber: - description: The index of the VM device for the NIC attachment (between 0 and 7, both included). This parameter is required if you create a NIC when creating the VM. - type: long - NicId: - description: The ID of the NIC, if you are attaching an existing NIC when creating a VM. - type: string - PrivateIps: - description: One or more private IP addresses to assign to the NIC, if you create a NIC when creating a VM. Only one private IP address can be the primary private IP address. - items: - $ref: '#/components/schemas/PrivateIpLight' - type: array - SecondaryPrivateIpCount: - description: The number of secondary private IP addresses, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP address in the `PrivateIps` parameter. - type: long - SecurityGroupIds: - description: One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM. - items: - type: string - type: array - SubnetId: - description: The ID of the Subnet for the NIC, if you create a NIC when creating a VM. - type: string - type: object - NicLight: - additionalProperties: false - description: Information about the network interface card (NIC). - properties: - AccountId: - description: The account ID of the owner of the NIC. - type: string - Description: - description: The description of the NIC. - type: string - IsSourceDestChecked: - description: (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - type: boolean - LinkNic: - $ref: '#/components/schemas/LinkNicLight' - LinkPublicIp: - $ref: '#/components/schemas/LinkPublicIpLightForVm' - MacAddress: - description: The Media Access Control (MAC) address of the NIC. - type: string - NetId: - description: The ID of the Net for the NIC. - type: string - NicId: - description: The ID of the NIC. - type: string - PrivateDnsName: - description: The name of the private DNS. - type: string - PrivateIps: - description: The private IP address or addresses of the NIC. - items: - $ref: '#/components/schemas/PrivateIpLightForVm' - type: array - SecurityGroups: - description: One or more IDs of security groups for the NIC. - items: - $ref: '#/components/schemas/SecurityGroupLight' - type: array - State: - description: The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). - type: string - SubnetId: - description: The ID of the Subnet for the NIC. - type: string - type: object - OsuApiKey: - additionalProperties: false - description: Information about the OSU API key. - properties: - ApiKeyId: - description: The API key of the OSU account that enables you to access the bucket. - type: string - SecretKey: - description: The secret key of the OSU account that enables you to access the bucket. - type: string - type: object - OsuExport: - additionalProperties: false - description: Information about the OSU export. - properties: - DiskImageFormat: - description: The format of the export disk (`qcow2` \| `vdi` \| `vmdk`). - type: string - OsuApiKey: - $ref: '#/components/schemas/OsuApiKey' - OsuBucket: - description: The name of the OSU bucket you want to export the object to. - type: string - OsuManifestUrl: - description: The URL of the manifest file. - type: string - OsuPrefix: - description: 'The prefix for the key of the OSU object. This key follows this format: `prefix + object_export_task_id + ''.'' + disk_image_format`.' - type: string - required: - - DiskImageFormat - - OsuBucket - type: object - PermissionsOnResource: - additionalProperties: false - description: Information about the users who have permissions for the resource. - properties: - AccountIds: - description: The account ID of one or more users who have permissions for the resource. - items: - type: string - type: array - GlobalPermission: - description: If `true`, the resource is public. If `false`, the resource is private. - type: boolean - type: object - PermissionsOnResourceCreation: - additionalProperties: false - description: Information about the permissions for the resource. - properties: - Additions: - $ref: '#/components/schemas/PermissionsOnResource' - Removals: - $ref: '#/components/schemas/PermissionsOnResource' - type: object - Placement: - additionalProperties: false - description: Information about the placement of the VM. - properties: - SubregionName: - description: The name of the Subregion. - type: string - Tenancy: - description: The tenancy of the VM (`default` \| `dedicated`). - type: string - type: object - PrivateIp: - additionalProperties: false - description: Information about the private IP. - properties: - IsPrimary: - description: If `true`, the IP address is the primary private IP address of the NIC. - type: boolean - LinkPublicIp: - $ref: '#/components/schemas/LinkPublicIp' - PrivateDnsName: - description: The name of the private DNS. - type: string - PrivateIp: - description: The private IP address of the NIC. - type: string - type: object - PrivateIpLight: - additionalProperties: false - description: Information about the private IP. - properties: - IsPrimary: - description: If `true`, the IP address is the primary private IP address of the NIC. - type: boolean - PrivateIp: - description: The private IP address of the NIC. - type: string - type: object - PrivateIpLightForVm: - additionalProperties: false - description: Information about the private IP of the NIC. - properties: - IsPrimary: - description: If `true`, the IP address is the primary private IP address of the NIC. - type: boolean - LinkPublicIp: - $ref: '#/components/schemas/LinkPublicIpLightForVm' - PrivateDnsName: - description: The name of the private DNS. - type: string - PrivateIp: - description: The private IP address. - type: string - type: object - ProductType: - additionalProperties: false - description: Information about the product type. - properties: - Description: - description: The description of the product type. - type: string - ProductTypeId: - description: The ID of the product type. - type: string - Vendor: - description: The vendor of the product type. - type: string - type: object - PublicIp: - additionalProperties: false - description: Information about the public IP. - properties: - LinkPublicIpId: - description: (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - type: string - NicAccountId: - description: The account ID of the owner of the NIC. - type: string - NicId: - description: The ID of the NIC the EIP is associated with (if any). - type: string - PrivateIp: - description: The private IP address associated with the EIP. - type: string - PublicIp: - description: The External IP address (EIP) associated with the NAT service. - type: string - PublicIpId: - description: The allocation ID of the EIP associated with the NAT service. - type: string - Tags: - description: One or more tags associated with the EIP. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - VmId: - description: The ID of the VM the External IP (EIP) is associated with (if any). - type: string - type: object - PublicIpLight: - additionalProperties: false - description: Information about the public IP. - properties: - PublicIp: - description: The External IP address (EIP) associated with the NAT service. - type: string - PublicIpId: - description: The allocation ID of the EIP associated with the NAT service. - type: string - type: object - Quota: - additionalProperties: false - description: Information about the quota. - properties: - AccountId: - description: The account ID of the owner of the quotas. - type: string - Description: - description: The description of the quota. - type: string - MaxValue: - description: The maximum value of the quota for the 3DS OUTSCALE user account (if there is no limit, `0`). - type: long - Name: - description: The unique name of the quota. - type: string - QuotaCollection: - description: The group name of the quota. - type: string - ShortDescription: - description: The description of the quota. - type: string - UsedValue: - description: The limit value currently used by the 3DS OUTSCALE user account. - type: long - type: object - QuotaTypes: - additionalProperties: false - description: One or more quotas. - properties: - QuotaType: - description: The resource ID if it is a resource-specific quota, `global` if it is not. - type: string - Quotas: - description: One or more quotas associated with the user. - items: - $ref: '#/components/schemas/Quota' - type: array - type: object - ReadAccessKeysRequest: - additionalProperties: false - properties: - Filters: - $ref: '#/components/schemas/FiltersAccessKeys' - type: object - ReadAccessKeysResponse: - additionalProperties: false - properties: - AccessKeys: - description: A list of access keys. - items: - $ref: '#/components/schemas/AccessKey' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadAccountsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - ReadAccountsResponse: - additionalProperties: false - properties: - Accounts: - description: The list of the accounts. - items: - $ref: '#/components/schemas/Account' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadAdminPasswordRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmId: - description: The ID of the VM. - type: string - required: - - VmId - type: object - ReadAdminPasswordResponse: - additionalProperties: false - properties: - AdminPassword: - description: The password of the VM. After the first boot, returns an empty string. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VmId: - description: The ID of the VM. - type: string - type: object - ReadApiLogsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersApiLog' - NextPageToken: - description: The token to request the next page of results. - type: string - ResultsPerPage: - description: The maximum number of items returned in a single page. By default, 100. - type: long - With: - $ref: '#/components/schemas/With' - type: object - ReadApiLogsResponse: - additionalProperties: false - properties: - Logs: - description: Information displayed in one or more API logs. - items: - $ref: '#/components/schemas/Log' - type: array - NextPageToken: - description: The token to request the next page of results. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadClientGatewaysRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersClientGateway' - type: object - ReadClientGatewaysResponse: - additionalProperties: false - properties: - ClientGateways: - description: Information about one or more client gateways. - items: - $ref: '#/components/schemas/ClientGateway' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadConsoleOutputRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmId: - description: The ID of the VM. - type: string - required: - - VmId - type: object - ReadConsoleOutputResponse: - additionalProperties: false - properties: - ConsoleOutput: - description: The Base64-encoded output of the console. If a command line tool is used, the output is decoded by the tool. - type: string - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VmId: - description: The ID of the VM. - type: string - type: object - ReadConsumptionAccountRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FromDate: - description: The beginning of the time period, in ISO-8601 format with the date only (for example, `2017-06-14` or `2017-06-14T00:00:00Z`). - format: datetime - type: string - ToDate: - description: The end of the time period, in ISO-8601 format with the date only (for example, `2017-06-30` or `2017-06-30T00:00:00Z`). - format: datetime - type: string - required: - - FromDate - - ToDate - type: object - ReadConsumptionAccountResponse: - additionalProperties: false - properties: - ConsumptionEntries: - description: Information about the resources consumed during the specified time period. - items: - $ref: '#/components/schemas/ConsumptionEntry' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadDhcpOptionsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersDhcpOptions' - type: object - ReadDhcpOptionsResponse: - additionalProperties: false - properties: - DhcpOptionsSets: - description: Information about one or more DHCP options sets. - items: - $ref: '#/components/schemas/DhcpOptionsSet' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadDirectLinkInterfacesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersDirectLinkInterface' - type: object - ReadDirectLinkInterfacesResponse: - additionalProperties: false - properties: - DirectLinkInterfaces: - description: Information about one or more DirectLink interfaces. - items: - $ref: '#/components/schemas/DirectLinkInterfaces' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadDirectLinksRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersDirectLink' - type: object - ReadDirectLinksResponse: - additionalProperties: false - properties: - DirectLinks: - description: Information about one or more DirectLinks. - items: - $ref: '#/components/schemas/DirectLink' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadFlexibleGpuCatalogRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - ReadFlexibleGpuCatalogResponse: - additionalProperties: false - properties: - FlexibleGpuCatalog: - description: Information about one or more fGPUs available in the public catalog. - items: - $ref: '#/components/schemas/FlexibleGpuCatalog' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadFlexibleGpusRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersFlexibleGpu' - type: object - ReadFlexibleGpusResponse: - additionalProperties: false - properties: - FlexibleGpus: - description: Information about one or more fGPUs. - items: - $ref: '#/components/schemas/FlexibleGpu' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadImageExportTasksRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersExportTask' - type: object - ReadImageExportTasksResponse: - additionalProperties: false - properties: - ImageExportTasks: - description: Information about one or more image export tasks. - items: - $ref: '#/components/schemas/ImageExportTask' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadImagesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersImage' - type: object - ReadImagesResponse: - additionalProperties: false - properties: - Images: - description: Information about one or more OMIs. - items: - $ref: '#/components/schemas/Image' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadInternetServicesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersInternetService' - type: object - ReadInternetServicesResponse: - additionalProperties: false - properties: - InternetServices: - description: Information about one or more Internet services. - items: - $ref: '#/components/schemas/InternetService' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadKeypairsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersKeypair' - type: object - ReadKeypairsResponse: - additionalProperties: false - properties: - Keypairs: - description: Information about one or more keypairs. - items: - $ref: '#/components/schemas/Keypair' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadListenerRulesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersListenerRule' - type: object - ReadListenerRulesResponse: - additionalProperties: false - properties: - ListenerRules: - description: The list of the rules to describe. - items: - $ref: '#/components/schemas/ListenerRule' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadLoadBalancerTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerNames: - description: One or more load balancer names. - items: - type: string - type: array - required: - - LoadBalancerNames - type: object - ReadLoadBalancerTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Tags: - description: Information about one or more load balancer tags. - items: - $ref: '#/components/schemas/LoadBalancerTag' - type: array - type: object - ReadLoadBalancersRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersLoadBalancer' - type: object - ReadLoadBalancersResponse: - additionalProperties: false - properties: - LoadBalancers: - description: Information about one or more load balancers. - items: - $ref: '#/components/schemas/LoadBalancer' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadLocationsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - ReadLocationsResponse: - additionalProperties: false - properties: - Locations: - description: Information about one or more locations. - items: - $ref: '#/components/schemas/Location' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadNatServicesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersNatService' - type: object - ReadNatServicesResponse: - additionalProperties: false - properties: - NatServices: - description: Information about one or more NAT services. - items: - $ref: '#/components/schemas/NatService' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadNetAccessPointServicesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersService' - type: object - ReadNetAccessPointServicesResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Services: - description: The names of the services you can use for Net access points. - items: - $ref: '#/components/schemas/Service' - type: array - type: object - ReadNetAccessPointsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersNetAccessPoint' - type: object - ReadNetAccessPointsResponse: - additionalProperties: false - properties: - NetAccessPoints: - description: One or more Net access points. - items: - $ref: '#/components/schemas/NetAccessPoint' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadNetPeeringsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersNetPeering' - type: object - ReadNetPeeringsResponse: - additionalProperties: false - properties: - NetPeerings: - description: Information about one or more Net peering connections. - items: - $ref: '#/components/schemas/NetPeering' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadNetsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersNet' - type: object - ReadNetsResponse: - additionalProperties: false - properties: - Nets: - description: Information about the described Nets. - items: - $ref: '#/components/schemas/Net' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadNicsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersNic' - type: object - ReadNicsResponse: - additionalProperties: false - properties: - Nics: - description: Information about one or more NICs. - items: - $ref: '#/components/schemas/Nic' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadProductTypesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersProductType' - type: object - ReadProductTypesResponse: - additionalProperties: false - properties: - ProductTypes: - description: Information about one or more product types. - items: - $ref: '#/components/schemas/ProductType' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadPublicIpRangesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - ReadPublicIpRangesResponse: - additionalProperties: false - properties: - PublicIps: - description: The list of public IPv4 addresses used in the Region, in CIDR notation. - items: - type: string - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadPublicIpsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersPublicIp' - type: object - ReadPublicIpsResponse: - additionalProperties: false - properties: - PublicIps: - description: Information about one or more EIPs. - items: - $ref: '#/components/schemas/PublicIp' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadQuotasRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersQuota' - type: object - ReadQuotasResponse: - additionalProperties: false - properties: - QuotaTypes: - description: Information about one or more quotas. - items: - $ref: '#/components/schemas/QuotaTypes' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadRegionsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - type: object - ReadRegionsResponse: - additionalProperties: false - properties: - Regions: - description: Information about one or more Regions. - items: - $ref: '#/components/schemas/Region' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadRouteTablesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersRouteTable' - type: object - ReadRouteTablesResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTables: - description: Information about one or more route tables. - items: - $ref: '#/components/schemas/RouteTable' - type: array - type: object - ReadSecretAccessKeyRequest: - additionalProperties: false - properties: - AccessKeyId: - description: The ID of the access key. - type: string - required: - - AccessKeyId - type: object - ReadSecretAccessKeyResponse: - additionalProperties: false - properties: - AccessKey: - $ref: '#/components/schemas/AccessKeySecretKey' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadSecurityGroupsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersSecurityGroup' - type: object - ReadSecurityGroupsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SecurityGroups: - description: Information about one or more security groups. - items: - $ref: '#/components/schemas/SecurityGroup' - type: array - type: object - ReadServerCertificatesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersServerCertificate' - type: object - ReadServerCertificatesResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - ServerCertificates: - description: Information about one or more server certificates. - items: - $ref: '#/components/schemas/ServerCertificate' - type: array - type: object - ReadSnapshotExportTasksRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersExportTask' - type: object - ReadSnapshotExportTasksResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - SnapshotExportTasks: - description: Information about one or more snapshot export tasks. - items: - $ref: '#/components/schemas/SnapshotExportTask' - type: array - type: object - ReadSnapshotsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersSnapshot' - type: object - ReadSnapshotsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Snapshots: - description: Information about one or more snapshots and their permissions. - items: - $ref: '#/components/schemas/Snapshot' - type: array - type: object - ReadSubnetsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersSubnet' - type: object - ReadSubnetsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Subnets: - description: Information about one or more Subnets. - items: - $ref: '#/components/schemas/Subnet' - type: array - type: object - ReadSubregionsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersSubregion' - type: object - ReadSubregionsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Subregions: - description: Information about one or more Subregions. - items: - $ref: '#/components/schemas/Subregion' - type: array - type: object - ReadTagsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersTag' - type: object - ReadTagsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Tags: - description: Information about one or more tags. - items: - $ref: '#/components/schemas/Tag' - type: array - type: object - ReadVirtualGatewaysRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVirtualGateway' - type: object - ReadVirtualGatewaysResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VirtualGateways: - description: Information about one or more virtual gateways. - items: - $ref: '#/components/schemas/VirtualGateway' - type: array - type: object - ReadVmTypesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVmType' - type: object - ReadVmTypesResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VmTypes: - description: Information about one or more VM types. - items: - $ref: '#/components/schemas/VmType' - type: array - type: object - ReadVmsHealthRequest: - additionalProperties: false - properties: - BackendVmIds: - description: One or more IDs of back-end VMs. - items: - type: string - type: array - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer. - type: string - required: - - LoadBalancerName - type: object - ReadVmsHealthResponse: - additionalProperties: false - properties: - BackendVmHealth: - description: Information about the health of one or more back-end VMs. - items: - $ref: '#/components/schemas/BackendVmHealth' - type: array - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ReadVmsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVm' - type: object - ReadVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vms: - description: Information about one or more VMs. - items: - $ref: '#/components/schemas/Vm' - type: array - type: object - ReadVmsStateRequest: - additionalProperties: false - properties: - AllVms: - description: If `true`, includes the status of all VMs. By default or if set to `false`, only includes the status of running VMs. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVmsState' - type: object - ReadVmsStateResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VmStates: - description: Information about one or more VM states. - items: - $ref: '#/components/schemas/VmStates' - type: array - type: object - ReadVolumesRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVolume' - type: object - ReadVolumesResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Volumes: - description: Information about one or more volumes. - items: - $ref: '#/components/schemas/Volume' - type: array - type: object - ReadVpnConnectionsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Filters: - $ref: '#/components/schemas/FiltersVpnConnection' - type: object - ReadVpnConnectionsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - VpnConnections: - description: Information about one or more VPN connections. - items: - $ref: '#/components/schemas/VpnConnection' - type: array - type: object - RebootVmsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmIds: - description: One or more IDs of the VMs you want to reboot. - items: - type: string - type: array - required: - - VmIds - type: object - RebootVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - Region: - additionalProperties: false - description: Information about the Region. - properties: - Endpoint: - description: The hostname of the gateway to access the Region. - type: string - RegionName: - description: The administrative name of the Region. - type: string - type: object - RegisterVmsInLoadBalancerRequest: - additionalProperties: false - properties: - BackendVmIds: - description: 'One or more IDs of back-end VMs.
- - Specifying the same ID several times has no effect as each back-end VM has equal weight.' - items: - type: string - type: array - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LoadBalancerName: - description: The name of the load balancer. - type: string - required: - - BackendVmIds - - LoadBalancerName - type: object - RegisterVmsInLoadBalancerResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - RejectNetPeeringRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetPeeringId: - description: The ID of the Net peering connection you want to reject. - type: string - required: - - NetPeeringId - type: object - RejectNetPeeringResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ResetAccountPasswordRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Password: - description: The new password for the account. - type: string - Token: - description: The token you received at the email address provided for the account. - type: string - required: - - Password - - Token - type: object - ResetAccountPasswordResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ResourceLoadBalancerTag: - additionalProperties: false - description: Information about the tag. - properties: - Key: - description: The key of the tag, with a minimum of 1 character. - type: string - type: object - ResourceTag: - additionalProperties: false - description: Information about the tag. - properties: - Key: - description: The key of the tag, with a minimum of 1 character. - type: string - Value: - description: The value of the tag, between 0 and 255 characters. - type: string - required: - - Key - - Value - type: object - ResponseContext: - additionalProperties: false - description: Information about the context of the response. - properties: - RequestId: - description: The ID of the request. - type: string - type: object - Route: - additionalProperties: false - description: Information about the route. - properties: - CreationMethod: - description: The method used to create the route. - type: string - DestinationIpRange: - description: The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - type: string - DestinationServiceId: - description: The ID of the 3DS OUTSCALE service. - type: string - GatewayId: - description: The ID of the Internet service or virtual gateway attached to the Net. - type: string - NatServiceId: - description: The ID of a NAT service attached to the Net. - type: string - NetAccessPointId: - description: The ID of the Net access point. - type: string - NetPeeringId: - description: The ID of the Net peering connection. - type: string - NicId: - description: The ID of the NIC. - type: string - State: - description: The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - type: string - VmAccountId: - description: The account ID of the owner of the VM. - type: string - VmId: - description: The ID of a VM specified in a route in the table. - type: string - type: object - RouteLight: - additionalProperties: false - description: Information about the route. - properties: - DestinationIpRange: - description: The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - type: string - RouteType: - description: The type of route (always `static`). - type: string - State: - description: The current state of the static route (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - type: object - RoutePropagatingVirtualGateway: - additionalProperties: false - description: Information about the route propagating virtual gateway. - properties: - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - type: object - RouteTable: - additionalProperties: false - description: Information about the route table. - properties: - LinkRouteTables: - description: One or more associations between the route table and Subnets. - items: - $ref: '#/components/schemas/LinkRouteTable' - type: array - NetId: - description: The ID of the Net for the route table. - type: string - RoutePropagatingVirtualGateways: - description: Information about virtual gateways propagating routes. - items: - $ref: '#/components/schemas/RoutePropagatingVirtualGateway' - type: array - RouteTableId: - description: The ID of the route table. - type: string - Routes: - description: One or more routes in the route table. - items: - $ref: '#/components/schemas/Route' - type: array - Tags: - description: One or more tags associated with the route table. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - SecurityGroup: - additionalProperties: false - description: Information about the security group. - properties: - AccountId: - description: The account ID of a user that has been granted permission. - type: string - Description: - description: The description of the security group. - type: string - InboundRules: - description: The inbound rules associated with the security group. - items: - $ref: '#/components/schemas/SecurityGroupRule' - type: array - NetId: - description: The ID of the Net for the security group. - type: string - OutboundRules: - description: The outbound rules associated with the security group. - items: - $ref: '#/components/schemas/SecurityGroupRule' - type: array - SecurityGroupId: - description: The ID of the security group. - type: string - SecurityGroupName: - description: (Public Cloud only) The name of the security group. - type: string - Tags: - description: One or more tags associated with the security group. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - SecurityGroupLight: - additionalProperties: false - description: Information about the security group. - properties: - SecurityGroupId: - description: The ID of the security group. - type: string - SecurityGroupName: - description: (Public Cloud only) The name of the security group. - type: string - type: object - SecurityGroupRule: - additionalProperties: false - description: Information about the security group rule. - properties: - FromPortRange: - description: The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - IpProtocol: - description: The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - type: string - IpRanges: - description: One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - items: - type: string - type: array - SecurityGroupsMembers: - description: Information about one or more members of a security group. - items: - $ref: '#/components/schemas/SecurityGroupsMember' - type: array - ServiceIds: - description: One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](#readnetaccesspointservices). - items: - type: string - type: array - ToPortRange: - description: The end of the port range for the TCP and UDP protocols, or an ICMP type number. - type: long - type: object - SecurityGroupsMember: - additionalProperties: false - description: Information about the member of a security group. - properties: - AccountId: - description: The account ID of a user. - type: string - SecurityGroupId: - description: The ID of the security group. - type: string - SecurityGroupName: - description: (Public Cloud only) The name of the security group. - type: string - type: object - SendResetPasswordEmailRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Email: - description: The email address provided for the account. - type: string - required: - - Email - type: object - SendResetPasswordEmailResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - ServerCertificate: - additionalProperties: false - description: Information about the server certificate. - properties: - ExpirationDate: - description: The date at which the server certificate expires. - format: date - type: string - Id: - description: The ID of the server certificate. - type: string - Name: - description: The name of the server certificate. - type: string - Path: - description: The path to the server certificate. - type: string - UploadDate: - description: The date at which the server certificate has been uploaded. - format: date - type: string - type: object - Service: - additionalProperties: false - description: Information about the service. - properties: - IpRanges: - description: The list of network prefixes used by the service, in CIDR notation. - items: - type: string - type: array - ServiceId: - description: The ID of the service. - type: string - ServiceName: - description: The name of the prefix list, which identifies the 3DS OUTSCALE service it is associated with. - type: string - type: object - Snapshot: - additionalProperties: false - description: Information about the snapshot. - properties: - AccountAlias: - description: The account alias of the owner of the snapshot. - type: string - AccountId: - description: The account ID of the owner of the snapshot. - type: string - Description: - description: The description of the snapshot. - type: string - PermissionsToCreateVolume: - $ref: '#/components/schemas/PermissionsOnResource' - Progress: - description: The progress of the snapshot, as a percentage. - type: long - SnapshotId: - description: The ID of the snapshot. - type: string - State: - description: The state of the snapshot (`in-queue` \| `completed` \| `error`). - type: string - Tags: - description: One or more tags associated with the snapshot. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - VolumeId: - description: The ID of the volume used to create the snapshot. - type: string - VolumeSize: - description: The size of the volume used to create the snapshot, in gibibytes (GiB). - type: long - type: object - SnapshotExportTask: - additionalProperties: false - description: Information about the snapshot export task. - properties: - Comment: - description: If the snapshot export task fails, an error message appears. - type: string - OsuExport: - $ref: '#/components/schemas/OsuExport' - Progress: - description: The progress of the snapshot export task, as a percentage. - type: long - SnapshotId: - description: The ID of the snapshot to be exported. - type: string - State: - description: The state of the snapshot export task (`pending` \| `active` \| `completed` \| `failed`). - type: string - Tags: - description: One or more tags associated with the snapshot export task. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - TaskId: - description: The ID of the snapshot export task. - type: string - type: object - SourceNet: - additionalProperties: false - description: Information about the source Net. - properties: - AccountId: - description: The account ID of the owner of the source Net. - type: string - IpRange: - description: The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - type: string - NetId: - description: The ID of the source Net. - type: string - type: object - SourceSecurityGroup: - additionalProperties: false - description: 'Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
- - To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source.' - properties: - SecurityGroupAccountId: - description: The account ID of the owner of the security group. - type: string - SecurityGroupName: - description: (Public Cloud only) The name of the security group. - type: string - type: object - StartVmsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - required: - - VmIds - type: object - StartVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vms: - description: Information about one or more started VMs. - items: - $ref: '#/components/schemas/VmState' - type: array - type: object - StateComment: - additionalProperties: false - description: Information about the change of state. - properties: - StateCode: - description: The code of the change of state. - type: string - StateMessage: - description: A message explaining the change of state. - type: string - type: object - StopVmsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ForceStop: - description: Forces the VM to stop. - type: boolean - VmIds: - description: One or more IDs of VMs. - items: - type: string - type: array - required: - - VmIds - type: object - StopVmsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vms: - description: Information about one or more stopped VMs. - items: - $ref: '#/components/schemas/VmState' - type: array - type: object - Subnet: - additionalProperties: false - description: Information about the Subnet. - properties: - AvailableIpsCount: - description: The number of available IP addresses in the Subnets. - type: long - IpRange: - description: The IP range in the Subnet, in CIDR notation (for example, 10.0.0.0/16). - type: string - MapPublicIpOnLaunch: - description: If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. - type: boolean - NetId: - description: The ID of the Net in which the Subnet is. - type: string - State: - description: The state of the Subnet (`pending` \| `available`). - type: string - SubnetId: - description: The ID of the Subnet. - type: string - SubregionName: - description: The name of the Subregion in which the Subnet is located. - type: string - Tags: - description: One or more tags associated with the Subnet. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - type: object - Subregion: - additionalProperties: false - description: Information about the Subregion. - properties: - RegionName: - description: The name of the Region containing the Subregion. - type: string - State: - description: The state of the Subregion (`available` \| `information` \| `impaired` \| `unavailable`). - type: string - SubregionName: - description: The name of the Subregion. - type: string - type: object - Tag: - additionalProperties: false - description: Information about the tag. - properties: - Key: - description: The key of the tag, with a minimum of 1 character. - type: string - ResourceId: - description: The ID of the resource. - type: string - ResourceType: - description: The type of the resource. - type: string - Value: - description: The value of the tag, between 0 and 255 characters. - type: string - type: object - UnlinkFlexibleGpuRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FlexibleGpuId: - description: The ID of the fGPU you want to detach from your VM. - type: string - required: - - FlexibleGpuId - type: object - UnlinkFlexibleGpuResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkInternetServiceRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - InternetServiceId: - description: The ID of the Internet service you want to detach. - type: string - NetId: - description: The ID of the Net from which you want to detach the Internet service. - type: string - required: - - InternetServiceId - - NetId - type: object - UnlinkInternetServiceResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkNicRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LinkNicId: - description: The ID of the attachment operation. - type: string - required: - - LinkNicId - type: object - UnlinkNicResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkPrivateIpsRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NicId: - description: The ID of the NIC. - type: string - PrivateIps: - description: One or more secondary private IP addresses you want to unassign from the NIC. - items: - type: string - type: array - required: - - NicId - - PrivateIps - type: object - UnlinkPrivateIpsResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkPublicIpRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LinkPublicIpId: - description: (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - type: string - PublicIp: - description: The External IP address. In the public Cloud, this parameter is required. - type: string - type: object - UnlinkPublicIpResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkRouteTableRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LinkRouteTableId: - description: The ID of the association between the route table and the Subnet. - type: string - required: - - LinkRouteTableId - type: object - UnlinkRouteTableResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkVirtualGatewayRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net from which you want to detach the virtual gateway. - type: string - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - required: - - NetId - - VirtualGatewayId - type: object - UnlinkVirtualGatewayResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UnlinkVolumeRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ForceUnlink: - description: 'Forces the detachment of the volume in case of previous failure. Important: This action may damage your data or file systems.' - type: boolean - VolumeId: - description: The ID of the volume you want to detach. - type: string - required: - - VolumeId - type: object - UnlinkVolumeResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateAccessKeyRequest: - additionalProperties: false - properties: - AccessKeyId: - description: The ID of the access key. - type: string - State: - description: The new state for the access key (`active` \| `inactive`). - type: string - required: - - AccessKeyId - - State - type: object - UpdateAccessKeyResponse: - additionalProperties: false - properties: - AccessKey: - $ref: '#/components/schemas/AccessKey' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateAccountRequest: - additionalProperties: false - properties: - City: - description: The new city of the account owner. - type: string - CompanyName: - description: The new name of the company for the account. - type: string - Country: - description: The new country of the account owner. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Email: - description: The new email address for the account. - type: string - FirstName: - description: The new first name of the account owner. - type: string - JobTitle: - description: The new job title of the account owner. - type: string - LastName: - description: The new last name of the account owner. - type: string - MobileNumber: - description: The new mobile phone number of the account owner. - type: string - PhoneNumber: - description: The new landline phone number of the account owner. - type: string - StateProvince: - description: The new state/province of the account owner. - type: string - VatNumber: - description: The new value added tax (VAT) number for the account. - type: string - ZipCode: - description: The new ZIP code of the city. - type: string - type: object - UpdateAccountResponse: - additionalProperties: false - properties: - Account: - $ref: '#/components/schemas/Account' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateFlexibleGpuRequest: - additionalProperties: false - properties: - DeleteOnVmDeletion: - description: If `true`, the fGPU is deleted when the VM is terminated. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - FlexibleGpuId: - description: The ID of the fGPU you want to modify. - type: string - required: - - FlexibleGpuId - type: object - UpdateFlexibleGpuResponse: - additionalProperties: false - properties: - FlexibleGpu: - $ref: '#/components/schemas/FlexibleGpu' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateImageRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - ImageId: - description: The ID of the OMI you want to modify. - type: string - PermissionsToLaunch: - $ref: '#/components/schemas/PermissionsOnResourceCreation' - required: - - ImageId - - PermissionsToLaunch - type: object - UpdateImageResponse: - additionalProperties: false - properties: - Image: - $ref: '#/components/schemas/Image' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateListenerRuleRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - HostPattern: - description: A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. - type: string - ListenerRuleName: - description: The name of the listener rule. - type: string - PathPattern: - description: A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. - type: string - required: - - ListenerRuleName - type: object - UpdateListenerRuleResponse: - additionalProperties: false - properties: - ListenerRule: - $ref: '#/components/schemas/ListenerRule' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateLoadBalancerRequest: - additionalProperties: false - properties: - AccessLog: - $ref: '#/components/schemas/AccessLog' - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - HealthCheck: - $ref: '#/components/schemas/HealthCheck' - LoadBalancerName: - description: The name of the load balancer. - type: string - LoadBalancerPort: - description: The port on which the load balancer is listening (between `1` and `65535`, both included). - type: long - PolicyNames: - description: The list of policy names (must contain all the policies to be enabled). - items: - type: string - type: array - ServerCertificateId: - description: The Outscale Resource Name (ORN) of the SSL certificate. - type: string - required: - - LoadBalancerName - type: object - UpdateLoadBalancerResponse: - additionalProperties: false - properties: - LoadBalancer: - $ref: '#/components/schemas/LoadBalancer' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateNetAccessPointRequest: - additionalProperties: false - properties: - AddRouteTableIds: - description: One or more IDs of route tables to associate with the specified Net access point. - items: - type: string - type: array - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetAccessPointId: - description: The ID of the Net access point. - type: string - RemoveRouteTableIds: - description: One or more IDs of route tables to disassociate from the specified Net access point. - items: - type: string - type: array - required: - - NetAccessPointId - type: object - UpdateNetAccessPointResponse: - additionalProperties: false - properties: - NetAccessPoint: - $ref: '#/components/schemas/NetAccessPoint' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateNetRequest: - additionalProperties: false - properties: - DhcpOptionsSetId: - description: The ID of the DHCP options set (or `default` if you want to associate the default one). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - NetId: - description: The ID of the Net. - type: string - required: - - DhcpOptionsSetId - - NetId - type: object - UpdateNetResponse: - additionalProperties: false - properties: - Net: - $ref: '#/components/schemas/Net' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateNicRequest: - additionalProperties: false - properties: - Description: - description: A new description for the NIC. - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - LinkNic: - $ref: '#/components/schemas/LinkNicToUpdate' - NicId: - description: The ID of the NIC you want to modify. - type: string - SecurityGroupIds: - description: 'One or more IDs of security groups for the NIC.
- - You must specify at least one group, even if you use the default security group in the Net.' - items: - type: string - type: array - required: - - NicId - type: object - UpdateNicResponse: - additionalProperties: false - properties: - Nic: - $ref: '#/components/schemas/Nic' - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - type: object - UpdateRoutePropagationRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Enable: - description: If `true`, a virtual gateway can propagate routes to a specified route table of a Net. If `false`, the propagation is disabled. - type: boolean - RouteTableId: - description: The ID of the route table. - type: string - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - required: - - Enable - - RouteTableId - - VirtualGatewayId - type: object - UpdateRoutePropagationResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTable: - $ref: '#/components/schemas/RouteTable' - type: object - UpdateRouteRequest: - additionalProperties: false - properties: - DestinationIpRange: - description: The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - type: string - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - GatewayId: - description: The ID of an Internet service or virtual gateway attached to your Net. - type: string - NatServiceId: - description: The ID of a NAT service. - type: string - NetPeeringId: - description: The ID of a Net peering connection. - type: string - NicId: - description: The ID of a network interface card (NIC). - type: string - RouteTableId: - description: The ID of the route table. - type: string - VmId: - description: The ID of a NAT VM in your Net. - type: string - required: - - RouteTableId - - DestinationIpRange - type: object - UpdateRouteResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - RouteTable: - $ref: '#/components/schemas/RouteTable' - type: object - UpdateServerCertificateRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - Name: - description: The name of the server certificate you want to modify. - type: string - NewName: - description: A new name for the server certificate. - type: string - NewPath: - description: A new path for the server certificate. - type: string - type: object - UpdateServerCertificateResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - ServerCertificate: - $ref: '#/components/schemas/ServerCertificate' - type: object - UpdateSnapshotRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - PermissionsToCreateVolume: - $ref: '#/components/schemas/PermissionsOnResourceCreation' - SnapshotId: - description: The ID of the snapshot. - type: string - required: - - SnapshotId - - PermissionsToCreateVolume - type: object - UpdateSnapshotResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Snapshot: - $ref: '#/components/schemas/Snapshot' - type: object - UpdateSubnetRequest: - additionalProperties: false - properties: - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - MapPublicIpOnLaunch: - description: If `true`, a public IP address is assigned to the network interface cards (NICs) created in the specified Subnet. - type: boolean - SubnetId: - description: The ID of the Subnet. - type: string - required: - - SubnetId - - MapPublicIpOnLaunch - type: object - UpdateSubnetResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Subnet: - $ref: '#/components/schemas/Subnet' - type: object - UpdateVmRequest: - additionalProperties: false - properties: - BlockDeviceMappings: - description: One or more block device mappings of the VM. - items: - $ref: '#/components/schemas/BlockDeviceMappingVmUpdate' - type: array - BsuOptimized: - description: If `true`, the VM is optimized for BSU I/O. - type: boolean - DeletionProtection: - description: If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - type: boolean - DryRun: - description: If `true`, checks whether you have the required permissions to perform the action. - type: boolean - IsSourceDestChecked: - description: (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - type: boolean - KeypairName: - description: 'The name of the keypair.
- - To complete the replacement, manually replace the old public key with the new public key in the ~/.ssh/authorized_keys file located in the VM. Restart the VM to apply the change.' - type: string - Performance: - description: The performance of the VM (`standard` \| `high` \| `highest`). - enum: - - medium - - high - - highest - type: string - SecurityGroupIds: - description: One or more IDs of security groups for the VM. - items: - type: string - type: array - UserData: - description: The Base64-encoded MIME user data. - type: string - VmId: - description: The ID of the VM. - type: string - VmInitiatedShutdownBehavior: - description: The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is terminated. - type: string - VmType: - description: The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - type: string - required: - - VmId - type: object - UpdateVmResponse: - additionalProperties: false - properties: - ResponseContext: - $ref: '#/components/schemas/ResponseContext' - Vm: - $ref: '#/components/schemas/Vm' - type: object - VirtualGateway: - additionalProperties: false - description: Information about the virtual gateway. - properties: - ConnectionType: - description: The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). - type: string - NetToVirtualGatewayLinks: - description: The Net to which the virtual gateway is attached. - items: - $ref: '#/components/schemas/NetToVirtualGatewayLink' - type: array - State: - description: The state of the virtual gateway (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - Tags: - description: One or more tags associated with the virtual gateway. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - VirtualGatewayId: - description: The ID of the virtual gateway. - type: string - type: object - Vm: - additionalProperties: false - description: Information about the VM. - properties: - Architecture: - description: The architecture of the VM (`i386` \| `x86_64`). - type: string - BlockDeviceMappings: - description: The block device mapping of the VM. - items: - $ref: '#/components/schemas/BlockDeviceMappingCreated' - type: array - BsuOptimized: - description: If `true`, the VM is optimized for BSU I/O. - type: boolean - ClientToken: - description: The idempotency token provided when launching the VM. - type: string - DeletionProtection: - description: If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. - type: boolean - Hypervisor: - description: The hypervisor type of the VMs (`ovm` \| `xen`). - type: string - ImageId: - description: The ID of the OMI used to create the VM. - type: string - IsSourceDestChecked: - description: (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - type: boolean - KeypairName: - description: The name of the keypair used when launching the VM. - type: string - LaunchNumber: - description: The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). - type: long - NetId: - description: The ID of the Net in which the VM is running. - type: string - Nics: - description: The network interface cards (NICs) the VMs are attached to. - items: - $ref: '#/components/schemas/NicLight' - type: array - OsFamily: - description: Indicates the operating system (OS) of the VM. - type: string - Performance: - description: The performance of the VM (`standard` \| `high` \| `highest`). - type: string - Placement: - $ref: '#/components/schemas/Placement' - PrivateDnsName: - description: The name of the private DNS. - type: string - PrivateIp: - description: The primary private IP address of the VM. - type: string - ProductCodes: - description: The product code associated with the OMI used to create the VM (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). - items: - type: string - type: array - PublicDnsName: - description: The name of the public DNS. - type: string - PublicIp: - description: The public IP address of the VM. - type: string - ReservationId: - description: The reservation ID of the VM. - type: string - RootDeviceName: - description: The name of the root device for the VM (for example, /dev/vda1). - type: string - RootDeviceType: - description: The type of root device used by the VM (always `bsu`). - type: string - SecurityGroups: - description: One or more security groups associated with the VM. - items: - $ref: '#/components/schemas/SecurityGroupLight' - type: array - State: - description: The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). - type: string - StateReason: - description: The reason explaining the current state of the VM. - type: string - SubnetId: - description: The ID of the Subnet for the VM. - type: string - Tags: - description: One or more tags associated with the VM. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - UserData: - description: The Base64-encoded MIME user data. - type: string - VmId: - description: The ID of the VM. - type: string - VmInitiatedShutdownBehavior: - description: The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. - type: string - VmType: - description: The type of VM. For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). - type: string - type: object - VmState: - additionalProperties: false - description: Information about the state of the VM. - properties: - CurrentState: - description: The current state of the VM (`InService` \| `OutOfService` \| `Unknown`). - type: string - PreviousState: - description: The previous state of the VM (`InService` \| `OutOfService` \| `Unknown`). - type: string - VmId: - description: The ID of the VM. - type: string - type: object - VmStates: - additionalProperties: false - description: Information about the states of the VMs. - properties: - MaintenanceEvents: - description: One or more scheduled events associated with the VM. - items: - $ref: '#/components/schemas/MaintenanceEvent' - type: array - SubregionName: - description: The name of the Subregion of the VM. - type: string - VmId: - description: The ID of the VM. - type: string - VmState: - description: The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). - type: string - type: object - VmType: - additionalProperties: false - description: Information about the VM type. - properties: - BsuOptimized: - description: Indicates whether the VM is optimized for BSU I/O. - type: boolean - MaxPrivateIps: - description: The maximum number of private IP addresses per network interface card (NIC). - type: long - MemorySize: - description: The amount of memory, in gibibytes. - format: float - type: number - VcoreCount: - description: The number of vCores. - type: long - VmTypeName: - description: The name of the VM type. - type: string - VolumeCount: - description: The maximum number of ephemeral storage disks. - type: long - VolumeSize: - description: The size of one ephemeral storage disk, in gibibytes (GiB). - type: long - type: object - Volume: - additionalProperties: false - description: Information about the volume. - properties: - Iops: - description: 'The number of I/O operations per second (IOPS):
- - - For `io1` volumes, the number of provisioned IOPS
- - - For `gp2` volumes, the baseline performance of the volume' - type: long - LinkedVolumes: - description: Information about your volume attachment. - items: - $ref: '#/components/schemas/LinkedVolume' - type: array - Size: - description: The size of the volume, in gibibytes (GiB). - type: long - SnapshotId: - description: The snapshot from which the volume was created. - type: string - State: - description: The state of the volume (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). - type: string - SubregionName: - description: The Subregion in which the volume was created. - type: string - Tags: - description: One or more tags associated with the volume. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - VolumeId: - description: The ID of the volume. - type: string - VolumeType: - description: The type of the volume (`standard` \| `gp2` \| `io1`). - type: string - type: object - VpnConnection: - additionalProperties: false - description: Information about a VPN connection. - properties: - ClientGatewayConfiguration: - description: The configuration to apply to the client gateway to establish the VPN connection, in XML format. - type: string - ClientGatewayId: - description: The ID of the client gateway used on the client end of the connection. - type: string - ConnectionType: - description: The type of VPN connection (always `ipsec.1`). - type: string - Routes: - description: Information about one or more static routes associated with the VPN connection, if any. - items: - $ref: '#/components/schemas/RouteLight' - type: array - State: - description: The state of the VPN connection (`pending` \| `available` \| `deleting` \| `deleted`). - type: string - StaticRoutesOnly: - description: If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](#createvpnconnectionroute) and [DeleteVpnConnectionRoute](#deletevpnconnectionroute). - type: boolean - Tags: - description: One or more tags associated with the VPN connection. - items: - $ref: '#/components/schemas/ResourceTag' - type: array - VirtualGatewayId: - description: The ID of the virtual gateway used on the 3DS OUTSCALE end of the connection. - type: string - VpnConnectionId: - description: The ID of the VPN connection. - type: string - type: object - With: - additionalProperties: false - description: The information to be displayed in the API logs to retrieve. - properties: - AccountId: - description: If set to `true`, the account ID is displayed in the logs. - type: boolean - CallDuration: - description: If set to `true`, the duration of the call is displayed each log. - type: boolean - QueryAccessKey: - description: If set to `true`, the API key used for the query is displayed each log. - type: boolean - QueryApiName: - description: If set to `true`, the name of the API service used by the call is displayed in each log (`oapi` \| `fcu` \| `lbu` \| `directlink` \| `eim` \| `icu`). - type: boolean - QueryApiVersion: - description: If set to `true`, the version of the API service used by the call is displayed in each log. - type: boolean - QueryCallName: - description: If set to `true`, the name of the call is displayed in each log. - type: boolean - QueryDate: - description: If set to `true`, the date of the call is displayed in each log. - type: boolean - QueryHeaderRaw: - description: If set to `true`, the query header RAW is displayed in each log. - type: boolean - QueryHeaderSize: - description: If set to `true`, the query header size is displayed in each log. - type: boolean - QueryIpAddress: - description: If set to `true`, the IP address used to make to query is displayed in each log. - type: boolean - QueryPayloadRaw: - description: If set to `true`, the query payload raw is displayed in each log. - type: boolean - QueryPayloadSize: - description: If set to `true`, the query payload size is displayed in each log. - type: boolean - QueryUserAgent: - description: If set to `true`, the user agent used to make the HTTP request is displayed in each log. - type: boolean - RequestId: - description: By default ot if set to `true`, the ID of the call is displayed in each log. - type: boolean - ResponseSize: - description: If set to `true`, the size of the response (in bytes) is displayed in each log. - type: boolean - ResponseStatusCode: - description: If set to `true`, the HTTP code provided by the response is displayed in each log. - type: boolean - type: object - securitySchemes: - ApiKeyAuth: - description: Signatures of API Requests based on the Hash-based Message Authentication Code (HMAC) protocol, [more information](https://wiki.outscale.net/display/EN/About+Signatures+of+API+Requests). - in: header - name: Authorization - type: apiKey -info: - contact: - email: support@outscale.com - description: 'Welcome to the 3DS OUTSCALE''s API documentation.

- - - The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

- - - Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

- - - You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface.' - license: - name: BSD 3 Clause - url: https://opensource.org/licenses/BSD-3-Clause - termsOfService: https://en.outscale.com/terms-of-service/ - title: 3DS OUTSCALE API - version: '1.1' -openapi: 3.0.0 -paths: - /AcceptNetPeering: - description: 'Accepts a Net peering connection request.
- - To accept this request, you must be the owner of the peer Net. If you do not accept the request within 7 days, the state of the Net peering connection becomes `expired`.' - post: - operationId: AcceptNetPeering - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/AcceptNetPeeringRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/AcceptNetPeeringResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NetPeering - /CheckAuthentication: - description: Validates the authenticity of the account. - post: - operationId: CheckAuthentication - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CheckAuthenticationRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CheckAuthenticationResponse' - description: Information about the response. - tags: - - Account - /CreateAccessKey: - description: Creates a new secret access key and the corresponding access key ID for a specified user. The created key is automatically set to `active`. - post: - operationId: CreateAccessKey - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateAccessKeyResponse' - description: Information about the response. - tags: - - AccessKey - /CreateAccount: - description: 'Creates a new 3DS OUTSCALE account.

- - - **[NOTE]**
- - * You need 3DS OUTSCALE credentials and the appropriate quotas to create a new account via API. To get quotas, you can send an email to sales@outscale.com.
- - * If you want to pass a numeral value as a string instead of an long, you must wrap your string in additional quotes (for example, `''"92000"''`).' - post: - operationId: CreateAccount - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateAccountRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateAccountResponse' - description: Information about the response. - tags: - - Account - /CreateClientGateway: - description: 'Provides information about your client gateway.
- - This action registers information to identify the client gateway that you deployed in your network.
- - To open a tunnel to the client gateway, you must at least provide the communication protocol type, the valid fixed public IP address of the gateway, and an Autonomous System Number (ASN).
- - If you do not have any ASN assigned to your network, you may use a private ASN within the [64000; 64495] or [4200000000; 4294967294] ranges. By default, you can use 65000 as BGP ASN.' - post: - operationId: CreateClientGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateClientGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateClientGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - ClientGateway - /CreateDhcpOptions: - description: Creates a new set of DHCP options, that you can then associate with a Net using the [UpdateNet](#updatenet) method. - post: - operationId: CreateDhcpOptions - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDhcpOptionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDhcpOptionsResponse' - description: The HTTP 200 response (OK). - tags: - - DhcpOption - /CreateDirectLink: - description: Creates a new DirectLink between a customer network and a specified DirectLink location. - post: - operationId: CreateDirectLink - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDirectLinkRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDirectLinkResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLink - /CreateDirectLinkInterface: - description: 'Creates a DirectLink interface.
- - DirectLink interfaces enable you to reach one of your Nets through a virtual gateway.' - post: - operationId: CreateDirectLinkInterface - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDirectLinkInterfaceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateDirectLinkInterfaceResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLinkInterface - /CreateFlexibleGpu: - description: 'Allocates a flexible GPU (fGPU) to your account.
- - You can then attach this fGPU to a virtual machine (VM).' - post: - operationId: CreateFlexibleGpu - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateFlexibleGpuRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateFlexibleGpuResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /CreateImage: - description: 'Creates an Outscale machine image (OMI) from an existing virtual machine (VM) which is either running or stopped.
- - This action also creates a snapshot of the root volume of the VM, as well as a snapshot of each Block Storage Unit (BSU) volume attached to the VM.

- - - You can also use this method to copy an OMI to your account, from an account in the same Region. To do so, the owner of the source OMI must share it with your account. For more information about how to share an OMI with another account in the same Region, see [UpdateImage](#updateimage).
- - To copy an OMI between accounts in different Regions, the owner of the source OMI must first export it to an Object Storage Unit (OSU) bucket using the [CreateImageExportTask](#createimageexporttask) method, and then you need to create a copy of the image in your account.
- - The copy of the source OMI is independent and belongs to you.

- - - You can also use this method to register an OMI to finalize its creation process.
- - You can register an OMI from a snapshot of a root device to create an OMI based on this snapshot. You can also register an OMI that has been exported to an OSU bucket to create a copy of it in your account. For more information about OMI export to an OSU bucket, see [CreateImageExportTask](#createimageexporttask).
- - You can register an OMI using a pre-signed URL of the manifest file of the OMI. You do not need any permission for this OMI, or the bucket in which it is contained. The manifest file is obsolete seven days after a completed export as it contains pre-signed URLs to the appropriate snapshots (pre-signed URLs are valid for only seven days).
- - Once the OMI is registered, you can launch a VM from this OMI. The copy of the source OMI is independent and belongs to you.' - post: - operationId: CreateImage - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateImageRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateImageResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Image - /CreateImageExportTask: - description: 'Exports an Outscale machine image (OMI) to an Object Storage Unit (OSU) bucket.
- - This action enables you to copy an OMI between accounts in different Regions. To copy an OMI in the same Region, you can also use the [CreateImage](#createimage) method.
- - The copy of the OMI belongs to you and is independent from the source OMI.

- - - **[NOTE]**
- - You cannot export a shared or public OMI, as they do not belong to you. To do so, you must first copy it to your account. The copy then belongs to you and you can export it.' - post: - operationId: CreateImageExportTask - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateImageExportTaskRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateImageExportTaskResponse' - description: The HTTP 200 response (OK). - tags: - - Image - /CreateInternetService: - description: 'Creates an Internet service you can use with a Net.
- - An Internet service enables your virtual machines (VMs) launched in a Net to connect to the Internet. By default, a Net includes an Internet service, and each Subnet is public. Every VM launched within a default Subnet has a private and a public IP addresses.' - post: - operationId: CreateInternetService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateInternetServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateInternetServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - InternetService - /CreateKeypair: - description: 'Creates a 2048-bit RSA keypair with a specified name.
- - This action returns the private key that you need to save. The public key is stored by 3DS OUTSCALE.

- - - You can also use this method to import a provided public key and create a keypair.
- - This action imports the public key of a keypair created by a third-party tool and uses it to create a new keypair. The private key is never provided to 3DS OUTSCALE.' - post: - operationId: CreateKeypair - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateKeypairRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateKeypairResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Keypair - /CreateListenerRule: - description: 'Creates a rule for traffic redirection for the specified listener. Each rule must have either the `HostNamePattern` or `PathPattern` parameter specified. Rules are treated in priority order, from the highest value to the lowest value.
- - Once the rule is created, you need to register backend VMs with it. For more information, see the [RegisterVmsInLoadBalancer](#registervmsinloadbalancer) method.' - post: - operationId: CreateListenerRule - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateListenerRuleRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateListenerRuleResponse' - description: Information about the reponse. - tags: - - Listener - /CreateLoadBalancer: - description: 'Creates a load balancer.
- - The load balancer is created with a unique Domain Name Service (DNS) name. It receives the incoming traffic and routes it to its registered virtual machines (VMs).
- - By default, this action creates an Internet-facing load balancer, resolving to public IP addresses. To create an internal load balancer in a Net, resolving to private IP addresses, use the `LoadBalancerType` parameter.' - post: - operationId: CreateLoadBalancer - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /CreateLoadBalancerListeners: - description: Creates one or more listeners for a specified load balancer. - post: - operationId: CreateLoadBalancerListeners - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerListenersRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerListenersResponse' - description: The HTTP 200 response (OK). - tags: - - Listener - /CreateLoadBalancerPolicy: - description: 'Creates a stickiness policy with sticky session lifetimes defined by the browser lifetime.
- - The created policy can be used with HTTP or HTTPS listeners only.
- - If this policy is implemented by a load balancer, this load balancer uses this cookie in all incoming requests to direct them to the specified back-end server virtual machine (VM). If this cookie is not present, the load balancer sends the request to any other server according to its load-balancing algorithm.

- - - You can also create a stickiness policy with sticky session lifetimes following the lifetime of an application-generated cookie.
- - Unlike the other type of stickiness policy, the lifetime of the special Load Balancer Unit (LBU) cookie follows the lifetime of the application-generated cookie specified in the policy configuration. The load balancer inserts a new stickiness cookie only when the application response includes a new application cookie.
- - The session stops being sticky if the application cookie is removed or expires, until a new application cookie is issued.' - post: - operationId: CreateLoadBalancerPolicy - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerPolicyRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerPolicyResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancerPolicy - /CreateLoadBalancerTags: - description: 'Adds one or more tags to the specified load balancers.
- - If a tag with the same key already exists for the load balancer, the tag value is replaced.' - post: - operationId: CreateLoadBalancerTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateLoadBalancerTagsResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /CreateNatService: - description: 'Creates a network address translation (NAT) service in the specified public Subnet of a Net.
- - A NAT service enables virtual machines (VMs) placed in the private Subnet of this Net to connect to the Internet, without being accessible from the Internet.
- - When creating a NAT service, you specify the allocation ID of the External IP (EIP) you want to use as public IP for the NAT service. Once the NAT service is created, you need to create a route in the route table of the private Subnet, with 0.0.0.0/0 as destination and the ID of the NAT service as target. For more information, see [LinkPublicIP](#linkpublicip) and [CreateRoute](#createroute).
- - This action also enables you to create multiple NAT services in the same Net (one per public Subnet).

- - - **[NOTE]**
- - You cannot modify the EIP associated with a NAT service after its creation. To do so, you need to delete the NAT service and create a new one with another EIP.' - post: - operationId: CreateNatService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNatServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNatServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NatService - /CreateNet: - description: 'Creates a Net with a specified IP range.
- - The IP range (network range) of your Net must be between a /28 netmask (16 IP addresses) and a /16 netmask (65 536 IP addresses).' - post: - operationId: CreateNet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Net - /CreateNetAccessPoint: - description: 'Creates a Net access point to access a 3DS OUTSCALE service from this Net without using the Internet and External IP addresses.
- - You specify the service using its prefix list name. For more information, see [DescribePrefixLists](#describeprefixlists)
- - To control the routing of traffic between the Net and the specified service, you can specify one or more route tables. Virtual machines placed in Subnets associated with the specified route table thus use the Net access point to access the service. When you specify a route table, a route is automatically added to it with the destination set to the prefix list ID of the service, and the target set to the ID of the access point.' - post: - operationId: CreateNetAccessPoint - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetAccessPointRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetAccessPointResponse' - description: The HTTP 200 response (OK). - tags: - - NetAccessPoint - /CreateNetPeering: - description: 'Requests a Net peering connection between a Net you own and a peer Net that belongs to you or another account.
- - This action creates a Net peering connection that remains in the `pending-acceptance` state until it is accepted by the owner of the peer Net. If the owner of the peer Net does not accept the request within 7 days, the state of the Net peering connection becomes `expired`. For more information, see [AcceptNetPeering](#acceptnetpeering).

- - - **[NOTE]**
- - The two Nets must not have overlapping IP ranges. Otherwise, the Net peering connection is in the `failed` state.' - post: - operationId: CreateNetPeering - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetPeeringRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNetPeeringResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NetPeering - /CreateNic: - description: Creates a network interface card (NIC) in the specified Subnet. - post: - operationId: CreateNic - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNicRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateNicResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /CreatePublicIp: - description: 'Acquires an External IP address (EIP) for your account.
- - An EIP is a static IP address designed for dynamic Cloud computing. It can be used for virtual machines (VMs) in the public Cloud (`standard`) or in a Net, for a network interface card (NIC), or for a NAT service.' - post: - operationId: CreatePublicIp - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreatePublicIpRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreatePublicIpResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - PublicIp - /CreateRoute: - description: 'Creates a route in a specified route table within a specified Net.
- - You must specify one of the following elements as the target:

- - - * Net peering connection
- - * NAT VM
- - * Internet service
- - * Virtual gateway
- - * NAT service
- - * Network interface card (NIC)

- - - The routing algorithm is based on the most specific match.' - post: - operationId: CreateRoute - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateRouteRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateRouteResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Route - /CreateRouteTable: - description: 'Creates a route table for a specified Net.
- - You can then add routes and associate this route table with a Subnet.' - post: - operationId: CreateRouteTable - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateRouteTableRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateRouteTableResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - RouteTable - /CreateSecurityGroup: - description: 'Creates a security group.
- - This action creates a security group either in the public Cloud or in a specified Net. By default, a default security group for use in the public Cloud and a default security group for use in a Net are created.
- - When launching a virtual machine (VM), if no security group is explicitly specified, the appropriate default security group is assigned to the VM. Default security groups include a default rule granting VMs network access to each other.
- - When creating a security group, you specify a name. Two security groups for use in the public Cloud or for use in a Net cannot have the same name.
- - You can have up to 500 security groups in the public Cloud. You can create up to 500 security groups per Net.
- - To add or remove rules, use the [CreateSecurityGroupRule](#createsecuritygrouprule) method.' - post: - operationId: CreateSecurityGroup - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSecurityGroupRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSecurityGroupResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - SecurityGroup - /CreateSecurityGroupRule: - description: 'Configures the rules for a security group.
- - The modifications are effective at virtual machine (VM) level as quickly as possible, but a small delay may occur.

- - - You can add one or more egress rules to a security group for use with a Net.
- - It allows VMs to send traffic to either one or more destination IP address ranges or destination security groups for the same Net.
- - We recommend using a set of IP permissions to authorize outbound access to a destination security group. We also recommended this method to create a rule with a specific IP protocol and a specific port range. In a set of IP permissions, we recommend to specify the the protocol.

- - - You can also add one or more ingress rules to a security group.
- - In the public Cloud, this action allows one or more IP address ranges to access a security group for your account, or allows one or more security groups (source groups) to access a security group for your own 3DS OUTSCALE account or another one.
- - In a Net, this action allows one or more IP address ranges to access a security group for your Net, or allows one or more other security groups (source groups) to access a security group for your Net. All the security groups must be for the same Net.

- - - **[NOTE]**
- - By default, traffic between two security groups is allowed through both public and private IP addresses. To restrict it to private IP addresses only, contact our Support team: support@outscale.com.' - post: - operationId: CreateSecurityGroupRule - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSecurityGroupRuleRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSecurityGroupRuleResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - SecurityGroupRule - /CreateServerCertificate: - description: 'Creates a server certificate and its matching private key.

- - These elements can be used with other services (for example, to configure SSL termination on load balancers).

- - You can also specify the chain of intermediate certification authorities if your certificate is not directly signed by a root one. You can specify multiple intermediate certification authorities in the `CertificateChain` parameter. To do so, concatenate all certificates in the correct order (the first certificate must be the authority of your certificate, the second must the the authority of the first one, and so on).

- - The private key must be a RSA key in PKCS1 form. To check this, open the PEM file and ensure its header reads as follows: BEGIN RSA PRIVATE KEY.

- - [IMPORTANT]

- - This private key must not be protected by a password or a passphrase.' - post: - operationId: CreateServerCertificate - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateServerCertificateRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateServerCertificateResponse' - description: Information about the response. - tags: - - ServerCertificate - /CreateSnapshot: - description: 'Creates a snapshot of a Block storage Unit (BSU) volume.
- - Snapshots are point-in-time images of a volume you can use to back up your data or to create replicas of this volume at the time the snapshot was created.

- - - You can also use this method to copy a snapshot to your account, from an account in the same Region.
- - To do so, the owner of the source snapshot must share it with your account. For more information about how to share a snapshot with another account, see [UpdateSnapshot](#updatesnapshot).
- - The copy of the source snapshot is independent and belongs to you.

- - - To copy a snapshot between accounts in different Regions, the owner of the source snapshot must export it to an Object Storage Unit (OSU) bucket using the [CreateSnapshotExportTask](#createsnapshotexporttask) method. You then need to import it from the OSU bucket to create a copy of this snapshot in your account.
- - You can import a snapshot using a pre-signed URL. You do not need any permission for this snapshot, or the bucket in which it is contained. The pre-signed URL is valid for seven days (you can regenerate a new one if needed).' - post: - operationId: CreateSnapshot - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSnapshotRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSnapshotResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Snapshot - /CreateSnapshotExportTask: - description: 'Exports a snapshot to an Object Storage Unit (OSU) bucket.
- - This action enables you to create a backup of your snapshot or to copy it to another account. You, or other users you send a pre-signed URL to, can then download this snapshot from the OSU bucket using the [CreateSnapshot](#createsnapshot) method.
- - This procedure enables you to copy a snapshot between accounts within the same Region or in different Regions. To copy a snapshot within the same Region, you can also use the [CreateSnapshot](#createsnapshot) direct method. The copy of the source snapshot is independent and belongs to you.' - post: - operationId: CreateSnapshotExportTask - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSnapshotExportTaskRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSnapshotExportTaskResponse' - description: The HTTP 200 response (OK). - tags: - - Snapshot - /CreateSubnet: - description: 'Creates a Subnet in an existing Net.
- - To create a Subnet in a Net, you have to provide the ID of the Net and the IP range for the Subnet (its network range). Once the Subnet is created, you cannot modify its IP range.
- - The IP range of the Subnet can be either the same as the Net one if you create only a single Subnet in this Net, or a subset of the Net one. In case of several Subnets in a Net, their IP ranges must not overlap. The smallest Subnet you can create uses a /30 netmask (four IP addresses).' - post: - operationId: CreateSubnet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSubnetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateSubnetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Subnet - /CreateTags: - description: 'Adds one or more tags to the specified resources.
- - If a tag with the same key already exists for the resource, the tag value is replaced.
- - You can tag the following resources using their IDs:

- - - * Virtual machines (VMs) (i-xxxxxxxx)
- - * OMIs (ami-xxxxxxxx)
- - * Volumes (vol-xxxxxxxx)
- - * Snapshots (snap-xxxxxxxx)
- - * EIPs (eipalloc-xxxxxxxx)
- - * Security groups (sg-xxxxxxxx)
- - * Route tables (rtb-xxxxxxxx)
- - * Network interface cards (NIC) (eni-xxxxxxxx)
- - * Nets (vpc-xxxxxxxx)
- - * Subnets (subnet-xxxxxxxx)
- - * Net peering connections (vpcx-xxxxxxxx)
- - * Net endpoints (vpce-xxxxxxxx)
- - * NAT services (nat-xxxxxxxx)
- - * Internet services (igw-xxxxxxxx)
- - * Client gateways (cgw-xxxxxxxx)
- - * Virtual gateways (vgw-xxxxxxxx)
- - * VPN connections (vpn-xxxxxxxx)
- - * DHCP options (dopt-xxxxxxxx)
- - * OMI export tasks (image-export-xxxxxxxx)
- - * Snapshot export tasks (snap-export-xxxxxxxx)' - post: - operationId: CreateTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateTagsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Tag - /CreateVirtualGateway: - description: 'Creates a virtual gateway.
- - A virtual gateway is the access point on the Net side of a VPN connection.' - post: - operationId: CreateVirtualGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVirtualGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVirtualGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /CreateVms: - description: 'Creates new virtual machines (VMs), and then launches them.
- - This action enables you to create a specified number of VMs using an Outscale machine image (OMI) that you are allowed to use, and then to automatically launch them.
- - The VMs remain in the `pending` state until they are created and ready to be used. Once automatically launched, they are in the `running` state.
- - To check the state of your VMs, call the [ReadVms](#readvms) method.
- - If not specified, the security group used by the service is the default one.
- - The metadata server enables you to get the public key provided when the VM is launched. Official OMIs contain a script to get this public key and put it inside the VM to provide secure access without password.' - post: - operationId: CreateVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /CreateVolume: - description: 'Creates a Block Storage Unit (BSU) volume in a specified Region.
- - BSU volumes can be attached to a virtual machine (VM) in the same Subregion. You can create a new empty volume or restore a volume from an existing snapshot.
- - You can create the following volume types: Enterprise (`io1`) for provisioned IOPS SSD volumes, Performance (`gp2`) for general purpose SSD volumes, or Magnetic (`standard`) volumes.' - post: - operationId: CreateVolume - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVolumeRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVolumeResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Volume - /CreateVpnConnection: - description: 'Creates a VPN connection between a specified virtual gateway and a specified client gateway.
- - You can create only one VPN connection between a virtual gateway and a client gateway.' - post: - operationId: CreateVpnConnection - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVpnConnectionRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVpnConnectionResponse' - description: The HTTP 200 response (OK). - tags: - - VpnConnection - /CreateVpnConnectionRoute: - description: 'Creates a static route to a VPN connection.
- - This enables you to select the network flows sent by the virtual gateway to the target VPN connection.' - post: - operationId: CreateVpnConnectionRoute - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVpnConnectionRouteRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/CreateVpnConnectionRouteResponse' - description: The HTTP 200 response (OK). - tags: - - VpnConnection - /DeleteAccessKey: - description: 'Deletes the specified access key associated with the account that sends the request.

- - - **[NOTE]**
- - To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.' - post: - operationId: DeleteAccessKey - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteAccessKeyRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteAccessKeyResponse' - description: Information about the response. - tags: - - AccessKey - /DeleteClientGateway: - description: 'Deletes a client gateway.
- - You must delete the VPN connection before deleting the client gateway.' - post: - operationId: DeleteClientGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteClientGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteClientGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - ClientGateway - /DeleteDhcpOptions: - description: 'Deletes a specified DHCP options set.
- - Before deleting a DHCP options set, you must disassociate it from the Nets you associated it with. To do so, you need to associate with each Net a new set of DHCP options, or the `default` one if you do not want to associate any DHCP options with the Net.

- - - **[NOTE]**
- - You cannot delete the `default` set.' - post: - operationId: DeleteDhcpOptions - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDhcpOptionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDhcpOptionsResponse' - description: The HTTP 200 response (OK). - tags: - - DhcpOption - /DeleteDirectLink: - description: 'Deletes a specified DirectLink.
- - Before deleting a DirectLink, ensure that all your DirectLink interfaces related to this DirectLink are deleted.' - post: - operationId: DeleteDirectLink - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDirectLinkRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDirectLinkResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLink - /DeleteDirectLinkInterface: - description: Deletes a specified DirectLink interface. - post: - operationId: DeleteDirectLinkInterface - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDirectLinkInterfaceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteDirectLinkInterfaceResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLinkInterface - /DeleteExportTask: - description: 'Deletes an export task.
- - If the export task is not running, the command fails and an error is returned.' - post: - operationId: DeleteExportTask - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteExportTaskRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteExportTaskResponse' - description: The HTTP 200 response (OK). - tags: - - Task - /DeleteFlexibleGpu: - description: 'Releases a flexible GPU (fGPU) from your account.
- - The fGPU becomes free to be used by someone else.' - post: - operationId: DeleteFlexibleGpu - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteFlexibleGpuRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteFlexibleGpuResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /DeleteImage: - description: Deletes an Outscale machine image (OMI) so that you cannot use it anymore to launch virtual machines (VMs). However, you can still use VMs already launched from this OMI. - post: - operationId: DeleteImage - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteImageRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteImageResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Image - /DeleteInternetService: - description: 'Deletes an Internet service.
- - Before deleting an Internet service, you must detach it from any Net it is attached to.' - post: - operationId: DeleteInternetService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteInternetServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteInternetServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - InternetService - /DeleteKeypair: - description: 'Deletes the specified keypair.
- - This action deletes the public key stored by 3DS OUTSCALE, thus deleting the keypair.' - post: - operationId: DeleteKeypair - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteKeypairRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteKeypairResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Keypair - /DeleteListenerRule: - description: 'Deletes a listener rule.
- - The previously active rule is disabled after deletion.' - post: - operationId: DeleteListenerRule - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteListenerRuleRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteListenerRuleResponse' - description: Information about the response. - tags: - - Listener - /DeleteLoadBalancer: - description: Deletes a specified load balancer. - post: - operationId: DeleteLoadBalancer - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /DeleteLoadBalancerListeners: - description: Deletes listeners of a specified load balancer. - post: - operationId: DeleteLoadBalancerListeners - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerListenersRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerListenersResponse' - description: The HTTP 200 response (OK). - tags: - - Listener - /DeleteLoadBalancerPolicy: - description: 'Deletes a specified policy from a load balancer.
- - In order to be deleted, the policy must not be enabled for any listener.' - post: - operationId: DeleteLoadBalancerPolicy - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerPolicyRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerPolicyResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancerPolicy - /DeleteLoadBalancerTags: - description: Deletes one or more tags from the specified load balancers. - post: - operationId: DeleteLoadBalancerTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteLoadBalancerTagsResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /DeleteNatService: - description: 'Deletes a specified network address translation (NAT) service.
- - This action disassociates the External IP address (EIP) from the NAT service, but does not release this EIP from your account. However, it does not delete any NAT service routes in your route tables.' - post: - operationId: DeleteNatService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNatServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNatServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NatService - /DeleteNet: - description: 'Deletes a specified Net.
- - Before deleting the Net, you need to delete or detach all the resources associated with the Net:

- - - * Virtual machines (VMs)
- - * Net peering connections
- - * Custom route tables
- - * External IP addresses (EIPs) allocated to resources in the Net
- - * Network Interface Cards (NICs) created in the Subnets
- - * Virtual gateways, Internet services and NAT services
- - * Load balancers
- - * Security groups
- - * Subnets' - post: - operationId: DeleteNet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Net - /DeleteNetAccessPoint: - description: 'Deletes one or more Net access point.
- - This action also deletes the corresponding routes added to the route tables you specified for the Net access point.' - post: - operationId: DeleteNetAccessPoint - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetAccessPointRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetAccessPointResponse' - description: The HTTP 200 response (OK). - tags: - - NetAccessPoint - /DeleteNetPeering: - description: 'Deletes a Net peering connection.
- - If the Net peering connection is in the `active` state, it can be deleted either by the owner of the requester Net or the owner of the peer Net.
- - If it is in the `pending-acceptance` state, it can be deleted only by the owner of the requester Net.
- - If it is in the `rejected`, `failed`, or `expired` states, it cannot be deleted.' - post: - operationId: DeleteNetPeering - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetPeeringRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNetPeeringResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NetPeering - /DeleteNic: - description: 'Deletes the specified network interface card (NIC).
- - The network interface must not be attached to any virtual machine (VM).' - post: - operationId: DeleteNic - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNicRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteNicResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /DeletePublicIp: - description: 'Releases an External IP address (EIP).
- - You can release an EIP associated with your account. This address is released in the EIP pool and can be used by someone else. Before releasing an EIP, ensure you updated all your resources communicating with this address.' - post: - operationId: DeletePublicIp - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeletePublicIpRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeletePublicIpResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - PublicIp - /DeleteRoute: - description: Deletes a route from a specified route table. - post: - operationId: DeleteRoute - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteRouteRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteRouteResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Route - /DeleteRouteTable: - description: 'Deletes a specified route table.
- - Before deleting a route table, you must disassociate it from any Subnet. You cannot delete the main route table.' - post: - operationId: DeleteRouteTable - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteRouteTableRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteRouteTableResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - RouteTable - /DeleteSecurityGroup: - description: 'Deletes a specified security group.
- - You can specify either the name of the security group or its ID.
- - This action fails if the specified group is associated with a virtual machine (VM) or referenced by another security group.' - post: - operationId: DeleteSecurityGroup - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSecurityGroupRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSecurityGroupResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - SecurityGroup - /DeleteSecurityGroupRule: - description: 'Deletes one or more inbound or outbound rules from a security group. For the rule to be deleted, the values specified in the deletion request must exactly match the value of the existing rule.
- - In case of TCP and UDP protocols, you have to indicate the destination port or range of ports. In case of ICMP protocol, you have to specify the ICMP type and code.
- - Rules (IP permissions) consist of the protocol, IP address range or source security group.
- - To remove outbound access to a destination security group, we recommend to use a set of IP permissions. We also recommend to specify the protocol in a set of IP permissions.' - post: - operationId: DeleteSecurityGroupRule - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSecurityGroupRuleRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSecurityGroupRuleResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - SecurityGroupRule - /DeleteServerCertificate: - description: Deletes a specified server certificate. - post: - operationId: DeleteServerCertificate - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteServerCertificateRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteServerCertificateResponse' - description: Informaton about the response. - tags: - - ServerCertificate - /DeleteSnapshot: - description: 'Deletes a specified snapshot.
- - You cannot delete a snapshot that is currently used by an Outscale machine image (OMI). To do so, you first need to delete the corresponding OMI. For more information, see the [DeleteImage](#deleteimage) method.' - post: - operationId: DeleteSnapshot - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSnapshotRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSnapshotResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Snapshot - /DeleteSubnet: - description: 'Deletes a specified Subnet.
- - You must terminate all the running virtual machines (VMs) in the Subnet before deleting it.' - post: - operationId: DeleteSubnet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSubnetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteSubnetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Subnet - /DeleteTags: - description: Deletes one or more tags from the specified resources. - post: - operationId: DeleteTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteTagsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Tag - /DeleteVirtualGateway: - description: 'Deletes a specified virtual gateway.
- - Before deleting a virtual gateway, we recommend to detach it from the Net and delete the VPN connection.' - post: - operationId: DeleteVirtualGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVirtualGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVirtualGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /DeleteVms: - description: 'Performs a shut down for at least one virtual machine (VM).
- - This operation is idempotent, that means that all calls succeed if you terminate a VM more than once.' - post: - operationId: DeleteVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /DeleteVolume: - description: 'Deletes a specified Block Storage Unit (BSU) volume.
- - You can delete available volumes only, that is, volumes that are not attached to a virtual machine (VM).' - post: - operationId: DeleteVolume - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVolumeRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVolumeResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Volume - /DeleteVpnConnection: - description: 'Deletes a specified VPN connection.
- - If you want to delete a Net and all its dependencies, we recommend to detach the virtual gateway from the Net and delete the Net before deleting the VPN connection. This enables you to delete the Net without waiting for the VPN connection to be deleted.' - post: - operationId: DeleteVpnConnection - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVpnConnectionRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVpnConnectionResponse' - description: The HTTP 200 response (OK). - tags: - - VpnConnection - /DeleteVpnConnectionRoute: - description: Deletes a static route to a VPN connection previously created using the CreateVpnConnectionRoute method. - post: - operationId: DeleteVpnConnectionRoute - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVpnConnectionRouteRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeleteVpnConnectionRouteResponse' - description: The HTTP 200 response (OK). - tags: - - VpnConnection - /DeregisterVmsInLoadBalancer: - description: Deregisters a specified virtual machine (VM) from a load balancer. - post: - operationId: DeregisterVmsInLoadBalancer - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/DeregisterVmsInLoadBalancerRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/DeregisterVmsInLoadBalancerResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /LinkFlexibleGpu: - description: 'Attaches one of your allocated flexible GPUs (fGPUs) to one of your virtual machines (VMs).
- - The fGPU is in the `attaching` state until the VM is stopped, after which it becomes `attached`.' - post: - operationId: LinkFlexibleGpu - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkFlexibleGpuRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkFlexibleGpuResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /LinkInternetService: - description: 'Attaches an Internet service to a Net.
- - To enable the connection between the Internet and a Net, you must attach an Internet service to this Net.' - post: - operationId: LinkInternetService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkInternetServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkInternetServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - InternetService - /LinkNic: - description: 'Attaches a network interface card (NIC) to a virtual machine (VM).
- - The interface and the VM must be in the same Subregion. The VM can be either `running` or `stopped`. The NIC must be in the `available` state.' - post: - operationId: LinkNic - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkNicRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkNicResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /LinkPrivateIps: - description: Assigns one or more secondary private IP addresses to a specified network interface card (NIC). This action is only available in a Net. The private IP addresses to be assigned can be added individually using the `PrivateIps` parameter, or you can specify the number of private IP addresses to be automatically chosen within the Subnet range using the `SecondaryPrivateIpCount` parameter. You can specify only one of these two parameters. If none of these parameters are specified, a private IP address is chosen within the Subnet range. - post: - operationId: LinkPrivateIps - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkPrivateIpsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkPrivateIpsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /LinkPublicIp: - description: 'Associates an External IP address (EIP) with a virtual machine (VM) or a network interface card (NIC), in the public Cloud or in a Net. You can associate an EIP with only one VM or network interface at a time.
- - To associate an EIP in a Net, ensure that the Net has an Internet service attached. For more information, see the [LinkInternetService](#linkinternetservice) method.
- - By default, the EIP is disassociated every time you stop and start the VM. For a persistent association, you can add the `osc.fcu.eip.auto-attach` tag to the VM with the EIP as value. For more information, see the [CreateTags](#createtags) method.

- - - **[NOTE]**
- - You can associate an EIP with a network address translation (NAT) service only when creating the NAT service. To modify its EIP, you need to delete the NAT service and re-create it with the new EIP. For more information, see the [CreateNatService](#createnatservice) method.' - post: - operationId: LinkPublicIp - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkPublicIpRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkPublicIpResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - PublicIp - /LinkRouteTable: - description: 'Associates a Subnet with a route table.
- - The Subnet and the route table must be in the same Net. The traffic is routed according to the route table defined within this Net. You can associate a route table with several Subnets.' - post: - operationId: LinkRouteTable - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkRouteTableRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkRouteTableResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - RouteTable - /LinkVirtualGateway: - description: Attaches a virtual gateway to a Net. - post: - operationId: LinkVirtualGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkVirtualGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkVirtualGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /LinkVolume: - description: 'Attaches a Block Storage Unit (BSU) volume to a virtual machine (VM).
- - The volume and the VM must be in the same Subregion. The VM can be running or stopped. The volume is attached to the specified VM device.' - post: - operationId: LinkVolume - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/LinkVolumeRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/LinkVolumeResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Volume - /ReadAccessKeys: - description: 'Returns information about the access key IDs of a specified user.
- - If the user does not have any access key ID, this action returns an empty list.' - post: - operationId: ReadAccessKeys - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAccessKeysRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAccessKeysResponse' - description: Information about the response. - tags: - - AccessKey - /ReadAccounts: - description: Gets information about the account that sent the request. - post: - operationId: ReadAccounts - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAccountsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAccountsResponse' - description: Information about the response. - tags: - - Account - /ReadAdminPassword: - description: 'Retrieves the administrator password for a Windows running virtual machine (VM).
- - The administrator password is encrypted using the keypair you specified when launching the VM.

- - - **[NOTE]**
- - The administrator password is generated only on the first boot of the Windows VM. It is not returned after the first boot.' - post: - operationId: ReadAdminPassword - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAdminPasswordRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadAdminPasswordResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /ReadApiLogs: - description: Retrieves your API logs. Only the logs of the calls made during the last 30 days can be retrieved through this method. You can use filters to retrieve specific logs. You can also specify the information to be displayed in the logs. - post: - operationId: ReadApiLogs - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadApiLogsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadApiLogsResponse' - description: The HTTP 200 response (OK). - tags: - - ApiLog - /ReadClientGateways: - description: 'Describes one or more of your client gateways.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadClientGateways - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadClientGatewaysRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadClientGatewaysResponse' - description: The HTTP 200 response (OK). - tags: - - ClientGateway - /ReadConsoleOutput: - description: 'Gets the console output for a virtual machine (VM). This console provides the most recent 64 KiB output.

- - - **[NOTE]**
- - On Windows VMs, the console is handled only on the first boot. It returns no output after the first boot.' - post: - operationId: ReadConsoleOutput - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadConsoleOutputRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadConsoleOutputResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /ReadConsumptionAccount: - description: 'Displays information about the consumption of your account for each billable resource within the specified time period.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadConsumptionAccount - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadConsumptionAccountRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadConsumptionAccountResponse' - description: Information about the response. - /ReadDhcpOptions: - description: 'Retrieves information about the content of one or more DHCP options sets.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadDhcpOptions - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDhcpOptionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDhcpOptionsResponse' - description: The HTTP 200 response (OK). - tags: - - DhcpOption - /ReadDirectLinkInterfaces: - description: 'Lists one or more of your DirectLink interfaces.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadDirectLinkInterfaces - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDirectLinkInterfacesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDirectLinkInterfacesResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLinkInterface - /ReadDirectLinks: - description: 'Lists all DirectLinks in the Region.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadDirectLinks - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDirectLinksRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadDirectLinksResponse' - description: The HTTP 200 response (OK). - tags: - - DirectLink - /ReadFlexibleGpuCatalog: - description: 'Lists all flexible GPUs available in the public catalog.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadFlexibleGpuCatalog - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadFlexibleGpuCatalogRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadFlexibleGpuCatalogResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - FlexibleGpu - /ReadFlexibleGpus: - description: 'Lists one or more flexible GPUs (fGPUs) allocated to your account.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadFlexibleGpus - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadFlexibleGpusRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadFlexibleGpusResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /ReadImageExportTasks: - description: 'Lists one or more image export tasks.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadImageExportTasks - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadImageExportTasksRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadImageExportTasksResponse' - description: The HTTP 200 response (OK). - tags: - - Image - /ReadImages: - description: 'Lists one or more Outscale machine images (OMIs) you can use.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadImages - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadImagesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadImagesResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Image - /ReadInternetServices: - description: 'Lists one or more of your Internet services.
- - An Internet service enables your virtual machines (VMs) launched in a Net to connect to the Internet. By default, a Net includes an Internet service, and each Subnet is public. Every VM launched within a default Subnet has a private and a public IP addresses.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadInternetServices - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadInternetServicesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadInternetServicesResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - InternetService - /ReadKeypairs: - description: 'Lists one or more of your keypairs.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadKeypairs - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadKeypairsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadKeypairsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Keypair - /ReadListenerRules: - description: Describes one or more listener rules. By default, this action returns the full list of listener rules for the account. - post: - operationId: ReadListenerRules - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadListenerRulesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadListenerRulesResponse' - description: Information about the response. - tags: - - Listener - /ReadLoadBalancerTags: - description: 'Describes the tags associated with one or more specified load balancers.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadLoadBalancerTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLoadBalancerTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLoadBalancerTagsResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /ReadLoadBalancers: - description: 'Lists one or more load balancers and their attributes.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadLoadBalancers - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLoadBalancersRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLoadBalancersResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /ReadLocations: - description: 'Lists the locations, corresponding to datacenters, where you can set up a DirectLink.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadLocations - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLocationsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadLocationsResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - Location - /ReadNatServices: - description: 'Lists one or more network address translation (NAT) services.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNatServices - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNatServicesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNatServicesResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NatService - /ReadNetAccessPointServices: - description: 'Describes 3DS OUTSCALE services available to create Net access points.
- - For more information, see [CreateNetAccessPoint](#createnetaccesspoint).

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNetAccessPointServices - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetAccessPointServicesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetAccessPointServicesResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - NetAccessPoint - /ReadNetAccessPoints: - description: 'Describes one or more Net access points.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNetAccessPoints - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetAccessPointsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetAccessPointsResponse' - description: The HTTP 200 response (OK). - tags: - - NetAccessPoint - /ReadNetPeerings: - description: 'Lists one or more peering connections between two Nets.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNetPeerings - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetPeeringsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetPeeringsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NetPeering - /ReadNets: - description: 'Lists one or more Nets.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNets - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNetsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Net - /ReadNics: - description: 'Lists one or more network interface cards (NICs).
- - A NIC is a virtual network interface that you can attach to a virtual machine (VM) in a Net.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadNics - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNicsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadNicsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /ReadProductTypes: - description: 'Describes one or more product types.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadProductTypes - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadProductTypesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadProductTypesResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - ProductType - /ReadPublicIpRanges: - description: Returns the public IPv4 addresses in CIDR notation for the Region specified in the endpoint of the request. For more information, see [Regions, Endpoints and Availability Zones Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). - post: - operationId: ReadPublicIpRanges - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadPublicIpRangesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadPublicIpRangesResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - PublicIp - /ReadPublicIps: - description: 'Lists one or more External IP addresses (EIPs) allocated to your account.
- - By default, this action returns information about all your EIPs: available, associated with a virtual machine (VM) or network interface card (NIC), or used for a NAT service.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadPublicIps - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadPublicIpsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadPublicIpsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - PublicIp - /ReadQuotas: - description: 'Describes one or more of your quotas.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadQuotas - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadQuotasRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadQuotasResponse' - description: The HTTP 200 response (OK). - tags: - - Quota - /ReadRegions: - description: Describes one or more Regions of the 3DS OUTSCALE Cloud. - post: - operationId: ReadRegions - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadRegionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadRegionsResponse' - description: Information about the response. - tags: - - Region - /ReadRouteTables: - description: 'Lists one or more of your route tables.
- - In your Net, each Subnet must be associated with a route table. If a Subnet is not explicitly associated with a route table, it is implicitly associated with the main route table of the Net.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadRouteTables - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadRouteTablesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadRouteTablesResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - RouteTable - /ReadSecretAccessKey: - description: Gets information about the secret access key associated with the account that sends the request. - post: - operationId: ReadSecretAccessKey - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSecretAccessKeyRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSecretAccessKeyResponse' - description: Information about the response. - tags: - - AccessKey - /ReadSecurityGroups: - description: 'Lists one or more security groups.
- - You can specify either the name of the security groups or their IDs.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadSecurityGroups - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSecurityGroupsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSecurityGroupsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - SecurityGroup - /ReadServerCertificates: - description: List your server certificates. - post: - operationId: ReadServerCertificates - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadServerCertificatesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadServerCertificatesResponse' - description: Information about the response. - tags: - - ServerCertificate - /ReadSnapshotExportTasks: - description: 'Lists one or more snapshot export tasks.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadSnapshotExportTasks - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSnapshotExportTasksRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSnapshotExportTasksResponse' - description: The HTTP 200 response (OK). - tags: - - Snapshot - /ReadSnapshots: - description: 'Lists one or more snapshots that are available to you and the permissions to create volumes from them.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadSnapshots - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSnapshotsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSnapshotsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Snapshot - /ReadSubnets: - description: 'Lists one or more of your Subnets.
- - If you do not specify any Subnet ID, this action describes all of your Subnets.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadSubnets - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSubnetsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSubnetsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Subnet - /ReadSubregions: - description: 'Lists one or more of the enabled Subregions that you can access in the current Region.

- - - **[NOTE]**
- - - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.
- - - You can use this command to get information about Subregions only in a Region for which you have an account. Otherwise, the `AuthFailure` error message is returned.' - post: - operationId: ReadSubregions - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSubregionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadSubregionsResponse' - description: The HTTP 200 response (OK). - tags: - - Subregion - /ReadTags: - description: 'Lists one or more tags for your resources.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadTags - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadTagsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadTagsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Tag - /ReadVirtualGateways: - description: 'Lists one or more virtual gateways.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVirtualGateways - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVirtualGatewaysRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVirtualGatewaysResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /ReadVmTypes: - description: 'Lists one or more predefined VM types.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVmTypes - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmTypesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmTypesResponse' - description: The HTTP 200 response (OK). - security: [] - tags: - - Vm - /ReadVms: - description: 'Lists one or more of your virtual machines (VMs).
- - If you provide one or more VM IDs, this action returns a description for all of these VMs. If you do not provide any VM ID, this action returns a description for all of the VMs that belong to you. If you provide an invalid VM ID, an error is returned. If you provide the ID of a VM that does not belong to you, the description of this VM is not included in the response. The refresh interval for data returned by this action is one hour, meaning that a terminated VM may appear in the response.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /ReadVmsHealth: - description: 'Lists the state of one or more back-end virtual machines (VMs) registered with a specified load balancer.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `Throttling` error message is returned.' - post: - operationId: ReadVmsHealth - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsHealthRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsHealthResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /ReadVmsState: - description: 'Lists the status of one or more virtual machines (VMs).

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVmsState - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsStateRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVmsStateResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /ReadVolumes: - description: 'Lists one or more specified Block Storage Unit (BSU) volumes.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVolumes - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVolumesRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVolumesResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Volume - /ReadVpnConnections: - description: 'Describes one or more VPN connections.

- - - **[NOTE]**
- - If you exceed the number of identical requests allowed for a configured time period, the `RequestLimitExceeded` error message is returned.' - post: - operationId: ReadVpnConnections - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVpnConnectionsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ReadVpnConnectionsResponse' - description: The HTTP 200 response (OK). - tags: - - VpnConnection - /RebootVms: - description: 'Reboots one or more virtual machines (VMs).
- - This operation sends a reboot request to one or more specified VMs. This is an asynchronous action that queues this reboot request. This action only reboots VMs that are valid and that belong to you.' - post: - operationId: RebootVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/RebootVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/RebootVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /RegisterVmsInLoadBalancer: - description: 'Registers one or more virtual machines (VMs) with a specified load balancer.
- - The VMs must be running in the same network as the load balancer (in the public Cloud or in the same Net). It may take a little time for a VM to be registered with the load balancer. Once the VM is registered with a load balancer, it receives traffic and requests from this load balancer and is called a back-end VM.' - post: - operationId: RegisterVmsInLoadBalancer - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/RegisterVmsInLoadBalancerRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/RegisterVmsInLoadBalancerResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /RejectNetPeering: - description: 'Rejects a Net peering connection request.
- - The Net peering connection must be in the `pending-acceptance` state to be rejected. The rejected Net peering connection is then in the `rejected` state.' - post: - operationId: RejectNetPeering - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/RejectNetPeeringRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/RejectNetPeeringResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '409': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 409 response (Conflict). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - NetPeering - /ResetAccountPassword: - description: 'Replaces the account password with the new one you provide.
- - You must also provide the token you received by email when asking for a password reset using the SendResetPasswordEmail method.

- - Password strength is tested through heuristic algorithms. For more information, see the [zxcvbn GitHub](https://github.com/dropbox/zxcvbn).

- - **[NOTE]**
- - To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.' - post: - operationId: ResetAccountPassword - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/ResetAccountPasswordRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/ResetAccountPasswordResponse' - description: Information about the response. - tags: - - Account - /SendResetPasswordEmail: - description: 'Sends an email to the email address provided for the account with a token to reset your password.
- - You need to provide this token when updating the account password using the ResetAccountPassword method.

- - **[NOTE]**
- - To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.' - post: - operationId: SendResetPasswordEmail - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/SendResetPasswordEmailRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/SendResetPasswordEmailResponse' - description: Information about the response.You need to provide this token when updating the account password using the ResetAccountPassword method. - tags: - - Account - /StartVms: - description: 'Start one or more virtual machines (VMs).
- - You can start only VMs that are valid and that belong to you.' - post: - operationId: StartVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/StartVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/StartVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /StopVms: - description: 'Stops one or more running virtual machines (VMs).
- - You can stop only VMs that are valid and that belong to you. Data stored in the VM RAM is lost.' - post: - operationId: StopVms - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/StopVmsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/StopVmsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm - /UnlinkFlexibleGpu: - description: 'Detaches a flexible GPU (fGPU) from a virtual machine (VM).
- - The fGPU is in the `detaching` state until the VM is stopped, after which it becomes available for allocation again.' - post: - operationId: UnlinkFlexibleGpu - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkFlexibleGpuRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkFlexibleGpuResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /UnlinkInternetService: - description: 'Detaches an Internet service from a Net.
- - This action disables and detaches an Internet service from a Net. The Net must not contain any running virtual machine (VM) using an External IP address (EIP).' - post: - operationId: UnlinkInternetService - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkInternetServiceRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkInternetServiceResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - InternetService - /UnlinkNic: - description: 'Detaches a network interface card (NIC) from a virtual machine (VM).
- - The primary NIC cannot be detached.' - post: - operationId: UnlinkNic - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkNicRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkNicResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /UnlinkPrivateIps: - description: Unassigns one or more secondary private IPs from a network interface card (NIC). - post: - operationId: UnlinkPrivateIps - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkPrivateIpsRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkPrivateIpsResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /UnlinkPublicIp: - description: 'Disassociates an External IP address (EIP) from the virtual machine (VM) or network interface card (NIC) it is associated with.

- - - **[NOTE]**
- - To disassociate a Public IP from a NAT service, you need to delete the NAT service. For more information, see the [DeleteNatGateway](#deletenatgateway) method.' - post: - operationId: UnlinkPublicIp - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkPublicIpRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkPublicIpResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - PublicIp - /UnlinkRouteTable: - description: 'Disassociates a Subnet from a route table.
- - After disassociation, the Subnet can no longer use the routes in this route table, but uses the routes in the main route table of the Net instead.' - post: - operationId: UnlinkRouteTable - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkRouteTableRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkRouteTableResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - RouteTable - /UnlinkVirtualGateway: - description: 'Detaches a virtual gateway from a Net.
- - You must wait until the virtual gateway is in the detached state before you can attach another Net to it or delete the Net it was previously attached to.' - post: - operationId: UnlinkVirtualGateway - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkVirtualGatewayRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkVirtualGatewayResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /UnlinkVolume: - description: 'Detaches a Block Storage Unit (BSU) volume from a virtual machine (VM).
- - To detach the root device of a VM, this VM must be stopped.' - post: - operationId: UnlinkVolume - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkVolumeRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UnlinkVolumeResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Volume - /UpdateAccessKey: - description: 'Modifies the status of the specified access key associated with the account that sends the request.
- - When set to `active`, the access key is enabled and can be used to send requests. When set to `inactive`, the access key is disabled.

- - - **[NOTE]**
- - To protect against brute force attacks, the number of requests allowed for this method in a given time period is limited.' - post: - operationId: UpdateAccessKey - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateAccessKeyRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateAccessKeyResponse' - description: Information about the response. - tags: - - AccessKey - /UpdateAccount: - description: Updates the account information for the account that sends the request. - post: - operationId: UpdateAccount - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateAccountRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateAccountResponse' - description: Information about the response. - tags: - - Account - /UpdateFlexibleGpu: - description: Modifies a flexible GPU (fGPU) behavior. - post: - operationId: UpdateFlexibleGpu - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateFlexibleGpuRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateFlexibleGpuResponse' - description: The HTTP 200 response (OK). - tags: - - FlexibleGpu - /UpdateImage: - description: 'Modifies the specified attribute of an Outscale machine image (OMI).
- - You can specify only one attribute at a time. You can modify the permissions to access the OMI by adding or removing account IDs or groups. You can share an OMI with a user that is in the same Region. The user can create a copy of the OMI you shared, obtaining all the rights for the copy of the OMI. For more information, see [CreateImage](#createimage).' - post: - operationId: UpdateImage - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateImageRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateImageResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Image - /UpdateListenerRule: - description: 'Updates the pattern of the listener rule.
- - This call updates the pattern matching algorithm for incoming traffic.' - post: - operationId: UpdateListenerRule - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateListenerRuleRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateListenerRuleResponse' - description: Information about the response. - tags: - - Listener - /UpdateLoadBalancer: - description: 'Modifies the specified attributes of a load balancer.

- - - You can set a new SSL certificate to an SSL or HTTPS listener of a load balancer.
- - This certificate replaces any certificate used on the same load balancer and port.

- - - You can also replace the current set of policies for a load balancer with another specified one.
- - If the `PolicyNames` parameter is empty, all current policies are disabled.' - post: - operationId: UpdateLoadBalancer - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateLoadBalancerRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateLoadBalancerResponse' - description: The HTTP 200 response (OK). - tags: - - LoadBalancer - /UpdateNet: - description: Associates a DHCP options set with a specified Net. - post: - operationId: UpdateNet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Net - /UpdateNetAccessPoint: - description: 'Modifies the attributes of a Net access point.
- - This action enables you to add or remove route tables associated with the specified Net access point.' - post: - operationId: UpdateNetAccessPoint - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNetAccessPointRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNetAccessPointResponse' - description: The HTTP 200 response (OK). - tags: - - NetAccessPoint - /UpdateNic: - description: Modifies the specified network interface card (NIC). You can specify only one attribute at a time. - post: - operationId: UpdateNic - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNicRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateNicResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Nic - /UpdateRoute: - description: 'Replaces an existing route within a route table in a Net.
- - You must specify one of the following elements as the target:

- - - * Net peering connection
- - * NAT virtual machine (VM)
- - * Internet service
- - * Virtual gateway
- - * NAT service
- - * Network interface card (NIC)

- - - The routing algorithm is based on the most specific match.' - post: - operationId: UpdateRoute - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateRouteRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateRouteResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Route - /UpdateRoutePropagation: - description: Configures the propagation of routes to a specified route table of a Net by a virtual gateway. - post: - operationId: UpdateRoutePropagation - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateRoutePropagationRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateRoutePropagationResponse' - description: The HTTP 200 response (OK). - tags: - - VirtualGateway - /UpdateServerCertificate: - description: Modifies the name and/or the path of a specified server certificate. - post: - operationId: UpdateServerCertificate - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateServerCertificateRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateServerCertificateResponse' - description: Information about the response. - tags: - - ServerCertificate - /UpdateSnapshot: - description: 'Modifies the permissions for a specified snapshot.
- - You can add or remove permissions for specified account IDs or groups. You can share a snapshot with a user that is in the same Region. The user can create a copy of the snapshot you shared, obtaining all the rights for the copy of the snapshot.' - post: - operationId: UpdateSnapshot - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateSnapshotRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateSnapshotResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Snapshot - /UpdateSubnet: - description: Modifies the specified attribute of a Subnet. - post: - operationId: UpdateSubnet - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateSubnetRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateSubnetResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Subnet - /UpdateVm: - description: 'Modifies a specific attribute of a virtual machine (VM).
- - You can modify only one attribute at a time. You can modify the `IsSourceDestChecked` attribute only if the VM is in a Net.
- - You must stop the VM before modifying the following attributes:

- - - * `VmType`
- - * `UserData`
- - * `BsuOptimized`' - post: - operationId: UpdateVm - requestBody: - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateVmRequest' - responses: - '200': - content: - application/json: - schema: - $ref: '#/components/schemas/UpdateVmResponse' - description: The HTTP 200 response (OK). - '400': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 400 response (Bad Request). - '401': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 401 response (Unauthorized). - '500': - content: - application/json: - schema: - $ref: '#/components/schemas/ErrorResponse' - description: The HTTP 500 response (Internal Server Error). - tags: - - Vm -security: -- ApiKeyAuth: [] -servers: -- url: https://api.{region}.outscale.com/api/v1 - variables: - region: - default: eu-west-2 - enum: - - eu-west-2 - - us-east-2 - - us-west-1 -- url: https://api.{region}.outscale.hk/api/v1 - variables: - region: - default: cn-southeast-1 - enum: - - cn-southeast-1 diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/response.go b/vendor/github.com/marinsalinas/osc-sdk-go/response.go deleted file mode 100644 index d0508ce82..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/response.go +++ /dev/null @@ -1,47 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "net/http" -) - -// APIResponse stores the API response returned by the server. -type APIResponse struct { - *http.Response `json:"-"` - Message string `json:"message,omitempty"` - // Operation is the name of the OpenAPI operation. - Operation string `json:"operation,omitempty"` - // RequestURL is the request URL. This value is always available, even if the - // embedded *http.Response is nil. - RequestURL string `json:"url,omitempty"` - // Method is the HTTP method used for the request. This value is always - // available, even if the embedded *http.Response is nil. - Method string `json:"method,omitempty"` - // Payload holds the contents of the response body (which may be nil or empty). - // This is provided here as the raw response.Body() reader will have already - // been drained. - Payload []byte `json:"-"` -} - -// NewAPIResponse returns a new APIResonse object. -func NewAPIResponse(r *http.Response) *APIResponse { - - response := &APIResponse{Response: r} - return response -} - -// NewAPIResponseWithError returns a new APIResponse object with the provided error message. -func NewAPIResponseWithError(errorMessage string) *APIResponse { - - response := &APIResponse{Message: errorMessage} - return response -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/transport.go b/vendor/github.com/marinsalinas/osc-sdk-go/transport.go deleted file mode 100644 index 498576d9d..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/transport.go +++ /dev/null @@ -1,57 +0,0 @@ -package oscgo - -import ( - "io/ioutil" - "net/http" - "strings" - "time" - - "github.com/aws/aws-sdk-go/aws/credentials" - v4 "github.com/aws/aws-sdk-go/aws/signer/v4" -) - -type transport struct { - transport http.RoundTripper - signer *v4.Signer - region string -} - -func (t *transport) sign(req *http.Request, body []byte) error { - reader := strings.NewReader(string(body)) - timestamp := time.Now() - _, err := t.signer.Sign(req, reader, "oapi", t.region, timestamp) - return err -} - -func (t *transport) RoundTrip(req *http.Request) (*http.Response, error) { - //Get the body - getBody := req.GetBody - copyBody, err := getBody() - if err != nil { - return nil, err - } - - body, err := ioutil.ReadAll(copyBody) - if err != nil { - return nil, err - } - - if err := t.sign(req, body); err != nil { - return nil, err - } - - resp, err := t.transport.RoundTrip(req) - if err != nil { - return resp, err - } - - return resp, nil -} - -func NewTransport(accessKey, accessSecret, region string, t http.RoundTripper) *transport { - s := &v4.Signer{ - Credentials: credentials.NewStaticCredentials(accessKey, - accessSecret, ""), - } - return &transport{t, s, region} -} diff --git a/vendor/github.com/marinsalinas/osc-sdk-go/utils.go b/vendor/github.com/marinsalinas/osc-sdk-go/utils.go deleted file mode 100644 index 97ca0b971..000000000 --- a/vendor/github.com/marinsalinas/osc-sdk-go/utils.go +++ /dev/null @@ -1,244 +0,0 @@ -/* - * 3DS OUTSCALE API - * - * Welcome to the 3DS OUTSCALE's API documentation.

The 3DS OUTSCALE API enables you to manage your resources in the 3DS OUTSCALE Cloud. This documentation describes the different actions available along with code examples.

Note that the 3DS OUTSCALE Cloud is compatible with Amazon Web Services (AWS) APIs, but some resources have different names in AWS than in the 3DS OUTSCALE API. You can find a list of the differences [here](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference).

You can also manage your resources using the [Cockpit](https://wiki.outscale.net/display/EN/About+Cockpit) web interface. - * - * API version: 1.1 - * Contact: support@outscale.com - * Generated by: OpenAPI Generator (https://openapi-generator.tech) - */ - -package oscgo - -import ( - "bytes" - "encoding/json" - "errors" - "time" -) - -var ErrInvalidNullable = errors.New("nullable cannot have non-zero Value and ExplicitNull simultaneously") - -// PtrBool is a helper routine that returns a pointer to given integer value. -func PtrBool(v bool) *bool { return &v } - -// PtrInt is a helper routine that returns a pointer to given integer value. -func PtrInt(v int) *int { return &v } - -// PtrInt32 is a helper routine that returns a pointer to given integer value. -func PtrInt32(v int32) *int32 { return &v } - -// PtrInt64 is a helper routine that returns a pointer to given integer value. -func PtrInt64(v int64) *int64 { return &v } - -// PtrFloat32 is a helper routine that returns a pointer to given float value. -func PtrFloat32(v float32) *float32 { return &v } - -// PtrFloat64 is a helper routine that returns a pointer to given float value. -func PtrFloat64(v float64) *float64 { return &v } - -// PtrString is a helper routine that returns a pointer to given string value. -func PtrString(v string) *string { return &v } - -// PtrTime is helper routine that returns a pointer to given Time value. -func PtrTime(v time.Time) *time.Time { return &v } - -type NullableBool struct { - Value bool - ExplicitNull bool -} - -func (v NullableBool) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableBool) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableInt struct { - Value int - ExplicitNull bool -} - -func (v NullableInt) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != 0: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableInt) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableInt32 struct { - Value int32 - ExplicitNull bool -} - -func (v NullableInt32) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != 0: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableInt32) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableInt64 struct { - Value int64 - ExplicitNull bool -} - -func (v NullableInt64) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != 0: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableInt64) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableFloat32 struct { - Value float32 - ExplicitNull bool -} - -func (v NullableFloat32) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != 0.0: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFloat32) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableFloat64 struct { - Value float64 - ExplicitNull bool -} - -func (v NullableFloat64) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != 0.0: - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableFloat64) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableString struct { - Value string - ExplicitNull bool -} - -func (v NullableString) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && v.Value != "": - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return json.Marshal(v.Value) - } -} - -func (v *NullableString) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} - -type NullableTime struct { - Value time.Time - ExplicitNull bool -} - -func (v NullableTime) MarshalJSON() ([]byte, error) { - switch { - case v.ExplicitNull && !v.Value.IsZero(): - return nil, ErrInvalidNullable - case v.ExplicitNull: - return []byte("null"), nil - default: - return v.Value.MarshalJSON() - } -} - -func (v *NullableTime) UnmarshalJSON(src []byte) error { - if bytes.Equal(src, []byte("null")) { - v.ExplicitNull = true - return nil - } - - return json.Unmarshal(src, &v.Value) -} diff --git a/vendor/modules.txt b/vendor/modules.txt index 7c776e93d..c97d5a8b7 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -8,8 +8,6 @@ cloud.google.com/go/internal/version cloud.google.com/go/storage # github.com/agext/levenshtein v1.2.2 github.com/agext/levenshtein -# github.com/antihax/optional v1.0.0 -github.com/antihax/optional # github.com/apparentlymart/go-cidr v1.0.1 github.com/apparentlymart/go-cidr/cidr # github.com/apparentlymart/go-textseg v1.0.0 @@ -196,8 +194,6 @@ github.com/hashicorp/terraform-svchost/disco github.com/hashicorp/yamux # github.com/jmespath/go-jmespath v0.3.0 github.com/jmespath/go-jmespath -# github.com/marinsalinas/osc-sdk-go v0.0.0-20200616160510-b775d5bdde1a -github.com/marinsalinas/osc-sdk-go # github.com/mattn/go-colorable v0.1.1 github.com/mattn/go-colorable # github.com/mattn/go-isatty v0.0.5 From f1ac49f67b150920ea2241f5f1956484fe9a8cb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Fri, 30 Oct 2020 11:52:09 -0700 Subject: [PATCH 012/218] chore: updated vendor sdk client with tag v2 beta --- go.mod | 3 +-- go.sum | 14 ++------------ outscale/config.go | 2 +- outscale/data_source_outscale_access_key.go | 2 +- outscale/data_source_outscale_access_keys.go | 2 +- outscale/data_source_outscale_client_gateway.go | 2 +- outscale/data_source_outscale_client_gateways.go | 2 +- outscale/data_source_outscale_dhcp_option.go | 2 +- outscale/data_source_outscale_dhcp_options.go | 2 +- outscale/data_source_outscale_image.go | 2 +- outscale/data_source_outscale_images.go | 2 +- outscale/data_source_outscale_internet_service.go | 2 +- outscale/data_source_outscale_internet_services.go | 2 +- outscale/data_source_outscale_keypair.go | 2 +- outscale/data_source_outscale_keypairs.go | 2 +- outscale/data_source_outscale_nat_service.go | 2 +- outscale/data_source_outscale_nat_services.go | 2 +- outscale/data_source_outscale_net.go | 2 +- outscale/data_source_outscale_net_attributes.go | 2 +- outscale/data_source_outscale_net_peering.go | 2 +- outscale/data_source_outscale_net_peerings.go | 2 +- outscale/data_source_outscale_nets.go | 2 +- outscale/data_source_outscale_nic.go | 2 +- outscale/data_source_outscale_nic_test.go | 2 +- outscale/data_source_outscale_nics.go | 2 +- outscale/data_source_outscale_public_ip.go | 2 +- outscale/data_source_outscale_public_ips.go | 2 +- outscale/data_source_outscale_route_table.go | 2 +- outscale/data_source_outscale_route_tables.go | 2 +- outscale/data_source_outscale_security_group.go | 2 +- outscale/data_source_outscale_security_groups.go | 2 +- outscale/data_source_outscale_snapshot.go | 2 +- outscale/data_source_outscale_snapshots.go | 2 +- outscale/data_source_outscale_subnet.go | 2 +- outscale/data_source_outscale_subnets.go | 2 +- outscale/data_source_outscale_tag.go | 2 +- outscale/data_source_outscale_tags.go | 2 +- outscale/data_source_outscale_virtual_gateway.go | 2 +- outscale/data_source_outscale_virtual_gateways.go | 2 +- outscale/data_source_outscale_vm.go | 2 +- outscale/data_source_outscale_vm_state.go | 2 +- outscale/data_source_outscale_vms.go | 2 +- outscale/data_source_outscale_vms_state.go | 2 +- outscale/data_source_outscale_volume.go | 2 +- outscale/data_source_outscale_volumes.go | 2 +- outscale/data_source_outscale_vpn_connection.go | 2 +- outscale/data_source_outscale_vpn_connections.go | 2 +- outscale/instance_set_set.go | 2 +- outscale/oapi_tags.go | 2 +- outscale/resource_outscale_access_key.go | 2 +- outscale/resource_outscale_access_key_test.go | 2 +- outscale/resource_outscale_client_gateway.go | 2 +- outscale/resource_outscale_client_gateway_test.go | 2 +- outscale/resource_outscale_dhcp_option.go | 2 +- outscale/resource_outscale_dhcp_option_test.go | 2 +- outscale/resource_outscale_image.go | 2 +- .../resource_outscale_image_launch_permission.go | 2 +- ...source_outscale_image_launch_permission_test.go | 2 +- outscale/resource_outscale_image_test.go | 2 +- outscale/resource_outscale_internet_service.go | 2 +- .../resource_outscale_internet_service_link.go | 2 +- ...resource_outscale_internet_service_link_test.go | 2 +- .../resource_outscale_internet_service_test.go | 2 +- outscale/resource_outscale_keypair.go | 2 +- outscale/resource_outscale_keypair_test.go | 2 +- outscale/resource_outscale_nat_service.go | 2 +- outscale/resource_outscale_nat_service_test.go | 2 +- outscale/resource_outscale_net.go | 2 +- outscale/resource_outscale_net_attributes.go | 2 +- outscale/resource_outscale_net_peering.go | 2 +- .../resource_outscale_net_peering_acceptation.go | 2 +- outscale/resource_outscale_net_peering_test.go | 2 +- outscale/resource_outscale_net_test.go | 2 +- outscale/resource_outscale_nic.go | 2 +- outscale/resource_outscale_nic_link.go | 2 +- outscale/resource_outscale_nic_link_test.go | 2 +- outscale/resource_outscale_nic_private_ip.go | 2 +- outscale/resource_outscale_nic_private_ip_test.go | 2 +- outscale/resource_outscale_nic_test.go | 2 +- outscale/resource_outscale_public_ip.go | 2 +- outscale/resource_outscale_public_ip_link.go | 2 +- outscale/resource_outscale_public_ip_link_test.go | 2 +- outscale/resource_outscale_public_ip_test.go | 2 +- outscale/resource_outscale_route.go | 2 +- outscale/resource_outscale_route_table.go | 2 +- outscale/resource_outscale_route_table_link.go | 2 +- .../resource_outscale_route_table_link_test.go | 2 +- outscale/resource_outscale_route_table_test.go | 2 +- outscale/resource_outscale_route_test.go | 2 +- outscale/resource_outscale_security_group.go | 2 +- outscale/resource_outscale_security_group_rule.go | 2 +- .../resource_outscale_security_group_rule_test.go | 2 +- outscale/resource_outscale_security_group_test.go | 2 +- outscale/resource_outscale_snapshot.go | 2 +- outscale/resource_outscale_snapshot_attributes.go | 2 +- outscale/resource_outscale_snapshot_test.go | 2 +- outscale/resource_outscale_subnet.go | 2 +- outscale/resource_outscale_subnet_test.go | 2 +- outscale/resource_outscale_tags.go | 2 +- outscale/resource_outscale_tags_test.go | 2 +- outscale/resource_outscale_virtual_gateway.go | 2 +- outscale/resource_outscale_virtual_gateway_link.go | 2 +- .../resource_outscale_virtual_gateway_link_test.go | 2 +- ...e_outscale_virtual_gateway_route_propagation.go | 2 +- ...scale_virtual_gateway_route_propagation_test.go | 2 +- outscale/resource_outscale_virtual_gateway_test.go | 2 +- outscale/resource_outscale_vm.go | 2 +- outscale/resource_outscale_vm_test.go | 2 +- outscale/resource_outscale_volume.go | 2 +- outscale/resource_outscale_volume_test.go | 2 +- outscale/resource_outscale_volumes_link.go | 2 +- outscale/resource_outscale_volumes_link_test.go | 2 +- outscale/resource_outscale_vpn_connection.go | 2 +- outscale/resource_outscale_vpn_connection_route.go | 2 +- .../resource_outscale_vpn_connection_route_test.go | 2 +- outscale/resource_outscale_vpn_connection_test.go | 2 +- utils/utils.go | 2 +- .../outscale/osc-sdk-go/{osc => v2}/.gitignore | 0 .../{osc => v2}/.openapi-generator-ignore | 0 .../outscale/osc-sdk-go/{osc => v2}/.travis.yml | 0 .../outscale/osc-sdk-go/{osc => v2}/README.md | 8 +++++++- .../osc-sdk-go/{osc => v2}/api_access_key.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_account.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_api_log.go | 0 .../osc-sdk-go/{osc => v2}/api_client_gateway.go | 0 .../osc-sdk-go/{osc => v2}/api_dhcp_option.go | 0 .../osc-sdk-go/{osc => v2}/api_direct_link.go | 0 .../{osc => v2}/api_direct_link_interface.go | 0 .../osc-sdk-go/{osc => v2}/api_flexible_gpu.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_image.go | 0 .../osc-sdk-go/{osc => v2}/api_internet_service.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_keypair.go | 0 .../osc-sdk-go/{osc => v2}/api_listener.go | 0 .../osc-sdk-go/{osc => v2}/api_load_balancer.go | 0 .../{osc => v2}/api_load_balancer_policy.go | 0 .../osc-sdk-go/{osc => v2}/api_location.go | 0 .../osc-sdk-go/{osc => v2}/api_nat_service.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_net.go | 0 .../osc-sdk-go/{osc => v2}/api_net_access_point.go | 0 .../osc-sdk-go/{osc => v2}/api_net_peering.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_nic.go | 0 .../osc-sdk-go/{osc => v2}/api_product_type.go | 0 .../osc-sdk-go/{osc => v2}/api_public_ip.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_quota.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_region.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_route.go | 0 .../osc-sdk-go/{osc => v2}/api_route_table.go | 0 .../osc-sdk-go/{osc => v2}/api_security_group.go | 0 .../{osc => v2}/api_security_group_rule.go | 0 .../{osc => v2}/api_server_certificate.go | 0 .../osc-sdk-go/{osc => v2}/api_snapshot.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_subnet.go | 0 .../osc-sdk-go/{osc => v2}/api_subregion.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_tag.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_task.go | 0 .../osc-sdk-go/{osc => v2}/api_virtual_gateway.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_vm.go | 0 .../outscale/osc-sdk-go/{osc => v2}/api_volume.go | 0 .../osc-sdk-go/{osc => v2}/api_vpn_connection.go | 0 .../outscale/osc-sdk-go/{osc => v2}/client.go | 0 .../osc-sdk-go/{osc => v2}/configuration.go | 2 +- .../outscale/osc-sdk-go/{osc => v2}/git_push.sh | 2 +- .../outscale/osc-sdk-go/{osc => v2}/go.mod | 2 +- .../outscale/osc-sdk-go/{osc => v2}/go.sum | 0 .../model_accept_net_peering_request.go | 0 .../model_accept_net_peering_response.go | 0 .../osc-sdk-go/{osc => v2}/model_accepter_net.go | 0 .../osc-sdk-go/{osc => v2}/model_access_key.go | 0 .../{osc => v2}/model_access_key_secret_key.go | 0 .../osc-sdk-go/{osc => v2}/model_access_log.go | 0 .../osc-sdk-go/{osc => v2}/model_account.go | 0 .../model_application_sticky_cookie_policy.go | 0 .../{osc => v2}/model_backend_vm_health.go | 0 .../model_block_device_mapping_created.go | 0 .../model_block_device_mapping_image.go | 0 .../model_block_device_mapping_vm_creation.go | 0 .../model_block_device_mapping_vm_update.go | 0 .../osc-sdk-go/{osc => v2}/model_bsu_created.go | 0 .../osc-sdk-go/{osc => v2}/model_bsu_to_create.go | 0 .../{osc => v2}/model_bsu_to_update_vm.go | 0 .../model_check_authentication_request.go | 0 .../model_check_authentication_response.go | 0 .../osc-sdk-go/{osc => v2}/model_client_gateway.go | 0 .../{osc => v2}/model_consumption_entry.go | 0 .../{osc => v2}/model_create_access_key_request.go | 0 .../model_create_access_key_response.go | 0 .../{osc => v2}/model_create_account_request.go | 0 .../{osc => v2}/model_create_account_response.go | 0 .../model_create_client_gateway_request.go | 0 .../model_create_client_gateway_response.go | 0 .../model_create_dhcp_options_request.go | 0 .../model_create_dhcp_options_response.go | 0 .../model_create_direct_link_interface_request.go | 0 .../model_create_direct_link_interface_response.go | 0 .../model_create_direct_link_request.go | 0 .../model_create_direct_link_response.go | 0 .../model_create_flexible_gpu_request.go | 0 .../model_create_flexible_gpu_response.go | 0 .../model_create_image_export_task_request.go | 0 .../model_create_image_export_task_response.go | 0 .../{osc => v2}/model_create_image_request.go | 0 .../{osc => v2}/model_create_image_response.go | 0 .../model_create_internet_service_request.go | 0 .../model_create_internet_service_response.go | 0 .../{osc => v2}/model_create_keypair_request.go | 0 .../{osc => v2}/model_create_keypair_response.go | 0 .../model_create_listener_rule_request.go | 0 .../model_create_listener_rule_response.go | 0 ...model_create_load_balancer_listeners_request.go | 0 ...odel_create_load_balancer_listeners_response.go | 0 .../model_create_load_balancer_policy_request.go | 0 .../model_create_load_balancer_policy_response.go | 0 .../model_create_load_balancer_request.go | 0 .../model_create_load_balancer_response.go | 0 .../model_create_load_balancer_tags_request.go | 0 .../model_create_load_balancer_tags_response.go | 0 .../model_create_nat_service_request.go | 0 .../model_create_nat_service_response.go | 0 .../model_create_net_access_point_request.go | 0 .../model_create_net_access_point_response.go | 0 .../model_create_net_peering_request.go | 0 .../model_create_net_peering_response.go | 0 .../{osc => v2}/model_create_net_request.go | 0 .../{osc => v2}/model_create_net_response.go | 0 .../{osc => v2}/model_create_nic_request.go | 0 .../{osc => v2}/model_create_nic_response.go | 0 .../{osc => v2}/model_create_public_ip_request.go | 0 .../{osc => v2}/model_create_public_ip_response.go | 0 .../{osc => v2}/model_create_route_request.go | 0 .../{osc => v2}/model_create_route_response.go | 0 .../model_create_route_table_request.go | 0 .../model_create_route_table_response.go | 0 .../model_create_security_group_request.go | 0 .../model_create_security_group_response.go | 0 .../model_create_security_group_rule_request.go | 0 .../model_create_security_group_rule_response.go | 0 .../model_create_server_certificate_request.go | 0 .../model_create_server_certificate_response.go | 0 .../model_create_snapshot_export_task_request.go | 0 .../model_create_snapshot_export_task_response.go | 0 .../{osc => v2}/model_create_snapshot_request.go | 0 .../{osc => v2}/model_create_snapshot_response.go | 0 .../{osc => v2}/model_create_subnet_request.go | 0 .../{osc => v2}/model_create_subnet_response.go | 0 .../{osc => v2}/model_create_tags_request.go | 0 .../{osc => v2}/model_create_tags_response.go | 0 .../model_create_virtual_gateway_request.go | 0 .../model_create_virtual_gateway_response.go | 0 .../{osc => v2}/model_create_vms_request.go | 0 .../{osc => v2}/model_create_vms_response.go | 0 .../{osc => v2}/model_create_volume_request.go | 0 .../{osc => v2}/model_create_volume_response.go | 0 .../model_create_vpn_connection_request.go | 0 .../model_create_vpn_connection_response.go | 0 .../model_create_vpn_connection_route_request.go | 0 .../model_create_vpn_connection_route_response.go | 0 .../{osc => v2}/model_delete_access_key_request.go | 0 .../model_delete_access_key_response.go | 0 .../model_delete_client_gateway_request.go | 0 .../model_delete_client_gateway_response.go | 0 .../model_delete_dhcp_options_request.go | 0 .../model_delete_dhcp_options_response.go | 0 .../model_delete_direct_link_interface_request.go | 0 .../model_delete_direct_link_interface_response.go | 0 .../model_delete_direct_link_request.go | 0 .../model_delete_direct_link_response.go | 0 .../model_delete_export_task_request.go | 0 .../model_delete_export_task_response.go | 0 .../model_delete_flexible_gpu_request.go | 0 .../model_delete_flexible_gpu_response.go | 0 .../{osc => v2}/model_delete_image_request.go | 0 .../{osc => v2}/model_delete_image_response.go | 0 .../model_delete_internet_service_request.go | 0 .../model_delete_internet_service_response.go | 0 .../{osc => v2}/model_delete_keypair_request.go | 0 .../{osc => v2}/model_delete_keypair_response.go | 0 .../model_delete_listener_rule_request.go | 0 .../model_delete_listener_rule_response.go | 0 ...model_delete_load_balancer_listeners_request.go | 0 ...odel_delete_load_balancer_listeners_response.go | 0 .../model_delete_load_balancer_policy_request.go | 0 .../model_delete_load_balancer_policy_response.go | 0 .../model_delete_load_balancer_request.go | 0 .../model_delete_load_balancer_response.go | 0 .../model_delete_load_balancer_tags_request.go | 0 .../model_delete_load_balancer_tags_response.go | 0 .../model_delete_nat_service_request.go | 0 .../model_delete_nat_service_response.go | 0 .../model_delete_net_access_point_request.go | 0 .../model_delete_net_access_point_response.go | 0 .../model_delete_net_peering_request.go | 0 .../model_delete_net_peering_response.go | 0 .../{osc => v2}/model_delete_net_request.go | 0 .../{osc => v2}/model_delete_net_response.go | 0 .../{osc => v2}/model_delete_nic_request.go | 0 .../{osc => v2}/model_delete_nic_response.go | 0 .../{osc => v2}/model_delete_public_ip_request.go | 0 .../{osc => v2}/model_delete_public_ip_response.go | 0 .../{osc => v2}/model_delete_route_request.go | 0 .../{osc => v2}/model_delete_route_response.go | 0 .../model_delete_route_table_request.go | 0 .../model_delete_route_table_response.go | 0 .../model_delete_security_group_request.go | 0 .../model_delete_security_group_response.go | 0 .../model_delete_security_group_rule_request.go | 0 .../model_delete_security_group_rule_response.go | 0 .../model_delete_server_certificate_request.go | 0 .../model_delete_server_certificate_response.go | 0 .../{osc => v2}/model_delete_snapshot_request.go | 0 .../{osc => v2}/model_delete_snapshot_response.go | 0 .../{osc => v2}/model_delete_subnet_request.go | 0 .../{osc => v2}/model_delete_subnet_response.go | 0 .../{osc => v2}/model_delete_tags_request.go | 0 .../{osc => v2}/model_delete_tags_response.go | 0 .../model_delete_virtual_gateway_request.go | 0 .../model_delete_virtual_gateway_response.go | 0 .../{osc => v2}/model_delete_vms_request.go | 0 .../{osc => v2}/model_delete_vms_response.go | 0 .../{osc => v2}/model_delete_volume_request.go | 0 .../{osc => v2}/model_delete_volume_response.go | 0 .../model_delete_vpn_connection_request.go | 0 .../model_delete_vpn_connection_response.go | 0 .../model_delete_vpn_connection_route_request.go | 0 .../model_delete_vpn_connection_route_response.go | 0 ...odel_deregister_vms_in_load_balancer_request.go | 0 ...del_deregister_vms_in_load_balancer_response.go | 0 .../{osc => v2}/model_dhcp_options_set.go | 0 .../osc-sdk-go/{osc => v2}/model_direct_link.go | 0 .../{osc => v2}/model_direct_link_interface.go | 0 .../{osc => v2}/model_direct_link_interfaces.go | 0 .../osc-sdk-go/{osc => v2}/model_error_response.go | 0 .../osc-sdk-go/{osc => v2}/model_errors.go | 0 .../{osc => v2}/model_filters_access_keys.go | 0 .../{osc => v2}/model_filters_api_log.go | 0 .../{osc => v2}/model_filters_client_gateway.go | 0 .../{osc => v2}/model_filters_dhcp_options.go | 0 .../{osc => v2}/model_filters_direct_link.go | 0 .../model_filters_direct_link_interface.go | 0 .../{osc => v2}/model_filters_export_task.go | 0 .../{osc => v2}/model_filters_flexible_gpu.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_image.go | 0 .../{osc => v2}/model_filters_internet_service.go | 0 .../{osc => v2}/model_filters_keypair.go | 0 .../{osc => v2}/model_filters_listener_rule.go | 0 .../{osc => v2}/model_filters_load_balancer.go | 0 .../{osc => v2}/model_filters_nat_service.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_net.go | 0 .../{osc => v2}/model_filters_net_access_point.go | 0 .../{osc => v2}/model_filters_net_peering.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_nic.go | 0 .../{osc => v2}/model_filters_product_type.go | 0 .../{osc => v2}/model_filters_public_ip.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_quota.go | 0 .../{osc => v2}/model_filters_route_table.go | 0 .../{osc => v2}/model_filters_security_group.go | 0 .../model_filters_server_certificate.go | 0 .../{osc => v2}/model_filters_service.go | 0 .../{osc => v2}/model_filters_snapshot.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_subnet.go | 0 .../{osc => v2}/model_filters_subregion.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_tag.go | 0 .../{osc => v2}/model_filters_virtual_gateway.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_vm.go | 0 .../{osc => v2}/model_filters_vm_type.go | 0 .../{osc => v2}/model_filters_vms_state.go | 0 .../osc-sdk-go/{osc => v2}/model_filters_volume.go | 0 .../{osc => v2}/model_filters_vpn_connection.go | 0 .../osc-sdk-go/{osc => v2}/model_flexible_gpu.go | 0 .../{osc => v2}/model_flexible_gpu_catalog.go | 0 .../osc-sdk-go/{osc => v2}/model_health_check.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_image.go | 0 .../{osc => v2}/model_image_export_task.go | 0 .../{osc => v2}/model_internet_service.go | 0 .../osc-sdk-go/{osc => v2}/model_keypair.go | 0 .../{osc => v2}/model_keypair_created.go | 0 .../{osc => v2}/model_link_flexible_gpu_request.go | 0 .../model_link_flexible_gpu_response.go | 0 .../model_link_internet_service_request.go | 0 .../model_link_internet_service_response.go | 0 .../osc-sdk-go/{osc => v2}/model_link_nic.go | 0 .../osc-sdk-go/{osc => v2}/model_link_nic_light.go | 0 .../{osc => v2}/model_link_nic_request.go | 0 .../{osc => v2}/model_link_nic_response.go | 0 .../{osc => v2}/model_link_nic_to_update.go | 0 .../{osc => v2}/model_link_private_ips_request.go | 0 .../{osc => v2}/model_link_private_ips_response.go | 0 .../osc-sdk-go/{osc => v2}/model_link_public_ip.go | 0 .../model_link_public_ip_light_for_vm.go | 0 .../{osc => v2}/model_link_public_ip_request.go | 0 .../{osc => v2}/model_link_public_ip_response.go | 0 .../{osc => v2}/model_link_route_table.go | 0 .../{osc => v2}/model_link_route_table_request.go | 0 .../{osc => v2}/model_link_route_table_response.go | 0 .../model_link_virtual_gateway_request.go | 0 .../model_link_virtual_gateway_response.go | 0 .../{osc => v2}/model_link_volume_request.go | 0 .../{osc => v2}/model_link_volume_response.go | 0 .../osc-sdk-go/{osc => v2}/model_linked_volume.go | 0 .../osc-sdk-go/{osc => v2}/model_listener.go | 0 .../{osc => v2}/model_listener_for_creation.go | 0 .../osc-sdk-go/{osc => v2}/model_listener_rule.go | 0 .../model_listener_rule_for_creation.go | 0 .../osc-sdk-go/{osc => v2}/model_load_balancer.go | 0 .../{osc => v2}/model_load_balancer_light.go | 0 .../model_load_balancer_sticky_cookie_policy.go | 0 .../{osc => v2}/model_load_balancer_tag.go | 0 .../osc-sdk-go/{osc => v2}/model_location.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_log.go | 0 .../{osc => v2}/model_maintenance_event.go | 0 .../osc-sdk-go/{osc => v2}/model_nat_service.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_net.go | 0 .../{osc => v2}/model_net_access_point.go | 0 .../osc-sdk-go/{osc => v2}/model_net_peering.go | 0 .../{osc => v2}/model_net_peering_state.go | 0 .../model_net_to_virtual_gateway_link.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_nic.go | 0 .../{osc => v2}/model_nic_for_vm_creation.go | 0 .../osc-sdk-go/{osc => v2}/model_nic_light.go | 0 .../osc-sdk-go/{osc => v2}/model_osu_api_key.go | 0 .../osc-sdk-go/{osc => v2}/model_osu_export.go | 0 .../{osc => v2}/model_permissions_on_resource.go | 0 .../model_permissions_on_resource_creation.go | 0 .../osc-sdk-go/{osc => v2}/model_placement.go | 0 .../osc-sdk-go/{osc => v2}/model_private_ip.go | 0 .../{osc => v2}/model_private_ip_light.go | 0 .../{osc => v2}/model_private_ip_light_for_vm.go | 0 .../osc-sdk-go/{osc => v2}/model_product_type.go | 0 .../osc-sdk-go/{osc => v2}/model_public_ip.go | 0 .../{osc => v2}/model_public_ip_light.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_quota.go | 0 .../osc-sdk-go/{osc => v2}/model_quota_types.go | 0 .../{osc => v2}/model_read_access_keys_request.go | 0 .../{osc => v2}/model_read_access_keys_response.go | 0 .../{osc => v2}/model_read_accounts_request.go | 0 .../{osc => v2}/model_read_accounts_response.go | 0 .../model_read_admin_password_request.go | 0 .../model_read_admin_password_response.go | 0 .../{osc => v2}/model_read_api_logs_request.go | 0 .../{osc => v2}/model_read_api_logs_response.go | 0 .../model_read_client_gateways_request.go | 0 .../model_read_client_gateways_response.go | 0 .../model_read_console_output_request.go | 0 .../model_read_console_output_response.go | 0 .../model_read_consumption_account_request.go | 0 .../model_read_consumption_account_response.go | 0 .../{osc => v2}/model_read_dhcp_options_request.go | 0 .../model_read_dhcp_options_response.go | 0 .../model_read_direct_link_interfaces_request.go | 0 .../model_read_direct_link_interfaces_response.go | 0 .../{osc => v2}/model_read_direct_links_request.go | 0 .../model_read_direct_links_response.go | 0 .../model_read_flexible_gpu_catalog_request.go | 0 .../model_read_flexible_gpu_catalog_response.go | 0 .../model_read_flexible_gpus_request.go | 0 .../model_read_flexible_gpus_response.go | 0 .../model_read_image_export_tasks_request.go | 0 .../model_read_image_export_tasks_response.go | 0 .../{osc => v2}/model_read_images_request.go | 0 .../{osc => v2}/model_read_images_response.go | 0 .../model_read_internet_services_request.go | 0 .../model_read_internet_services_response.go | 0 .../{osc => v2}/model_read_keypairs_request.go | 0 .../{osc => v2}/model_read_keypairs_response.go | 0 .../model_read_listener_rules_request.go | 0 .../model_read_listener_rules_response.go | 0 .../model_read_load_balancer_tags_request.go | 0 .../model_read_load_balancer_tags_response.go | 0 .../model_read_load_balancers_request.go | 0 .../model_read_load_balancers_response.go | 0 .../{osc => v2}/model_read_locations_request.go | 0 .../{osc => v2}/model_read_locations_response.go | 0 .../{osc => v2}/model_read_nat_services_request.go | 0 .../model_read_nat_services_response.go | 0 ...model_read_net_access_point_services_request.go | 0 ...odel_read_net_access_point_services_response.go | 0 .../model_read_net_access_points_request.go | 0 .../model_read_net_access_points_response.go | 0 .../{osc => v2}/model_read_net_peerings_request.go | 0 .../model_read_net_peerings_response.go | 0 .../{osc => v2}/model_read_nets_request.go | 0 .../{osc => v2}/model_read_nets_response.go | 0 .../{osc => v2}/model_read_nics_request.go | 0 .../{osc => v2}/model_read_nics_response.go | 0 .../model_read_product_types_request.go | 0 .../model_read_product_types_response.go | 0 .../model_read_public_ip_ranges_request.go | 0 .../model_read_public_ip_ranges_response.go | 0 .../{osc => v2}/model_read_public_ips_request.go | 0 .../{osc => v2}/model_read_public_ips_response.go | 0 .../{osc => v2}/model_read_quotas_request.go | 0 .../{osc => v2}/model_read_quotas_response.go | 0 .../{osc => v2}/model_read_regions_request.go | 0 .../{osc => v2}/model_read_regions_response.go | 0 .../{osc => v2}/model_read_route_tables_request.go | 0 .../model_read_route_tables_response.go | 0 .../model_read_secret_access_key_request.go | 0 .../model_read_secret_access_key_response.go | 0 .../model_read_security_groups_request.go | 0 .../model_read_security_groups_response.go | 0 .../model_read_server_certificates_request.go | 0 .../model_read_server_certificates_response.go | 0 .../model_read_snapshot_export_tasks_request.go | 0 .../model_read_snapshot_export_tasks_response.go | 0 .../{osc => v2}/model_read_snapshots_request.go | 0 .../{osc => v2}/model_read_snapshots_response.go | 0 .../{osc => v2}/model_read_subnets_request.go | 0 .../{osc => v2}/model_read_subnets_response.go | 0 .../{osc => v2}/model_read_subregions_request.go | 0 .../{osc => v2}/model_read_subregions_response.go | 0 .../{osc => v2}/model_read_tags_request.go | 0 .../{osc => v2}/model_read_tags_response.go | 0 .../model_read_virtual_gateways_request.go | 0 .../model_read_virtual_gateways_response.go | 0 .../{osc => v2}/model_read_vm_types_request.go | 0 .../{osc => v2}/model_read_vm_types_response.go | 0 .../{osc => v2}/model_read_vms_health_request.go | 0 .../{osc => v2}/model_read_vms_health_response.go | 0 .../{osc => v2}/model_read_vms_request.go | 0 .../{osc => v2}/model_read_vms_response.go | 0 .../{osc => v2}/model_read_vms_state_request.go | 0 .../{osc => v2}/model_read_vms_state_response.go | 0 .../{osc => v2}/model_read_volumes_request.go | 0 .../{osc => v2}/model_read_volumes_response.go | 0 .../model_read_vpn_connections_request.go | 0 .../model_read_vpn_connections_response.go | 0 .../{osc => v2}/model_reboot_vms_request.go | 0 .../{osc => v2}/model_reboot_vms_response.go | 0 .../osc-sdk-go/{osc => v2}/model_region.go | 0 .../model_register_vms_in_load_balancer_request.go | 0 ...model_register_vms_in_load_balancer_response.go | 0 .../model_reject_net_peering_request.go | 0 .../model_reject_net_peering_response.go | 0 .../model_reset_account_password_request.go | 0 .../model_reset_account_password_response.go | 0 .../model_resource_load_balancer_tag.go | 0 .../osc-sdk-go/{osc => v2}/model_resource_tag.go | 0 .../{osc => v2}/model_response_context.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_route.go | 0 .../osc-sdk-go/{osc => v2}/model_route_light.go | 0 .../model_route_propagating_virtual_gateway.go | 0 .../osc-sdk-go/{osc => v2}/model_route_table.go | 0 .../osc-sdk-go/{osc => v2}/model_security_group.go | 0 .../{osc => v2}/model_security_group_light.go | 0 .../{osc => v2}/model_security_group_rule.go | 0 .../{osc => v2}/model_security_groups_member.go | 0 .../model_send_reset_password_email_request.go | 0 .../model_send_reset_password_email_response.go | 0 .../{osc => v2}/model_server_certificate.go | 0 .../osc-sdk-go/{osc => v2}/model_service.go | 0 .../osc-sdk-go/{osc => v2}/model_snapshot.go | 0 .../{osc => v2}/model_snapshot_export_task.go | 0 .../osc-sdk-go/{osc => v2}/model_source_net.go | 0 .../{osc => v2}/model_source_security_group.go | 0 .../{osc => v2}/model_start_vms_request.go | 0 .../{osc => v2}/model_start_vms_response.go | 0 .../osc-sdk-go/{osc => v2}/model_state_comment.go | 0 .../{osc => v2}/model_stop_vms_request.go | 0 .../{osc => v2}/model_stop_vms_response.go | 0 .../osc-sdk-go/{osc => v2}/model_subnet.go | 0 .../osc-sdk-go/{osc => v2}/model_subregion.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_tag.go | 0 .../model_unlink_flexible_gpu_request.go | 0 .../model_unlink_flexible_gpu_response.go | 0 .../model_unlink_internet_service_request.go | 0 .../model_unlink_internet_service_response.go | 0 .../{osc => v2}/model_unlink_nic_request.go | 0 .../{osc => v2}/model_unlink_nic_response.go | 0 .../model_unlink_private_ips_request.go | 0 .../model_unlink_private_ips_response.go | 0 .../{osc => v2}/model_unlink_public_ip_request.go | 0 .../{osc => v2}/model_unlink_public_ip_response.go | 0 .../model_unlink_route_table_request.go | 0 .../model_unlink_route_table_response.go | 0 .../model_unlink_virtual_gateway_request.go | 0 .../model_unlink_virtual_gateway_response.go | 0 .../{osc => v2}/model_unlink_volume_request.go | 0 .../{osc => v2}/model_unlink_volume_response.go | 0 .../{osc => v2}/model_update_access_key_request.go | 0 .../model_update_access_key_response.go | 0 .../{osc => v2}/model_update_account_request.go | 0 .../{osc => v2}/model_update_account_response.go | 0 .../model_update_flexible_gpu_request.go | 0 .../model_update_flexible_gpu_response.go | 0 .../{osc => v2}/model_update_image_request.go | 0 .../{osc => v2}/model_update_image_response.go | 0 .../model_update_listener_rule_request.go | 0 .../model_update_listener_rule_response.go | 0 .../model_update_load_balancer_request.go | 0 .../model_update_load_balancer_response.go | 0 .../model_update_net_access_point_request.go | 0 .../model_update_net_access_point_response.go | 0 .../{osc => v2}/model_update_net_request.go | 0 .../{osc => v2}/model_update_net_response.go | 0 .../{osc => v2}/model_update_nic_request.go | 0 .../{osc => v2}/model_update_nic_response.go | 0 .../model_update_route_propagation_request.go | 0 .../model_update_route_propagation_response.go | 0 .../{osc => v2}/model_update_route_request.go | 0 .../{osc => v2}/model_update_route_response.go | 0 .../model_update_server_certificate_request.go | 0 .../model_update_server_certificate_response.go | 0 .../{osc => v2}/model_update_snapshot_request.go | 0 .../{osc => v2}/model_update_snapshot_response.go | 0 .../{osc => v2}/model_update_subnet_request.go | 0 .../{osc => v2}/model_update_subnet_response.go | 0 .../{osc => v2}/model_update_vm_request.go | 0 .../{osc => v2}/model_update_vm_response.go | 0 .../{osc => v2}/model_virtual_gateway.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_vm.go | 0 .../osc-sdk-go/{osc => v2}/model_vm_state.go | 0 .../osc-sdk-go/{osc => v2}/model_vm_states.go | 0 .../osc-sdk-go/{osc => v2}/model_vm_type.go | 0 .../osc-sdk-go/{osc => v2}/model_volume.go | 0 .../osc-sdk-go/{osc => v2}/model_vpn_connection.go | 0 .../outscale/osc-sdk-go/{osc => v2}/model_with.go | 0 .../outscale/osc-sdk-go/{osc => v2}/response.go | 0 .../outscale/osc-sdk-go/{osc => v2}/utils.go | 0 vendor/modules.txt | 4 ++-- 618 files changed, 130 insertions(+), 135 deletions(-) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/.gitignore (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/.openapi-generator-ignore (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/.travis.yml (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/README.md (99%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_access_key.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_account.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_api_log.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_client_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_dhcp_option.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_direct_link.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_direct_link_interface.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_flexible_gpu.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_image.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_internet_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_keypair.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_listener.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_load_balancer.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_load_balancer_policy.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_location.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_nat_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_net.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_net_access_point.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_net_peering.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_nic.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_product_type.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_public_ip.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_quota.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_region.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_route.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_route_table.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_security_group.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_security_group_rule.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_server_certificate.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_snapshot.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_subnet.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_subregion.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_task.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_virtual_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_volume.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/api_vpn_connection.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/client.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/configuration.go (99%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/git_push.sh (98%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/go.mod (73%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/go.sum (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_accept_net_peering_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_accept_net_peering_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_accepter_net.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_access_key.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_access_key_secret_key.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_access_log.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_account.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_application_sticky_cookie_policy.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_backend_vm_health.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_block_device_mapping_created.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_block_device_mapping_image.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_block_device_mapping_vm_creation.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_block_device_mapping_vm_update.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_bsu_created.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_bsu_to_create.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_bsu_to_update_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_check_authentication_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_check_authentication_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_client_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_consumption_entry.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_access_key_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_access_key_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_account_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_account_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_client_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_client_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_dhcp_options_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_dhcp_options_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_direct_link_interface_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_direct_link_interface_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_direct_link_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_direct_link_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_flexible_gpu_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_flexible_gpu_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_image_export_task_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_image_export_task_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_image_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_image_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_internet_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_internet_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_keypair_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_keypair_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_listener_rule_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_listener_rule_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_listeners_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_listeners_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_policy_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_policy_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_load_balancer_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_nat_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_nat_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_access_point_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_access_point_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_peering_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_peering_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_net_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_nic_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_nic_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_public_ip_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_public_ip_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_route_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_route_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_route_table_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_route_table_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_security_group_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_security_group_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_security_group_rule_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_security_group_rule_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_server_certificate_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_server_certificate_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_snapshot_export_task_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_snapshot_export_task_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_snapshot_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_snapshot_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_subnet_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_subnet_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_virtual_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_virtual_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_volume_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_volume_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vpn_connection_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vpn_connection_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vpn_connection_route_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_create_vpn_connection_route_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_access_key_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_access_key_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_client_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_client_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_dhcp_options_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_dhcp_options_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_direct_link_interface_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_direct_link_interface_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_direct_link_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_direct_link_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_export_task_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_export_task_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_flexible_gpu_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_flexible_gpu_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_image_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_image_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_internet_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_internet_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_keypair_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_keypair_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_listener_rule_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_listener_rule_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_listeners_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_listeners_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_policy_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_policy_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_load_balancer_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_nat_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_nat_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_access_point_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_access_point_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_peering_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_peering_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_net_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_nic_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_nic_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_public_ip_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_public_ip_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_route_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_route_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_route_table_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_route_table_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_security_group_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_security_group_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_security_group_rule_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_security_group_rule_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_server_certificate_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_server_certificate_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_snapshot_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_snapshot_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_subnet_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_subnet_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_virtual_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_virtual_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_volume_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_volume_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vpn_connection_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vpn_connection_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vpn_connection_route_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_delete_vpn_connection_route_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_deregister_vms_in_load_balancer_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_deregister_vms_in_load_balancer_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_dhcp_options_set.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_direct_link.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_direct_link_interface.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_direct_link_interfaces.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_error_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_errors.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_access_keys.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_api_log.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_client_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_dhcp_options.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_direct_link.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_direct_link_interface.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_export_task.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_flexible_gpu.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_image.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_internet_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_keypair.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_listener_rule.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_load_balancer.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_nat_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_net.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_net_access_point.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_net_peering.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_nic.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_product_type.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_public_ip.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_quota.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_route_table.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_security_group.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_server_certificate.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_snapshot.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_subnet.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_subregion.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_virtual_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_vm_type.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_vms_state.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_volume.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_filters_vpn_connection.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_flexible_gpu.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_flexible_gpu_catalog.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_health_check.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_image.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_image_export_task.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_internet_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_keypair.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_keypair_created.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_flexible_gpu_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_flexible_gpu_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_internet_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_internet_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_nic.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_nic_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_nic_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_nic_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_nic_to_update.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_private_ips_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_private_ips_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_public_ip.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_public_ip_light_for_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_public_ip_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_public_ip_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_route_table.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_route_table_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_route_table_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_virtual_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_virtual_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_volume_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_link_volume_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_linked_volume.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_listener.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_listener_for_creation.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_listener_rule.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_listener_rule_for_creation.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_load_balancer.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_load_balancer_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_load_balancer_sticky_cookie_policy.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_load_balancer_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_location.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_log.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_maintenance_event.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_nat_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_net.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_net_access_point.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_net_peering.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_net_peering_state.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_net_to_virtual_gateway_link.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_nic.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_nic_for_vm_creation.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_nic_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_osu_api_key.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_osu_export.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_permissions_on_resource.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_permissions_on_resource_creation.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_placement.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_private_ip.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_private_ip_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_private_ip_light_for_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_product_type.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_public_ip.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_public_ip_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_quota.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_quota_types.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_access_keys_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_access_keys_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_accounts_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_accounts_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_admin_password_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_admin_password_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_api_logs_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_api_logs_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_client_gateways_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_client_gateways_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_console_output_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_console_output_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_consumption_account_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_consumption_account_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_dhcp_options_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_dhcp_options_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_direct_link_interfaces_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_direct_link_interfaces_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_direct_links_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_direct_links_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_flexible_gpu_catalog_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_flexible_gpu_catalog_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_flexible_gpus_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_flexible_gpus_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_image_export_tasks_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_image_export_tasks_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_images_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_images_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_internet_services_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_internet_services_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_keypairs_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_keypairs_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_listener_rules_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_listener_rules_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_load_balancer_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_load_balancer_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_load_balancers_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_load_balancers_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_locations_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_locations_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nat_services_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nat_services_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_access_point_services_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_access_point_services_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_access_points_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_access_points_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_peerings_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_net_peerings_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nets_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nets_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nics_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_nics_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_product_types_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_product_types_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_public_ip_ranges_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_public_ip_ranges_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_public_ips_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_public_ips_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_quotas_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_quotas_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_regions_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_regions_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_route_tables_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_route_tables_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_secret_access_key_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_secret_access_key_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_security_groups_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_security_groups_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_server_certificates_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_server_certificates_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_snapshot_export_tasks_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_snapshot_export_tasks_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_snapshots_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_snapshots_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_subnets_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_subnets_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_subregions_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_subregions_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_tags_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_tags_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_virtual_gateways_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_virtual_gateways_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vm_types_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vm_types_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_health_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_health_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_state_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vms_state_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_volumes_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_volumes_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vpn_connections_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_read_vpn_connections_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reboot_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reboot_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_region.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_register_vms_in_load_balancer_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_register_vms_in_load_balancer_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reject_net_peering_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reject_net_peering_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reset_account_password_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_reset_account_password_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_resource_load_balancer_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_resource_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_response_context.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_route.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_route_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_route_propagating_virtual_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_route_table.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_security_group.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_security_group_light.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_security_group_rule.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_security_groups_member.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_send_reset_password_email_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_send_reset_password_email_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_server_certificate.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_service.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_snapshot.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_snapshot_export_task.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_source_net.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_source_security_group.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_start_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_start_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_state_comment.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_stop_vms_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_stop_vms_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_subnet.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_subregion.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_tag.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_flexible_gpu_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_flexible_gpu_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_internet_service_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_internet_service_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_nic_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_nic_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_private_ips_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_private_ips_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_public_ip_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_public_ip_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_route_table_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_route_table_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_virtual_gateway_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_virtual_gateway_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_volume_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_unlink_volume_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_access_key_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_access_key_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_account_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_account_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_flexible_gpu_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_flexible_gpu_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_image_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_image_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_listener_rule_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_listener_rule_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_load_balancer_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_load_balancer_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_net_access_point_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_net_access_point_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_net_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_net_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_nic_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_nic_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_route_propagation_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_route_propagation_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_route_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_route_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_server_certificate_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_server_certificate_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_snapshot_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_snapshot_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_subnet_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_subnet_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_vm_request.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_update_vm_response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_virtual_gateway.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_vm.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_vm_state.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_vm_states.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_vm_type.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_volume.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_vpn_connection.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/model_with.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/response.go (100%) rename vendor/github.com/outscale/osc-sdk-go/{osc => v2}/utils.go (100%) diff --git a/go.mod b/go.mod index c9af480a7..9af04c838 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,6 @@ module github.com/terraform-providers/terraform-provider-outscale go 1.12 require ( - github.com/antihax/optional v1.0.0 // indirect github.com/aws/aws-sdk-go v1.34.14 github.com/davecgh/go-spew v1.1.1 github.com/go-test/deep v1.0.6 @@ -11,6 +10,6 @@ require ( github.com/hashicorp/terraform v0.12.26 github.com/hashicorp/terraform-plugin-sdk v1.13.1 github.com/openlyinc/pointy v1.1.2 - github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c + github.com/outscale/osc-sdk-go/v2 v2.0.0-beta.3 github.com/spf13/cast v1.3.1 ) diff --git a/go.sum b/go.sum index 33c749623..549430080 100644 --- a/go.sum +++ b/go.sum @@ -42,8 +42,6 @@ github.com/aliyun/aliyun-oss-go-sdk v0.0.0-20190103054945-8205d1f41e70/go.mod h1 github.com/aliyun/aliyun-tablestore-go-sdk v4.1.2+incompatible/go.mod h1:LDQHRZylxvcg8H7wBIDfvO5g/cy4/sz1iucBlc2l3Jw= github.com/antchfx/xpath v0.0.0-20190129040759-c8489ed3251e/go.mod h1:Yee4kTMuNiPYJ7nSNorELQMr1J33uOpXDMByNYhvtNk= github.com/antchfx/xquery v0.0.0-20180515051857-ad5b8c7a47b0/go.mod h1:LzD22aAzDP8/dyiCKFp31He4m2GPjl0AFyzDtZzUu9M= -github.com/antihax/optional v1.0.0 h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg= -github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/apparentlymart/go-cidr v1.0.1 h1:NmIwLZ/KdsjIUlhf+/Np40atNXm/+lZ5txfTJ/SpF+U= github.com/apparentlymart/go-cidr v1.0.1/go.mod h1:EBcsNrHc3zQeuaeCeCtQruQm+n9/YjEn/vI25Lg7Gwc= github.com/apparentlymart/go-dump v0.0.0-20180507223929-23540a00eaa3/go.mod h1:oL81AME2rN47vu18xqj1S1jPIPuN7afo62yKTNn3XMM= @@ -59,10 +57,7 @@ github.com/armon/go-radix v1.0.0 h1:F4z6KzEeeQIMeLFa97iZU6vupzoecKdU5TX24SNppXI= github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aws/aws-sdk-go v1.15.78/go.mod h1:E3/ieXAlvM0XWO57iftYVDLLvQ824smPP3ATZkfNZeM= github.com/aws/aws-sdk-go v1.25.3/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= -github.com/aws/aws-sdk-go v1.26.3/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.30.12/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= -github.com/aws/aws-sdk-go v1.31.10 h1:33jOMifUSdOP9pvNEOj+PGwljzunc8bJvKKNF/JuGzo= -github.com/aws/aws-sdk-go v1.31.10/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/aws/aws-sdk-go v1.34.14 h1:G0jUdSDSp63P0oo/N3c/ldo7s8mYW3Kh/GPIJ+oESVQ= github.com/aws/aws-sdk-go v1.34.14/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/baiyubin/aliyun-sts-go-sdk v0.0.0-20180326062324-cfa1a18b161f/go.mod h1:AuiFmCCPBSrqvVMvuqFuk0qogytodnVFVSN5CeJB8Gc= @@ -292,13 +287,8 @@ github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/openlyinc/pointy v1.1.2 h1:LywVV2BWC5Sp5v7FoP4bUD+2Yn5k0VNeRbU5vq9jUMY= github.com/openlyinc/pointy v1.1.2/go.mod h1:w2Sytx+0FVuMKn37xpXIAyBNhFNBIJGR/v2m7ik1WtM= -github.com/outscale/osc-sdk-go v1.3.0 h1:M3moUrGrwsK5XYk82zhWuypRKwnpBwzuX89YMIzx/IA= -github.com/outscale/osc-sdk-go v1.3.1-0.20201014193009-10509d4e084c h1:+20TjLxqtIVO18OPrpHh6sniXshSxJJntiRYdnmiK2g= -github.com/outscale/osc-sdk-go v1.3.1-0.20201014193009-10509d4e084c/go.mod h1:R2qnfXaSxnGSNgyCQ6VRV3sqFPjkjupMDOiKbqs5cAI= -github.com/outscale/osc-sdk-go/osc v0.0.0-20200902152503-f3b2a0227815 h1:iW3PlDOm545CGaMkZv5s1k6r5/j3JTll/FCLjasVPko= -github.com/outscale/osc-sdk-go/osc v0.0.0-20200902152503-f3b2a0227815/go.mod h1:5AqqNH1X8zCHescKVlpSHRzrat1KCKDXqZoQPe8fY3A= -github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c h1:/XVdGvgImVYxABbV4BttnO02tA45jpVXT/A5TWDRBuk= -github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c/go.mod h1:bq0k5osdMFbx7TKlbTFCSFwudIDJqp5VYf4hD1iQCl0= +github.com/outscale/osc-sdk-go/v2 v2.0.0-beta.3 h1:IZGX/5dfnCmwI0J9LakhBUTRFWXXn5SUo0LzQRGKQFw= +github.com/outscale/osc-sdk-go/v2 v2.0.0-beta.3/go.mod h1:ErlOZe3hawZx+XM7eEYHlcjDWGknFTTfHkS2N6LBsT8= github.com/packer-community/winrmcp v0.0.0-20180102160824-81144009af58/go.mod h1:f6Izs6JvFTdnRbziASagjZ2vmf55NSIkC/weStxCHqk= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= diff --git a/outscale/config.go b/outscale/config.go index 914ead2f7..9ead7434c 100644 --- a/outscale/config.go +++ b/outscale/config.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/logging" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) // Config ... diff --git a/outscale/data_source_outscale_access_key.go b/outscale/data_source_outscale_access_key.go index 29f8e62cf..232225d7b 100644 --- a/outscale/data_source_outscale_access_key.go +++ b/outscale/data_source_outscale_access_key.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_access_keys.go b/outscale/data_source_outscale_access_keys.go index 2f661c6cd..b27b73ada 100644 --- a/outscale/data_source_outscale_access_keys.go +++ b/outscale/data_source_outscale_access_keys.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_client_gateway.go b/outscale/data_source_outscale_client_gateway.go index b383ec1bf..7d5e84966 100644 --- a/outscale/data_source_outscale_client_gateway.go +++ b/outscale/data_source_outscale_client_gateway.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_client_gateways.go b/outscale/data_source_outscale_client_gateways.go index 7951ea8be..782a86996 100644 --- a/outscale/data_source_outscale_client_gateways.go +++ b/outscale/data_source_outscale_client_gateways.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_dhcp_option.go b/outscale/data_source_outscale_dhcp_option.go index 2d23ea6c8..ff622786d 100644 --- a/outscale/data_source_outscale_dhcp_option.go +++ b/outscale/data_source_outscale_dhcp_option.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_dhcp_options.go b/outscale/data_source_outscale_dhcp_options.go index 1d638162b..4580214a5 100644 --- a/outscale/data_source_outscale_dhcp_options.go +++ b/outscale/data_source_outscale_dhcp_options.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_image.go b/outscale/data_source_outscale_image.go index c0c8c3a41..f5c53befc 100644 --- a/outscale/data_source_outscale_image.go +++ b/outscale/data_source_outscale_image.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" diff --git a/outscale/data_source_outscale_images.go b/outscale/data_source_outscale_images.go index 069555da3..2471bd1b2 100644 --- a/outscale/data_source_outscale_images.go +++ b/outscale/data_source_outscale_images.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_internet_service.go b/outscale/data_source_outscale_internet_service.go index edf98c583..0b9c8ce83 100644 --- a/outscale/data_source_outscale_internet_service.go +++ b/outscale/data_source_outscale_internet_service.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_internet_services.go b/outscale/data_source_outscale_internet_services.go index a6b3ee9c0..60f2c73ce 100644 --- a/outscale/data_source_outscale_internet_services.go +++ b/outscale/data_source_outscale_internet_services.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_keypair.go b/outscale/data_source_outscale_keypair.go index 2c29a8b92..b8543fee6 100644 --- a/outscale/data_source_outscale_keypair.go +++ b/outscale/data_source_outscale_keypair.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_keypairs.go b/outscale/data_source_outscale_keypairs.go index eacec0064..d8cb39bd5 100644 --- a/outscale/data_source_outscale_keypairs.go +++ b/outscale/data_source_outscale_keypairs.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_nat_service.go b/outscale/data_source_outscale_nat_service.go index 2257bb1e8..964e9a68d 100644 --- a/outscale/data_source_outscale_nat_service.go +++ b/outscale/data_source_outscale_nat_service.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_nat_services.go b/outscale/data_source_outscale_nat_services.go index 8b806ff74..c3330f407 100644 --- a/outscale/data_source_outscale_nat_services.go +++ b/outscale/data_source_outscale_nat_services.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_net.go b/outscale/data_source_outscale_net.go index 361d9a5af..10f2a146f 100644 --- a/outscale/data_source_outscale_net.go +++ b/outscale/data_source_outscale_net.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_net_attributes.go b/outscale/data_source_outscale_net_attributes.go index b741e2678..4cb071d15 100644 --- a/outscale/data_source_outscale_net_attributes.go +++ b/outscale/data_source_outscale_net_attributes.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_net_peering.go b/outscale/data_source_outscale_net_peering.go index fa1dc47b5..b480b69ce 100644 --- a/outscale/data_source_outscale_net_peering.go +++ b/outscale/data_source_outscale_net_peering.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "log" "reflect" "strings" diff --git a/outscale/data_source_outscale_net_peerings.go b/outscale/data_source_outscale_net_peerings.go index 5f5a07148..cda181312 100644 --- a/outscale/data_source_outscale_net_peerings.go +++ b/outscale/data_source_outscale_net_peerings.go @@ -6,7 +6,7 @@ import ( "log" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_nets.go b/outscale/data_source_outscale_nets.go index 9b41fd3f4..fc4a00f07 100644 --- a/outscale/data_source_outscale_nets.go +++ b/outscale/data_source_outscale_nets.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_nic.go b/outscale/data_source_outscale_nic.go index 868ffcc15..0103c5a56 100644 --- a/outscale/data_source_outscale_nic.go +++ b/outscale/data_source_outscale_nic.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_nic_test.go b/outscale/data_source_outscale_nic_test.go index a7c8ef867..fde692001 100644 --- a/outscale/data_source_outscale_nic_test.go +++ b/outscale/data_source_outscale_nic_test.go @@ -6,7 +6,7 @@ import ( "os" "strings" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "testing" "time" diff --git a/outscale/data_source_outscale_nics.go b/outscale/data_source_outscale_nics.go index dd02f73b0..d79994224 100644 --- a/outscale/data_source_outscale_nics.go +++ b/outscale/data_source_outscale_nics.go @@ -5,7 +5,7 @@ import ( "fmt" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_public_ip.go b/outscale/data_source_outscale_public_ip.go index 349b0f0e1..90422082a 100644 --- a/outscale/data_source_outscale_public_ip.go +++ b/outscale/data_source_outscale_public_ip.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_public_ips.go b/outscale/data_source_outscale_public_ips.go index de6013211..d42db887f 100644 --- a/outscale/data_source_outscale_public_ips.go +++ b/outscale/data_source_outscale_public_ips.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_route_table.go b/outscale/data_source_outscale_route_table.go index 3f1963017..502217054 100644 --- a/outscale/data_source_outscale_route_table.go +++ b/outscale/data_source_outscale_route_table.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_route_tables.go b/outscale/data_source_outscale_route_tables.go index ee6f95287..3c1c54ca0 100644 --- a/outscale/data_source_outscale_route_tables.go +++ b/outscale/data_source_outscale_route_tables.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_security_group.go b/outscale/data_source_outscale_security_group.go index 4e2592ee6..bc846f688 100644 --- a/outscale/data_source_outscale_security_group.go +++ b/outscale/data_source_outscale_security_group.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_security_groups.go b/outscale/data_source_outscale_security_groups.go index e3a7acd95..93fd57976 100644 --- a/outscale/data_source_outscale_security_groups.go +++ b/outscale/data_source_outscale_security_groups.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_snapshot.go b/outscale/data_source_outscale_snapshot.go index 23adef347..80a0c07c0 100644 --- a/outscale/data_source_outscale_snapshot.go +++ b/outscale/data_source_outscale_snapshot.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" diff --git a/outscale/data_source_outscale_snapshots.go b/outscale/data_source_outscale_snapshots.go index 2aab45061..f57096f3b 100644 --- a/outscale/data_source_outscale_snapshots.go +++ b/outscale/data_source_outscale_snapshots.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_subnet.go b/outscale/data_source_outscale_subnet.go index 3726f043a..f56e85337 100644 --- a/outscale/data_source_outscale_subnet.go +++ b/outscale/data_source_outscale_subnet.go @@ -9,7 +9,7 @@ import ( "github.com/spf13/cast" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_subnets.go b/outscale/data_source_outscale_subnets.go index 0788c8a8a..1a55b013c 100644 --- a/outscale/data_source_outscale_subnets.go +++ b/outscale/data_source_outscale_subnets.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_tag.go b/outscale/data_source_outscale_tag.go index 11554fb21..1b2db8d1c 100644 --- a/outscale/data_source_outscale_tag.go +++ b/outscale/data_source_outscale_tag.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_tags.go b/outscale/data_source_outscale_tags.go index 89cd61d9b..18dcfbbb4 100644 --- a/outscale/data_source_outscale_tags.go +++ b/outscale/data_source_outscale_tags.go @@ -5,7 +5,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_virtual_gateway.go b/outscale/data_source_outscale_virtual_gateway.go index 4040688ef..e3f818ab1 100644 --- a/outscale/data_source_outscale_virtual_gateway.go +++ b/outscale/data_source_outscale_virtual_gateway.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "log" "strings" "time" diff --git a/outscale/data_source_outscale_virtual_gateways.go b/outscale/data_source_outscale_virtual_gateways.go index 14a1f39f2..78ca91466 100644 --- a/outscale/data_source_outscale_virtual_gateways.go +++ b/outscale/data_source_outscale_virtual_gateways.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "strings" "time" diff --git a/outscale/data_source_outscale_vm.go b/outscale/data_source_outscale_vm.go index 763c652c8..8ae5c4c22 100644 --- a/outscale/data_source_outscale_vm.go +++ b/outscale/data_source_outscale_vm.go @@ -11,7 +11,7 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func dataSourceOutscaleOAPIVM() *schema.Resource { diff --git a/outscale/data_source_outscale_vm_state.go b/outscale/data_source_outscale_vm_state.go index 4d0f863fa..9d5889ad7 100644 --- a/outscale/data_source_outscale_vm_state.go +++ b/outscale/data_source_outscale_vm_state.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_vms.go b/outscale/data_source_outscale_vms.go index 9996b9a43..bd3df65a5 100644 --- a/outscale/data_source_outscale_vms.go +++ b/outscale/data_source_outscale_vms.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func datasourceOutscaleOApiVMS() *schema.Resource { diff --git a/outscale/data_source_outscale_vms_state.go b/outscale/data_source_outscale_vms_state.go index 7196599a6..32570f529 100644 --- a/outscale/data_source_outscale_vms_state.go +++ b/outscale/data_source_outscale_vms_state.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_volume.go b/outscale/data_source_outscale_volume.go index 7c8ccbc65..4acc61b6a 100644 --- a/outscale/data_source_outscale_volume.go +++ b/outscale/data_source_outscale_volume.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/davecgh/go-spew/spew" diff --git a/outscale/data_source_outscale_volumes.go b/outscale/data_source_outscale_volumes.go index 39c0f0791..fbe02a2b4 100644 --- a/outscale/data_source_outscale_volumes.go +++ b/outscale/data_source_outscale_volumes.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/davecgh/go-spew/spew" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_vpn_connection.go b/outscale/data_source_outscale_vpn_connection.go index fcd4787f6..e4b59c126 100644 --- a/outscale/data_source_outscale_vpn_connection.go +++ b/outscale/data_source_outscale_vpn_connection.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_vpn_connections.go b/outscale/data_source_outscale_vpn_connections.go index afeef3123..ceb631a7f 100644 --- a/outscale/data_source_outscale_vpn_connections.go +++ b/outscale/data_source_outscale_vpn_connections.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func dataSourceOutscaleVPNConnections() *schema.Resource { diff --git a/outscale/instance_set_set.go b/outscale/instance_set_set.go index 94757a1ea..dc060dcc4 100644 --- a/outscale/instance_set_set.go +++ b/outscale/instance_set_set.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/hashcode" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func getOAPISecurityGroups(groups []oscgo.SecurityGroupLight) (SecurityGroup []map[string]interface{}, SecurityGroupIds []string) { diff --git a/outscale/oapi_tags.go b/outscale/oapi_tags.go index da01e0d8d..0b2394eb0 100644 --- a/outscale/oapi_tags.go +++ b/outscale/oapi_tags.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func setOSCAPITags(conn *oscgo.APIClient, d *schema.ResourceData) error { diff --git a/outscale/resource_outscale_access_key.go b/outscale/resource_outscale_access_key.go index c41ba86dd..c2f0cb800 100644 --- a/outscale/resource_outscale_access_key.go +++ b/outscale/resource_outscale_access_key.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" "github.com/hashicorp/terraform-plugin-sdk/helper/validation" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleAccessKey() *schema.Resource { diff --git a/outscale/resource_outscale_access_key_test.go b/outscale/resource_outscale_access_key_test.go index 90f6ac2e2..c915b4f85 100644 --- a/outscale/resource_outscale_access_key_test.go +++ b/outscale/resource_outscale_access_key_test.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func TestAccOutscaleAccessKey_basic(t *testing.T) { diff --git a/outscale/resource_outscale_client_gateway.go b/outscale/resource_outscale_client_gateway.go index db8d650f7..4c22f74de 100644 --- a/outscale/resource_outscale_client_gateway.go +++ b/outscale/resource_outscale_client_gateway.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleClientGateway() *schema.Resource { diff --git a/outscale/resource_outscale_client_gateway_test.go b/outscale/resource_outscale_client_gateway_test.go index 0517dfc7f..137540f7e 100644 --- a/outscale/resource_outscale_client_gateway_test.go +++ b/outscale/resource_outscale_client_gateway_test.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" ) diff --git a/outscale/resource_outscale_dhcp_option.go b/outscale/resource_outscale_dhcp_option.go index 74e77ed49..4ac945bf6 100644 --- a/outscale/resource_outscale_dhcp_option.go +++ b/outscale/resource_outscale_dhcp_option.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_dhcp_option_test.go b/outscale/resource_outscale_dhcp_option_test.go index 09c5b4e18..949c9f60e 100644 --- a/outscale/resource_outscale_dhcp_option_test.go +++ b/outscale/resource_outscale_dhcp_option_test.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" "github.com/hashicorp/terraform/helper/acctest" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func TestAccOutscaleOAPIDhcpOptional_basic(t *testing.T) { diff --git a/outscale/resource_outscale_image.go b/outscale/resource_outscale_image.go index 196864820..f273cca0e 100644 --- a/outscale/resource_outscale_image.go +++ b/outscale/resource_outscale_image.go @@ -6,7 +6,7 @@ import ( "log" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/openlyinc/pointy" "github.com/spf13/cast" diff --git a/outscale/resource_outscale_image_launch_permission.go b/outscale/resource_outscale_image_launch_permission.go index 26cb15ff0..c7b4d5c9b 100644 --- a/outscale/resource_outscale_image_launch_permission.go +++ b/outscale/resource_outscale_image_launch_permission.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" diff --git a/outscale/resource_outscale_image_launch_permission_test.go b/outscale/resource_outscale_image_launch_permission_test.go index 971aca212..dc1977db2 100644 --- a/outscale/resource_outscale_image_launch_permission_test.go +++ b/outscale/resource_outscale_image_launch_permission_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws" r "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_image_test.go b/outscale/resource_outscale_image_test.go index 6b1f24f01..f632080ed 100644 --- a/outscale/resource_outscale_image_test.go +++ b/outscale/resource_outscale_image_test.go @@ -6,7 +6,7 @@ import ( "os" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_internet_service.go b/outscale/resource_outscale_internet_service.go index c284cd0b1..1cfeadc0b 100644 --- a/outscale/resource_outscale_internet_service.go +++ b/outscale/resource_outscale_internet_service.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleOAPIInternetService() *schema.Resource { diff --git a/outscale/resource_outscale_internet_service_link.go b/outscale/resource_outscale_internet_service_link.go index 245e14b1f..b7365bddd 100644 --- a/outscale/resource_outscale_internet_service_link.go +++ b/outscale/resource_outscale_internet_service_link.go @@ -6,7 +6,7 @@ import ( "fmt" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_internet_service_link_test.go b/outscale/resource_outscale_internet_service_link_test.go index ebbee9e4c..40223d168 100644 --- a/outscale/resource_outscale_internet_service_link_test.go +++ b/outscale/resource_outscale_internet_service_link_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_internet_service_test.go b/outscale/resource_outscale_internet_service_test.go index e8783e19a..a5241d2d9 100644 --- a/outscale/resource_outscale_internet_service_test.go +++ b/outscale/resource_outscale_internet_service_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_keypair.go b/outscale/resource_outscale_keypair.go index fd42a580d..a8c45b62a 100644 --- a/outscale/resource_outscale_keypair.go +++ b/outscale/resource_outscale_keypair.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_keypair_test.go b/outscale/resource_outscale_keypair_test.go index 9c4057161..6acee3437 100644 --- a/outscale/resource_outscale_keypair_test.go +++ b/outscale/resource_outscale_keypair_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" diff --git a/outscale/resource_outscale_nat_service.go b/outscale/resource_outscale_nat_service.go index 5d307a36f..dcfde327c 100644 --- a/outscale/resource_outscale_nat_service.go +++ b/outscale/resource_outscale_nat_service.go @@ -7,7 +7,7 @@ import ( "log" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_nat_service_test.go b/outscale/resource_outscale_nat_service_test.go index 519eb797b..8d373033d 100644 --- a/outscale/resource_outscale_nat_service_test.go +++ b/outscale/resource_outscale_nat_service_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_net.go b/outscale/resource_outscale_net.go index 58dfeb442..8f0c6b229 100644 --- a/outscale/resource_outscale_net.go +++ b/outscale/resource_outscale_net.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_net_attributes.go b/outscale/resource_outscale_net_attributes.go index 4de610bc8..ef4e05a88 100644 --- a/outscale/resource_outscale_net_attributes.go +++ b/outscale/resource_outscale_net_attributes.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_net_peering.go b/outscale/resource_outscale_net_peering.go index 99a8eaa20..459a58bed 100644 --- a/outscale/resource_outscale_net_peering.go +++ b/outscale/resource_outscale_net_peering.go @@ -9,7 +9,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_net_peering_acceptation.go b/outscale/resource_outscale_net_peering_acceptation.go index aa9bfc545..6c5af22e2 100644 --- a/outscale/resource_outscale_net_peering_acceptation.go +++ b/outscale/resource_outscale_net_peering_acceptation.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_net_peering_test.go b/outscale/resource_outscale_net_peering_test.go index 8c65072b6..c1ef9c65f 100644 --- a/outscale/resource_outscale_net_peering_test.go +++ b/outscale/resource_outscale_net_peering_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_net_test.go b/outscale/resource_outscale_net_test.go index e2f6b1e65..3ecb3f85d 100644 --- a/outscale/resource_outscale_net_test.go +++ b/outscale/resource_outscale_net_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_nic.go b/outscale/resource_outscale_nic.go index e9ca7f8de..537c2966c 100644 --- a/outscale/resource_outscale_nic.go +++ b/outscale/resource_outscale_nic.go @@ -10,7 +10,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_nic_link.go b/outscale/resource_outscale_nic_link.go index 91a4783e8..0c80983e6 100644 --- a/outscale/resource_outscale_nic_link.go +++ b/outscale/resource_outscale_nic_link.go @@ -9,7 +9,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_nic_link_test.go b/outscale/resource_outscale_nic_link_test.go index 2b96e7b8a..04fdb11fa 100644 --- a/outscale/resource_outscale_nic_link_test.go +++ b/outscale/resource_outscale_nic_link_test.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_nic_private_ip.go b/outscale/resource_outscale_nic_private_ip.go index 890dc6e87..8cca94a3e 100644 --- a/outscale/resource_outscale_nic_private_ip.go +++ b/outscale/resource_outscale_nic_private_ip.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_nic_private_ip_test.go b/outscale/resource_outscale_nic_private_ip_test.go index 329baa84d..42f25abf7 100644 --- a/outscale/resource_outscale_nic_private_ip_test.go +++ b/outscale/resource_outscale_nic_private_ip_test.go @@ -5,7 +5,7 @@ import ( "os" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/resource_outscale_nic_test.go b/outscale/resource_outscale_nic_test.go index dbef70e20..7017c6bd7 100644 --- a/outscale/resource_outscale_nic_test.go +++ b/outscale/resource_outscale_nic_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_public_ip.go b/outscale/resource_outscale_public_ip.go index 32803653e..760eea642 100644 --- a/outscale/resource_outscale_public_ip.go +++ b/outscale/resource_outscale_public_ip.go @@ -10,7 +10,7 @@ import ( "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" ) diff --git a/outscale/resource_outscale_public_ip_link.go b/outscale/resource_outscale_public_ip_link.go index a62076c18..cf6ba9eed 100644 --- a/outscale/resource_outscale_public_ip_link.go +++ b/outscale/resource_outscale_public_ip_link.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_public_ip_link_test.go b/outscale/resource_outscale_public_ip_link_test.go index a4dda903b..67a9bb1b5 100644 --- a/outscale/resource_outscale_public_ip_link_test.go +++ b/outscale/resource_outscale_public_ip_link_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_public_ip_test.go b/outscale/resource_outscale_public_ip_test.go index 261bfac4d..e2a009f88 100644 --- a/outscale/resource_outscale_public_ip_test.go +++ b/outscale/resource_outscale_public_ip_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_route.go b/outscale/resource_outscale_route.go index fd6bd9bc9..d272de4da 100644 --- a/outscale/resource_outscale_route.go +++ b/outscale/resource_outscale_route.go @@ -10,7 +10,7 @@ import ( "time" "github.com/openlyinc/pointy" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_route_table.go b/outscale/resource_outscale_route_table.go index 4ae80eafc..92910bfc4 100644 --- a/outscale/resource_outscale_route_table.go +++ b/outscale/resource_outscale_route_table.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_route_table_link.go b/outscale/resource_outscale_route_table_link.go index 58b35a77b..4149b6b06 100644 --- a/outscale/resource_outscale_route_table_link.go +++ b/outscale/resource_outscale_route_table_link.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_route_table_link_test.go b/outscale/resource_outscale_route_table_link_test.go index 5be848fbb..97a6eddcb 100644 --- a/outscale/resource_outscale_route_table_link_test.go +++ b/outscale/resource_outscale_route_table_link_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_route_table_test.go b/outscale/resource_outscale_route_table_test.go index 324a3867e..d5cdb7ae3 100644 --- a/outscale/resource_outscale_route_table_test.go +++ b/outscale/resource_outscale_route_table_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_route_test.go b/outscale/resource_outscale_route_test.go index 910f10c6e..3cf20a564 100644 --- a/outscale/resource_outscale_route_test.go +++ b/outscale/resource_outscale_route_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_security_group.go b/outscale/resource_outscale_security_group.go index 173792971..ef8b7b784 100644 --- a/outscale/resource_outscale_security_group.go +++ b/outscale/resource_outscale_security_group.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_security_group_rule.go b/outscale/resource_outscale_security_group_rule.go index 18dbd2a00..d15207879 100644 --- a/outscale/resource_outscale_security_group_rule.go +++ b/outscale/resource_outscale_security_group_rule.go @@ -7,7 +7,7 @@ import ( "time" "github.com/openlyinc/pointy" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/terraform-providers/terraform-provider-outscale/utils" diff --git a/outscale/resource_outscale_security_group_rule_test.go b/outscale/resource_outscale_security_group_rule_test.go index 14221cc53..18e89eb5f 100644 --- a/outscale/resource_outscale_security_group_rule_test.go +++ b/outscale/resource_outscale_security_group_rule_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_security_group_test.go b/outscale/resource_outscale_security_group_test.go index 255364137..ea7c86c33 100644 --- a/outscale/resource_outscale_security_group_test.go +++ b/outscale/resource_outscale_security_group_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_snapshot.go b/outscale/resource_outscale_snapshot.go index c7fca5866..785b0b5fe 100644 --- a/outscale/resource_outscale_snapshot.go +++ b/outscale/resource_outscale_snapshot.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_snapshot_attributes.go b/outscale/resource_outscale_snapshot_attributes.go index c3d241aea..b5902a442 100644 --- a/outscale/resource_outscale_snapshot_attributes.go +++ b/outscale/resource_outscale_snapshot_attributes.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_snapshot_test.go b/outscale/resource_outscale_snapshot_test.go index f004b8b26..e41ec5a3a 100644 --- a/outscale/resource_outscale_snapshot_test.go +++ b/outscale/resource_outscale_snapshot_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_subnet.go b/outscale/resource_outscale_subnet.go index 0177eb82e..8cd935b7f 100644 --- a/outscale/resource_outscale_subnet.go +++ b/outscale/resource_outscale_subnet.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleOAPISubNet() *schema.Resource { diff --git a/outscale/resource_outscale_subnet_test.go b/outscale/resource_outscale_subnet_test.go index 41e3ab5cb..51163e9f7 100644 --- a/outscale/resource_outscale_subnet_test.go +++ b/outscale/resource_outscale_subnet_test.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func TestAccOutscaleOAPISubNet_basic(t *testing.T) { diff --git a/outscale/resource_outscale_tags.go b/outscale/resource_outscale_tags.go index bdbe48231..e354d5641 100644 --- a/outscale/resource_outscale_tags.go +++ b/outscale/resource_outscale_tags.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_tags_test.go b/outscale/resource_outscale_tags_test.go index 708f65df6..088c3e8f8 100644 --- a/outscale/resource_outscale_tags_test.go +++ b/outscale/resource_outscale_tags_test.go @@ -10,7 +10,7 @@ import ( "github.com/go-test/deep" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_virtual_gateway.go b/outscale/resource_outscale_virtual_gateway.go index 598c61fff..08bdd27d4 100644 --- a/outscale/resource_outscale_virtual_gateway.go +++ b/outscale/resource_outscale_virtual_gateway.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "log" "strings" "time" diff --git a/outscale/resource_outscale_virtual_gateway_link.go b/outscale/resource_outscale_virtual_gateway_link.go index f5f4eda83..463eb6b94 100644 --- a/outscale/resource_outscale_virtual_gateway_link.go +++ b/outscale/resource_outscale_virtual_gateway_link.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_virtual_gateway_link_test.go b/outscale/resource_outscale_virtual_gateway_link_test.go index 947a0845a..ecd1d47e8 100644 --- a/outscale/resource_outscale_virtual_gateway_link_test.go +++ b/outscale/resource_outscale_virtual_gateway_link_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_virtual_gateway_route_propagation.go b/outscale/resource_outscale_virtual_gateway_route_propagation.go index 1d00f3c24..541813152 100644 --- a/outscale/resource_outscale_virtual_gateway_route_propagation.go +++ b/outscale/resource_outscale_virtual_gateway_route_propagation.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "log" "strings" "time" diff --git a/outscale/resource_outscale_virtual_gateway_route_propagation_test.go b/outscale/resource_outscale_virtual_gateway_route_propagation_test.go index 59e143a81..730865fa0 100644 --- a/outscale/resource_outscale_virtual_gateway_route_propagation_test.go +++ b/outscale/resource_outscale_virtual_gateway_route_propagation_test.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "strings" "testing" "time" diff --git a/outscale/resource_outscale_virtual_gateway_test.go b/outscale/resource_outscale_virtual_gateway_test.go index b74404940..bdac3bbbc 100644 --- a/outscale/resource_outscale_virtual_gateway_test.go +++ b/outscale/resource_outscale_virtual_gateway_test.go @@ -3,7 +3,7 @@ package outscale import ( "context" "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "strings" "testing" "time" diff --git a/outscale/resource_outscale_vm.go b/outscale/resource_outscale_vm.go index a910add11..907fd572d 100644 --- a/outscale/resource_outscale_vm.go +++ b/outscale/resource_outscale_vm.go @@ -14,7 +14,7 @@ import ( "github.com/spf13/cast" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" ) diff --git a/outscale/resource_outscale_vm_test.go b/outscale/resource_outscale_vm_test.go index cd2f8e51e..12d9f96b2 100644 --- a/outscale/resource_outscale_vm_test.go +++ b/outscale/resource_outscale_vm_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/aws/aws-sdk-go/aws/awserr" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_volume.go b/outscale/resource_outscale_volume.go index 0f6c710c2..187e233ee 100644 --- a/outscale/resource_outscale_volume.go +++ b/outscale/resource_outscale_volume.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/terraform-providers/terraform-provider-outscale/utils" "github.com/aws/aws-sdk-go/aws/awserr" diff --git a/outscale/resource_outscale_volume_test.go b/outscale/resource_outscale_volume_test.go index d6649c3ad..8e8663c73 100644 --- a/outscale/resource_outscale_volume_test.go +++ b/outscale/resource_outscale_volume_test.go @@ -8,7 +8,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_volumes_link.go b/outscale/resource_outscale_volumes_link.go index a8353d7dd..7ff4db2e7 100644 --- a/outscale/resource_outscale_volumes_link.go +++ b/outscale/resource_outscale_volumes_link.go @@ -8,7 +8,7 @@ import ( "time" "github.com/openlyinc/pointy" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/aws/aws-sdk-go/aws/awserr" diff --git a/outscale/resource_outscale_volumes_link_test.go b/outscale/resource_outscale_volumes_link_test.go index 0d38f1e0e..b16a348ce 100644 --- a/outscale/resource_outscale_volumes_link_test.go +++ b/outscale/resource_outscale_volumes_link_test.go @@ -5,7 +5,7 @@ import ( "os" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" diff --git a/outscale/resource_outscale_vpn_connection.go b/outscale/resource_outscale_vpn_connection.go index ed530e227..726133484 100644 --- a/outscale/resource_outscale_vpn_connection.go +++ b/outscale/resource_outscale_vpn_connection.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" "github.com/spf13/cast" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleVPNConnection() *schema.Resource { diff --git a/outscale/resource_outscale_vpn_connection_route.go b/outscale/resource_outscale_vpn_connection_route.go index ddec8d46b..1c20bcb35 100644 --- a/outscale/resource_outscale_vpn_connection_route.go +++ b/outscale/resource_outscale_vpn_connection_route.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func resourceOutscaleVPNConnectionRoute() *schema.Resource { diff --git a/outscale/resource_outscale_vpn_connection_route_test.go b/outscale/resource_outscale_vpn_connection_route_test.go index 8d95e7265..d40c6a6ca 100644 --- a/outscale/resource_outscale_vpn_connection_route_test.go +++ b/outscale/resource_outscale_vpn_connection_route_test.go @@ -6,7 +6,7 @@ import ( "os" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_vpn_connection_test.go b/outscale/resource_outscale_vpn_connection_test.go index 263a149c6..5d09995d6 100644 --- a/outscale/resource_outscale_vpn_connection_test.go +++ b/outscale/resource_outscale_vpn_connection_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/utils/utils.go b/utils/utils.go index abc07cc6e..2014b169c 100644 --- a/utils/utils.go +++ b/utils/utils.go @@ -5,7 +5,7 @@ import ( "fmt" "strconv" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/spf13/cast" "github.com/aws/aws-sdk-go/aws" diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.gitignore b/vendor/github.com/outscale/osc-sdk-go/v2/.gitignore similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/.gitignore rename to vendor/github.com/outscale/osc-sdk-go/v2/.gitignore diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore b/vendor/github.com/outscale/osc-sdk-go/v2/.openapi-generator-ignore similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/.openapi-generator-ignore rename to vendor/github.com/outscale/osc-sdk-go/v2/.openapi-generator-ignore diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml b/vendor/github.com/outscale/osc-sdk-go/v2/.travis.yml similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/.travis.yml rename to vendor/github.com/outscale/osc-sdk-go/v2/.travis.yml diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/README.md b/vendor/github.com/outscale/osc-sdk-go/v2/README.md similarity index 99% rename from vendor/github.com/outscale/osc-sdk-go/osc/README.md rename to vendor/github.com/outscale/osc-sdk-go/v2/README.md index 3fb0f2728..9b9b68a39 100644 --- a/vendor/github.com/outscale/osc-sdk-go/osc/README.md +++ b/vendor/github.com/outscale/osc-sdk-go/v2/README.md @@ -12,7 +12,7 @@ You can also manage your resources using the [Cockpit](https://wiki.outscale.net This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. - API version: 1.4 -- Package version: 1.0.0 +- Package version: 2.0.0-beta.3 - Build package: org.openapitools.codegen.languages.GoClientCodegen ## Installation @@ -31,6 +31,12 @@ Put the package under your project folder and add the following in import: import sw "./osc" ``` +To use a proxy, set the environment variable `HTTP_PROXY`: + +```golang +os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port") +``` + ## Configuration of Server URL Default configuration comes with `Servers` field that contains server objects as defined in the OpenAPI specification. diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_access_key.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_access_key.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_access_key.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_account.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_account.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_account.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_account.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_api_log.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_api_log.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_api_log.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_client_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_client_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_client_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_dhcp_option.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_dhcp_option.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_dhcp_option.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_direct_link.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_direct_link.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_direct_link_interface.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_direct_link_interface.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_direct_link_interface.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_flexible_gpu.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_flexible_gpu.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_flexible_gpu.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_image.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_image.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_image.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_image.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_internet_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_internet_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_internet_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_keypair.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_keypair.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_keypair.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_listener.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_listener.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_listener.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_load_balancer.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_load_balancer.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_load_balancer_policy.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_load_balancer_policy.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_load_balancer_policy.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_location.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_location.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_location.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_location.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_nat_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_nat_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_nat_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_net.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_net.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_net.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_net_access_point.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_net_access_point.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_net_access_point.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_net_peering.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_net_peering.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_net_peering.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_nic.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_nic.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_nic.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_product_type.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_product_type.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_product_type.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_public_ip.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_public_ip.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_public_ip.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_quota.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_quota.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_quota.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_region.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_region.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_region.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_region.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_route.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_route.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_route.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_route.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_route_table.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_route_table.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_route_table.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_security_group.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_security_group.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_security_group.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_security_group_rule.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_security_group_rule.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_security_group_rule.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_server_certificate.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_server_certificate.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_server_certificate.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_snapshot.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_snapshot.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_snapshot.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_subnet.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_subnet.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_subnet.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_subregion.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_subregion.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_subregion.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_task.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_task.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_task.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_task.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_virtual_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_virtual_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_virtual_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_volume.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_volume.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_volume.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/v2/api_vpn_connection.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/api_vpn_connection.go rename to vendor/github.com/outscale/osc-sdk-go/v2/api_vpn_connection.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/client.go b/vendor/github.com/outscale/osc-sdk-go/v2/client.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/client.go rename to vendor/github.com/outscale/osc-sdk-go/v2/client.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/configuration.go b/vendor/github.com/outscale/osc-sdk-go/v2/configuration.go similarity index 99% rename from vendor/github.com/outscale/osc-sdk-go/osc/configuration.go rename to vendor/github.com/outscale/osc-sdk-go/v2/configuration.go index ac823894b..913463ffe 100644 --- a/vendor/github.com/outscale/osc-sdk-go/osc/configuration.go +++ b/vendor/github.com/outscale/osc-sdk-go/v2/configuration.go @@ -112,7 +112,7 @@ type Configuration struct { func NewConfiguration() *Configuration { cfg := &Configuration{ DefaultHeader: make(map[string]string), - UserAgent: "OpenAPI-Generator/1.0.0/go", + UserAgent: "OpenAPI-Generator/2.0.0-beta.3/go", Debug: false, Servers: ServerConfigurations{ { diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh b/vendor/github.com/outscale/osc-sdk-go/v2/git_push.sh similarity index 98% rename from vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh rename to vendor/github.com/outscale/osc-sdk-go/v2/git_push.sh index babca737b..49c077740 100644 --- a/vendor/github.com/outscale/osc-sdk-go/osc/git_push.sh +++ b/vendor/github.com/outscale/osc-sdk-go/v2/git_push.sh @@ -19,7 +19,7 @@ if [ "$git_user_id" = "" ]; then fi if [ "$git_repo_id" = "" ]; then - git_repo_id="osc-sdk-go/osc" + git_repo_id="osc-sdk-go/v2" echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" fi diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/go.mod b/vendor/github.com/outscale/osc-sdk-go/v2/go.mod similarity index 73% rename from vendor/github.com/outscale/osc-sdk-go/osc/go.mod rename to vendor/github.com/outscale/osc-sdk-go/v2/go.mod index 10c2adcf3..9f940ba94 100644 --- a/vendor/github.com/outscale/osc-sdk-go/osc/go.mod +++ b/vendor/github.com/outscale/osc-sdk-go/v2/go.mod @@ -1,4 +1,4 @@ -module github.com/outscale/osc-sdk-go/osc +module github.com/outscale/osc-sdk-go/v2 go 1.13 diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/go.sum b/vendor/github.com/outscale/osc-sdk-go/v2/go.sum similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/go.sum rename to vendor/github.com/outscale/osc-sdk-go/v2/go.sum diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_accept_net_peering_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_accept_net_peering_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_accept_net_peering_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_accept_net_peering_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_accept_net_peering_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_accepter_net.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_accepter_net.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_accepter_net.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_access_key.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_access_key.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_access_key.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_access_key_secret_key.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_access_key_secret_key.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_access_key_secret_key.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_access_log.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_access_log.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_access_log.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_account.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_account.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_account.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_account.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_application_sticky_cookie_policy.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_application_sticky_cookie_policy.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_application_sticky_cookie_policy.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_backend_vm_health.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_backend_vm_health.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_backend_vm_health.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_created.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_created.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_created.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_image.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_image.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_image.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_vm_creation.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_creation.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_vm_creation.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_vm_update.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_block_device_mapping_vm_update.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_block_device_mapping_vm_update.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_created.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_created.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_created.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_to_create.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_create.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_to_create.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_to_update_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_bsu_to_update_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_bsu_to_update_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_check_authentication_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_check_authentication_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_check_authentication_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_check_authentication_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_check_authentication_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_client_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_client_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_client_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_consumption_entry.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_consumption_entry.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_consumption_entry.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_access_key_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_access_key_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_access_key_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_access_key_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_access_key_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_account_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_account_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_account_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_account_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_account_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_client_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_client_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_client_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_client_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_client_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_dhcp_options_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_dhcp_options_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_dhcp_options_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_dhcp_options_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_dhcp_options_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_interface_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_interface_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_interface_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_interface_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_interface_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_direct_link_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_direct_link_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_flexible_gpu_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_flexible_gpu_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_flexible_gpu_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_flexible_gpu_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_flexible_gpu_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_export_task_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_export_task_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_export_task_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_export_task_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_export_task_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_image_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_image_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_internet_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_internet_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_internet_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_internet_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_internet_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_keypair_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_keypair_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_keypair_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_keypair_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_keypair_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_listener_rule_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_listener_rule_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_listener_rule_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_listener_rule_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_listener_rule_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_listeners_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_listeners_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_listeners_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_listeners_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_listeners_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_policy_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_policy_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_policy_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_policy_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_policy_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_load_balancer_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_load_balancer_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_nat_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_nat_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_nat_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_nat_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_nat_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_access_point_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_access_point_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_access_point_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_access_point_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_access_point_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_peering_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_peering_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_peering_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_peering_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_peering_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_net_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_net_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_nic_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_nic_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_nic_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_nic_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_nic_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_public_ip_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_public_ip_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_public_ip_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_public_ip_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_public_ip_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_table_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_table_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_table_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_route_table_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_route_table_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_rule_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_rule_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_rule_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_security_group_rule_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_security_group_rule_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_server_certificate_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_server_certificate_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_server_certificate_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_server_certificate_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_server_certificate_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_export_task_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_export_task_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_export_task_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_export_task_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_export_task_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_snapshot_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_snapshot_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_subnet_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_subnet_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_subnet_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_subnet_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_subnet_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_virtual_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_virtual_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_virtual_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_virtual_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_virtual_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_volume_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_volume_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_volume_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_volume_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_volume_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_route_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_route_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_route_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_create_vpn_connection_route_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_create_vpn_connection_route_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_access_key_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_access_key_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_access_key_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_access_key_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_access_key_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_client_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_client_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_client_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_client_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_client_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_dhcp_options_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_dhcp_options_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_dhcp_options_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_dhcp_options_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_dhcp_options_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_interface_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_interface_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_interface_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_interface_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_interface_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_direct_link_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_direct_link_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_export_task_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_export_task_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_export_task_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_export_task_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_export_task_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_flexible_gpu_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_flexible_gpu_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_flexible_gpu_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_flexible_gpu_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_flexible_gpu_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_image_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_image_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_image_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_image_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_image_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_internet_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_internet_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_internet_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_internet_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_internet_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_keypair_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_keypair_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_keypair_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_keypair_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_keypair_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_listener_rule_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_listener_rule_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_listener_rule_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_listener_rule_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_listener_rule_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_listeners_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_listeners_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_listeners_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_listeners_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_listeners_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_policy_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_policy_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_policy_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_policy_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_policy_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_load_balancer_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_load_balancer_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nat_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nat_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nat_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nat_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nat_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_access_point_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_access_point_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_access_point_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_access_point_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_access_point_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_peering_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_peering_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_peering_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_peering_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_peering_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_net_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_net_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nic_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nic_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nic_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_nic_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_nic_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_public_ip_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_public_ip_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_public_ip_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_public_ip_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_public_ip_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_table_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_table_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_table_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_route_table_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_route_table_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_rule_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_rule_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_rule_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_security_group_rule_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_security_group_rule_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_server_certificate_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_server_certificate_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_server_certificate_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_server_certificate_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_server_certificate_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_snapshot_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_snapshot_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_snapshot_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_snapshot_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_snapshot_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_subnet_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_subnet_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_subnet_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_subnet_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_subnet_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_virtual_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_virtual_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_virtual_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_virtual_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_virtual_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_volume_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_volume_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_volume_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_volume_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_volume_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_route_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_route_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_route_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_delete_vpn_connection_route_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_delete_vpn_connection_route_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_deregister_vms_in_load_balancer_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_deregister_vms_in_load_balancer_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_deregister_vms_in_load_balancer_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_deregister_vms_in_load_balancer_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_deregister_vms_in_load_balancer_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_dhcp_options_set.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_dhcp_options_set.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_dhcp_options_set.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link_interface.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interface.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link_interface.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link_interfaces.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_direct_link_interfaces.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_direct_link_interfaces.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_error_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_error_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_error_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_errors.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_errors.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_errors.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_access_keys.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_access_keys.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_access_keys.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_api_log.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_api_log.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_api_log.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_client_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_client_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_client_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_dhcp_options.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_dhcp_options.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_dhcp_options.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_direct_link.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_direct_link.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_direct_link_interface.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_direct_link_interface.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_direct_link_interface.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_export_task.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_export_task.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_export_task.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_flexible_gpu.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_flexible_gpu.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_flexible_gpu.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_image.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_image.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_image.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_internet_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_internet_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_internet_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_keypair.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_keypair.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_keypair.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_listener_rule.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_listener_rule.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_listener_rule.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_load_balancer.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_load_balancer.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_load_balancer.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_nat_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nat_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_nat_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net_access_point.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_access_point.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net_access_point.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net_peering.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_net_peering.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_net_peering.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_nic.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_nic.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_nic.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_product_type.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_product_type.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_product_type.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_public_ip.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_public_ip.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_public_ip.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_quota.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_quota.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_quota.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_route_table.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_route_table.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_route_table.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_security_group.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_security_group.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_security_group.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_server_certificate.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_server_certificate.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_server_certificate.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_snapshot.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_snapshot.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_snapshot.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_subnet.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subnet.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_subnet.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_subregion.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_subregion.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_subregion.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_virtual_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_virtual_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_virtual_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vm_type.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vm_type.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vm_type.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vms_state.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vms_state.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vms_state.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_volume.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_volume.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_volume.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vpn_connection.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_filters_vpn_connection.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_filters_vpn_connection.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_flexible_gpu.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_flexible_gpu.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_flexible_gpu_catalog.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_flexible_gpu_catalog.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_flexible_gpu_catalog.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_health_check.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_health_check.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_health_check.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_image.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_image.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_image.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_image.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_image_export_task.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_image_export_task.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_image_export_task.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_internet_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_internet_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_internet_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_keypair.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_keypair.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_keypair.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_keypair_created.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_keypair_created.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_keypair_created.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_flexible_gpu_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_flexible_gpu_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_flexible_gpu_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_flexible_gpu_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_flexible_gpu_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_internet_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_internet_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_internet_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_internet_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_internet_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_to_update.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_nic_to_update.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_nic_to_update.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_private_ips_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_private_ips_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_private_ips_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_private_ips_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_private_ips_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_light_for_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_light_for_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_light_for_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_public_ip_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_public_ip_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_route_table_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_route_table_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_virtual_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_virtual_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_virtual_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_virtual_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_virtual_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_volume_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_volume_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_link_volume_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_link_volume_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_link_volume_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_linked_volume.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_linked_volume.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_linked_volume.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_listener.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_listener.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_listener.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_listener_for_creation.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_listener_for_creation.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_listener_for_creation.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_listener_rule.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_listener_rule.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_listener_rule_for_creation.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_listener_rule_for_creation.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_listener_rule_for_creation.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_sticky_cookie_policy.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_sticky_cookie_policy.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_sticky_cookie_policy.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_load_balancer_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_load_balancer_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_location.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_location.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_location.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_location.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_log.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_log.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_log.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_log.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_maintenance_event.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_maintenance_event.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_maintenance_event.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_nat_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_nat_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_nat_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_net.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_net.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_net.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_net_access_point.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_net_access_point.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_net_access_point.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_net_peering.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_net_peering.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_net_peering_state.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_net_peering_state.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_net_peering_state.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_net_to_virtual_gateway_link.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_net_to_virtual_gateway_link.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_net_to_virtual_gateway_link.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_nic.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_nic.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_nic.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_nic_for_vm_creation.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_nic_for_vm_creation.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_nic_for_vm_creation.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_nic_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_nic_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_nic_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_osu_api_key.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_osu_api_key.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_osu_api_key.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_osu_export.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_osu_export.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_osu_export.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_permissions_on_resource.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_permissions_on_resource.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_permissions_on_resource_creation.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_permissions_on_resource_creation.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_permissions_on_resource_creation.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_placement.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_placement.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_placement.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip_light_for_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_private_ip_light_for_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_private_ip_light_for_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_product_type.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_product_type.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_product_type.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_public_ip.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_public_ip.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_public_ip_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_public_ip_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_public_ip_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_quota.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_quota.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_quota.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_quota_types.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_quota_types.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_quota_types.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_access_keys_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_access_keys_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_access_keys_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_access_keys_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_access_keys_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_accounts_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_accounts_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_accounts_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_accounts_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_accounts_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_admin_password_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_admin_password_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_admin_password_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_admin_password_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_admin_password_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_api_logs_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_api_logs_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_api_logs_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_api_logs_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_api_logs_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_client_gateways_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_client_gateways_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_client_gateways_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_client_gateways_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_client_gateways_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_console_output_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_console_output_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_console_output_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_console_output_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_console_output_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_consumption_account_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_consumption_account_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_consumption_account_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_consumption_account_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_consumption_account_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_dhcp_options_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_dhcp_options_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_dhcp_options_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_dhcp_options_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_dhcp_options_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_link_interfaces_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_link_interfaces_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_link_interfaces_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_link_interfaces_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_link_interfaces_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_links_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_links_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_links_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_direct_links_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_direct_links_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpu_catalog_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpu_catalog_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpu_catalog_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpu_catalog_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpu_catalog_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpus_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpus_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpus_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_flexible_gpus_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_flexible_gpus_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_image_export_tasks_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_image_export_tasks_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_image_export_tasks_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_image_export_tasks_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_image_export_tasks_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_images_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_images_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_images_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_images_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_images_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_internet_services_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_internet_services_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_internet_services_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_internet_services_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_internet_services_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_keypairs_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_keypairs_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_keypairs_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_keypairs_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_keypairs_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_listener_rules_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_listener_rules_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_listener_rules_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_listener_rules_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_listener_rules_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancer_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancer_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancer_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancer_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancer_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancers_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancers_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancers_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_load_balancers_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_load_balancers_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_locations_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_locations_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_locations_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_locations_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_locations_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nat_services_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nat_services_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nat_services_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nat_services_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nat_services_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_point_services_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_point_services_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_point_services_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_point_services_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_point_services_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_points_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_points_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_points_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_access_points_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_access_points_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_peerings_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_peerings_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_peerings_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_net_peerings_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_net_peerings_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nets_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nets_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nets_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nets_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nets_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nics_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nics_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_nics_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_nics_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_nics_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_product_types_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_product_types_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_product_types_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_product_types_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_product_types_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ip_ranges_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ip_ranges_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ip_ranges_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ip_ranges_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ip_ranges_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ips_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ips_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ips_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_public_ips_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_public_ips_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_quotas_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_quotas_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_quotas_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_quotas_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_quotas_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_regions_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_regions_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_regions_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_regions_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_regions_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_route_tables_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_route_tables_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_route_tables_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_route_tables_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_route_tables_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_secret_access_key_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_secret_access_key_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_secret_access_key_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_secret_access_key_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_secret_access_key_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_security_groups_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_security_groups_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_security_groups_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_security_groups_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_security_groups_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_server_certificates_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_server_certificates_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_server_certificates_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_server_certificates_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_server_certificates_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshot_export_tasks_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshot_export_tasks_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshot_export_tasks_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshot_export_tasks_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshot_export_tasks_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshots_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshots_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshots_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_snapshots_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_snapshots_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_subnets_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_subnets_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_subnets_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_subnets_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_subnets_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_subregions_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_subregions_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_subregions_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_subregions_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_subregions_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_tags_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_tags_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_tags_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_tags_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_tags_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_virtual_gateways_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_virtual_gateways_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_virtual_gateways_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_virtual_gateways_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_virtual_gateways_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vm_types_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vm_types_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vm_types_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vm_types_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vm_types_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_health_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_health_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_health_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_health_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_health_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_state_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_state_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_state_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vms_state_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vms_state_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_volumes_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_volumes_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_volumes_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_volumes_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_volumes_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vpn_connections_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vpn_connections_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_read_vpn_connections_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_read_vpn_connections_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_read_vpn_connections_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reboot_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reboot_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reboot_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reboot_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reboot_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_region.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_region.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_region.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_region.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_register_vms_in_load_balancer_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_register_vms_in_load_balancer_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_register_vms_in_load_balancer_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_register_vms_in_load_balancer_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_register_vms_in_load_balancer_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reject_net_peering_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reject_net_peering_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reject_net_peering_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reject_net_peering_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reject_net_peering_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reset_account_password_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reset_account_password_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_reset_account_password_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_reset_account_password_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_reset_account_password_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_resource_load_balancer_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_resource_load_balancer_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_resource_load_balancer_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_resource_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_resource_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_resource_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_response_context.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_response_context.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_response_context.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_route.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_route.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_route.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_route_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_route_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_route_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_route_propagating_virtual_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_route_propagating_virtual_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_route_propagating_virtual_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_route_table.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_route_table.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_route_table.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_security_group.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_security_group.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_security_group.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_security_group_light.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_light.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_security_group_light.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_security_group_rule.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_security_group_rule.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_security_group_rule.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_security_groups_member.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_security_groups_member.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_security_groups_member.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_send_reset_password_email_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_send_reset_password_email_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_send_reset_password_email_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_send_reset_password_email_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_send_reset_password_email_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_server_certificate.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_server_certificate.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_server_certificate.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_service.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_service.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_service.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_service.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_snapshot.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_snapshot.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_snapshot_export_task.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_snapshot_export_task.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_snapshot_export_task.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_source_net.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_source_net.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_source_net.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_source_security_group.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_source_security_group.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_source_security_group.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_start_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_start_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_start_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_start_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_start_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_state_comment.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_state_comment.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_state_comment.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_stop_vms_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_stop_vms_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_stop_vms_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_stop_vms_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_stop_vms_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_subnet.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_subnet.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_subnet.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_subregion.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_subregion.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_subregion.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_tag.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_tag.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_tag.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_flexible_gpu_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_flexible_gpu_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_flexible_gpu_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_flexible_gpu_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_flexible_gpu_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_internet_service_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_internet_service_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_internet_service_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_internet_service_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_internet_service_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_nic_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_nic_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_nic_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_nic_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_nic_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_private_ips_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_private_ips_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_private_ips_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_private_ips_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_private_ips_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_public_ip_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_public_ip_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_public_ip_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_public_ip_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_public_ip_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_route_table_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_route_table_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_route_table_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_route_table_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_route_table_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_virtual_gateway_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_virtual_gateway_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_virtual_gateway_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_virtual_gateway_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_virtual_gateway_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_volume_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_volume_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_volume_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_unlink_volume_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_unlink_volume_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_access_key_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_access_key_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_access_key_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_access_key_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_access_key_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_account_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_account_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_account_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_account_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_account_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_flexible_gpu_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_flexible_gpu_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_flexible_gpu_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_flexible_gpu_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_flexible_gpu_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_image_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_image_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_image_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_image_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_image_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_listener_rule_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_listener_rule_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_listener_rule_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_listener_rule_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_listener_rule_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_load_balancer_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_load_balancer_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_load_balancer_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_load_balancer_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_load_balancer_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_access_point_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_access_point_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_access_point_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_access_point_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_access_point_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_net_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_net_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_nic_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_nic_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_nic_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_nic_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_nic_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_propagation_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_propagation_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_propagation_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_propagation_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_propagation_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_route_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_route_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_server_certificate_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_server_certificate_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_server_certificate_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_server_certificate_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_server_certificate_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_snapshot_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_snapshot_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_snapshot_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_snapshot_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_snapshot_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_subnet_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_subnet_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_subnet_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_subnet_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_subnet_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_vm_request.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_request.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_vm_request.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_update_vm_response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_update_vm_response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_update_vm_response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_virtual_gateway.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_virtual_gateway.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_virtual_gateway.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_vm.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_vm.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_vm.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_vm_state.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_vm_state.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_vm_state.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_vm_states.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_vm_states.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_vm_states.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_vm_type.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_vm_type.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_vm_type.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_volume.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_volume.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_volume.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_vpn_connection.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_vpn_connection.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_vpn_connection.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/model_with.go b/vendor/github.com/outscale/osc-sdk-go/v2/model_with.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/model_with.go rename to vendor/github.com/outscale/osc-sdk-go/v2/model_with.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/response.go b/vendor/github.com/outscale/osc-sdk-go/v2/response.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/response.go rename to vendor/github.com/outscale/osc-sdk-go/v2/response.go diff --git a/vendor/github.com/outscale/osc-sdk-go/osc/utils.go b/vendor/github.com/outscale/osc-sdk-go/v2/utils.go similarity index 100% rename from vendor/github.com/outscale/osc-sdk-go/osc/utils.go rename to vendor/github.com/outscale/osc-sdk-go/v2/utils.go diff --git a/vendor/modules.txt b/vendor/modules.txt index c97d5a8b7..37ad076f9 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -218,8 +218,8 @@ github.com/mitchellh/reflectwalk github.com/oklog/run # github.com/openlyinc/pointy v1.1.2 github.com/openlyinc/pointy -# github.com/outscale/osc-sdk-go/osc v0.0.0-20201014193009-10509d4e084c -github.com/outscale/osc-sdk-go/osc +# github.com/outscale/osc-sdk-go/v2 v2.0.0-beta.3 +github.com/outscale/osc-sdk-go/v2 # github.com/posener/complete v1.2.1 github.com/posener/complete github.com/posener/complete/cmd From 270d3549a2805ea1d2c81891d5338f1bf3836e89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Tue, 3 Nov 2020 11:10:55 -0700 Subject: [PATCH 013/218] fix: fixed error about access key --- outscale/resource_outscale_access_key.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_access_key.go b/outscale/resource_outscale_access_key.go index c2f0cb800..c4e5b8b01 100644 --- a/outscale/resource_outscale_access_key.go +++ b/outscale/resource_outscale_access_key.go @@ -59,7 +59,7 @@ func resourceOutscaleAccessKeyCreate(d *schema.ResourceData, meta interface{}) e var res oscgo.CreateAccessKeyResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - res, _, err = conn.AccessKeyApi.CreateAccessKey(context.Background()).Execute() + res, _, err = conn.AccessKeyApi.CreateAccessKey(context.Background()).CreateAccessKeyRequest(oscgo.CreateAccessKeyRequest{}).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:") { return resource.RetryableError(err) From 829b826d1c06ae92991d19a394bba70da39ebe40 Mon Sep 17 00:00:00 2001 From: "meriem.zouari" Date: Thu, 12 Nov 2020 09:29:07 +0000 Subject: [PATCH 014/218] add dependency to "outscale_nat_service" resource to avoid nat creation failure --- examples/main.tf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/main.tf b/examples/main.tf index fd27f6051..21a85bff7 100644 --- a/examples/main.tf +++ b/examples/main.tf @@ -315,7 +315,7 @@ resource "outscale_route" "route019" { } resource "outscale_nat_service" "nat_service019" { - depends_on = [outscale_route.route019] + depends_on = [outscale_route.route019,outscale_route_table_link.route_table_link019] subnet_id = outscale_subnet.subnet019.subnet_id public_ip_id = outscale_public_ip.public_ip019.public_ip_id tags { @@ -953,4 +953,4 @@ data "outscale_access_key" "outscale_access_key_042d"{ values = [outscale_access_key.outscale_access_key_042.access_key_id] } } - \ No newline at end of file + From 57af898c048001ecb5a51f3fc82d08ccb157e98b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Wed, 18 Nov 2020 11:14:46 -0700 Subject: [PATCH 015/218] fix: added retry for unlink internet service --- .../resource_outscale_internet_service_link.go | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_internet_service_link.go b/outscale/resource_outscale_internet_service_link.go index b7365bddd..677570810 100644 --- a/outscale/resource_outscale_internet_service_link.go +++ b/outscale/resource_outscale_internet_service_link.go @@ -2,8 +2,8 @@ package outscale import ( "context" - "fmt" + "strings" "time" oscgo "github.com/outscale/osc-sdk-go/v2" @@ -185,7 +185,19 @@ func resourceOutscaleOAPIInternetServiceLinkDelete(d *schema.ResourceData, meta NetId: internetService.GetNetId(), } - _, _, err = conn.InternetServiceApi.UnlinkInternetService(context.Background()).UnlinkInternetServiceRequest(req).Execute() + err = resource.Retry(60*time.Second, func() *resource.RetryError { + _, res, err := conn.InternetServiceApi.UnlinkInternetService(context.Background()).UnlinkInternetServiceRequest(req).Execute() + if err != nil { + if strings.Contains(fmt.Sprint(err), "Failed Dependency") { + return resource.RetryableError(err) // retry + } + return resource.NonRetryableError(err) + } + if res != nil && res.StatusCode == 424 { + return resource.RetryableError(err) // retry + } + return nil + }) if err != nil { return fmt.Errorf("error unlink Internet Service (%s): %s", d.Id(), err) } From 32f4dd2e5ef3c86b19f78d860656ee4dded54af2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Wed, 18 Nov 2020 12:41:34 -0700 Subject: [PATCH 016/218] fix: added retry for creating nat services to avoid error conflicts --- outscale/resource_outscale_nat_service.go | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_nat_service.go b/outscale/resource_outscale_nat_service.go index dcfde327c..fe5b407cc 100644 --- a/outscale/resource_outscale_nat_service.go +++ b/outscale/resource_outscale_nat_service.go @@ -2,6 +2,7 @@ package outscale import ( "context" + "strings" "fmt" "log" @@ -77,7 +78,23 @@ func resourceOAPINatServiceCreate(d *schema.ResourceData, meta interface{}) erro SubnetId: d.Get("subnet_id").(string), } - resp, _, err := conn.NatServiceApi.CreateNatService(context.Background()).CreateNatServiceRequest(req).Execute() + var resp oscgo.CreateNatServiceResponse + var err error + + err = resource.Retry(60*time.Second, func() *resource.RetryError { + res, contex, err := conn.NatServiceApi.CreateNatService(context.Background()).CreateNatServiceRequest(req).Execute() + if err != nil { + if strings.Contains(fmt.Sprint(err), "Conflict") { + return resource.RetryableError(err) // retry + } + return resource.NonRetryableError(err) + } + if contex != nil && contex.StatusCode == 409 { + return resource.RetryableError(err) // retry + } + resp = res + return nil + }) if err != nil { return fmt.Errorf("Error creating Nat Service: %s", err.Error()) } From 5da4d8224c17e784f762f3fb075e3eb92fcc2dec Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 6 Mar 2020 15:32:37 +0100 Subject: [PATCH 017/218] Revert "rm resource_outscale_oapi_load_balancer_vms" This reverts commit 98cd6879e83515d3043723effbe132bdff7002b8. --- ...esource_outscale_oapi_load_balancer_vms.go | 189 ++++++++++++++++++ ...ce_outscale_oapi_load_balancer_vms_test.go | 77 +++++++ 2 files changed, 266 insertions(+) create mode 100644 outscale/resource_outscale_oapi_load_balancer_vms.go create mode 100644 outscale/resource_outscale_oapi_load_balancer_vms_test.go diff --git a/outscale/resource_outscale_oapi_load_balancer_vms.go b/outscale/resource_outscale_oapi_load_balancer_vms.go new file mode 100644 index 000000000..761bed76b --- /dev/null +++ b/outscale/resource_outscale_oapi_load_balancer_vms.go @@ -0,0 +1,189 @@ +package outscale + +import ( + "fmt" + "log" + "strings" + "time" + + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" +) + +func resourceOutscaleOAPILBUAttachment() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleOAPILBUAttachmentCreate, + Read: resourceOutscaleOAPILBUAttachmentRead, + Delete: resourceOutscaleOAPILBUAttachmentDelete, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + ForceNew: true, + Required: true, + }, + + "backend_vm_id": &schema.Schema{ + Type: schema.TypeList, + ForceNew: true, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "vm_id": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + }, + } +} + +func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + e, eok := d.GetOk("load_balancer_name") + i, iok := d.GetOk("backend_vm_id") + + if !eok && !iok { + return fmt.Errorf("please provide the required attributes load_balancer_name and backend_vm_id") + } + + lb := make([]*lbu.Instance, len(i.([]interface{}))) + + for k, v := range i.([]interface{}) { + ins := v.(map[string]interface{})["vm_id"] + lb[k] = &lbu.Instance{InstanceId: aws.String(ins.(string))} + } + + registerInstancesOpts := lbu.RegisterInstancesWithLoadBalancerInput{ + LoadBalancerName: aws.String(e.(string)), + Instances: lb, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.RegisterInstancesWithLoadBalancer(®isterInstancesOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure registering backend_vm_id with LBU: %s", err) + } + + d.SetId(resource.PrefixedUniqueId(fmt.Sprintf("%s-", e))) + + return nil +} + +func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + e := d.Get("load_balancer_name").(string) + expected := d.Get("backend_vm_id").([]interface{}) + + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(e)}, + } + + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancersResult != nil { + describeResp = resp.DescribeLoadBalancersResult + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + log.Printf("[ERROR] LBU %s not found", e) + d.SetId("") + return nil + } + return fmt.Errorf("Error retrieving LBU: %s", err) + } + if len(describeResp.LoadBalancerDescriptions) != 1 { + log.Printf("[ERROR] Unable to find LBU: %v", describeResp.LoadBalancerDescriptions) + d.SetId("") + return nil + } + + found := false + for _, i := range describeResp.LoadBalancerDescriptions[0].Instances { + for k1 := range expected { + instance := expected[k1].(map[string]interface{})["vm_id"].(string) + if instance == *i.InstanceId { + d.Set("backend_vm_id", expected) + found = true + } + } + } + + if !found { + log.Printf("[WARN] i %s not found in lbu attachments", expected) + d.SetId("") + } + + return nil +} + +func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + e := d.Get("load_balancer_name").(string) + i := d.Get("backend_vm_id").([]interface{}) + + lb := make([]*lbu.Instance, len(i)) + + for k, v := range i { + ins := v.(map[string]interface{})["vm_id"] + lb[k] = &lbu.Instance{InstanceId: aws.String(ins.(string))} + } + + deRegisterInstancesOpts := lbu.DeregisterInstancesFromLoadBalancerInput{ + LoadBalancerName: aws.String(e), + Instances: lb, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err := conn.API.DeregisterInstancesFromLoadBalancer(&deRegisterInstancesOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure deregistering backend_vm_id from LBU: %s", err) + } + + return nil +} diff --git a/outscale/resource_outscale_oapi_load_balancer_vms_test.go b/outscale/resource_outscale_oapi_load_balancer_vms_test.go new file mode 100644 index 000000000..c26310e30 --- /dev/null +++ b/outscale/resource_outscale_oapi_load_balancer_vms_test.go @@ -0,0 +1,77 @@ +package outscale + +import ( + "fmt" + "os" + "strconv" + "testing" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { + o := os.Getenv("OUTSCALE_OAPI") + + oapi, err := strconv.ParseBool(o) + if err != nil { + oapi = false + } + + if !oapi { + t.Skip() + } + + var conf lbu.LoadBalancerDescription + + testCheckInstanceAttached := func(count int) resource.TestCheckFunc { + return func(*terraform.State) error { + if len(conf.Instances) != count { + return fmt.Errorf("backend_vm_id count does not match") + } + return nil + } + } + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + resource.TestStep{ + Config: testAccOutscaleOAPILBUAttachmentConfig1, + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + testCheckInstanceAttached(1), + ), + }, + }, + }) +} + +// add one attachment +const testAccOutscaleOAPILBUAttachmentConfig1 = ` +resource "outscale_load_balancer" "bar" { + load_balancer_name = "load-test" + + availability_zones = ["eu-west-2a"] + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } +} + +resource "outscale_vm" "foo1" { + image_id = "ami-8a6a0120" + type = "t2.micro" +} + +resource "outscale_load_balancer_vms" "foo1" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + backend_vm_id = ["${outscale_vm.foo1.id}"] +} +` From 7459d55be15a23336bac1d4009f9a54efae1de74 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 13 Mar 2020 17:06:57 +0100 Subject: [PATCH 018/218] LBU: resource_outscale_oapi_load_balancer_vms.go and test initial port Signed-off-by: matthias.gatto --- ...esource_outscale_oapi_load_balancer_vms.go | 106 +++++++++++------- ...ce_outscale_oapi_load_balancer_vms_test.go | 19 +--- 2 files changed, 68 insertions(+), 57 deletions(-) diff --git a/outscale/resource_outscale_oapi_load_balancer_vms.go b/outscale/resource_outscale_oapi_load_balancer_vms.go index 761bed76b..d0788b5f2 100644 --- a/outscale/resource_outscale_oapi_load_balancer_vms.go +++ b/outscale/resource_outscale_oapi_load_balancer_vms.go @@ -1,14 +1,15 @@ package outscale import ( + "context" "fmt" "log" "strings" "time" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/aws/aws-sdk-go/aws" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" ) @@ -20,13 +21,13 @@ func resourceOutscaleOAPILBUAttachment() *schema.Resource { Delete: resourceOutscaleOAPILBUAttachmentDelete, Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, ForceNew: true, Required: true, }, - "backend_vm_id": &schema.Schema{ + "backend_vm_id": { Type: schema.TypeList, ForceNew: true, Required: true, @@ -44,7 +45,7 @@ func resourceOutscaleOAPILBUAttachment() *schema.Resource { } func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI e, eok := d.GetOk("load_balancer_name") i, iok := d.GetOk("backend_vm_id") @@ -53,21 +54,26 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf return fmt.Errorf("please provide the required attributes load_balancer_name and backend_vm_id") } - lb := make([]*lbu.Instance, len(i.([]interface{}))) + m := i.([]interface{}) + a := make([]string, len(m)) + for k, v := range m { + a[k] = v.(string) + } - for k, v := range i.([]interface{}) { - ins := v.(map[string]interface{})["vm_id"] - lb[k] = &lbu.Instance{InstanceId: aws.String(ins.(string))} + req := oscgo.RegisterVmsInLoadBalancerRequest{ + LoadBalancerName: e.(string), + BackendVmIds: a, } - registerInstancesOpts := lbu.RegisterInstancesWithLoadBalancerInput{ - LoadBalancerName: aws.String(e.(string)), - Instances: lb, + registerInstancesOpts := oscgo.RegisterVmsInLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.RegisterInstancesWithLoadBalancer(®isterInstancesOpts) + _, _, err = conn.LoadBalancerApi. + RegisterVmsInLoadBalancer(context.Background(), + ®isterInstancesOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -89,20 +95,29 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf } func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI e := d.Get("load_balancer_name").(string) expected := d.Get("backend_vm_id").([]interface{}) - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(e)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{e}, + } + + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -111,31 +126,32 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancersResult != nil { - describeResp = resp.DescribeLoadBalancersResult - } return nil }) if err != nil { - if isLoadBalancerNotFound(err) { - log.Printf("[ERROR] LBU %s not found", e) - d.SetId("") - return nil - } + /* + if isLoadBalancerNotFound(err) { + log.Printf("[ERROR] LBU %s not found", e) + d.SetId("") + return nil + } + */ return fmt.Errorf("Error retrieving LBU: %s", err) } - if len(describeResp.LoadBalancerDescriptions) != 1 { - log.Printf("[ERROR] Unable to find LBU: %v", describeResp.LoadBalancerDescriptions) - d.SetId("") - return nil - } found := false - for _, i := range describeResp.LoadBalancerDescriptions[0].Instances { + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", expected) + } + + lb := (lbs)[0] + + for _, v := range *lb.BackendVmIds { for k1 := range expected { - instance := expected[k1].(map[string]interface{})["vm_id"].(string) - if instance == *i.InstanceId { + sid := expected[k1].(string) + if sid == v { d.Set("backend_vm_id", expected) found = true } @@ -151,25 +167,29 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac } func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI e := d.Get("load_balancer_name").(string) i := d.Get("backend_vm_id").([]interface{}) - lb := make([]*lbu.Instance, len(i)) + lb := make([]string, len(i)) for k, v := range i { - ins := v.(map[string]interface{})["vm_id"] - lb[k] = &lbu.Instance{InstanceId: aws.String(ins.(string))} + lb[k] = v.(string) } - deRegisterInstancesOpts := lbu.DeregisterInstancesFromLoadBalancerInput{ - LoadBalancerName: aws.String(e), - Instances: lb, + req := oscgo.DeregisterVmsInLoadBalancerRequest{ + LoadBalancerName: e, + BackendVmIds: lb, + } + deRegisterInstancesOpts := oscgo.DeregisterVmsInLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err := conn.API.DeregisterInstancesFromLoadBalancer(&deRegisterInstancesOpts) + _, _, err := conn.LoadBalancerApi. + DeregisterVmsInLoadBalancer(context.Background(), + &deRegisterInstancesOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { diff --git a/outscale/resource_outscale_oapi_load_balancer_vms_test.go b/outscale/resource_outscale_oapi_load_balancer_vms_test.go index c26310e30..dda429c68 100644 --- a/outscale/resource_outscale_oapi_load_balancer_vms_test.go +++ b/outscale/resource_outscale_oapi_load_balancer_vms_test.go @@ -3,31 +3,22 @@ package outscale import ( "fmt" "os" - "strconv" "testing" "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/terraform" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + + oscgo "github.com/marinsalinas/osc-sdk-go" ) func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { o := os.Getenv("OUTSCALE_OAPI") - oapi, err := strconv.ParseBool(o) - if err != nil { - oapi = false - } - - if !oapi { - t.Skip() - } - - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer testCheckInstanceAttached := func(count int) resource.TestCheckFunc { return func(*terraform.State) error { - if len(conf.Instances) != count { + if len(*conf.BackendVmIds) != count { return fmt.Errorf("backend_vm_id count does not match") } return nil @@ -40,7 +31,7 @@ func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: testAccOutscaleOAPILBUAttachmentConfig1, Check: resource.ComposeTestCheckFunc( testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), From 64e8d94efaa7a8e536632cd6d2dcf35f7d33b093 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 20 Mar 2020 09:49:32 +0100 Subject: [PATCH 019/218] Revert "LBU-remove: rm resource_outscale_load_balancer_ssl_certificate" This reverts commit a67f053df30a4aaadddafcf2d70b12e60294976b. --- ..._outscale_load_balancer_ssl_certificate.go | 147 ++++++++++++++++++ ...cale_load_balancer_ssl_certificate_test.go | 85 ++++++++++ 2 files changed, 232 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_ssl_certificate.go create mode 100644 outscale/resource_outscale_load_balancer_ssl_certificate_test.go diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate.go b/outscale/resource_outscale_load_balancer_ssl_certificate.go new file mode 100644 index 000000000..101853c1b --- /dev/null +++ b/outscale/resource_outscale_load_balancer_ssl_certificate.go @@ -0,0 +1,147 @@ +package outscale + +import ( + "fmt" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancerSSLCertificate() *schema.Resource { + return &schema.Resource{ + Read: resourceOutscaleOAPILoadBalancerSSLCertificateRead, + Create: resourceOutscaleOAPILoadBalancerSSLCertificateCreate, + Update: resourceOutscaleOAPILoadBalancerSSLCertificateUpdate, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Delete: resourceOutscaleOAPILoadBalancerSSLCertificateDelete, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "load_balancer_port": { + Type: schema.TypeInt, + Required: true, + ForceNew: true, + }, + "server_certificate_id": { + Type: schema.TypeString, + Required: true, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + ename, ok := d.GetOk("load_balancer_name") + port, pok := d.GetOk("load_balancer_port") + ssl, sok := d.GetOk("server_certificate_id") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + if !pok { + return fmt.Errorf("please provide the load_balancer_port argument") + } + + if !sok { + return fmt.Errorf("please provide server_certificate_id argument") + } + + opts := lbu.SetLoadBalancerListenerSSLCertificateInput{ + LoadBalancerName: aws.String(ename.(string)), + LoadBalancerPort: aws.Int64(int64(port.(int))), + SSLCertificateId: aws.String(ssl.(string)), + } + var err error + var resp = &lbu.SetLoadBalancerListenerSSLCertificateOutput{} + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.SetLoadBalancerListenerSSLCertificate(&opts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) + } + + if resp.ResponseMetadata != nil { + d.Set("request_id", resp.ResponseMetadata.RequestID) + } + + d.SetId(ename.(string)) + + return resourceOutscaleOAPILoadBalancerSSLCertificateRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerSSLCertificateUpdate(d *schema.ResourceData, meta interface{}) error { + if !d.HasChange("server_certificate_id") { + return nil + } + + conn := meta.(*OutscaleClient).LBU + + opts := lbu.SetLoadBalancerListenerSSLCertificateInput{ + LoadBalancerName: aws.String(d.Get("load_balancer_name").(string)), + LoadBalancerPort: aws.Int64(d.Get("server_certificate_id").(int64)), + SSLCertificateId: aws.String(d.Get("server_certificate_id").(string)), + } + var err error + var resp = &lbu.SetLoadBalancerListenerSSLCertificateOutput{} + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.SetLoadBalancerListenerSSLCertificate(&opts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) + } + + if resp.ResponseMetadata != nil { + d.Set("request_id", resp.ResponseMetadata.RequestID) + } + + d.SetId(aws.StringValue(opts.LoadBalancerName)) + + return resourceOutscaleOAPILoadBalancerSSLCertificateRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerSSLCertificateRead(d *schema.ResourceData, meta interface{}) error { + return nil +} + +func resourceOutscaleOAPILoadBalancerSSLCertificateDelete(d *schema.ResourceData, meta interface{}) error { + d.SetId("") + + return nil +} diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go new file mode 100644 index 000000000..3267d3b91 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go @@ -0,0 +1,85 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" +) + +func TestAccOutscaleLBUOAPISSLCertificate_basic(t *testing.T) { + t.Skip() + + //WIP: Missing correct test case + rInt := acctest.RandIntRange(0, 10) + unixFile := "test-fixtures/eim-ssl-unix-line-endings.pem" + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer_ssl_certificate.test", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccOutscaleOAPISSLCertificateConfig(rInt, unixFile), + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr( + "outscale_load_balancer_ssl_certificate.test", "ssl_certificate.load_balancer_port", "80"), + ), + }, + }, + }) +} + +func testAccOutscaleOAPISSLCertificateConfig(r int, fName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "bar" { + sub_region_name = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-lbu-%d" + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + +} + +resource "outscale_server_certificate" "test_cert" { + server_certificate_name = "terraform-test-cert-%d" + server_certificate_body = "${file("%s")}" + private_key = < Date: Fri, 20 Mar 2020 15:18:37 +0100 Subject: [PATCH 020/218] port to oapi Signed-off-by: matthias.gatto --- ..._outscale_load_balancer_ssl_certificate.go | 60 ++++++++++++------- 1 file changed, 39 insertions(+), 21 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate.go b/outscale/resource_outscale_load_balancer_ssl_certificate.go index 101853c1b..865bae73e 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate.go @@ -1,14 +1,16 @@ package outscale import ( + "context" "fmt" "strings" "time" - "github.com/aws/aws-sdk-go/aws" + "github.com/antihax/optional" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + oscgo "github.com/marinsalinas/osc-sdk-go" ) func resourceOutscaleOAPILoadBalancerSSLCertificate() *schema.Resource { @@ -45,7 +47,7 @@ func resourceOutscaleOAPILoadBalancerSSLCertificate() *schema.Resource { } func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") port, pok := d.GetOk("load_balancer_port") @@ -62,17 +64,24 @@ func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData if !sok { return fmt.Errorf("please provide server_certificate_id argument") } + port_i := port.(int64) + ssl_s := ssl.(string) + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: ename.(string), + LoadBalancerPort: &port_i, + ServerCertificateId: &ssl_s, + } - opts := lbu.SetLoadBalancerListenerSSLCertificateInput{ - LoadBalancerName: aws.String(ename.(string)), - LoadBalancerPort: aws.Int64(int64(port.(int))), - SSLCertificateId: aws.String(ssl.(string)), + opts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), } + var err error - var resp = &lbu.SetLoadBalancerListenerSSLCertificateOutput{} + var resp = oscgo.UpdateLoadBalancerResponse{} err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.SetLoadBalancerListenerSSLCertificate(&opts) + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &opts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -87,8 +96,8 @@ func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) } - if resp.ResponseMetadata != nil { - d.Set("request_id", resp.ResponseMetadata.RequestID) + if resp.ResponseContext != nil { + d.Set("request_id", resp.ResponseContext.RequestId) } d.SetId(ename.(string)) @@ -101,18 +110,27 @@ func resourceOutscaleOAPILoadBalancerSSLCertificateUpdate(d *schema.ResourceData return nil } - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI + + port := d.Get("load_balancer_port").(int64) + ssl := d.Get("server_certificate_id").(string) - opts := lbu.SetLoadBalancerListenerSSLCertificateInput{ - LoadBalancerName: aws.String(d.Get("load_balancer_name").(string)), - LoadBalancerPort: aws.Int64(d.Get("server_certificate_id").(int64)), - SSLCertificateId: aws.String(d.Get("server_certificate_id").(string)), + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: d.Get("load_balancer_name").(string), + LoadBalancerPort: &port, + ServerCertificateId: &ssl, } + + opts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), + } + var err error - var resp = &lbu.SetLoadBalancerListenerSSLCertificateOutput{} + var resp = oscgo.UpdateLoadBalancerResponse{} err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.SetLoadBalancerListenerSSLCertificate(&opts) + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &opts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -127,11 +145,11 @@ func resourceOutscaleOAPILoadBalancerSSLCertificateUpdate(d *schema.ResourceData return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) } - if resp.ResponseMetadata != nil { - d.Set("request_id", resp.ResponseMetadata.RequestID) + if resp.ResponseContext != nil { + d.Set("request_id", resp.ResponseContext.RequestId) } - d.SetId(aws.StringValue(opts.LoadBalancerName)) + d.SetId(req.LoadBalancerName) return resourceOutscaleOAPILoadBalancerSSLCertificateRead(d, meta) } From 90a342e5dcd0e0b911b345da922fd6528c440b45 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 20 Mar 2020 15:32:06 +0100 Subject: [PATCH 021/218] Revert "LBU-remove: rm resource_outscale_load_balancer_listeners" This reverts commit 3d6fdf5ec2258c529eccbaf76898a7816dcdd57a. --- ...source_outscale_load_balancer_listeners.go | 264 ++++++++++++++++++ ...e_outscale_load_balancer_listeners_test.go | 67 +++++ 2 files changed, 331 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_listeners.go create mode 100644 outscale/resource_outscale_load_balancer_listeners_test.go diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go new file mode 100644 index 000000000..07bab5454 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -0,0 +1,264 @@ +package outscale + +import ( + "fmt" + "log" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleOAPILoadBalancerListenersCreate, + Read: resourceOutscaleOAPILoadBalancerListenersRead, + Delete: resourceOutscaleOAPILoadBalancerListenersDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "listener": &schema.Schema{ + Type: schema.TypeList, + Required: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + }, + }, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + // "request_id": &schema.Schema{ + // Type: schema.TypeString, + // Computed: true, + // }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + elbOpts := &lbu.CreateLoadBalancerListenersInput{} + + listener, err := expandListeners(d.Get("listener").([]interface{})) + if err != nil { + return err + } + + elbOpts.Listeners = listener + + if v, ok := d.GetOk("load_balancer_name"); ok { + elbOpts.LoadBalancerName = aws.String(v.(string)) + } + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.CreateLoadBalancerListeners(elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "DuplicateListener") { + log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId(*elbOpts.LoadBalancerName) + log.Printf("[INFO] ELB ID: %s", d.Id()) + + return resourceOutscaleOAPILoadBalancerListenersRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta interface{}) error { + listener, err := expandListeners(d.Get("listener").([]interface{})) + if err != nil { + return err + } + + result := make([]map[string]interface{}, 0, len(listener)) + for _, i := range listener { + listener := map[string]interface{}{ + "backend_port": aws.Int64Value(i.InstancePort), + "backend_protocol": aws.StringValue(i.InstanceProtocol), + "load_balancer_port": aws.Int64Value(i.LoadBalancerPort), + "load_balancer_protocol": aws.StringValue(i.Protocol), + "server_certificate_id": aws.StringValue(i.SSLCertificateId), + } + result = append(result, listener) + } + if err := d.Set("listener", result); err != nil { + return err + } + d.Set("load_balancer_name", d.Id()) + + // d.Set("request_id", describeResp.ResponseMetadata.RequestID) + + return nil +} + +func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + d.Partial(true) + + if d.HasChange("listener") { + o, n := d.GetChange("listener") + os := o.([]interface{}) + ns := n.([]interface{}) + + remove, _ := expandListeners(ns) + add, _ := expandListeners(os) + + if len(remove) > 0 { + ports := make([]*int64, 0, len(remove)) + for _, listener := range remove { + ports = append(ports, listener.LoadBalancerPort) + } + + deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ + LoadBalancerName: aws.String(d.Id()), + LoadBalancerPorts: ports, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure removing outdated ELB listener: %s", err) + } + } + + if len(add) > 0 { + createListenersOpts := &lbu.CreateLoadBalancerListenersInput{ + LoadBalancerName: aws.String(d.Id()), + Listeners: add, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.CreateLoadBalancerListeners(createListenersOpts) + if err != nil { + if err, ok := err.(awserr.Error); ok { + if strings.Contains(fmt.Sprint(err), "DuplicateListener") { + log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) + } + } + + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return fmt.Errorf("Failure adding new or updated ELB listener: %s", err) + } + } + + d.SetPartial("listener") + } + + d.Partial(false) + + return resourceOutscaleOAPILoadBalancerListenersRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + remove, _ := expandListeners(d.Get("listener").([]interface{})) + + ports := make([]*int64, 0, len(remove)) + for _, listener := range remove { + ports = append(ports, listener.LoadBalancerPort) + } + + deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ + LoadBalancerName: aws.String(d.Id()), + LoadBalancerPorts: ports, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure removing outdated ELB listener: %s", err) + } + + d.SetId("") + + return nil +} diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go new file mode 100644 index 000000000..d8a428f85 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -0,0 +1,67 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPILBUUpdate_Listener(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerDescription + r := acctest.RandIntRange(0, 10) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer_listeners.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccOutscaleOAPILBUListenersConfig(r), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer_listeners.bar", &conf), + testAccCheckOutscaleOAPILBUAttributes(&conf), + resource.TestCheckResourceAttr( + "outscale_load_balancer_listeners.bar", "listener.0.backend_port", "9000"), + ), + }, + }, + }) +} + +func testAccOutscaleOAPILBUListenersConfig(r int) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + sub_region_name = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-lbu-%d" + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + tag { + bar = "baz" + } + +} + +resource "outscale_load_balancer_listeners" "bar" { + load_balancer_name = "${outscale_load_balancer.lb.id}" + listener { + backend_port = 9000 + backend_protocol = "HTTP" + load_balancer_port = 9000 + load_balancer_protocol = "HTTP" + } +} +`, r) +} From 18f1b77804e5247b8137d5b8f5d5c1a9b78d1e5b Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Tue, 24 Mar 2020 17:56:05 +0100 Subject: [PATCH 022/218] port resource_outscale_load_balancer_listeners.go --- ...source_outscale_load_balancer_listeners.go | 211 +++++++++++++----- 1 file changed, 160 insertions(+), 51 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 07bab5454..e07271b38 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -1,16 +1,17 @@ package outscale import ( + "context" "fmt" "log" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" ) func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { @@ -23,31 +24,31 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "listener": &schema.Schema{ + "listener": { Type: schema.TypeList, Required: true, ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeInt, Required: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Required: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Required: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Required: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Optional: true, Computed: true, @@ -55,7 +56,7 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { }, }, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, @@ -68,24 +69,118 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { } } +func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { + listeners := make([]*oscgo.Listener, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["instance_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + bproto := data["instance_protocol"].(string) + lproto := data["protocol"].(string) + l := &oscgo.Listener{ + BackendPort: &ip, + BackendProtocol: &bproto, + LoadBalancerPort: &lp, + LoadBalancerProtocol: &lproto, + } + + if v, ok := data["ssl_certificate_id"]; ok && v != "" { + vs := v.(string) + l.ServerCertificateId = &vs + } + + var valid bool + if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { + // validate the protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.BackendProtocol) == p) || + (strings.ToLower(*l.LoadBalancerProtocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + +func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCreation, error) { + listeners := make([]oscgo.ListenerForCreation, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["instance_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + bproto := data["instance_protocol"].(string) + lproto := data["protocol"].(string) + l := oscgo.ListenerForCreation{ + BackendPort: ip, + BackendProtocol: &bproto, + LoadBalancerPort: lp, + LoadBalancerProtocol: lproto, + } + + if v, ok := data["ssl_certificate_id"]; ok && v != "" { + vs := v.(string) + l.ServerCertificateId = &vs + } + + var valid bool + if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { + // validate the protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.BackendProtocol) == p) || + (strings.ToLower(l.LoadBalancerProtocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - elbOpts := &lbu.CreateLoadBalancerListenersInput{} + req := oscgo.CreateLoadBalancerListenersRequest{} - listener, err := expandListeners(d.Get("listener").([]interface{})) + listener, err := expandListenerForCreation(d.Get("listener").([]interface{})) if err != nil { return err } - elbOpts.Listeners = listener + req.Listeners = listener if v, ok := d.GetOk("load_balancer_name"); ok { - elbOpts.LoadBalancerName = aws.String(v.(string)) + req.LoadBalancerName = v.(string) } + elbOpts := oscgo.CreateLoadBalancerListenersOpts{ + optional.NewInterface(req), + } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.CreateLoadBalancerListeners(elbOpts) + _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( + context.Background(), &elbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "DuplicateListener") { @@ -109,7 +204,7 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met return err } - d.SetId(*elbOpts.LoadBalancerName) + d.SetId(req.LoadBalancerName) log.Printf("[INFO] ELB ID: %s", d.Id()) return resourceOutscaleOAPILoadBalancerListenersRead(d, meta) @@ -124,11 +219,11 @@ func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta result := make([]map[string]interface{}, 0, len(listener)) for _, i := range listener { listener := map[string]interface{}{ - "backend_port": aws.Int64Value(i.InstancePort), - "backend_protocol": aws.StringValue(i.InstanceProtocol), - "load_balancer_port": aws.Int64Value(i.LoadBalancerPort), - "load_balancer_protocol": aws.StringValue(i.Protocol), - "server_certificate_id": aws.StringValue(i.SSLCertificateId), + "backend_port": i.BackendPort, + "backend_protocol": i.BackendProtocol, + "load_balancer_port": i.LoadBalancerPort, + "load_balancer_protocol": i.LoadBalancerProtocol, + "server_certificate_id": i.ServerCertificateId, } result = append(result, listener) } @@ -143,7 +238,7 @@ func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta } func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI d.Partial(true) @@ -153,22 +248,27 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met ns := n.([]interface{}) remove, _ := expandListeners(ns) - add, _ := expandListeners(os) + add, _ := expandListenerForCreation(os) if len(remove) > 0 { - ports := make([]*int64, 0, len(remove)) + ports := make([]int64, 0, len(remove)) for _, listener := range remove { - ports = append(ports, listener.LoadBalancerPort) + ports = append(ports, *listener.LoadBalancerPort) } - deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ - LoadBalancerName: aws.String(d.Id()), + req := &oscgo.DeleteLoadBalancerListenersRequest{ + LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } + deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ + optional.NewInterface(req), + } + var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( + context.Background(), deleteListenersOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -185,28 +285,31 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met } if len(add) > 0 { - createListenersOpts := &lbu.CreateLoadBalancerListenersInput{ - LoadBalancerName: aws.String(d.Id()), + req := &oscgo.CreateLoadBalancerListenersRequest{ + LoadBalancerName: d.Id(), Listeners: add, } + createListenersOpts := &oscgo.CreateLoadBalancerListenersOpts{ + optional.NewInterface(req), + } + var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.CreateLoadBalancerListeners(createListenersOpts) + _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( + context.Background(), createListenersOpts) if err != nil { - if err, ok := err.(awserr.Error); ok { - if strings.Contains(fmt.Sprint(err), "DuplicateListener") { - log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(err) - } + if strings.Contains(fmt.Sprint(err), "DuplicateListener") { + log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) } return resource.NonRetryableError(err) @@ -227,23 +330,29 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met } func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI remove, _ := expandListeners(d.Get("listener").([]interface{})) - ports := make([]*int64, 0, len(remove)) + ports := make([]int64, 0, len(remove)) for _, listener := range remove { - ports = append(ports, listener.LoadBalancerPort) + ports = append(ports, *listener.LoadBalancerPort) } - deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ - LoadBalancerName: aws.String(d.Id()), + req := &oscgo.DeleteLoadBalancerListenersRequest{ + LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } + deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ + optional.NewInterface(req), + } + var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( + context.Background(), + deleteListenersOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { From d3f68a7d2859a835c10c9a9f485b9f0b9cba2838 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 26 Mar 2020 17:44:38 +0100 Subject: [PATCH 023/218] Revert "LBU-remove: rm resource_outscale_load_balancer_health_check" This reverts commit aff24a935fb5111dc7045b0d279ff29229d1a897. --- ...rce_outscale_load_balancer_health_check.go | 233 ++++++++++++++++++ ...utscale_load_balancer_health_check_test.go | 72 ++++++ 2 files changed, 305 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_health_check.go create mode 100644 outscale/resource_outscale_load_balancer_health_check_test.go diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go new file mode 100644 index 000000000..af0838ea9 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -0,0 +1,233 @@ +package outscale + +import ( + "fmt" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { + return &schema.Resource{ + Read: resourceOutscaleOAPILoadBalancerHealthCheckRead, + Create: resourceOutscaleOAPILoadBalancerHealthCheckCreate, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Delete: resourceOutscaleOAPILoadBalancerHealthCheckDelete, + + Schema: map[string]*schema.Schema{ + "health_check": { + Type: schema.TypeMap, + Required: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "unhealthy_threshold": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "checked_vm": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "check_interval": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "timeout": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + }, + }, + }, + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + ename, ok := d.GetOk("load_balancer_name") + hc, hok := d.GetOk("health_check") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + if !hok { + return fmt.Errorf("please provide health check values") + } + + check := hc.(map[string]interface{}) + + ht, hterr := strconv.Atoi(check["healthy_threshold"].(string)) + ut, uterr := strconv.Atoi(check["unhealthy_threshold"].(string)) + i, ierr := strconv.Atoi(check["check_interval"].(string)) + t, terr := strconv.Atoi(check["timeout"].(string)) + + if hterr != nil { + return fmt.Errorf("please provide an number in health_check.healthy_threshold argument") + } + + if uterr != nil { + return fmt.Errorf("please provide an number in health_check.unhealthy_threshold argument") + } + + if ierr != nil { + return fmt.Errorf("please provide an number in health_check.check_interval argument") + } + + if terr != nil { + return fmt.Errorf("please provide an number in health_check.timeout argument") + } + + configureHealthCheckOpts := lbu.ConfigureHealthCheckInput{ + LoadBalancerName: aws.String(ename.(string)), + HealthCheck: &lbu.HealthCheck{ + HealthyThreshold: aws.Int64(int64(ht)), + UnhealthyThreshold: aws.Int64(int64(ut)), + Interval: aws.Int64(int64(i)), + Target: aws.String(check["checked_vm"].(string)), + Timeout: aws.Int64(int64(t)), + }, + } + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.ConfigureHealthCheck(&configureHealthCheckOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure configuring health check for ELB: %s", err) + } + + d.SetId(ename.(string)) + + return resourceOutscaleOAPILoadBalancerHealthCheckRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + ename, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + elbName := ename.(string) + + // Retrieve the ELB properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(elbName)}, + } + + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + describeResp = resp.DescribeLoadBalancersResult + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO ELB FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + } + + lb := describeResp.LoadBalancerDescriptions[0] + + h := "" + i := "" + t := "" + ti := "" + u := "" + + healthCheck := make(map[string]interface{}) + + if *lb.HealthCheck.Target != "" { + h = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.HealthyThreshold), 10) + i = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.Interval), 10) + t = aws.StringValue(lb.HealthCheck.Target) + ti = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.Timeout), 10) + u = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.UnhealthyThreshold), 10) + } + + healthCheck["healthy_threshold"] = h + healthCheck["check_interval"] = i + healthCheck["checked_vm"] = t + healthCheck["timeout"] = ti + healthCheck["unhealthy_threshold"] = u + + d.Set("health_check", healthCheck) + d.Set("load_balancer_name", *lb.LoadBalancerName) + + reqID := "" + if resp.ResponseMetadata != nil { + reqID = aws.StringValue(resp.ResponseMetadata.RequestID) + } + + return d.Set("request_id", reqID) +} + +func resourceOutscaleOAPILoadBalancerHealthCheckDelete(d *schema.ResourceData, meta interface{}) error { + d.SetId("") + + return nil +} diff --git a/outscale/resource_outscale_load_balancer_health_check_test.go b/outscale/resource_outscale_load_balancer_health_check_test.go new file mode 100644 index 000000000..e6d120784 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_health_check_test.go @@ -0,0 +1,72 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" +) + +func TestAccOutscaleOAPIHealthCheck_basic(t *testing.T) { + t.Skip() + + r := acctest.RandIntRange(0, 10) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer_health_check.test", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccOutscaleOAPIHealthCheckConfig(r), + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr( + "outscale_load_balancer_health_check.test", "health_check.healthy_threshold", "2"), + resource.TestCheckResourceAttr( + "outscale_load_balancer_health_check.test", "health_check.unhealthy_threshold", "4"), + resource.TestCheckResourceAttr( + "outscale_load_balancer_health_check.test", "health_check.checked_vm", "HTTP:8000/index.html"), + resource.TestCheckResourceAttr( + "outscale_load_balancer_health_check.test", "health_check.interval", "5"), + resource.TestCheckResourceAttr( + "outscale_load_balancer_health_check.test", "health_check.timeout", "5"), + )}, + }, + }) +} + +func testAccOutscaleOAPIHealthCheckConfig(r int) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "bar" { + sub_region_name = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + +} + +resource "outscale_load_balancer_health_check" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + health_check { + healthy_threshold = 2 + unhealthy_threshold = 4 + check_interval = 5 + timeout = 5 + checked_vm = "HTTP:8000/index.html" + } +} +`, r) +} From 730f0cf2ab7ed43c1461f3b0003efe40693478aa Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 27 Mar 2020 10:44:53 +0100 Subject: [PATCH 024/218] LBU heal check Signed-off-by: matthias.gatto --- ...rce_outscale_load_balancer_health_check.go | 82 ++++++++++++------- 1 file changed, 51 insertions(+), 31 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index af0838ea9..e6f18ee41 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -1,15 +1,17 @@ package outscale import ( + "context" "fmt" "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" ) func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { @@ -74,8 +76,12 @@ func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { } } +func isLoadBalancerNotFound(err error) bool { + return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") +} + func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") hc, hok := d.GetOk("health_check") @@ -111,20 +117,26 @@ func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, m return fmt.Errorf("please provide an number in health_check.timeout argument") } - configureHealthCheckOpts := lbu.ConfigureHealthCheckInput{ - LoadBalancerName: aws.String(ename.(string)), - HealthCheck: &lbu.HealthCheck{ - HealthyThreshold: aws.Int64(int64(ht)), - UnhealthyThreshold: aws.Int64(int64(ut)), - Interval: aws.Int64(int64(i)), - Target: aws.String(check["checked_vm"].(string)), - Timeout: aws.Int64(int64(t)), + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: ename.(string), + HealthCheck: &oscgo.HealthCheck{ + HealthyThreshold: int64(ht), + UnhealthyThreshold: int64(ut), + CheckInterval: int64(i), + Path: check["checked_vm"].(string), + Timeout: int64(t), }, } + + configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), + } + var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.ConfigureHealthCheck(&configureHealthCheckOpts) + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &configureHealthCheckOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -145,7 +157,7 @@ func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, m } func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -155,16 +167,24 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met elbName := ename.(string) // Retrieve the ELB properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(elbName)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) - describeResp = resp.DescribeLoadBalancersResult + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) @@ -183,15 +203,15 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met return fmt.Errorf("Error retrieving ELB: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { + if resp.LoadBalancers == nil { return fmt.Errorf("NO ELB FOUND") } - if len(describeResp.LoadBalancerDescriptions) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + if len(*resp.LoadBalancers) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) } - lb := describeResp.LoadBalancerDescriptions[0] + lb := (*resp.LoadBalancers)[0] h := "" i := "" @@ -201,12 +221,12 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met healthCheck := make(map[string]interface{}) - if *lb.HealthCheck.Target != "" { - h = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.HealthyThreshold), 10) - i = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.Interval), 10) - t = aws.StringValue(lb.HealthCheck.Target) - ti = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.Timeout), 10) - u = strconv.FormatInt(aws.Int64Value(lb.HealthCheck.UnhealthyThreshold), 10) + if lb.HealthCheck.Path != "" { + h = strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) + i = strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) + t = lb.HealthCheck.Path + ti = strconv.FormatInt(lb.HealthCheck.Timeout, 10) + u = strconv.FormatInt(lb.HealthCheck.UnhealthyThreshold, 10) } healthCheck["healthy_threshold"] = h @@ -219,8 +239,8 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met d.Set("load_balancer_name", *lb.LoadBalancerName) reqID := "" - if resp.ResponseMetadata != nil { - reqID = aws.StringValue(resp.ResponseMetadata.RequestID) + if resp.ResponseContext != nil { + reqID = *resp.ResponseContext.RequestId } return d.Set("request_id", reqID) From a9c8442bd70ae4c39d0e69014082a0bc73b9486c Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 27 Mar 2020 10:47:42 +0100 Subject: [PATCH 025/218] Revert "LBU-remove: rm resource_outscale_load_balancer_policy" This reverts commit 55ec1e1b632a417c04f87436afa957167b56e2c9. --- .../resource_outscale_load_balancer_policy.go | 135 ++++++++++++++++++ ...urce_outscale_load_balancer_policy_test.go | 49 +++++++ 2 files changed, 184 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_policy.go create mode 100644 outscale/resource_outscale_load_balancer_policy_test.go diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go new file mode 100644 index 000000000..f562c7a30 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -0,0 +1,135 @@ +package outscale + +import ( + "fmt" + "log" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleOAPILoadBalancerPolicyCreate, + Read: resourceOutscaleOAPILoadBalancerPolicyRead, + Delete: resourceOutscaleOAPILoadBalancerPolicyDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "policy_names": &schema.Schema{ + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Optional: true, + ForceNew: true, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerPolicyCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + pInput := &lbu.SetLoadBalancerPoliciesOfListenerInput{} + + pInput.PolicyNames = expandStringList(d.Get("policy_names").([]interface{})) + + if v, ok := d.GetOk("load_balancer_name"); ok { + pInput.LoadBalancerName = aws.String(v.(string)) + } + + if v, ok := d.GetOk("load_balancer_port"); ok { + pInput.LoadBalancerPort = aws.Int64(int64(v.(int))) + } + + var err error + var resp *lbu.SetLoadBalancerPoliciesOfListenerOutput + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.SetLoadBalancerPoliciesOfListener(pInput) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Policy, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + fmt.Printf("POLICY ERROR:%s", err) + return err + } + + if resp.ResponseMatadata != nil { + d.Set("request_id", resp.ResponseMatadata.RequestID) + } + + d.SetId(*pInput.LoadBalancerName) + log.Printf("[INFO] ELB Policies Listener ID: %s", d.Id()) + + return nil +} + +func resourceOutscaleOAPILoadBalancerPolicyRead(d *schema.ResourceData, meta interface{}) error { + return nil +} + +func resourceOutscaleOAPILoadBalancerPolicyDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + pInput := &lbu.SetLoadBalancerPoliciesOfListenerInput{} + + pInput.PolicyNames = make([]*string, 0) + + if v, ok := d.GetOk("load_balancer_name"); ok { + pInput.LoadBalancerName = aws.String(v.(string)) + } + + if v, ok := d.GetOk("load_balancer_port"); ok { + pInput.LoadBalancerPort = aws.Int64(int64(v.(int))) + } + + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.SetLoadBalancerPoliciesOfListener(pInput) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Policy, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId("") + + return nil +} diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go new file mode 100644 index 000000000..58763fc25 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -0,0 +1,49 @@ +package outscale + +import ( + "testing" + + "github.com/hashicorp/terraform/helper/resource" +) + +func TestOutscaleOAPILoadBalancerPolicy_basic(t *testing.T) { + t.Skip() + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + Providers: testAccProviders, + // CheckDestroy: testAccCheckOutscaleLoadBalancerDestroy, + Steps: []resource.TestStep{ + resource.TestStep{ + Config: testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig, + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr( + "outscale_load_balancer_policy.outscale_load_balancer_policy", "load_balancer_port", "25"), + ), + }, + }, + }) +} + +const testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig = ` +resource "outscale_load_balancer" "outscale_load_balancer" { + load_balancer_name = "foobar-terraform-elb" + sub_region_name = ["eu-west-2a"] + + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } +} + +resource "outscale_load_balancer_policy" "outscale_load_balancer_policy" { + load_balancer_name = "${outscale_load_balancer.outscale_load_balancer.load_balancer_name}" + + load_balancer_port = "${outscale_load_balancer.outscale_load_balancer.listeners.0.load_balancer_port}" +} +` From 08a6f59fbb03a1ce2d603bdfaa5e924c11e8f999 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 27 Mar 2020 12:38:02 +0100 Subject: [PATCH 026/218] resource_outscale_load_balancer_policy.go to OAPI Signed-off-by: matthias.gatto --- .../resource_outscale_load_balancer_policy.go | 66 +++++++++++++------ 1 file changed, 45 insertions(+), 21 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index f562c7a30..16e842993 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -1,15 +1,17 @@ package outscale import ( + "context" "fmt" "log" "strings" "time" - "github.com/aws/aws-sdk-go/aws" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" ) func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { @@ -22,23 +24,23 @@ func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "policy_names": &schema.Schema{ + "policy_names": { Type: schema.TypeList, Optional: true, ForceNew: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Optional: true, ForceNew: true, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -46,25 +48,40 @@ func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { } } +func expandStringList(ifs []interface{}) *[]string { + r := make([]string, len(ifs)) + + for k, v := range ifs { + r[k] = v.(string) + } + return &r +} + func resourceOutscaleOAPILoadBalancerPolicyCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - pInput := &lbu.SetLoadBalancerPoliciesOfListenerInput{} + pInput := oscgo.UpdateLoadBalancerRequest{} pInput.PolicyNames = expandStringList(d.Get("policy_names").([]interface{})) if v, ok := d.GetOk("load_balancer_name"); ok { - pInput.LoadBalancerName = aws.String(v.(string)) + pInput.LoadBalancerName = v.(string) } if v, ok := d.GetOk("load_balancer_port"); ok { - pInput.LoadBalancerPort = aws.Int64(int64(v.(int))) + port := int64(v.(int)) + pInput.LoadBalancerPort = &port + } + + opts := &oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(pInput), } var err error - var resp *lbu.SetLoadBalancerPoliciesOfListenerOutput + var resp oscgo.UpdateLoadBalancerResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.SetLoadBalancerPoliciesOfListener(pInput) + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), opts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -81,11 +98,11 @@ func resourceOutscaleOAPILoadBalancerPolicyCreate(d *schema.ResourceData, meta i return err } - if resp.ResponseMatadata != nil { - d.Set("request_id", resp.ResponseMatadata.RequestID) + if resp.ResponseContext != nil { + d.Set("request_id", resp.ResponseContext.RequestId) } - d.SetId(*pInput.LoadBalancerName) + d.SetId(pInput.LoadBalancerName) log.Printf("[INFO] ELB Policies Listener ID: %s", d.Id()) return nil @@ -96,24 +113,31 @@ func resourceOutscaleOAPILoadBalancerPolicyRead(d *schema.ResourceData, meta int } func resourceOutscaleOAPILoadBalancerPolicyDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - pInput := &lbu.SetLoadBalancerPoliciesOfListenerInput{} + pInput := &oscgo.UpdateLoadBalancerRequest{} - pInput.PolicyNames = make([]*string, 0) + pols := make([]string, 0) + pInput.PolicyNames = &pols if v, ok := d.GetOk("load_balancer_name"); ok { - pInput.LoadBalancerName = aws.String(v.(string)) + pInput.LoadBalancerName = v.(string) } if v, ok := d.GetOk("load_balancer_port"); ok { - pInput.LoadBalancerPort = aws.Int64(int64(v.(int))) + p := int64(v.(int)) + pInput.LoadBalancerPort = &p + } + + opts := &oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(pInput), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.SetLoadBalancerPoliciesOfListener(pInput) + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), opts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { From cf7f36bdabd871f5fb73c5c2d4d7947edb4530f0 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 27 Mar 2020 13:57:25 +0100 Subject: [PATCH 027/218] Revert "LBU-remove: rm resource_outscale_load_balancer_attributes" This reverts commit c4b5b3043d019f7163f63104011f61a25a44443c. --- ...ource_outscale_load_balancer_attributes.go | 270 ++++++++++++++++++ ..._outscale_load_balancer_attributes_test.go | 76 +++++ 2 files changed, 346 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_attributes.go create mode 100644 outscale/resource_outscale_load_balancer_attributes_test.go diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go new file mode 100644 index 000000000..6a7fd88f2 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -0,0 +1,270 @@ +package outscale + +import ( + "fmt" + "log" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleOAPILoadBalancerAttributesCreate, + Read: resourceOutscaleOAPILoadBalancerAttributesRead, + Update: resourceOutscaleOAPILoadBalancerAttributesUpdate, + Delete: resourceOutscaleOAPILoadBalancerAttributesDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "publication_interval": &schema.Schema{ + Type: schema.TypeInt, + Optional: true, + }, + "is_enabled": &schema.Schema{ + Type: schema.TypeBool, + Required: true, + }, + "osu_bucket_name": &schema.Schema{ + Type: schema.TypeString, + Optional: true, + }, + "osu_bucket_prefix": &schema.Schema{ + Type: schema.TypeString, + Optional: true, + }, + "load_balancer_attributes": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "access_log": &schema.Schema{ + Type: schema.TypeMap, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "publication_interval": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "is_enabled": &schema.Schema{ + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + }, + }, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + v, ok := d.GetOk("is_enabled") + v1, ok1 := d.GetOk("load_balancer_name") + + if !ok && !ok1 { + return fmt.Errorf("please provide the is_enabled and load_balancer_name required attributes") + } + + elbOpts := &lbu.ModifyLoadBalancerAttributesInput{ + LoadBalancerName: aws.String(v1.(string)), + } + access := &lbu.AccessLog{ + Enabled: aws.Bool(v.(bool)), + } + + if v, ok := d.GetOk("publication_interval"); ok { + access.EmitInterval = aws.Int64(int64(v.(int))) + } + if v, ok := d.GetOk("osu_bucket_name"); ok { + access.S3BucketName = aws.String(v.(string)) + } + if v, ok := d.GetOk("osu_bucket_prefix"); ok { + access.S3BucketPrefix = aws.String(v.(string)) + } + + elbOpts.LoadBalancerAttributes = &lbu.LoadBalancerAttributes{ + AccessLog: access, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.ModifyLoadBalancerAttributes(elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr Listener with SSL Cert, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId(*elbOpts.LoadBalancerName) + log.Printf("[INFO] LBU Attr ID: %s", d.Id()) + + return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + elbName := d.Id() + + // Retrieve the LBU Attr properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ + LoadBalancerName: aws.String(elbName), + } + + var describeResp *lbu.DescribeLoadBalancerAttributesResult + var resp *lbu.DescribeLoadBalancerAttributesOutput + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancerAttributesResult != nil { + describeResp = resp.DescribeLoadBalancerAttributesResult + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving LBU Attr: %s", err) + } + + if describeResp.LoadBalancerAttributes == nil { + return fmt.Errorf("NO Attributes FOUND") + } + + a := describeResp.LoadBalancerAttributes.AccessLog + + access := make(map[string]string) + ac := make(map[string]interface{}) + access["publication_interval"] = strconv.Itoa(int(aws.Int64Value(a.EmitInterval))) + access["is_enabled"] = strconv.FormatBool(aws.BoolValue(a.Enabled)) + access["osu_bucket_name"] = aws.StringValue(a.S3BucketName) + access["osu_bucket_prefix"] = aws.StringValue(a.S3BucketPrefix) + ac["access_log"] = access + + l := make([]map[string]interface{}, 1) + l[0] = ac + + d.Set("request_id", resp.ResponseMetadata.RequestID) + + return d.Set("load_balancer_attributes", l) +} + +func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + elbOpts := &lbu.ModifyLoadBalancerAttributesInput{} + access := &lbu.AccessLog{} + if d.HasChange("load_balancer_name") { + _, n := d.GetChange("load_balancer_name") + + elbOpts.LoadBalancerName = aws.String(n.(string)) + } + if d.HasChange("is_enabled") { + _, n := d.GetChange("is_enabled") + + b, err := strconv.ParseBool(n.(string)) + if err != nil { + return err + } + + access.Enabled = aws.Bool(b) + } + if d.HasChange("publication_interval") { + _, n := d.GetChange("publication_interval") + + i, err := strconv.Atoi(n.(string)) + if err != nil { + return err + } + access.EmitInterval = aws.Int64(int64(i)) + } + if d.HasChange("osu_bucket_name") { + _, n := d.GetChange("osu_bucket_name") + + access.S3BucketName = aws.String(n.(string)) + } + if d.HasChange("osu_bucket_prefix") { + _, n := d.GetChange("osu_bucket_prefix") + access.S3BucketPrefix = aws.String(n.(string)) + } + + elbOpts.LoadBalancerAttributes = &lbu.LoadBalancerAttributes{ + AccessLog: access, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.ModifyLoadBalancerAttributes(elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerAttributesDelete(d *schema.ResourceData, meta interface{}) error { + + d.SetId("") + + return nil +} diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go new file mode 100644 index 000000000..7574ab1a2 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -0,0 +1,76 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPILBUAttr_basic(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerAttributes + + r := acctest.RandIntRange(0, 10) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer_attributes.bar2", + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccOutscaleOAPILBUAttrConfig(r), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUAttrExists("outscale_load_balancer_attributes.bar2", &conf), + )}, + }, + }) +} + +func testAccCheckOutscaleOAPILBUAttrExists(n string, res *lbu.LoadBalancerAttributes) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[n] + if !ok { + return fmt.Errorf("Not found: %s", n) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No LBU Attr ID is set") + } + + return nil + } +} + +func testAccOutscaleOAPILBUAttrConfig(r int) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "bar" { + sub_regions = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tags { + bar = "baz" + } + +} + +resource "outscale_load_balancer_attributes" "bar2" { + is_enabled = "false" + osu_bucket_prefix = "donustestbucket" + load_balancer_name = "${outscale_load_balancer.bar.id}" +} +`, r) +} From 6043486dc362398dd38e23c50802afbe9a0a8051 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 27 Mar 2020 17:13:05 +0100 Subject: [PATCH 028/218] port resource_outscale_load_balancer_attributes.go Signed-off-by: matthias.gatto --- ...ource_outscale_load_balancer_attributes.go | 138 +++++++++++------- 1 file changed, 85 insertions(+), 53 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 6a7fd88f2..50fa6ff8b 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -1,16 +1,18 @@ package outscale import ( + "context" "fmt" "log" "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" ) func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { @@ -24,45 +26,45 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "publication_interval": &schema.Schema{ + "publication_interval": { Type: schema.TypeInt, Optional: true, }, - "is_enabled": &schema.Schema{ + "is_enabled": { Type: schema.TypeBool, Required: true, }, - "osu_bucket_name": &schema.Schema{ + "osu_bucket_name": { Type: schema.TypeString, Optional: true, }, - "osu_bucket_prefix": &schema.Schema{ + "osu_bucket_prefix": { Type: schema.TypeString, Optional: true, }, - "load_balancer_attributes": &schema.Schema{ + "load_balancer_attributes": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "access_log": &schema.Schema{ + "access_log": { Type: schema.TypeMap, Required: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "publication_interval": &schema.Schema{ + "publication_interval": { Type: schema.TypeInt, Computed: true, }, - "is_enabled": &schema.Schema{ + "is_enabled": { Type: schema.TypeBool, Computed: true, }, - "osu_bucket_name": &schema.Schema{ + "osu_bucket_name": { Type: schema.TypeString, Computed: true, }, - "osu_bucket_prefix": &schema.Schema{ + "osu_bucket_prefix": { Type: schema.TypeString, Computed: true, }, @@ -72,12 +74,12 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -86,7 +88,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { } func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI v, ok := d.GetOk("is_enabled") v1, ok1 := d.GetOk("load_balancer_name") @@ -95,30 +97,38 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me return fmt.Errorf("please provide the is_enabled and load_balancer_name required attributes") } - elbOpts := &lbu.ModifyLoadBalancerAttributesInput{ - LoadBalancerName: aws.String(v1.(string)), + req := &oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: v1.(string), } - access := &lbu.AccessLog{ - Enabled: aws.Bool(v.(bool)), + + is_enable := v.(bool) + access := &oscgo.AccessLog{ + IsEnabled: &is_enable, } if v, ok := d.GetOk("publication_interval"); ok { - access.EmitInterval = aws.Int64(int64(v.(int))) + pi := int64(v.(int)) + access.PublicationInterval = &pi } if v, ok := d.GetOk("osu_bucket_name"); ok { - access.S3BucketName = aws.String(v.(string)) + obn := v.(string) + access.OsuBucketName = &obn } if v, ok := d.GetOk("osu_bucket_prefix"); ok { - access.S3BucketPrefix = aws.String(v.(string)) + obp := v.(string) + access.OsuBucketPrefix = &obp } - elbOpts.LoadBalancerAttributes = &lbu.LoadBalancerAttributes{ - AccessLog: access, + req.AccessLog = access + + elbOpts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.ModifyLoadBalancerAttributes(elbOpts) + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &elbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -134,26 +144,35 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me return err } - d.SetId(*elbOpts.LoadBalancerName) + d.SetId(req.LoadBalancerName) log.Printf("[INFO] LBU Attr ID: %s", d.Id()) return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) } func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() // Retrieve the LBU Attr properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ - LoadBalancerName: aws.String(elbName), + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var describeResp *lbu.DescribeLoadBalancerAttributesResult - var resp *lbu.DescribeLoadBalancerAttributesOutput + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { @@ -161,9 +180,6 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancerAttributesResult != nil { - describeResp = resp.DescribeLoadBalancerAttributesResult - } return nil }) @@ -176,37 +192,46 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta return fmt.Errorf("Error retrieving LBU Attr: %s", err) } - if describeResp.LoadBalancerAttributes == nil { + if resp.LoadBalancers == nil { + return fmt.Errorf("NO ELB FOUND") + } + + if len(*resp.LoadBalancers) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) + } + + lb_resp := (*resp.LoadBalancers)[0] + if lb_resp.AccessLog == nil { return fmt.Errorf("NO Attributes FOUND") } - a := describeResp.LoadBalancerAttributes.AccessLog + a := lb_resp.AccessLog access := make(map[string]string) ac := make(map[string]interface{}) - access["publication_interval"] = strconv.Itoa(int(aws.Int64Value(a.EmitInterval))) - access["is_enabled"] = strconv.FormatBool(aws.BoolValue(a.Enabled)) - access["osu_bucket_name"] = aws.StringValue(a.S3BucketName) - access["osu_bucket_prefix"] = aws.StringValue(a.S3BucketPrefix) + access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) + access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) + access["osu_bucket_name"] = *a.OsuBucketName + access["osu_bucket_prefix"] = *a.OsuBucketPrefix ac["access_log"] = access l := make([]map[string]interface{}, 1) l[0] = ac - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) return d.Set("load_balancer_attributes", l) } func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - elbOpts := &lbu.ModifyLoadBalancerAttributesInput{} - access := &lbu.AccessLog{} + req := &oscgo.UpdateLoadBalancerRequest{} + access := &oscgo.AccessLog{} if d.HasChange("load_balancer_name") { _, n := d.GetChange("load_balancer_name") - elbOpts.LoadBalancerName = aws.String(n.(string)) + req.LoadBalancerName = n.(string) } if d.HasChange("is_enabled") { _, n := d.GetChange("is_enabled") @@ -216,7 +241,7 @@ func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, me return err } - access.Enabled = aws.Bool(b) + access.IsEnabled = &b } if d.HasChange("publication_interval") { _, n := d.GetChange("publication_interval") @@ -225,25 +250,32 @@ func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, me if err != nil { return err } - access.EmitInterval = aws.Int64(int64(i)) + i64 := int64(i) + access.PublicationInterval = &i64 } if d.HasChange("osu_bucket_name") { _, n := d.GetChange("osu_bucket_name") - access.S3BucketName = aws.String(n.(string)) + s := n.(string) + access.OsuBucketName = &s } if d.HasChange("osu_bucket_prefix") { _, n := d.GetChange("osu_bucket_prefix") - access.S3BucketPrefix = aws.String(n.(string)) + + s := n.(string) + access.OsuBucketPrefix = &s } - elbOpts.LoadBalancerAttributes = &lbu.LoadBalancerAttributes{ - AccessLog: access, + req.AccessLog = access + + elbOpts := &oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.ModifyLoadBalancerAttributes(elbOpts) + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), elbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { From a82091bab686567b8891619aa07f19459687471e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 30 Mar 2020 13:36:55 +0200 Subject: [PATCH 029/218] Revert "LBU-remove: rm resource_outscale_load_balancer" This reverts commit 26c10484d62a77697143d12bf5e47f6ed1fb5014. --- outscale/resource_outscale_load_balancer.go | 984 ++++++++++++++++++ .../resource_outscale_load_balancer_test.go | 214 ++++ 2 files changed, 1198 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer.go create mode 100644 outscale/resource_outscale_load_balancer_test.go diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go new file mode 100644 index 000000000..0983434fe --- /dev/null +++ b/outscale/resource_outscale_load_balancer.go @@ -0,0 +1,984 @@ +package outscale + +import ( + "fmt" + "log" + "sort" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleOAPILoadBalancer() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleOAPILoadBalancerCreate, + Read: resourceOutscaleOAPILoadBalancerRead, + Update: resourceOutscaleOAPILoadBalancerUpdate, + Delete: resourceOutscaleOAPILoadBalancerDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + + Schema: map[string]*schema.Schema{ + "sub_region_name": &schema.Schema{ + Type: schema.TypeList, + Required: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "listener": &schema.Schema{ + Type: schema.TypeList, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Required: true, + }, + + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Optional: true, + }, + }, + }, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "load_balancer_type": &schema.Schema{ + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "subnet_id": &schema.Schema{ + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "tag": tagsSchema(), + + "public_dns_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "health_check": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "checked_vm": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "check_interval": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "timeout": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "backend_vm_id": &schema.Schema{ + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "vm_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "listeners": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "listener": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "source_firewall_rules_set": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "account_alias": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "vpc_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "policies": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "application_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "other_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + elbOpts := &lbu.CreateLoadBalancerInput{} + + listeners, err := expandOAPIListeners(d.Get("listener").([]interface{})) + if err != nil { + return err + } + + elbOpts.Listeners = listeners + + if v, ok := d.GetOk("load_balancer_name"); ok { + elbOpts.LoadBalancerName = aws.String(v.(string)) + } + + if v, ok := d.GetOk("tag"); ok { + elbOpts.Tags = tagsFromMapLBU(v.(map[string]interface{})) + } + + if v, ok := d.GetOk("load_balancer_type"); ok { + elbOpts.Scheme = aws.String(v.(string)) + } + + if v, ok := d.GetOk("sub_region_name"); ok { + elbOpts.AvailabilityZones = expandStringList(v.([]interface{})) + } + + if v, ok := d.GetOk("firewall_rules_set_name"); ok { + elbOpts.SecurityGroups = expandStringList(v.([]interface{})) + } + + if v, ok := d.GetOk("subnet_id"); ok { + elbOpts.Subnets = expandStringList(v.([]interface{})) + } + + log.Printf("[DEBUG] Load Balancer create configuration: %#v", elbOpts) + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.CreateLoadBalancer(elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating Load Balancer Listener with SSL Cert, retrying: %s", err)) + } + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating Load Balancer Listener with SSL Cert, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + // Assign the lbu's unique identifier for use later + d.SetId(*elbOpts.LoadBalancerName) + log.Printf("[INFO] Load Balancer ID: %s", d.Id()) + + if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { + return err + } + d.Set("policies", make([]map[string]interface{}, 0)) + + return resourceOutscaleOAPILoadBalancerRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + elbName := d.Id() + + // Retrieve the Load Balancer properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(elbName)}, + } + + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + describeResp = resp.DescribeLoadBalancersResult + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving Load Balancer: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO Load Balancer FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) != 1 { + return fmt.Errorf("Unable to find Load Balancer: %#v", describeResp.LoadBalancerDescriptions) + } + + lb := describeResp.LoadBalancerDescriptions[0] + + d.Set("sub_region_name", flattenStringList(lb.AvailabilityZones)) + d.Set("public_dns_name", aws.StringValue(lb.DNSName)) + d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + + if lb.Instances != nil { + d.Set("backend_vm_id", flattenOAPIInstances(lb.Instances)) + } else { + d.Set("backend_vm_id", make([]map[string]interface{}, 0)) + } + if lb.ListenerDescriptions != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.ListenerDescriptions)); err != nil { + return err + } + } else { + if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { + return err + } + } + d.Set("load_balancer_name", aws.StringValue(lb.LoadBalancerName)) + + policies := make(map[string]interface{}) + if lb.Policies != nil { + app := make([]map[string]interface{}, len(lb.Policies.AppCookieStickinessPolicies)) + for k, v := range lb.Policies.AppCookieStickinessPolicies { + a := make(map[string]interface{}) + a["cookie_name"] = aws.StringValue(v.CookieName) + a["policy_name"] = aws.StringValue(v.PolicyName) + app[k] = a + } + policies["application_sticky_cookie_policy"] = app + lbc := make([]map[string]interface{}, len(lb.Policies.LBCookieStickinessPolicies)) + for k, v := range lb.Policies.LBCookieStickinessPolicies { + a := make(map[string]interface{}) + a["policy_name"] = aws.StringValue(v.PolicyName) + lbc[k] = a + } + policies["load_balancer_sticky_cookie_policy"] = lbc + policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) + } else { + lbc := make([]map[string]interface{}, 0) + policies["load_balancer_sticky_cookie_policy"] = lbc + policies["other_policy"] = lbc + } + d.Set("policies", policies) + d.Set("load_balancer_type", aws.StringValue(lb.Scheme)) + if lb.SecurityGroups != nil { + d.Set("firewall_rules_set_name", flattenStringList(lb.SecurityGroups)) + } else { + d.Set("firewall_rules_set_name", make([]map[string]interface{}, 0)) + } + ssg := make(map[string]string) + if lb.SourceSecurityGroup != nil { + ssg["firewall_rules_set_name"] = aws.StringValue(lb.SourceSecurityGroup.GroupName) + ssg["account_alias"] = aws.StringValue(lb.SourceSecurityGroup.OwnerAlias) + } + d.Set("source_firewall_rules_set", ssg) + d.Set("subnet_id", flattenStringList(lb.Subnets)) + d.Set("vpc_id", aws.StringValue(lb.VPCId)) + d.Set("request_id", resp.ResponseMetadata.RequestID) + + return nil +} + +func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + d.Partial(true) + + if d.HasChange("listener") { + o, n := d.GetChange("listener") + os := o.([]interface{}) + ns := n.([]interface{}) + + remove, _ := expandListeners(ns) + add, _ := expandOAPIListeners(os) + + if len(remove) > 0 { + ports := make([]*int64, 0, len(remove)) + for _, listener := range remove { + ports = append(ports, listener.LoadBalancerPort) + } + + deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ + LoadBalancerName: aws.String(d.Id()), + LoadBalancerPorts: ports, + } + + log.Printf("[DEBUG] Load Balancer Delete Listeners opts: %v", deleteListenersOpts) + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure removing outdated Load Balancer listeners: %s", err) + } + } + + if len(add) > 0 { + createListenersOpts := &lbu.CreateLoadBalancerListenersInput{ + LoadBalancerName: aws.String(d.Id()), + Listeners: add, + } + + // Occasionally AWS will error with a 'duplicate listener', without any + // other listeners on the Load Balancer. Retry here to eliminate that. + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + log.Printf("[DEBUG] Load Balancer Create Listeners opts: %v", createListenersOpts) + _, err = conn.API.CreateLoadBalancerListeners(createListenersOpts) + if err != nil { + if awsErr, ok := err.(awserr.Error); ok { + if strings.Contains(fmt.Sprint(err), "DuplicateListener") { + log.Printf("[DEBUG] Duplicate listener found for Load Balancer (%s), retrying", d.Id()) + return resource.RetryableError(awsErr) + } + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(awsErr) + } + if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(awsErr) + } + } + + // Didn't recognize the error, so shouldn't retry. + return resource.NonRetryableError(err) + } + // Successful creation + return nil + }) + if err != nil { + return fmt.Errorf("Failure adding new or updated Load Balancer listeners: %s", err) + } + } + + d.SetPartial("listener") + } + + if d.HasChange("backend_vm_id") { + o, n := d.GetChange("backend_vm_id") + os := o.(*schema.Set) + ns := n.(*schema.Set) + remove := expandInstanceString(os.Difference(ns).List()) + add := expandInstanceString(ns.Difference(os).List()) + + if len(add) > 0 { + registerInstancesOpts := lbu.RegisterInstancesWithLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + Instances: add, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.RegisterInstancesWithLoadBalancer(®isterInstancesOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure registering instances with Load Balancer: %s", err) + } + } + if len(remove) > 0 { + deRegisterInstancesOpts := lbu.DeregisterInstancesFromLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + Instances: remove, + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeregisterInstancesFromLoadBalancer(&deRegisterInstancesOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure deregistering instances from Load Balancer: %s", err) + } + } + + d.SetPartial("backend_vm_id") + } + + if d.HasChange("health_check") { + hc := d.Get("health_check").([]interface{}) + if len(hc) > 0 { + check := hc[0].(map[string]interface{}) + configureHealthCheckOpts := lbu.ConfigureHealthCheckInput{ + LoadBalancerName: aws.String(d.Id()), + HealthCheck: &lbu.HealthCheck{ + HealthyThreshold: aws.Int64(int64(check["healthy_threshold"].(int))), + UnhealthyThreshold: aws.Int64(int64(check["unhealthy_threshold"].(int))), + Interval: aws.Int64(int64(check["check_interval"].(int))), + Target: aws.String(check["checked_vm"].(string)), + Timeout: aws.Int64(int64(check["timeout"].(int))), + }, + } + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.ConfigureHealthCheck(&configureHealthCheckOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure configuring health check for Load Balancer: %s", err) + } + d.SetPartial("health_check") + } + } + + if d.HasChange("firewall_rules_set_name") { + groups := d.Get("firewall_rules_set_name").([]interface{}) + + applySecurityGroupsOpts := lbu.ApplySecurityGroupsToLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + SecurityGroups: expandStringList(groups), + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.ApplySecurityGroupsToLoadBalancer(&applySecurityGroupsOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure applying security groups to Load Balancer: %s", err) + } + + d.SetPartial("firewall_rules_set_name") + } + + if d.HasChange("sub_region_name") { + o, n := d.GetChange("sub_region_name") + os := o.(*schema.Set) + ns := n.(*schema.Set) + + removed := expandStringList(os.Difference(ns).List()) + added := expandStringList(ns.Difference(os).List()) + + if len(added) > 0 { + enableOpts := &lbu.EnableAvailabilityZonesForLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + AvailabilityZones: added, + } + + log.Printf("[DEBUG] Load Balancer enable availability zones opts: %v", enableOpts) + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.EnableAvailabilityZonesForLoadBalancer(enableOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure enabling Load Balancer availability zones: %s", err) + } + } + + if len(removed) > 0 { + disableOpts := &lbu.DisableAvailabilityZonesForLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + AvailabilityZones: removed, + } + + log.Printf("[DEBUG] Load Balancer disable availability zones opts: %v", disableOpts) + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DisableAvailabilityZonesForLoadBalancer(disableOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure disabling Load Balancer availability zones: %s", err) + } + } + + d.SetPartial("availability_zones") + } + + if d.HasChange("subnet_id") { + o, n := d.GetChange("subnet_id") + os := o.(*schema.Set) + ns := n.(*schema.Set) + + removed := expandStringList(os.Difference(ns).List()) + added := expandStringList(ns.Difference(os).List()) + + if len(removed) > 0 { + detachOpts := &lbu.DetachLoadBalancerFromSubnetsInput{ + LoadBalancerName: aws.String(d.Id()), + Subnets: removed, + } + + log.Printf("[DEBUG] Load Balancer detach subnet_id opts: %v", detachOpts) + + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err := conn.API.DetachLoadBalancerFromSubnets(detachOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure removing Load Balancer subnets: %s", err) + } + } + + if len(added) > 0 { + attachOpts := &lbu.AttachLoadBalancerToSubnetsInput{ + LoadBalancerName: aws.String(d.Id()), + Subnets: added, + } + var err error + + log.Printf("[DEBUG] Load Balancer attach subnets opts: %v", attachOpts) + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.AttachLoadBalancerToSubnets(attachOpts) + if err != nil { + if awsErr, ok := err.(awserr.Error); ok { + // eventually consistent issue with removing a subnet in AZ1 and + // immediately adding a new one in the same AZ + if awsErr.Code() == "InvalidConfigurationRequest" && strings.Contains(awsErr.Message(), "cannot be attached to multiple subnets in the same AZ") { + log.Printf("[DEBUG] retrying az association") + return resource.RetryableError(awsErr) + } + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return fmt.Errorf("Failure adding Load Balancer subnets: %s", err) + } + } + + d.SetPartial("subnet_id") + } + + d.SetPartial("listeners") + d.SetPartial("policies") + + d.Partial(false) + + return resourceOutscaleOAPILoadBalancerRead(d, meta) +} + +func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + log.Printf("[INFO] Deleting Load Balancer: %s", d.Id()) + + // Destroy the load balancer + deleteElbOpts := lbu.DeleteLoadBalancerInput{ + LoadBalancerName: aws.String(d.Id()), + } + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeleteLoadBalancer(&deleteElbOpts) + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Error deleting Load Balancer: %s", err) + } + + d.SetId("") + + return nil +} + +func isLoadBalancerNotFound(err error) bool { + return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") +} + +func expandListeners(configured []interface{}) ([]*lbu.Listener, error) { + listeners := make([]*lbu.Listener, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["instance_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + l := &lbu.Listener{ + InstancePort: &ip, + InstanceProtocol: aws.String(data["instance_protocol"].(string)), + LoadBalancerPort: &lp, + Protocol: aws.String(data["protocol"].(string)), + } + + if v, ok := data["ssl_certificate_id"]; ok && v != "" { + l.SSLCertificateId = aws.String(v.(string)) + } + + var valid bool + if l.SSLCertificateId != nil && *l.SSLCertificateId != "" { + // validate the protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.InstanceProtocol) == p) || (strings.ToLower(*l.Protocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + +func flattenInstances(list []*lbu.Instance) []map[string]string { + result := make([]map[string]string, len(list)) + for _, i := range list { + result = append(result, map[string]string{"instance_id": *i.InstanceId}) + } + return result +} + +// Expands an array of String Instance IDs into a []Instances +func expandInstanceString(list []interface{}) []*lbu.Instance { + result := make([]*lbu.Instance, 0, len(list)) + for _, i := range list { + result = append(result, &lbu.Instance{InstanceId: aws.String(i.(string))}) + } + return result +} + +// Flattens an array of Backend Descriptions into a a map of instance_port to policy names. +func flattenBackendPolicies(backends []*lbu.BackendServerDescription) map[int64][]string { + policies := make(map[int64][]string) + for _, i := range backends { + for _, p := range i.PolicyNames { + policies[*i.InstancePort] = append(policies[*i.InstancePort], *p) + } + sort.Strings(policies[*i.InstancePort]) + } + return policies +} + +// Flattens an array of Listeners into a []map[string]interface{} +func flattenListeners(list []*lbu.ListenerDescription) []map[string]interface{} { + result := make([]map[string]interface{}, 0, len(list)) + + for _, i := range list { + l := make(map[string]interface{}) + listener := map[string]interface{}{ + "instance_port": strconv.Itoa(int(aws.Int64Value(i.Listener.InstancePort))), + "instance_protocol": strings.ToLower(aws.StringValue(i.Listener.InstanceProtocol)), + "load_balancer_port": strconv.Itoa(int(aws.Int64Value(i.Listener.LoadBalancerPort))), + "protocol": strings.ToLower(aws.StringValue(i.Listener.Protocol)), + "ssl_certificate_id": aws.StringValue(i.Listener.SSLCertificateId), + } + l["listener"] = listener + l["policy_names"] = flattenStringList(i.PolicyNames) + result = append(result, l) + } + return result +} + +func flattenHealthCheck(check *lbu.HealthCheck) map[string]interface{} { + chk := make(map[string]interface{}) + + if check != nil { + chk["unhealthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.UnhealthyThreshold))) + chk["healthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.HealthyThreshold))) + chk["target"] = aws.StringValue(check.Target) + chk["timeout"] = strconv.Itoa(int(aws.Int64Value(check.Timeout))) + chk["interval"] = strconv.Itoa(int(aws.Int64Value(check.Interval))) + } + + return chk +} + +func expandOAPIListeners(configured []interface{}) ([]*lbu.Listener, error) { + listeners := make([]*lbu.Listener, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["backend_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + l := &lbu.Listener{ + InstancePort: &ip, + InstanceProtocol: aws.String(data["backend_protocol"].(string)), + LoadBalancerPort: &lp, + Protocol: aws.String(data["load_balancer_protocol"].(string)), + } + + if v, ok := data["server_certificate_id"]; ok && v != "" { + l.SSLCertificateId = aws.String(v.(string)) + } + + var valid bool + if l.SSLCertificateId != nil && *l.SSLCertificateId != "" { + // validate the load_balancer_protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.InstanceProtocol) == p) || (strings.ToLower(*l.Protocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] Load Balancer Listener: server_certificate_id may be set only when load_balancer_protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + +func flattenOAPIInstances(list []*lbu.Instance) []map[string]string { + result := make([]map[string]string, len(list)) + for _, i := range list { + result = append(result, map[string]string{"vm_id": *i.InstanceId}) + } + return result +} + +// Flattens an array of Listeners into a []map[string]interface{} +func flattenOAPIListeners(list []*lbu.ListenerDescription) []map[string]interface{} { + result := make([]map[string]interface{}, 0, len(list)) + + for _, i := range list { + l := make(map[string]interface{}) + listener := map[string]interface{}{ + "backend_port": strconv.Itoa(int(aws.Int64Value(i.Listener.InstancePort))), + "backend_protocol": strings.ToLower(aws.StringValue(i.Listener.InstanceProtocol)), + "load_balancer_port": strconv.Itoa(int(aws.Int64Value(i.Listener.LoadBalancerPort))), + "load_balancer_protocol": strings.ToLower(aws.StringValue(i.Listener.Protocol)), + "server_certificate_id": aws.StringValue(i.Listener.SSLCertificateId), + } + l["listener"] = listener + l["policy_name"] = flattenStringList(i.PolicyNames) + result = append(result, l) + } + return result +} + +func flattenOAPIHealthCheck(check *lbu.HealthCheck) map[string]interface{} { + chk := make(map[string]interface{}) + + if check != nil { + chk["unhealthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.UnhealthyThreshold))) + chk["healthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.HealthyThreshold))) + chk["target"] = aws.StringValue(check.Target) + chk["timeout"] = strconv.Itoa(int(aws.Int64Value(check.Timeout))) + chk["interval"] = strconv.Itoa(int(aws.Int64Value(check.Interval))) + } + + return chk +} diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go new file mode 100644 index 000000000..feb194241 --- /dev/null +++ b/outscale/resource_outscale_load_balancer_test.go @@ -0,0 +1,214 @@ +package outscale + +import ( + "fmt" + "reflect" + "sort" + "strings" + "testing" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPILBUBasic(t *testing.T) { + t.Skip() + var conf lbu.LoadBalancerDescription + + r := acctest.RandIntRange(0, 10) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccOutscaleOAPILBUConfig(r), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + testAccCheckOutscaleOAPILBUAttributes(&conf), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "sub_region_name.#", "1"), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "sub_region_name.0", "eu-west-2a"), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "listener.0.backend_port", "8000"), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "listener.0.backend_protocol", "HTTP"), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "listener.0.load_balancer_port", "80"), + resource.TestCheckResourceAttr( + "outscale_load_balancer.bar", "listener.0.load_balancer_protocol", "HTTP"), + )}, + }, + }) +} + +func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { + conn := testAccProvider.Meta().(*OutscaleClient).LBU + + for _, rs := range s.RootModule().Resources { + if rs.Type != "outscale_load_balancer" { + continue + } + + var err error + var resp *lbu.DescribeLoadBalancersOutput + var describe *lbu.DescribeLoadBalancersResult + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(&lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(rs.Primary.ID)}, + }) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancersResult != nil { + describe = resp.DescribeLoadBalancersResult + } + return nil + }) + + if err == nil { + if len(describe.LoadBalancerDescriptions) != 0 && + *describe.LoadBalancerDescriptions[0].LoadBalancerName == rs.Primary.ID { + return fmt.Errorf("LBU still exists") + } + } + + if strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") { + return nil + } + + if err != nil { + return err + } + } + + return nil +} + +func testAccCheckOutscaleOAPILBUAttributes(conf *lbu.LoadBalancerDescription) resource.TestCheckFunc { + return func(s *terraform.State) error { + zones := []string{"eu-west-2a"} + azs := make([]string, 0, len(conf.AvailabilityZones)) + for _, x := range conf.AvailabilityZones { + azs = append(azs, *x) + } + sort.StringSlice(azs).Sort() + if !reflect.DeepEqual(azs, zones) { + return fmt.Errorf("bad sub_region_name") + } + + if *conf.DNSName == "" { + return fmt.Errorf("empty dns_name") + } + + return nil + } +} + +func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *lbu.LoadBalancerDescription) resource.TestCheckFunc { + return func(s *terraform.State) error { + zones := []string{"eu-west-2a"} + azs := make([]string, 0, len(conf.AvailabilityZones)) + for _, x := range conf.AvailabilityZones { + azs = append(azs, *x) + } + sort.StringSlice(azs).Sort() + if !reflect.DeepEqual(azs, zones) { + return fmt.Errorf("bad sub_region_name") + } + + if *conf.DNSName == "" { + return fmt.Errorf("empty dns_name") + } + + return nil + } +} + +func testAccCheckOutscaleOAPILBUExists(n string, res *lbu.LoadBalancerDescription) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[n] + if !ok { + return fmt.Errorf("Not found: %s", n) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No LBU ID is set") + } + + conn := testAccProvider.Meta().(*OutscaleClient).LBU + + var err error + var resp *lbu.DescribeLoadBalancersOutput + var describe *lbu.DescribeLoadBalancersResult + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(&lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(rs.Primary.ID)}, + }) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancersResult != nil { + describe = resp.DescribeLoadBalancersResult + } + return nil + }) + + if err != nil { + return err + } + + if len(describe.LoadBalancerDescriptions) != 1 || + *describe.LoadBalancerDescriptions[0].LoadBalancerName != rs.Primary.ID { + return fmt.Errorf("LBU not found") + } + + *res = *describe.LoadBalancerDescriptions[0] + + if res.VPCId != nil { + sgid := rs.Primary.Attributes["source_security_group_id"] + if sgid == "" { + return fmt.Errorf("Expected to find source_security_group_id for LBU, but was empty") + } + } + + return nil + } +} + +func testAccOutscaleOAPILBUConfig(r int) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "bar" { + sub_region_name = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + +} +`, r) +} From 07b70c86a0f6f789e01106d47f39f3c27874e1a2 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 6 Apr 2020 16:59:04 +0200 Subject: [PATCH 030/218] port resource_outscale_load_balancer.go, still need to fix resourceOutscaleOAPILoadBalancerUpdate Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 695 +++++++------------- 1 file changed, 234 insertions(+), 461 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 0983434fe..e6560ee6d 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -1,18 +1,18 @@ package outscale import ( + "context" "fmt" "log" - "sort" "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/aws/aws-sdk-go/aws/awserr" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILoadBalancer() *schema.Resource { @@ -26,60 +26,60 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "sub_region_name": &schema.Schema{ + "sub_region_name": { Type: schema.TypeList, Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "listener": &schema.Schema{ + "listener": { Type: schema.TypeList, Required: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeInt, Required: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Required: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Required: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Required: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Optional: true, }, }, }, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "load_balancer_type": &schema.Schema{ + "load_balancer_type": { Type: schema.TypeString, Optional: true, Computed: true, ForceNew: true, }, - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeList, Optional: true, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "subnet_id": &schema.Schema{ + "subnet_id": { Type: schema.TypeList, Optional: true, Computed: true, @@ -87,85 +87,85 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, "tag": tagsSchema(), - "public_dns_name": &schema.Schema{ + "public_dns_name": { Type: schema.TypeString, Computed: true, }, - "health_check": &schema.Schema{ + "health_check": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "healthy_threshold": &schema.Schema{ + "healthy_threshold": { Type: schema.TypeString, Computed: true, }, - "unhealthy_threshold": &schema.Schema{ + "unhealthy_threshold": { Type: schema.TypeString, Computed: true, }, - "checked_vm": &schema.Schema{ + "checked_vm": { Type: schema.TypeString, Computed: true, }, - "check_interval": &schema.Schema{ + "check_interval": { Type: schema.TypeString, Computed: true, }, - "timeout": &schema.Schema{ + "timeout": { Type: schema.TypeString, Computed: true, }, }, }, }, - "backend_vm_id": &schema.Schema{ + "backend_vm_id": { Type: schema.TypeList, Optional: true, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "vm_id": &schema.Schema{ + "vm_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "listeners": &schema.Schema{ + "listeners": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "listener": &schema.Schema{ + "listener": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeInt, Computed: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Computed: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Computed: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Computed: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -173,60 +173,60 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "source_firewall_rules_set": &schema.Schema{ + "source_firewall_rules_set": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeString, Computed: true, }, - "account_alias": &schema.Schema{ + "account_alias": { Type: schema.TypeString, Computed: true, }, }, }, }, - "vpc_id": &schema.Schema{ + "vpc_id": { Type: schema.TypeString, Computed: true, }, - "policies": &schema.Schema{ + "policies": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": &schema.Schema{ + "application_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "cookie_name": &schema.Schema{ + "cookie_name": { Type: schema.TypeString, Computed: true, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "load_balancer_sticky_cookie_policy": &schema.Schema{ + "load_balancer_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "other_policy": &schema.Schema{ + "other_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -234,7 +234,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -243,44 +243,50 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { } func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - elbOpts := &lbu.CreateLoadBalancerInput{} + req := &oscgo.CreateLoadBalancerRequest{} - listeners, err := expandOAPIListeners(d.Get("listener").([]interface{})) + listeners, err := expandListenerForCreation(d.Get("listener").([]interface{})) if err != nil { return err } - elbOpts.Listeners = listeners + req.Listeners = listeners if v, ok := d.GetOk("load_balancer_name"); ok { - elbOpts.LoadBalancerName = aws.String(v.(string)) + req.LoadBalancerName = v.(string) } if v, ok := d.GetOk("tag"); ok { - elbOpts.Tags = tagsFromMapLBU(v.(map[string]interface{})) + req.Tags = tagsFromMapLBU(v.(map[string]interface{})) } if v, ok := d.GetOk("load_balancer_type"); ok { - elbOpts.Scheme = aws.String(v.(string)) + s := v.(string) + req.LoadBalancerType = &s } if v, ok := d.GetOk("sub_region_name"); ok { - elbOpts.AvailabilityZones = expandStringList(v.([]interface{})) + req.SubregionNames = expandStringList(v.([]interface{})) } if v, ok := d.GetOk("firewall_rules_set_name"); ok { - elbOpts.SecurityGroups = expandStringList(v.([]interface{})) + req.SecurityGroups = expandStringList(v.([]interface{})) } if v, ok := d.GetOk("subnet_id"); ok { - elbOpts.Subnets = expandStringList(v.([]interface{})) + req.Subnets = expandStringList(v.([]interface{})) + } + + elbOpts := &oscgo.CreateLoadBalancerOpts{ + optional.NewInterface(req), } log.Printf("[DEBUG] Load Balancer create configuration: %#v", elbOpts) err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.CreateLoadBalancer(elbOpts) + _, _, err = conn.LoadBalancerApi.CreateLoadBalancer( + context.Background(), elbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "CertificateNotFound") { @@ -301,7 +307,7 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa } // Assign the lbu's unique identifier for use later - d.SetId(*elbOpts.LoadBalancerName) + d.SetId(req.LoadBalancerName) log.Printf("[INFO] Load Balancer ID: %s", d.Id()) if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { @@ -312,21 +318,37 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerRead(d, meta) } +func flattenStringList(list []string) []interface{} { + vs := make([]interface{}, 0, len(list)) + for _, v := range list { + vs = append(vs, v) + } + return vs +} + func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() // Retrieve the Load Balancer properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(elbName)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) - describeResp = resp.DescribeLoadBalancersResult + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) @@ -345,27 +367,28 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return fmt.Errorf("Error retrieving Load Balancer: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { + if resp.LoadBalancers == nil { return fmt.Errorf("NO Load Balancer FOUND") } - if len(describeResp.LoadBalancerDescriptions) != 1 { - return fmt.Errorf("Unable to find Load Balancer: %#v", describeResp.LoadBalancerDescriptions) + if len(*resp.LoadBalancers) != 1 { + return fmt.Errorf("Unable to find Load Balancer: %#v", + resp.LoadBalancers) } - lb := describeResp.LoadBalancerDescriptions[0] + lb := (*resp.LoadBalancers)[0] - d.Set("sub_region_name", flattenStringList(lb.AvailabilityZones)) - d.Set("public_dns_name", aws.StringValue(lb.DNSName)) + d.Set("sub_region_name", flattenStringList(*lb.SubregionNames)) + d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) - if lb.Instances != nil { - d.Set("backend_vm_id", flattenOAPIInstances(lb.Instances)) + if lb.BackendVmIds != nil { + d.Set("backend_vm_id", flattenOAPIInstances(lb.BackendVmIds)) } else { d.Set("backend_vm_id", make([]map[string]interface{}, 0)) } - if lb.ListenerDescriptions != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.ListenerDescriptions)); err != nil { + if lb.Listeners != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { return err } } else { @@ -373,80 +396,104 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } - d.Set("load_balancer_name", aws.StringValue(lb.LoadBalancerName)) + d.Set("load_balancer_name", lb.LoadBalancerName) policies := make(map[string]interface{}) - if lb.Policies != nil { - app := make([]map[string]interface{}, len(lb.Policies.AppCookieStickinessPolicies)) - for k, v := range lb.Policies.AppCookieStickinessPolicies { + if lb.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, + len(*lb.ApplicationStickyCookiePolicies)) + for k, v := range *lb.ApplicationStickyCookiePolicies { a := make(map[string]interface{}) - a["cookie_name"] = aws.StringValue(v.CookieName) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName app[k] = a } policies["application_sticky_cookie_policy"] = app - lbc := make([]map[string]interface{}, len(lb.Policies.LBCookieStickinessPolicies)) - for k, v := range lb.Policies.LBCookieStickinessPolicies { + lbc := make([]map[string]interface{}, + len(*lb.LoadBalancerStickyCookiePolicies)) + for k, v := range *lb.LoadBalancerStickyCookiePolicies { a := make(map[string]interface{}) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["policy_name"] = v.PolicyName lbc[k] = a } policies["load_balancer_sticky_cookie_policy"] = lbc - policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) + // TODO: check this can be remove V + // policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) } else { lbc := make([]map[string]interface{}, 0) policies["load_balancer_sticky_cookie_policy"] = lbc - policies["other_policy"] = lbc + // TODO: check this can be remove V + // policies["other_policy"] = lbc } d.Set("policies", policies) - d.Set("load_balancer_type", aws.StringValue(lb.Scheme)) + d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { - d.Set("firewall_rules_set_name", flattenStringList(lb.SecurityGroups)) + d.Set("firewall_rules_set_name", flattenStringList(*lb.SecurityGroups)) } else { d.Set("firewall_rules_set_name", make([]map[string]interface{}, 0)) } ssg := make(map[string]string) if lb.SourceSecurityGroup != nil { - ssg["firewall_rules_set_name"] = aws.StringValue(lb.SourceSecurityGroup.GroupName) - ssg["account_alias"] = aws.StringValue(lb.SourceSecurityGroup.OwnerAlias) + ssg["firewall_rules_set_name"] = *lb.SourceSecurityGroup.SecurityGroupName + ssg["account_alias"] = *lb.SourceSecurityGroup.SecurityGroupAccountId } d.Set("source_firewall_rules_set", ssg) - d.Set("subnet_id", flattenStringList(lb.Subnets)) - d.Set("vpc_id", aws.StringValue(lb.VPCId)) - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("subnet_id", flattenStringList(*lb.Subnets)) + d.Set("vpc_id", lb.NetId) + d.Set("request_id", resp.ResponseContext.RequestId) return nil } func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI d.Partial(true) + // if anye of thoses V are true, ake a + // resourceOutscaleOAPILoadBalancerDelete(d, meta) + // resourceOutscaleOAPILoadBalancerCreate(d, meta) + if d.HasChange("firewall_rules_set_name") { + return fmt.Errorf("firewall_rules_set_name update is not supported") + } + + if d.HasChange("sub_region_name") { + return fmt.Errorf("sub_region_name update is not supported") + } + + if d.HasChange("subnet_id") { + return fmt.Errorf("subnet_id update is not supported") + } + if d.HasChange("listener") { o, n := d.GetChange("listener") os := o.([]interface{}) ns := n.([]interface{}) remove, _ := expandListeners(ns) - add, _ := expandOAPIListeners(os) + add, _ := expandListenerForCreation(os) if len(remove) > 0 { - ports := make([]*int64, 0, len(remove)) + ports := make([]int64, 0, len(remove)) for _, listener := range remove { - ports = append(ports, listener.LoadBalancerPort) + ports = append(ports, *listener.LoadBalancerPort) } - deleteListenersOpts := &lbu.DeleteLoadBalancerListenersInput{ - LoadBalancerName: aws.String(d.Id()), + req := &oscgo.DeleteLoadBalancerListenersRequest{ + LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } + deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ + optional.NewInterface(req), + } + log.Printf("[DEBUG] Load Balancer Delete Listeners opts: %v", deleteListenersOpts) var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeleteLoadBalancerListeners(deleteListenersOpts) + _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( + context.Background(), deleteListenersOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -463,34 +510,35 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } if len(add) > 0 { - createListenersOpts := &lbu.CreateLoadBalancerListenersInput{ - LoadBalancerName: aws.String(d.Id()), + req := &oscgo.CreateLoadBalancerListenersRequest{ + LoadBalancerName: d.Id(), Listeners: add, } + createListenersOpts := oscgo.CreateLoadBalancerListenersOpts{ + optional.NewInterface(req), + } + // Occasionally AWS will error with a 'duplicate listener', without any // other listeners on the Load Balancer. Retry here to eliminate that. var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { log.Printf("[DEBUG] Load Balancer Create Listeners opts: %v", createListenersOpts) - _, err = conn.API.CreateLoadBalancerListeners(createListenersOpts) + _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( + context.Background(), &createListenersOpts) if err != nil { - if awsErr, ok := err.(awserr.Error); ok { - if strings.Contains(fmt.Sprint(err), "DuplicateListener") { - log.Printf("[DEBUG] Duplicate listener found for Load Balancer (%s), retrying", d.Id()) - return resource.RetryableError(awsErr) - } - if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(awsErr) - } - if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(awsErr) - } + if strings.Contains(fmt.Sprint(err), "DuplicateListener") { + log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { + log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") + return resource.RetryableError(err) + } + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) } - - // Didn't recognize the error, so shouldn't retry. return resource.NonRetryableError(err) } // Successful creation @@ -512,37 +560,50 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa add := expandInstanceString(ns.Difference(os).List()) if len(add) > 0 { - registerInstancesOpts := lbu.RegisterInstancesWithLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), - Instances: add, + + req := oscgo.RegisterVmsInLoadBalancerRequest{ + LoadBalancerName: d.Id(), + BackendVmIds: add, + } + + registerInstancesOpts := oscgo.RegisterVmsInLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.RegisterInstancesWithLoadBalancer(®isterInstancesOpts) + _, _, err = conn.LoadBalancerApi. + RegisterVmsInLoadBalancer(context.Background(), + ®isterInstancesOpts) if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) } return resource.NonRetryableError(err) } return nil }) - if err != nil { return fmt.Errorf("Failure registering instances with Load Balancer: %s", err) } } if len(remove) > 0 { - deRegisterInstancesOpts := lbu.DeregisterInstancesFromLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), - Instances: remove, + req := oscgo.DeregisterVmsInLoadBalancerRequest{ + LoadBalancerName: d.Id(), + BackendVmIds: remove, + } + deRegisterInstancesOpts := oscgo.DeregisterVmsInLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeregisterInstancesFromLoadBalancer(&deRegisterInstancesOpts) + _, _, err := conn.LoadBalancerApi. + DeregisterVmsInLoadBalancer( + context.Background(), + &deRegisterInstancesOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -565,20 +626,24 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa hc := d.Get("health_check").([]interface{}) if len(hc) > 0 { check := hc[0].(map[string]interface{}) - configureHealthCheckOpts := lbu.ConfigureHealthCheckInput{ - LoadBalancerName: aws.String(d.Id()), - HealthCheck: &lbu.HealthCheck{ - HealthyThreshold: aws.Int64(int64(check["healthy_threshold"].(int))), - UnhealthyThreshold: aws.Int64(int64(check["unhealthy_threshold"].(int))), - Interval: aws.Int64(int64(check["check_interval"].(int))), - Target: aws.String(check["checked_vm"].(string)), - Timeout: aws.Int64(int64(check["timeout"].(int))), + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: d.Id(), + HealthCheck: &oscgo.HealthCheck{ + HealthyThreshold: int64(check["healthy_threshold"].(int)), + UnhealthyThreshold: int64(check["unhealthy_threshold"].(int)), + CheckInterval: int64(check["check_interval"].(int)), + Path: check["checked_vm"].(string), + Timeout: int64(check["timeout"].(int)), }, } + configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), + } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.ConfigureHealthCheck(&configureHealthCheckOpts) + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &configureHealthCheckOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -596,163 +661,6 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } } - if d.HasChange("firewall_rules_set_name") { - groups := d.Get("firewall_rules_set_name").([]interface{}) - - applySecurityGroupsOpts := lbu.ApplySecurityGroupsToLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), - SecurityGroups: expandStringList(groups), - } - - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.ApplySecurityGroupsToLoadBalancer(&applySecurityGroupsOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure applying security groups to Load Balancer: %s", err) - } - - d.SetPartial("firewall_rules_set_name") - } - - if d.HasChange("sub_region_name") { - o, n := d.GetChange("sub_region_name") - os := o.(*schema.Set) - ns := n.(*schema.Set) - - removed := expandStringList(os.Difference(ns).List()) - added := expandStringList(ns.Difference(os).List()) - - if len(added) > 0 { - enableOpts := &lbu.EnableAvailabilityZonesForLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), - AvailabilityZones: added, - } - - log.Printf("[DEBUG] Load Balancer enable availability zones opts: %v", enableOpts) - var err error - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.EnableAvailabilityZonesForLoadBalancer(enableOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure enabling Load Balancer availability zones: %s", err) - } - } - - if len(removed) > 0 { - disableOpts := &lbu.DisableAvailabilityZonesForLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), - AvailabilityZones: removed, - } - - log.Printf("[DEBUG] Load Balancer disable availability zones opts: %v", disableOpts) - var err error - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DisableAvailabilityZonesForLoadBalancer(disableOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure disabling Load Balancer availability zones: %s", err) - } - } - - d.SetPartial("availability_zones") - } - - if d.HasChange("subnet_id") { - o, n := d.GetChange("subnet_id") - os := o.(*schema.Set) - ns := n.(*schema.Set) - - removed := expandStringList(os.Difference(ns).List()) - added := expandStringList(ns.Difference(os).List()) - - if len(removed) > 0 { - detachOpts := &lbu.DetachLoadBalancerFromSubnetsInput{ - LoadBalancerName: aws.String(d.Id()), - Subnets: removed, - } - - log.Printf("[DEBUG] Load Balancer detach subnet_id opts: %v", detachOpts) - - var err error - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err := conn.API.DetachLoadBalancerFromSubnets(detachOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure removing Load Balancer subnets: %s", err) - } - } - - if len(added) > 0 { - attachOpts := &lbu.AttachLoadBalancerToSubnetsInput{ - LoadBalancerName: aws.String(d.Id()), - Subnets: added, - } - var err error - - log.Printf("[DEBUG] Load Balancer attach subnets opts: %v", attachOpts) - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.AttachLoadBalancerToSubnets(attachOpts) - if err != nil { - if awsErr, ok := err.(awserr.Error); ok { - // eventually consistent issue with removing a subnet in AZ1 and - // immediately adding a new one in the same AZ - if awsErr.Code() == "InvalidConfigurationRequest" && strings.Contains(awsErr.Message(), "cannot be attached to multiple subnets in the same AZ") { - log.Printf("[DEBUG] retrying az association") - return resource.RetryableError(awsErr) - } - } - return resource.NonRetryableError(err) - } - return nil - }) - if err != nil { - return fmt.Errorf("Failure adding Load Balancer subnets: %s", err) - } - } - - d.SetPartial("subnet_id") - } - d.SetPartial("listeners") d.SetPartial("policies") @@ -762,18 +670,23 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI log.Printf("[INFO] Deleting Load Balancer: %s", d.Id()) // Destroy the load balancer - deleteElbOpts := lbu.DeleteLoadBalancerInput{ - LoadBalancerName: aws.String(d.Id()), + req := oscgo.DeleteLoadBalancerRequest{ + LoadBalancerName: d.Id(), + } + + deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ + optional.NewInterface(req), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeleteLoadBalancer(&deleteElbOpts) + _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer( + context.Background(), &deleteElbOpts) if err != nil { if strings.Contains(err.Error(), "Throttling:") { return resource.RetryableError(err) @@ -792,192 +705,52 @@ func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interfa return nil } -func isLoadBalancerNotFound(err error) bool { - return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") -} - -func expandListeners(configured []interface{}) ([]*lbu.Listener, error) { - listeners := make([]*lbu.Listener, 0, len(configured)) - - for _, lRaw := range configured { - data := lRaw.(map[string]interface{}) - - ip := int64(data["instance_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) - l := &lbu.Listener{ - InstancePort: &ip, - InstanceProtocol: aws.String(data["instance_protocol"].(string)), - LoadBalancerPort: &lp, - Protocol: aws.String(data["protocol"].(string)), - } - - if v, ok := data["ssl_certificate_id"]; ok && v != "" { - l.SSLCertificateId = aws.String(v.(string)) - } - - var valid bool - if l.SSLCertificateId != nil && *l.SSLCertificateId != "" { - // validate the protocol is correct - for _, p := range []string{"https", "ssl"} { - if (strings.ToLower(*l.InstanceProtocol) == p) || (strings.ToLower(*l.Protocol) == p) { - valid = true - } - } - } else { - valid = true - } - - if valid { - listeners = append(listeners, l) - } else { - return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") - } - } - - return listeners, nil -} - -func flattenInstances(list []*lbu.Instance) []map[string]string { - result := make([]map[string]string, len(list)) - for _, i := range list { - result = append(result, map[string]string{"instance_id": *i.InstanceId}) - } - return result -} - // Expands an array of String Instance IDs into a []Instances -func expandInstanceString(list []interface{}) []*lbu.Instance { - result := make([]*lbu.Instance, 0, len(list)) +func expandInstanceString(list []interface{}) []string { + result := make([]string, 0, len(list)) for _, i := range list { - result = append(result, &lbu.Instance{InstanceId: aws.String(i.(string))}) - } - return result -} - -// Flattens an array of Backend Descriptions into a a map of instance_port to policy names. -func flattenBackendPolicies(backends []*lbu.BackendServerDescription) map[int64][]string { - policies := make(map[int64][]string) - for _, i := range backends { - for _, p := range i.PolicyNames { - policies[*i.InstancePort] = append(policies[*i.InstancePort], *p) - } - sort.Strings(policies[*i.InstancePort]) - } - return policies -} - -// Flattens an array of Listeners into a []map[string]interface{} -func flattenListeners(list []*lbu.ListenerDescription) []map[string]interface{} { - result := make([]map[string]interface{}, 0, len(list)) - - for _, i := range list { - l := make(map[string]interface{}) - listener := map[string]interface{}{ - "instance_port": strconv.Itoa(int(aws.Int64Value(i.Listener.InstancePort))), - "instance_protocol": strings.ToLower(aws.StringValue(i.Listener.InstanceProtocol)), - "load_balancer_port": strconv.Itoa(int(aws.Int64Value(i.Listener.LoadBalancerPort))), - "protocol": strings.ToLower(aws.StringValue(i.Listener.Protocol)), - "ssl_certificate_id": aws.StringValue(i.Listener.SSLCertificateId), - } - l["listener"] = listener - l["policy_names"] = flattenStringList(i.PolicyNames) - result = append(result, l) + result = append(result, i.(string)) } return result } -func flattenHealthCheck(check *lbu.HealthCheck) map[string]interface{} { - chk := make(map[string]interface{}) - - if check != nil { - chk["unhealthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.UnhealthyThreshold))) - chk["healthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.HealthyThreshold))) - chk["target"] = aws.StringValue(check.Target) - chk["timeout"] = strconv.Itoa(int(aws.Int64Value(check.Timeout))) - chk["interval"] = strconv.Itoa(int(aws.Int64Value(check.Interval))) - } - - return chk -} - -func expandOAPIListeners(configured []interface{}) ([]*lbu.Listener, error) { - listeners := make([]*lbu.Listener, 0, len(configured)) - - for _, lRaw := range configured { - data := lRaw.(map[string]interface{}) - - ip := int64(data["backend_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) - l := &lbu.Listener{ - InstancePort: &ip, - InstanceProtocol: aws.String(data["backend_protocol"].(string)), - LoadBalancerPort: &lp, - Protocol: aws.String(data["load_balancer_protocol"].(string)), - } - - if v, ok := data["server_certificate_id"]; ok && v != "" { - l.SSLCertificateId = aws.String(v.(string)) - } - - var valid bool - if l.SSLCertificateId != nil && *l.SSLCertificateId != "" { - // validate the load_balancer_protocol is correct - for _, p := range []string{"https", "ssl"} { - if (strings.ToLower(*l.InstanceProtocol) == p) || (strings.ToLower(*l.Protocol) == p) { - valid = true - } - } - } else { - valid = true - } - - if valid { - listeners = append(listeners, l) - } else { - return nil, fmt.Errorf("[ERR] Load Balancer Listener: server_certificate_id may be set only when load_balancer_protocol is 'https' or 'ssl'") - } - } - - return listeners, nil -} - -func flattenOAPIInstances(list []*lbu.Instance) []map[string]string { - result := make([]map[string]string, len(list)) - for _, i := range list { - result = append(result, map[string]string{"vm_id": *i.InstanceId}) +func flattenOAPIInstances(list *[]string) []map[string]string { + result := make([]map[string]string, len(*list)) + for _, s := range *list { + result = append(result, map[string]string{"vm_id": s}) } return result } // Flattens an array of Listeners into a []map[string]interface{} -func flattenOAPIListeners(list []*lbu.ListenerDescription) []map[string]interface{} { - result := make([]map[string]interface{}, 0, len(list)) +func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { + result := make([]map[string]interface{}, 0, len(*list)) - for _, i := range list { + for _, i := range *list { l := make(map[string]interface{}) listener := map[string]interface{}{ - "backend_port": strconv.Itoa(int(aws.Int64Value(i.Listener.InstancePort))), - "backend_protocol": strings.ToLower(aws.StringValue(i.Listener.InstanceProtocol)), - "load_balancer_port": strconv.Itoa(int(aws.Int64Value(i.Listener.LoadBalancerPort))), - "load_balancer_protocol": strings.ToLower(aws.StringValue(i.Listener.Protocol)), - "server_certificate_id": aws.StringValue(i.Listener.SSLCertificateId), + "backend_port": strconv.Itoa(int(*i.BackendPort)), + "backend_protocol": strings.ToLower(*i.BackendProtocol), + "load_balancer_port": strconv.Itoa(int(*i.LoadBalancerPort)), + "load_balancer_protocol": strings.ToLower(*i.LoadBalancerProtocol), + "server_certificate_id": i.ServerCertificateId, } l["listener"] = listener - l["policy_name"] = flattenStringList(i.PolicyNames) + l["policy_name"] = flattenStringList(*i.PolicyNames) result = append(result, l) } return result } -func flattenOAPIHealthCheck(check *lbu.HealthCheck) map[string]interface{} { +func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { chk := make(map[string]interface{}) if check != nil { - chk["unhealthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.UnhealthyThreshold))) - chk["healthy_threshold"] = strconv.Itoa(int(aws.Int64Value(check.HealthyThreshold))) - chk["target"] = aws.StringValue(check.Target) - chk["timeout"] = strconv.Itoa(int(aws.Int64Value(check.Timeout))) - chk["interval"] = strconv.Itoa(int(aws.Int64Value(check.Interval))) + chk["unhealthy_threshold"] = strconv.Itoa(int(check.UnhealthyThreshold)) + chk["healthy_threshold"] = strconv.Itoa(int(check.HealthyThreshold)) + chk["target"] = check.Path + chk["timeout"] = strconv.Itoa(int(check.Timeout)) + chk["interval"] = strconv.Itoa(int(check.CheckInterval)) } return chk From 16d42087503d2a5377160e2eb78da318ca08d938 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 9 Apr 2020 17:59:19 +0200 Subject: [PATCH 031/218] tags: add lbu Signed-off-by: matthias.gatto --- outscale/oapi_tags.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/outscale/oapi_tags.go b/outscale/oapi_tags.go index 0b2394eb0..09bf0d082 100644 --- a/outscale/oapi_tags.go +++ b/outscale/oapi_tags.go @@ -155,6 +155,19 @@ func diffOSCAPITags(oldTags, newTags []oscgo.ResourceTag) ([]oscgo.ResourceTag, return tagsOSCAPIFromMap(create), remove } +func tagsFromMapLBU(m map[string]interface{}) *[]oscgo.ResourceTag { + result := make([]oscgo.ResourceTag, 0, len(m)) + for k, v := range m { + t := oscgo.ResourceTag{ + Key: k, + Value: v.(string), + } + result = append(result, t) + } + + return &result +} + func tagsFromSliceMap(m *schema.Set) []oscgo.ResourceTag { result := make([]oscgo.ResourceTag, 0, m.Len()) for _, v := range m.List() { From 9cd7a8ccee5987830e035ff2829ee1260c3b2fca Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 9 Apr 2020 17:46:12 +0200 Subject: [PATCH 032/218] lbu: tests Signed-off-by: matthias.gatto --- ..._outscale_load_balancer_attributes_test.go | 14 +-- ...utscale_load_balancer_health_check_test.go | 7 +- ...e_outscale_load_balancer_listeners_test.go | 11 +- ...urce_outscale_load_balancer_policy_test.go | 7 +- ...cale_load_balancer_ssl_certificate_test.go | 7 +- .../resource_outscale_load_balancer_test.go | 103 ++++++++++-------- ...ce_outscale_oapi_load_balancer_vms_test.go | 7 +- 7 files changed, 79 insertions(+), 77 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index 7574ab1a2..36b4bfbb0 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -4,22 +4,22 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleOAPILBUAttr_basic(t *testing.T) { t.Skip() - var conf lbu.LoadBalancerAttributes + var conf oscgo.AccessLog r := acctest.RandIntRange(0, 10) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer_attributes.bar2", @@ -34,7 +34,7 @@ func TestAccOutscaleOAPILBUAttr_basic(t *testing.T) { }) } -func testAccCheckOutscaleOAPILBUAttrExists(n string, res *lbu.LoadBalancerAttributes) resource.TestCheckFunc { +func testAccCheckOutscaleOAPILBUAttrExists(n string, res *oscgo.AccessLog) resource.TestCheckFunc { return func(s *terraform.State) error { rs, ok := s.RootModule().Resources[n] if !ok { diff --git a/outscale/resource_outscale_load_balancer_health_check_test.go b/outscale/resource_outscale_load_balancer_health_check_test.go index e6d120784..a14efbae1 100644 --- a/outscale/resource_outscale_load_balancer_health_check_test.go +++ b/outscale/resource_outscale_load_balancer_health_check_test.go @@ -4,18 +4,15 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIHealthCheck_basic(t *testing.T) { - t.Skip() - r := acctest.RandIntRange(0, 10) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer_health_check.test", diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go index d8a428f85..e7ba1b508 100644 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -2,22 +2,19 @@ package outscale import ( "fmt" + oscgo "github.com/marinsalinas/osc-sdk-go" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPILBUUpdate_Listener(t *testing.T) { - t.Skip() - - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer r := acctest.RandIntRange(0, 10) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer_listeners.bar", diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index 58763fc25..85927abb4 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -3,21 +3,18 @@ package outscale import ( "testing" - "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestOutscaleOAPILoadBalancerPolicy_basic(t *testing.T) { - t.Skip() - resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, Providers: testAccProviders, // CheckDestroy: testAccCheckOutscaleLoadBalancerDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig, Check: resource.ComposeTestCheckFunc( resource.TestCheckResourceAttr( diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go index 3267d3b91..5de34d6d9 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go @@ -4,20 +4,17 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleLBUOAPISSLCertificate_basic(t *testing.T) { - t.Skip() - //WIP: Missing correct test case rInt := acctest.RandIntRange(0, 10) unixFile := "test-fixtures/eim-ssl-unix-line-endings.pem" resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer_ssl_certificate.test", diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index feb194241..f2fdbe823 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -1,6 +1,7 @@ package outscale import ( + "context" "fmt" "reflect" "sort" @@ -8,22 +9,21 @@ import ( "testing" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleOAPILBUBasic(t *testing.T) { - t.Skip() - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer r := acctest.RandIntRange(0, 10) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", @@ -53,7 +53,7 @@ func TestAccOutscaleOAPILBUBasic(t *testing.T) { } func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { - conn := testAccProvider.Meta().(*OutscaleClient).LBU + conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI for _, rs := range s.RootModule().Resources { if rs.Type != "outscale_load_balancer" { @@ -61,12 +61,22 @@ func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { } var err error - var resp *lbu.DescribeLoadBalancersOutput - var describe *lbu.DescribeLoadBalancersResult + var resp oscgo.ReadLoadBalancersResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(&lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(rs.Primary.ID)}, - }) + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{rs.Primary.ID}, + } + + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -74,15 +84,13 @@ func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancersResult != nil { - describe = resp.DescribeLoadBalancersResult - } return nil }) if err == nil { - if len(describe.LoadBalancerDescriptions) != 0 && - *describe.LoadBalancerDescriptions[0].LoadBalancerName == rs.Primary.ID { + if len(*resp.LoadBalancers) != 0 && + *(*resp.LoadBalancers)[0].LoadBalancerName == + rs.Primary.ID { return fmt.Errorf("LBU still exists") } } @@ -99,19 +107,19 @@ func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { return nil } -func testAccCheckOutscaleOAPILBUAttributes(conf *lbu.LoadBalancerDescription) resource.TestCheckFunc { +func testAccCheckOutscaleOAPILBUAttributes(conf *oscgo.LoadBalancer) resource.TestCheckFunc { return func(s *terraform.State) error { zones := []string{"eu-west-2a"} - azs := make([]string, 0, len(conf.AvailabilityZones)) - for _, x := range conf.AvailabilityZones { - azs = append(azs, *x) + azs := make([]string, 0, len(*conf.SubregionNames)) + for _, x := range *conf.SubregionNames { + azs = append(azs, x) } sort.StringSlice(azs).Sort() if !reflect.DeepEqual(azs, zones) { return fmt.Errorf("bad sub_region_name") } - if *conf.DNSName == "" { + if *conf.DnsName == "" { return fmt.Errorf("empty dns_name") } @@ -119,19 +127,19 @@ func testAccCheckOutscaleOAPILBUAttributes(conf *lbu.LoadBalancerDescription) re } } -func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *lbu.LoadBalancerDescription) resource.TestCheckFunc { +func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *oscgo.LoadBalancer) resource.TestCheckFunc { return func(s *terraform.State) error { zones := []string{"eu-west-2a"} - azs := make([]string, 0, len(conf.AvailabilityZones)) - for _, x := range conf.AvailabilityZones { - azs = append(azs, *x) + azs := make([]string, 0, len(*conf.SubregionNames)) + for _, x := range *conf.SubregionNames { + azs = append(azs, x) } sort.StringSlice(azs).Sort() if !reflect.DeepEqual(azs, zones) { return fmt.Errorf("bad sub_region_name") } - if *conf.DNSName == "" { + if *conf.DnsName == "" { return fmt.Errorf("empty dns_name") } @@ -139,7 +147,7 @@ func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *lbu.LoadBalancerDesc } } -func testAccCheckOutscaleOAPILBUExists(n string, res *lbu.LoadBalancerDescription) resource.TestCheckFunc { +func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resource.TestCheckFunc { return func(s *terraform.State) error { rs, ok := s.RootModule().Resources[n] if !ok { @@ -150,24 +158,33 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *lbu.LoadBalancerDescriptio return fmt.Errorf("No LBU ID is set") } - conn := testAccProvider.Meta().(*OutscaleClient).LBU + conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI var err error - var resp *lbu.DescribeLoadBalancersOutput - var describe *lbu.DescribeLoadBalancersResult + var resp oscgo.ReadLoadBalancersResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(&lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(rs.Primary.ID)}, - }) + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{rs.Primary.ID}, + } + + req := &oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancersResult != nil { - describe = resp.DescribeLoadBalancersResult - } return nil }) @@ -175,14 +192,14 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *lbu.LoadBalancerDescriptio return err } - if len(describe.LoadBalancerDescriptions) != 1 || - *describe.LoadBalancerDescriptions[0].LoadBalancerName != rs.Primary.ID { + if len(*resp.LoadBalancers) != 1 || + *(*resp.LoadBalancers)[0].LoadBalancerName != rs.Primary.ID { return fmt.Errorf("LBU not found") } - *res = *describe.LoadBalancerDescriptions[0] + res = &(*resp.LoadBalancers)[0] - if res.VPCId != nil { + if res.NetId != nil { sgid := rs.Primary.Attributes["source_security_group_id"] if sgid == "" { return fmt.Errorf("Expected to find source_security_group_id for LBU, but was empty") diff --git a/outscale/resource_outscale_oapi_load_balancer_vms_test.go b/outscale/resource_outscale_oapi_load_balancer_vms_test.go index dda429c68..8b744d51c 100644 --- a/outscale/resource_outscale_oapi_load_balancer_vms_test.go +++ b/outscale/resource_outscale_oapi_load_balancer_vms_test.go @@ -2,18 +2,15 @@ package outscale import ( "fmt" - "os" "testing" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" oscgo "github.com/marinsalinas/osc-sdk-go" ) func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { - o := os.Getenv("OUTSCALE_OAPI") - var conf oscgo.LoadBalancer testCheckInstanceAttached := func(count int) resource.TestCheckFunc { From b603afc9ee6c568c023e8dca5ce1272e5549d2db Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 10 Apr 2020 11:53:08 +0200 Subject: [PATCH 033/218] Revert "LBU-remove: rm resource_outscale_load_balancer_cookiepolicy" This reverts commit fa8551d98fc94231c601345f725a002d07ae35a0. --- ...rce_outscale_load_balancer_cookiepolicy.go | 138 ++++++++++++ ...utscale_load_balancer_cookiepolicy_test.go | 209 ++++++++++++++++++ 2 files changed, 347 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_cookiepolicy.go create mode 100644 outscale/resource_outscale_load_balancer_cookiepolicy_test.go diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_cookiepolicy.go new file mode 100644 index 000000000..f2e73fa8d --- /dev/null +++ b/outscale/resource_outscale_load_balancer_cookiepolicy.go @@ -0,0 +1,138 @@ +package outscale + +import ( + "fmt" + "regexp" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleAppCookieStickinessPolicyCreate, + Read: resourceOutscaleAppCookieStickinessPolicyRead, + Delete: resourceOutscaleAppCookieStickinessPolicyDelete, + + Schema: map[string]*schema.Schema{ + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + ValidateFunc: func(v interface{}, k string) (ws []string, es []error) { + value := v.(string) + if !regexp.MustCompile(`^[0-9A-Za-z-]+$`).MatchString(value) { + es = append(es, fmt.Errorf( + "only alphanumeric characters and hyphens allowed in %q", k)) + } + return + }, + }, + + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "cookie_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + l, lok := d.GetOk("load_balancer_name") + p, pok := d.GetOk("policy_name") + v, ok := d.GetOk("cookie_name") + + if !lok && !pok && !ok { + return fmt.Errorf("please provide the required attributes load_balancer_name, policy_name and cookie_name") + } + + acspOpts := &lbu.CreateAppCookieStickinessPolicyInput{ + LoadBalancerName: aws.String(l.(string)), + PolicyName: aws.String(p.(string)), + CookieName: aws.String(v.(string)), + } + + var err error + var resp *lbu.CreateAppCookieStickinessPolicyOutput + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.CreateAppCookieStickinessPolicy(acspOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating AppCookieStickinessPolicy, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Error creating AppCookieStickinessPolicy: %s", err) + } + + //utils.PrintToJSON(resp, "RESPONSECookie") + + reqID := "" + if resp.ResponseMetadata != nil { + reqID = aws.StringValue(resp.ResponseMetadata.RequestID) + } + d.Set("request_id", reqID) + d.SetId(resource.UniqueId()) + d.Set("load_balancer_name", l.(string)) + d.Set("policy_name", p.(string)) + d.Set("cookie_name", v.(string)) + + return resourceOutscaleAppCookieStickinessPolicyRead(d, meta) +} + +func resourceOutscaleAppCookieStickinessPolicyRead(d *schema.ResourceData, meta interface{}) error { + return nil +} + +func resourceOutscaleAppCookieStickinessPolicyDelete(d *schema.ResourceData, meta interface{}) error { + elbconn := meta.(*OutscaleClient).LBU + + l := d.Get("load_balancer_name").(string) + p := d.Get("policy_name").(string) + + request := &lbu.DeleteLoadBalancerPolicyInput{ + LoadBalancerName: aws.String(l), + PolicyName: aws.String(p), + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = elbconn.API.DeleteLoadBalancerPolicy(request) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error deleting App stickiness policy, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Error deleting App stickiness policy %s: %s", d.Id(), err) + } + return nil +} diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy_test.go b/outscale/resource_outscale_load_balancer_cookiepolicy_test.go new file mode 100644 index 000000000..b18ee41aa --- /dev/null +++ b/outscale/resource_outscale_load_balancer_cookiepolicy_test.go @@ -0,0 +1,209 @@ +package outscale + +import ( + "fmt" + "os" + "strconv" + "strings" + "testing" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" +) + +func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { + t.Skip() + + o := os.Getenv("OUTSCALE_OAPI") + + oapi, err := strconv.ParseBool(o) + if err != nil { + oapi = false + } + + if oapi { + t.Skip() + } + + lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + Providers: testAccProviders, + CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, + Steps: []resource.TestStep{ + resource.TestStep{ + Config: testAccAppCookieStickinessPolicyConfig(lbName), + Check: resource.ComposeTestCheckFunc( + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), + ), + }, + resource.TestStep{ + Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName), + Check: resource.ComposeTestCheckFunc( + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), + ), + }, + }, + }) +} + +func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { + t.Skip() + o := os.Getenv("OUTSCALE_OAPI") + + oapi, err := strconv.ParseBool(o) + if err != nil { + oapi = false + } + + if oapi { + t.Skip() + } + + lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) + + // check that we can destroy the policy if the LB is missing + removeLB := func() { + conn := testAccProvider.Meta().(*OutscaleClient).LBU + + deleteElbOpts := lbu.DeleteLoadBalancerInput{ + LoadBalancerName: aws.String(lbName), + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, err = conn.API.DeleteLoadBalancer(&deleteElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + t.Fatalf("Error deleting ELB: %s", err) + } + } + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + Providers: testAccProviders, + CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, + Steps: []resource.TestStep{ + resource.TestStep{ + Config: testAccAppCookieStickinessPolicyConfig(lbName), + Check: resource.ComposeTestCheckFunc( + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), + ), + }, + resource.TestStep{ + PreConfig: removeLB, + Config: testAccAppCookieStickinessPolicyConfigDestroy(lbName), + }, + }, + }) +} + +func testAccCheckAppCookieStickinessPolicyDestroy(s *terraform.State) error { + + for _, rs := range s.RootModule().Resources { + if rs.Type != "outscale_load_balancer_cookiepolicy" { + continue + } + } + return nil +} + +func testAccCheckAppCookieStickinessPolicy(elbResource string, policyResource string) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[elbResource] + if !ok { + return fmt.Errorf("Not found: %s", elbResource) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No ID is set") + } + + if !ok { + return fmt.Errorf("Not found: %s", policyResource) + } + + return nil + } +} + +func testAccAppCookieStickinessPolicyConfig(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +} + +resource "outscale_load_balancer_cookiepolicy" "foo" { + policy_name = "foo-policy" + load_balancer_name = "${outscale_load_balancer.lb.id}" + cookie_name = "MyAppCookie" +}`, rName) +} + +// Change the cookie_name to "MyOtherAppCookie". +func testAccAppCookieStickinessPolicyConfigUpdate(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +} + +resource "outscale_load_balancer_cookiepolicy" "foo" { + policy_name = "foo-policy" + load_balancer_name = "${outscale_load_balancer.lb.id}" + cookie_name = "MyOtherAppCookie" +}`, rName) +} + +// attempt to destroy the policy, but we'll delete the LB in the PreConfig +func testAccAppCookieStickinessPolicyConfigDestroy(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +}`, rName) +} From 609155b4a1d31ccd018b517c25c860cb70d34938 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 10 Apr 2020 13:42:54 +0200 Subject: [PATCH 034/218] remove oapi from vms name and port cookiepolicy Signed-off-by: matthias.gatto --- ...rce_outscale_load_balancer_cookiepolicy.go | 47 ++++++++++++------- ...=> resource_outscale_load_balancer_vms.go} | 0 ...source_outscale_load_balancer_vms_test.go} | 0 3 files changed, 31 insertions(+), 16 deletions(-) rename outscale/{resource_outscale_oapi_load_balancer_vms.go => resource_outscale_load_balancer_vms.go} (100%) rename outscale/{resource_outscale_oapi_load_balancer_vms_test.go => resource_outscale_load_balancer_vms_test.go} (100%) diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_cookiepolicy.go index f2e73fa8d..e2921eeba 100644 --- a/outscale/resource_outscale_load_balancer_cookiepolicy.go +++ b/outscale/resource_outscale_load_balancer_cookiepolicy.go @@ -1,15 +1,17 @@ package outscale import ( + "context" "fmt" "regexp" "strings" "time" - "github.com/aws/aws-sdk-go/aws" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform/helper/resource" "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" ) func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { @@ -52,7 +54,7 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { } func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI l, lok := d.GetOk("load_balancer_name") p, pok := d.GetOk("policy_name") @@ -62,16 +64,23 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met return fmt.Errorf("please provide the required attributes load_balancer_name, policy_name and cookie_name") } - acspOpts := &lbu.CreateAppCookieStickinessPolicyInput{ - LoadBalancerName: aws.String(l.(string)), - PolicyName: aws.String(p.(string)), - CookieName: aws.String(v.(string)), + vs := v.(string) + req := &oscgo.CreateLoadBalancerPolicyRequest{ + LoadBalancerName: l.(string), + PolicyName: p.(string), + CookieName: &vs, + } + acspOpts := oscgo.CreateLoadBalancerPolicyOpts{ + optional.NewInterface(req), } var err error - var resp *lbu.CreateAppCookieStickinessPolicyOutput + var resp oscgo.CreateLoadBalancerPolicyResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.CreateAppCookieStickinessPolicy(acspOpts) + resp, _, err = conn.LoadBalancerPolicyApi. + CreateLoadBalancerPolicy( + context.Background(), + &acspOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -90,8 +99,8 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met //utils.PrintToJSON(resp, "RESPONSECookie") reqID := "" - if resp.ResponseMetadata != nil { - reqID = aws.StringValue(resp.ResponseMetadata.RequestID) + if resp.ResponseContext != nil { + reqID = *resp.ResponseContext.RequestId } d.Set("request_id", reqID) d.SetId(resource.UniqueId()) @@ -107,19 +116,25 @@ func resourceOutscaleAppCookieStickinessPolicyRead(d *schema.ResourceData, meta } func resourceOutscaleAppCookieStickinessPolicyDelete(d *schema.ResourceData, meta interface{}) error { - elbconn := meta.(*OutscaleClient).LBU + elbconn := meta.(*OutscaleClient).OSCAPI l := d.Get("load_balancer_name").(string) p := d.Get("policy_name").(string) - request := &lbu.DeleteLoadBalancerPolicyInput{ - LoadBalancerName: aws.String(l), - PolicyName: aws.String(p), + request := &oscgo.DeleteLoadBalancerPolicyRequest{ + LoadBalancerName: l, + PolicyName: p, + } + + opts := &oscgo.DeleteLoadBalancerPolicyOpts{ + optional.NewInterface(request), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = elbconn.API.DeleteLoadBalancerPolicy(request) + _, _, err = elbconn.LoadBalancerPolicyApi. + DeleteLoadBalancerPolicy( + context.Background(), opts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { diff --git a/outscale/resource_outscale_oapi_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go similarity index 100% rename from outscale/resource_outscale_oapi_load_balancer_vms.go rename to outscale/resource_outscale_load_balancer_vms.go diff --git a/outscale/resource_outscale_oapi_load_balancer_vms_test.go b/outscale/resource_outscale_load_balancer_vms_test.go similarity index 100% rename from outscale/resource_outscale_oapi_load_balancer_vms_test.go rename to outscale/resource_outscale_load_balancer_vms_test.go From b87c0e92004de559c05704b9f88ab4f77cf30166 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 10 Apr 2020 15:36:25 +0200 Subject: [PATCH 035/218] lbu: provider.go Signed-off-by: matthias.gatto --- outscale/provider.go | 8 +++ ...ource_outscale_load_balancer_attributes.go | 4 +- ...rce_outscale_load_balancer_cookiepolicy.go | 12 ++-- ...utscale_load_balancer_cookiepolicy_test.go | 58 ++++++------------- ...rce_outscale_load_balancer_health_check.go | 4 +- ...source_outscale_load_balancer_listeners.go | 4 +- .../resource_outscale_load_balancer_policy.go | 4 +- ..._outscale_load_balancer_ssl_certificate.go | 4 +- .../resource_outscale_load_balancer_vms.go | 4 +- 9 files changed, 44 insertions(+), 58 deletions(-) diff --git a/outscale/provider.go b/outscale/provider.go index 9b0b56fc9..206942a9b 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -75,6 +75,14 @@ func Provider() terraform.ResourceProvider { "outscale_vpn_connection": resourceOutscaleVPNConnection(), "outscale_vpn_connection_route": resourceOutscaleVPNConnectionRoute(), "outscale_access_key": resourceOutscaleAccessKey(), + "outscale_load_balancer": resourceOutscaleOAPILoadBalancer(), + "outscale_load_balancer_cookiepolicy": resourceOutscaleAppCookieStickinessPolicy(), + "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), + "outscale_load_balancer_listeners": resourceOutscaleOAPILoadBalancerListeners(), + "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), + "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), + "outscale_load_balancer_policy": resourceOutscaleOAPILoadBalancerPolicy(), + "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), }, DataSourcesMap: map[string]*schema.Resource{ "outscale_vm": dataSourceOutscaleOAPIVM(), diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 50fa6ff8b..b979cc27d 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -11,8 +11,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_cookiepolicy.go index e2921eeba..989a33840 100644 --- a/outscale/resource_outscale_load_balancer_cookiepolicy.go +++ b/outscale/resource_outscale_load_balancer_cookiepolicy.go @@ -10,8 +10,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { @@ -21,7 +21,7 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { Delete: resourceOutscaleAppCookieStickinessPolicyDelete, Schema: map[string]*schema.Schema{ - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Required: true, ForceNew: true, @@ -35,17 +35,17 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { }, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "cookie_name": &schema.Schema{ + "cookie_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy_test.go b/outscale/resource_outscale_load_balancer_cookiepolicy_test.go index b18ee41aa..dcfd98c2c 100644 --- a/outscale/resource_outscale_load_balancer_cookiepolicy_test.go +++ b/outscale/resource_outscale_load_balancer_cookiepolicy_test.go @@ -1,35 +1,21 @@ package outscale import ( + "context" "fmt" - "os" - "strconv" "strings" "testing" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { - t.Skip() - - o := os.Getenv("OUTSCALE_OAPI") - - oapi, err := strconv.ParseBool(o) - if err != nil { - oapi = false - } - - if oapi { - t.Skip() - } - lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) resource.Test(t, resource.TestCase{ @@ -37,7 +23,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: testAccAppCookieStickinessPolicyConfig(lbName), Check: resource.ComposeTestCheckFunc( testAccCheckAppCookieStickinessPolicy( @@ -46,7 +32,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { ), ), }, - resource.TestStep{ + { Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName), Check: resource.ComposeTestCheckFunc( testAccCheckAppCookieStickinessPolicy( @@ -60,31 +46,23 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { } func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { - t.Skip() - o := os.Getenv("OUTSCALE_OAPI") - - oapi, err := strconv.ParseBool(o) - if err != nil { - oapi = false - } - - if oapi { - t.Skip() - } - lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) // check that we can destroy the policy if the LB is missing removeLB := func() { - conn := testAccProvider.Meta().(*OutscaleClient).LBU + conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI + + request := oscgo.DeleteLoadBalancerRequest{ + LoadBalancerName: lbName, + } - deleteElbOpts := lbu.DeleteLoadBalancerInput{ - LoadBalancerName: aws.String(lbName), + deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ + optional.NewInterface(request), } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, err = conn.API.DeleteLoadBalancer(&deleteElbOpts) + _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer(context.Background(), &deleteElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -106,7 +84,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { Providers: testAccProviders, CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, Steps: []resource.TestStep{ - resource.TestStep{ + { Config: testAccAppCookieStickinessPolicyConfig(lbName), Check: resource.ComposeTestCheckFunc( testAccCheckAppCookieStickinessPolicy( @@ -115,7 +93,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { ), ), }, - resource.TestStep{ + { PreConfig: removeLB, Config: testAccAppCookieStickinessPolicyConfigDestroy(lbName), }, diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index e6f18ee41..7ade67e62 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -10,8 +10,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index e07271b38..80cd0220e 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -10,8 +10,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index 16e842993..fea51addc 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -10,8 +10,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate.go b/outscale/resource_outscale_load_balancer_ssl_certificate.go index 865bae73e..712cbd0e2 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate.go @@ -8,8 +8,8 @@ import ( "github.com/antihax/optional" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" oscgo "github.com/marinsalinas/osc-sdk-go" ) diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index d0788b5f2..5e3497c2a 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -10,8 +10,8 @@ import ( "github.com/antihax/optional" oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func resourceOutscaleOAPILBUAttachment() *schema.Resource { From 40a10f89bcf7fa5114d3286e884c288be103ba3e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Tue, 14 Apr 2020 12:13:46 +0200 Subject: [PATCH 036/218] fix multiple errors: fix X is X fix flattenListenerForCreation fix flattenString (or something similar) other fix I've forgot Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 40 +++++++++++-------- ...ource_outscale_load_balancer_attributes.go | 6 +-- ...rce_outscale_load_balancer_cookiepolicy.go | 4 +- ...rce_outscale_load_balancer_health_check.go | 2 +- ...source_outscale_load_balancer_listeners.go | 18 ++++----- .../resource_outscale_load_balancer_policy.go | 2 +- .../resource_outscale_load_balancer_test.go | 10 ++--- .../resource_outscale_load_balancer_vms.go | 2 +- 8 files changed, 46 insertions(+), 38 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index e6560ee6d..0ce0622ef 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -26,9 +26,10 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "sub_region_name": { + "subregion_name": { Type: schema.TypeList, - Required: true, + Optional: true, + Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, "listener": { @@ -267,7 +268,7 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req.LoadBalancerType = &s } - if v, ok := d.GetOk("sub_region_name"); ok { + if v, ok := d.GetOk("subregion_name"); ok { req.SubregionNames = expandStringList(v.([]interface{})) } @@ -280,7 +281,7 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa } elbOpts := &oscgo.CreateLoadBalancerOpts{ - optional.NewInterface(req), + optional.NewInterface(*req), } log.Printf("[DEBUG] Load Balancer create configuration: %#v", elbOpts) @@ -318,9 +319,12 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerRead(d, meta) } -func flattenStringList(list []string) []interface{} { - vs := make([]interface{}, 0, len(list)) - for _, v := range list { +func flattenStringList(list *[]string) []interface{} { + if list == nil { + return make([]interface{}, 0) + } + vs := make([]interface{}, 0, len(*list)) + for _, v := range *list { vs = append(vs, v) } return vs @@ -335,7 +339,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface LoadBalancerNames: &[]string{elbName}, } - req := &oscgo.ReadLoadBalancersRequest{ + req := oscgo.ReadLoadBalancersRequest{ Filters: filter, } @@ -378,7 +382,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface lb := (*resp.LoadBalancers)[0] - d.Set("sub_region_name", flattenStringList(*lb.SubregionNames)) + d.Set("subregion_name", flattenStringList(lb.SubregionNames)) d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) @@ -428,7 +432,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("policies", policies) d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { - d.Set("firewall_rules_set_name", flattenStringList(*lb.SecurityGroups)) + d.Set("firewall_rules_set_name", flattenStringList(lb.SecurityGroups)) } else { d.Set("firewall_rules_set_name", make([]map[string]interface{}, 0)) } @@ -438,7 +442,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface ssg["account_alias"] = *lb.SourceSecurityGroup.SecurityGroupAccountId } d.Set("source_firewall_rules_set", ssg) - d.Set("subnet_id", flattenStringList(*lb.Subnets)) + d.Set("subnet_id", flattenStringList(lb.Subnets)) d.Set("vpc_id", lb.NetId) d.Set("request_id", resp.ResponseContext.RequestId) @@ -457,7 +461,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return fmt.Errorf("firewall_rules_set_name update is not supported") } - if d.HasChange("sub_region_name") { + if d.HasChange("subregion_name") { return fmt.Errorf("sub_region_name update is not supported") } @@ -479,7 +483,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa ports = append(ports, *listener.LoadBalancerPort) } - req := &oscgo.DeleteLoadBalancerListenersRequest{ + req := oscgo.DeleteLoadBalancerListenersRequest{ LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } @@ -510,7 +514,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } if len(add) > 0 { - req := &oscgo.CreateLoadBalancerListenersRequest{ + req := oscgo.CreateLoadBalancerListenersRequest{ LoadBalancerName: d.Id(), Listeners: add, } @@ -733,10 +737,14 @@ func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { "backend_protocol": strings.ToLower(*i.BackendProtocol), "load_balancer_port": strconv.Itoa(int(*i.LoadBalancerPort)), "load_balancer_protocol": strings.ToLower(*i.LoadBalancerProtocol), - "server_certificate_id": i.ServerCertificateId, + } + if i.ServerCertificateId != nil { + listener["server_certificate_id"] = + *i.ServerCertificateId } l["listener"] = listener - l["policy_name"] = flattenStringList(*i.PolicyNames) + l["policy_name"] = flattenStringList(i.PolicyNames) + log.Printf("[DEBUG] before append: %v", l) result = append(result, l) } return result diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index b979cc27d..f67c956ec 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -97,7 +97,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me return fmt.Errorf("please provide the is_enabled and load_balancer_name required attributes") } - req := &oscgo.UpdateLoadBalancerRequest{ + req := oscgo.UpdateLoadBalancerRequest{ LoadBalancerName: v1.(string), } @@ -159,7 +159,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta LoadBalancerNames: &[]string{elbName}, } - req := &oscgo.ReadLoadBalancersRequest{ + req := oscgo.ReadLoadBalancersRequest{ Filters: filter, } @@ -226,7 +226,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - req := &oscgo.UpdateLoadBalancerRequest{} + req := oscgo.UpdateLoadBalancerRequest{} access := &oscgo.AccessLog{} if d.HasChange("load_balancer_name") { _, n := d.GetChange("load_balancer_name") diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_cookiepolicy.go index 989a33840..72ea07c46 100644 --- a/outscale/resource_outscale_load_balancer_cookiepolicy.go +++ b/outscale/resource_outscale_load_balancer_cookiepolicy.go @@ -65,7 +65,7 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met } vs := v.(string) - req := &oscgo.CreateLoadBalancerPolicyRequest{ + req := oscgo.CreateLoadBalancerPolicyRequest{ LoadBalancerName: l.(string), PolicyName: p.(string), CookieName: &vs, @@ -121,7 +121,7 @@ func resourceOutscaleAppCookieStickinessPolicyDelete(d *schema.ResourceData, met l := d.Get("load_balancer_name").(string) p := d.Get("policy_name").(string) - request := &oscgo.DeleteLoadBalancerPolicyRequest{ + request := oscgo.DeleteLoadBalancerPolicyRequest{ LoadBalancerName: l, PolicyName: p, } diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index 7ade67e62..d43613ac1 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -171,7 +171,7 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met LoadBalancerNames: &[]string{elbName}, } - req := &oscgo.ReadLoadBalancersRequest{ + req := oscgo.ReadLoadBalancersRequest{ Filters: filter, } diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 80cd0220e..01a779625 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -75,10 +75,10 @@ func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { for _, lRaw := range configured { data := lRaw.(map[string]interface{}) - ip := int64(data["instance_port"].(int)) + ip := int64(data["backend_port"].(int)) lp := int64(data["load_balancer_port"].(int)) - bproto := data["instance_protocol"].(string) - lproto := data["protocol"].(string) + bproto := data["backend_protocol"].(string) + lproto := data["load_balancer_protocol"].(string) l := &oscgo.Listener{ BackendPort: &ip, BackendProtocol: &bproto, @@ -120,10 +120,10 @@ func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCre for _, lRaw := range configured { data := lRaw.(map[string]interface{}) - ip := int64(data["instance_port"].(int)) + ip := int64(data["backend_port"].(int)) lp := int64(data["load_balancer_port"].(int)) - bproto := data["instance_protocol"].(string) - lproto := data["protocol"].(string) + bproto := data["backend_protocol"].(string) + lproto := data["load_balancer_protocol"].(string) l := oscgo.ListenerForCreation{ BackendPort: ip, BackendProtocol: &bproto, @@ -256,7 +256,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met ports = append(ports, *listener.LoadBalancerPort) } - req := &oscgo.DeleteLoadBalancerListenersRequest{ + req := oscgo.DeleteLoadBalancerListenersRequest{ LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } @@ -285,7 +285,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met } if len(add) > 0 { - req := &oscgo.CreateLoadBalancerListenersRequest{ + req := oscgo.CreateLoadBalancerListenersRequest{ LoadBalancerName: d.Id(), Listeners: add, } @@ -339,7 +339,7 @@ func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, met ports = append(ports, *listener.LoadBalancerPort) } - req := &oscgo.DeleteLoadBalancerListenersRequest{ + req := oscgo.DeleteLoadBalancerListenersRequest{ LoadBalancerName: d.Id(), LoadBalancerPorts: ports, } diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index fea51addc..c33319c64 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -115,7 +115,7 @@ func resourceOutscaleOAPILoadBalancerPolicyRead(d *schema.ResourceData, meta int func resourceOutscaleOAPILoadBalancerPolicyDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - pInput := &oscgo.UpdateLoadBalancerRequest{} + pInput := oscgo.UpdateLoadBalancerRequest{} pols := make([]string, 0) pInput.PolicyNames = &pols diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index f2fdbe823..551ba933a 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -36,9 +36,9 @@ func TestAccOutscaleOAPILBUBasic(t *testing.T) { testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), testAccCheckOutscaleOAPILBUAttributes(&conf), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "sub_region_name.#", "1"), + "outscale_load_balancer.bar", "subregion_name.#", "1"), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "sub_region_name.0", "eu-west-2a"), + "outscale_load_balancer.bar", "subregion_name.0", "eu-west-2a"), resource.TestCheckResourceAttr( "outscale_load_balancer.bar", "listener.0.backend_port", "8000"), resource.TestCheckResourceAttr( @@ -116,7 +116,7 @@ func testAccCheckOutscaleOAPILBUAttributes(conf *oscgo.LoadBalancer) resource.Te } sort.StringSlice(azs).Sort() if !reflect.DeepEqual(azs, zones) { - return fmt.Errorf("bad sub_region_name") + return fmt.Errorf("bad subregion_name") } if *conf.DnsName == "" { @@ -136,7 +136,7 @@ func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *oscgo.LoadBalancer) } sort.StringSlice(azs).Sort() if !reflect.DeepEqual(azs, zones) { - return fmt.Errorf("bad sub_region_name") + return fmt.Errorf("bad subregion_name") } if *conf.DnsName == "" { @@ -213,7 +213,7 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resour func testAccOutscaleOAPILBUConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%d" listeners { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 5e3497c2a..8822ca37d 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -104,7 +104,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac LoadBalancerNames: &[]string{e}, } - req := &oscgo.ReadLoadBalancersRequest{ + req := oscgo.ReadLoadBalancersRequest{ Filters: filter, } From a483b6e2da29d14ec9f4fb1d39a3ff7598eaf294 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Tue, 14 Apr 2020 15:02:26 +0200 Subject: [PATCH 037/218] LBU: listener -> listeners Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 106 ++++++------------ ...source_outscale_load_balancer_listeners.go | 16 +-- 2 files changed, 43 insertions(+), 79 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 0ce0622ef..e7ed9ce38 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -32,37 +32,6 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "listener": { - Type: schema.TypeList, - Required: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Required: true, - }, - - "backend_protocol": { - Type: schema.TypeString, - Required: true, - }, - - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - }, - - "load_balancer_protocol": { - Type: schema.TypeString, - Required: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Optional: true, - }, - }, - }, - }, "load_balancer_name": { Type: schema.TypeString, Required: true, @@ -135,36 +104,28 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, "listeners": { Type: schema.TypeList, - Computed: true, + Required: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "listener": { - Type: schema.TypeMap, + "backend_port": { + Type: schema.TypeInt, + Required: true, + }, + "backend_protocol": { + Type: schema.TypeString, + Required: true, + }, + "load_balancer_port": { + Type: schema.TypeInt, + Required: true, + }, + "load_balancer_protocol": { + Type: schema.TypeString, + Required: true, + }, + "server_certificate_id": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Computed: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Computed: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, "policy_name": { Type: schema.TypeList, @@ -248,7 +209,7 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req := &oscgo.CreateLoadBalancerRequest{} - listeners, err := expandListenerForCreation(d.Get("listener").([]interface{})) + listeners, err := expandListenerForCreation(d.Get("listeners").([]interface{})) if err != nil { return err } @@ -393,6 +354,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface } if lb.Listeners != nil { if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { + log.Printf("[DEBUG] out err %v", err) return err } } else { @@ -400,6 +362,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } + log.Printf("[DEBUG] out-") d.Set("load_balancer_name", lb.LoadBalancerName) policies := make(map[string]interface{}) @@ -446,6 +409,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("vpc_id", lb.NetId) d.Set("request_id", resp.ResponseContext.RequestId) + log.Printf("[DEBUG] out- out out") return nil } @@ -469,8 +433,8 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return fmt.Errorf("subnet_id update is not supported") } - if d.HasChange("listener") { - o, n := d.GetChange("listener") + if d.HasChange("listeners") { + o, n := d.GetChange("listeners") os := o.([]interface{}) ns := n.([]interface{}) @@ -553,7 +517,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } } - d.SetPartial("listener") + d.SetPartial("listeners") } if d.HasChange("backend_vm_id") { @@ -731,22 +695,22 @@ func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { result := make([]map[string]interface{}, 0, len(*list)) for _, i := range *list { - l := make(map[string]interface{}) + log.Printf("[DEBUG] i: %v", i) listener := map[string]interface{}{ - "backend_port": strconv.Itoa(int(*i.BackendPort)), - "backend_protocol": strings.ToLower(*i.BackendProtocol), - "load_balancer_port": strconv.Itoa(int(*i.LoadBalancerPort)), - "load_balancer_protocol": strings.ToLower(*i.LoadBalancerProtocol), + "backend_port": int(*i.BackendPort), + "backend_protocol": *i.BackendProtocol, + "load_balancer_port": int(*i.LoadBalancerPort), + "load_balancer_protocol": *i.LoadBalancerProtocol, } if i.ServerCertificateId != nil { listener["server_certificate_id"] = *i.ServerCertificateId } - l["listener"] = listener - l["policy_name"] = flattenStringList(i.PolicyNames) - log.Printf("[DEBUG] before append: %v", l) - result = append(result, l) + listener["policy_name"] = flattenStringList(i.PolicyNames) + log.Printf("[DEBUG] before append: %v", listener) + result = append(result, listener) } + log.Printf("[DEBUG] out %v", result) return result } diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 01a779625..4a476da8a 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -24,7 +24,7 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "listener": { + "listeners": { Type: schema.TypeList, Required: true, ForceNew: true, @@ -164,7 +164,7 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met req := oscgo.CreateLoadBalancerListenersRequest{} - listener, err := expandListenerForCreation(d.Get("listener").([]interface{})) + listener, err := expandListenerForCreation(d.Get("listeners").([]interface{})) if err != nil { return err } @@ -211,7 +211,7 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met } func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta interface{}) error { - listener, err := expandListeners(d.Get("listener").([]interface{})) + listener, err := expandListeners(d.Get("listeners").([]interface{})) if err != nil { return err } @@ -227,7 +227,7 @@ func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta } result = append(result, listener) } - if err := d.Set("listener", result); err != nil { + if err := d.Set("listeners", result); err != nil { return err } d.Set("load_balancer_name", d.Id()) @@ -242,8 +242,8 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met d.Partial(true) - if d.HasChange("listener") { - o, n := d.GetChange("listener") + if d.HasChange("listeners") { + o, n := d.GetChange("listeners") os := o.([]interface{}) ns := n.([]interface{}) @@ -321,7 +321,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met } } - d.SetPartial("listener") + d.SetPartial("listeners") } d.Partial(false) @@ -332,7 +332,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - remove, _ := expandListeners(d.Get("listener").([]interface{})) + remove, _ := expandListeners(d.Get("listeners").([]interface{})) ports := make([]int64, 0, len(remove)) for _, listener := range remove { From c95e18e0235756794de1ca71d19f8444984d3745 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Tue, 14 Apr 2020 18:57:32 +0200 Subject: [PATCH 038/218] big renaming et tags bug less Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 64 +++++++++---------- ...source_outscale_load_balancer_listeners.go | 17 ++--- 2 files changed, 39 insertions(+), 42 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index e7ed9ce38..2963fc139 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -26,7 +26,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "subregion_name": { + "subregion_names": { Type: schema.TypeList, Optional: true, Computed: true, @@ -43,19 +43,19 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Computed: true, ForceNew: true, }, - "firewall_rules_set_name": { + "security_groups": { Type: schema.TypeList, Optional: true, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "subnet_id": { + "subnets": { Type: schema.TypeList, Optional: true, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "tag": tagsSchema(), + "tags": tagsListOAPISchema(), "public_dns_name": { Type: schema.TypeString, @@ -103,7 +103,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, "listeners": { - Type: schema.TypeList, + Type: schema.TypeSet, Required: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -135,16 +135,16 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "source_firewall_rules_set": { + "source_security_group": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": { + "security_group_name": { Type: schema.TypeString, Computed: true, }, - "account_alias": { + "security_group_account_id": { Type: schema.TypeString, Computed: true, }, @@ -209,7 +209,7 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req := &oscgo.CreateLoadBalancerRequest{} - listeners, err := expandListenerForCreation(d.Get("listeners").([]interface{})) + listeners, err := expandListenerForCreation(d.Get("listeners").(*schema.Set).List()) if err != nil { return err } @@ -220,8 +220,9 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req.LoadBalancerName = v.(string) } - if v, ok := d.GetOk("tag"); ok { - req.Tags = tagsFromMapLBU(v.(map[string]interface{})) + if v, ok := d.GetOk("tags"); ok { + r := tagsFromSliceMap(v.([]interface{})) + req.Tags = &r } if v, ok := d.GetOk("load_balancer_type"); ok { @@ -229,15 +230,15 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req.LoadBalancerType = &s } - if v, ok := d.GetOk("subregion_name"); ok { + if v, ok := d.GetOk("subregion_names"); ok { req.SubregionNames = expandStringList(v.([]interface{})) } - if v, ok := d.GetOk("firewall_rules_set_name"); ok { + if v, ok := d.GetOk("security_groups"); ok { req.SecurityGroups = expandStringList(v.([]interface{})) } - if v, ok := d.GetOk("subnet_id"); ok { + if v, ok := d.GetOk("subnets"); ok { req.Subnets = expandStringList(v.([]interface{})) } @@ -343,7 +344,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface lb := (*resp.LoadBalancers)[0] - d.Set("subregion_name", flattenStringList(lb.SubregionNames)) + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) @@ -362,7 +363,6 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } - log.Printf("[DEBUG] out-") d.Set("load_balancer_name", lb.LoadBalancerName) policies := make(map[string]interface{}) @@ -395,21 +395,20 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("policies", policies) d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { - d.Set("firewall_rules_set_name", flattenStringList(lb.SecurityGroups)) + d.Set("security_groups", flattenStringList(lb.SecurityGroups)) } else { - d.Set("firewall_rules_set_name", make([]map[string]interface{}, 0)) + d.Set("security_groups", make([]map[string]interface{}, 0)) } ssg := make(map[string]string) if lb.SourceSecurityGroup != nil { - ssg["firewall_rules_set_name"] = *lb.SourceSecurityGroup.SecurityGroupName - ssg["account_alias"] = *lb.SourceSecurityGroup.SecurityGroupAccountId + ssg["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName + ssg["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId } - d.Set("source_firewall_rules_set", ssg) - d.Set("subnet_id", flattenStringList(lb.Subnets)) + d.Set("source_security_group", ssg) + d.Set("subnets", flattenStringList(lb.Subnets)) d.Set("vpc_id", lb.NetId) d.Set("request_id", resp.ResponseContext.RequestId) - log.Printf("[DEBUG] out- out out") return nil } @@ -421,25 +420,25 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa // if anye of thoses V are true, ake a // resourceOutscaleOAPILoadBalancerDelete(d, meta) // resourceOutscaleOAPILoadBalancerCreate(d, meta) - if d.HasChange("firewall_rules_set_name") { - return fmt.Errorf("firewall_rules_set_name update is not supported") + if d.HasChange("security_groups") { + return fmt.Errorf("security group update is not supported") } - if d.HasChange("subregion_name") { + if d.HasChange("subregion_names") { return fmt.Errorf("sub_region_name update is not supported") } - if d.HasChange("subnet_id") { + if d.HasChange("subnets") { return fmt.Errorf("subnet_id update is not supported") } if d.HasChange("listeners") { o, n := d.GetChange("listeners") - os := o.([]interface{}) - ns := n.([]interface{}) + os := o.(*schema.Set).List() + ns := n.(*schema.Set).List() - remove, _ := expandListeners(ns) - add, _ := expandListenerForCreation(os) + remove, _ := expandListeners(os) + add, _ := expandListenerForCreation(ns) if len(remove) > 0 { ports := make([]int64, 0, len(remove)) @@ -695,7 +694,6 @@ func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { result := make([]map[string]interface{}, 0, len(*list)) for _, i := range *list { - log.Printf("[DEBUG] i: %v", i) listener := map[string]interface{}{ "backend_port": int(*i.BackendPort), "backend_protocol": *i.BackendProtocol, @@ -707,10 +705,8 @@ func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { *i.ServerCertificateId } listener["policy_name"] = flattenStringList(i.PolicyNames) - log.Printf("[DEBUG] before append: %v", listener) result = append(result, listener) } - log.Printf("[DEBUG] out %v", result) return result } diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 4a476da8a..ea589cd54 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -25,7 +25,7 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { Schema: map[string]*schema.Schema{ "listeners": { - Type: schema.TypeList, + Type: schema.TypeSet, Required: true, ForceNew: true, Elem: &schema.Resource{ @@ -164,7 +164,7 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met req := oscgo.CreateLoadBalancerListenersRequest{} - listener, err := expandListenerForCreation(d.Get("listeners").([]interface{})) + listener, err := expandListenerForCreation(d.Get("listeners").(*schema.Set).List()) if err != nil { return err } @@ -211,7 +211,7 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met } func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta interface{}) error { - listener, err := expandListeners(d.Get("listeners").([]interface{})) + listener, err := expandListeners(d.Get("listeners").(*schema.Set).List()) if err != nil { return err } @@ -244,11 +244,11 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met if d.HasChange("listeners") { o, n := d.GetChange("listeners") - os := o.([]interface{}) - ns := n.([]interface{}) + os := o.(*schema.Set).List() + ns := n.(*schema.Set).List() - remove, _ := expandListeners(ns) - add, _ := expandListenerForCreation(os) + remove, _ := expandListeners(os) + add, _ := expandListenerForCreation(ns) if len(remove) > 0 { ports := make([]int64, 0, len(remove)) @@ -296,6 +296,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { + log.Printf("[DEBUG] Load Balancer Create Listeners opts: %v", createListenersOpts) _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( context.Background(), createListenersOpts) if err != nil { @@ -332,7 +333,7 @@ func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, met func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - remove, _ := expandListeners(d.Get("listeners").([]interface{})) + remove, _ := expandListeners(d.Get("listeners").(*schema.Set).List()) ports := make([]int64, 0, len(remove)) for _, listener := range remove { From e472c3a885d5a1278a71be66d97578d6ea23f508 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 24 Apr 2020 14:48:07 +0200 Subject: [PATCH 039/218] broken lbu recreation on update, but broken Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 2963fc139..59a2159d3 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -339,7 +339,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface if len(*resp.LoadBalancers) != 1 { return fmt.Errorf("Unable to find Load Balancer: %#v", - resp.LoadBalancers) + elbName) } lb := (*resp.LoadBalancers)[0] @@ -420,16 +420,13 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa // if anye of thoses V are true, ake a // resourceOutscaleOAPILoadBalancerDelete(d, meta) // resourceOutscaleOAPILoadBalancerCreate(d, meta) - if d.HasChange("security_groups") { - return fmt.Errorf("security group update is not supported") - } - - if d.HasChange("subregion_names") { - return fmt.Errorf("sub_region_name update is not supported") - } - - if d.HasChange("subnets") { - return fmt.Errorf("subnet_id update is not supported") + if d.HasChange("security_groups") || d.HasChange("subregion_names") || + d.HasChange("subnets") { + log.Printf("[INFO] update Load Balancer: %s", d.Id()) + //dcp := *d + resourceOutscaleOAPILoadBalancerDelete(d, meta) + resourceOutscaleOAPILoadBalancerCreate(d, meta) + return nil } if d.HasChange("listeners") { From 66cf318513df2e3336af3c116f98139e1106a071 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Fri, 24 Apr 2020 18:05:34 +0200 Subject: [PATCH 040/218] recreate lbu seems to work Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 46 ++++++++++++++------- 1 file changed, 31 insertions(+), 15 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 59a2159d3..c311e09b2 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -30,6 +30,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeList, Optional: true, Computed: true, + ForceNew: true, Elem: &schema.Schema{Type: schema.TypeString}, }, "load_balancer_name": { @@ -52,6 +53,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { "subnets": { Type: schema.TypeList, Optional: true, + ForceNew: true, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, @@ -205,6 +207,10 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { } func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interface{}) error { + return resourceOutscaleOAPILoadBalancerCreate_(d, meta, false) +} + +func resourceOutscaleOAPILoadBalancerCreate_(d *schema.ResourceData, meta interface{}, isUpdate bool) error { conn := meta.(*OutscaleClient).OSCAPI req := &oscgo.CreateLoadBalancerRequest{} @@ -230,16 +236,22 @@ func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interfa req.LoadBalancerType = &s } - if v, ok := d.GetOk("subregion_names"); ok { - req.SubregionNames = expandStringList(v.([]interface{})) - } - if v, ok := d.GetOk("security_groups"); ok { req.SecurityGroups = expandStringList(v.([]interface{})) } - if v, ok := d.GetOk("subnets"); ok { - req.Subnets = expandStringList(v.([]interface{})) + v_sb, sb_ok := d.GetOk("subnets") + if sb_ok { + req.Subnets = expandStringList(v_sb.([]interface{})) + } + + v_srn, srn_ok := d.GetOk("subregion_names") + if isUpdate && sb_ok && srn_ok { + return fmt.Errorf("can't use both 'subregion_names' and 'subnets'") + } + + if srn_ok && sb_ok == false { + req.SubregionNames = expandStringList(v_srn.([]interface{})) } elbOpts := &oscgo.CreateLoadBalancerOpts{ @@ -417,16 +429,15 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa d.Partial(true) - // if anye of thoses V are true, ake a - // resourceOutscaleOAPILoadBalancerDelete(d, meta) - // resourceOutscaleOAPILoadBalancerCreate(d, meta) if d.HasChange("security_groups") || d.HasChange("subregion_names") || d.HasChange("subnets") { log.Printf("[INFO] update Load Balancer: %s", d.Id()) - //dcp := *d - resourceOutscaleOAPILoadBalancerDelete(d, meta) - resourceOutscaleOAPILoadBalancerCreate(d, meta) - return nil + e := resourceOutscaleOAPILoadBalancerDelete_(d, meta, false) + + if e != nil { + return e + } + return resourceOutscaleOAPILoadBalancerCreate_(d, meta, true) } if d.HasChange("listeners") { @@ -632,8 +643,11 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerRead(d, meta) } - func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interface{}) error { + return resourceOutscaleOAPILoadBalancerDelete_(d, meta, true) +} + +func resourceOutscaleOAPILoadBalancerDelete_(d *schema.ResourceData, meta interface{}, needupdate bool) error { conn := meta.(*OutscaleClient).OSCAPI log.Printf("[INFO] Deleting Load Balancer: %s", d.Id()) @@ -664,7 +678,9 @@ func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interfa return fmt.Errorf("Error deleting Load Balancer: %s", err) } - d.SetId("") + if needupdate { + d.SetId("") + } return nil } From 6f32932c01abae45c81b2f18cc6c73e2ea2e48c7 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Tue, 9 Jun 2020 18:25:05 +0200 Subject: [PATCH 041/218] fix parameters Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 11 ++++++++--- ...esource_outscale_load_balancer_health_check.go | 15 ++++++++++++--- 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index c311e09b2..daba54712 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -76,7 +76,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "checked_vm": { + "path": { Type: schema.TypeString, Computed: true, }, @@ -607,10 +607,15 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa HealthyThreshold: int64(check["healthy_threshold"].(int)), UnhealthyThreshold: int64(check["unhealthy_threshold"].(int)), CheckInterval: int64(check["check_interval"].(int)), - Path: check["checked_vm"].(string), + Protocol: check["protocol"].(string), + Port: int64(check["port"].(int)), Timeout: int64(check["timeout"].(int)), }, } + if check["path"] != nil { + req.HealthCheck.Path = check["path"].(string) + } + configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ optional.NewInterface(req), } @@ -729,7 +734,7 @@ func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { if check != nil { chk["unhealthy_threshold"] = strconv.Itoa(int(check.UnhealthyThreshold)) chk["healthy_threshold"] = strconv.Itoa(int(check.HealthyThreshold)) - chk["target"] = check.Path + chk["path"] = check.Path chk["timeout"] = strconv.Itoa(int(check.Timeout)) chk["interval"] = strconv.Itoa(int(check.CheckInterval)) } diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index d43613ac1..069fd6f5e 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -42,7 +42,7 @@ func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { Computed: true, ForceNew: true, }, - "checked_vm": { + "path": { Type: schema.TypeString, Optional: true, Computed: true, @@ -100,6 +100,7 @@ func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, m ut, uterr := strconv.Atoi(check["unhealthy_threshold"].(string)) i, ierr := strconv.Atoi(check["check_interval"].(string)) t, terr := strconv.Atoi(check["timeout"].(string)) + p, perr := strconv.Atoi(check["port"].(string)) if hterr != nil { return fmt.Errorf("please provide an number in health_check.healthy_threshold argument") @@ -117,16 +118,24 @@ func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, m return fmt.Errorf("please provide an number in health_check.timeout argument") } + if perr != nil { + return fmt.Errorf("please provide an number in health_check.port argument") + } + req := oscgo.UpdateLoadBalancerRequest{ LoadBalancerName: ename.(string), HealthCheck: &oscgo.HealthCheck{ HealthyThreshold: int64(ht), UnhealthyThreshold: int64(ut), CheckInterval: int64(i), - Path: check["checked_vm"].(string), + Protocol: check["protocol"].(string), + Port: int64(p), Timeout: int64(t), }, } + if check["path"] != nil { + req.HealthCheck.Path = check["path"].(string) + } configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ optional.NewInterface(req), @@ -231,7 +240,7 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met healthCheck["healthy_threshold"] = h healthCheck["check_interval"] = i - healthCheck["checked_vm"] = t + healthCheck["path"] = t healthCheck["timeout"] = ti healthCheck["unhealthy_threshold"] = u From 5e748f9e78741dafa263096f81692f2b24f340b0 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 15 Jun 2020 15:08:13 +0200 Subject: [PATCH 042/218] backend_vm_id -> backend_vm_ids Signed-off-by: matthias.gatto --- outscale/resource_outscale_load_balancer.go | 31 ++++++------------- .../resource_outscale_load_balancer_vms.go | 23 +++++--------- ...esource_outscale_load_balancer_vms_test.go | 4 +-- 3 files changed, 19 insertions(+), 39 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index daba54712..c47b590bb 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -91,17 +91,12 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "backend_vm_id": { + "backend_vm_ids": { Type: schema.TypeList, Optional: true, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "vm_id": { - Type: schema.TypeString, - Computed: true, - }, - }, + Elem: &schema.Schema{ + Type: schema.TypeString, }, }, "listeners": { @@ -361,9 +356,9 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) if lb.BackendVmIds != nil { - d.Set("backend_vm_id", flattenOAPIInstances(lb.BackendVmIds)) + d.Set("backend_vm_ids", lb.BackendVmIds) } else { - d.Set("backend_vm_id", make([]map[string]interface{}, 0)) + d.Set("backend_vm_ids", make([]interface{}, 0)) } if lb.Listeners != nil { if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { @@ -371,7 +366,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } else { - if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { + if err := d.Set("listeners", make([]interface{}, 0)); err != nil { return err } } @@ -527,8 +522,8 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa d.SetPartial("listeners") } - if d.HasChange("backend_vm_id") { - o, n := d.GetChange("backend_vm_id") + if d.HasChange("backend_vm_ids") { + o, n := d.GetChange("backend_vm_ids") os := o.(*schema.Set) ns := n.(*schema.Set) remove := expandInstanceString(os.Difference(ns).List()) @@ -594,7 +589,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } } - d.SetPartial("backend_vm_id") + d.SetPartial("backend_vm_ids") } if d.HasChange("health_check") { @@ -699,14 +694,6 @@ func expandInstanceString(list []interface{}) []string { return result } -func flattenOAPIInstances(list *[]string) []map[string]string { - result := make([]map[string]string, len(*list)) - for _, s := range *list { - result = append(result, map[string]string{"vm_id": s}) - } - return result -} - // Flattens an array of Listeners into a []map[string]interface{} func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { result := make([]map[string]interface{}, 0, len(*list)) diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 8822ca37d..f5cc3c06e 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -27,18 +27,11 @@ func resourceOutscaleOAPILBUAttachment() *schema.Resource { Required: true, }, - "backend_vm_id": { + "backend_vm_ids": { Type: schema.TypeList, ForceNew: true, Required: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "vm_id": { - Type: schema.TypeString, - Required: true, - }, - }, - }, + Elem: &schema.Schema{Type: schema.TypeString}, }, }, } @@ -48,7 +41,7 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf conn := meta.(*OutscaleClient).OSCAPI e, eok := d.GetOk("load_balancer_name") - i, iok := d.GetOk("backend_vm_id") + i, iok := d.GetOk("backend_vm_ids") if !eok && !iok { return fmt.Errorf("please provide the required attributes load_balancer_name and backend_vm_id") @@ -86,7 +79,7 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf }) if err != nil { - return fmt.Errorf("Failure registering backend_vm_id with LBU: %s", err) + return fmt.Errorf("Failure registering backend_vm_ids with LBU: %s", err) } d.SetId(resource.PrefixedUniqueId(fmt.Sprintf("%s-", e))) @@ -98,7 +91,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac conn := meta.(*OutscaleClient).OSCAPI e := d.Get("load_balancer_name").(string) - expected := d.Get("backend_vm_id").([]interface{}) + expected := d.Get("backend_vm_ids").([]interface{}) filter := &oscgo.FiltersLoadBalancer{ LoadBalancerNames: &[]string{e}, @@ -152,7 +145,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac for k1 := range expected { sid := expected[k1].(string) if sid == v { - d.Set("backend_vm_id", expected) + d.Set("backend_vm_ids", expected) found = true } } @@ -169,7 +162,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI e := d.Get("load_balancer_name").(string) - i := d.Get("backend_vm_id").([]interface{}) + i := d.Get("backend_vm_ids").([]interface{}) lb := make([]string, len(i)) @@ -202,7 +195,7 @@ func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interf }) if err != nil { - return fmt.Errorf("Failure deregistering backend_vm_id from LBU: %s", err) + return fmt.Errorf("Failure deregistering backend_vm_ids from LBU: %s", err) } return nil diff --git a/outscale/resource_outscale_load_balancer_vms_test.go b/outscale/resource_outscale_load_balancer_vms_test.go index 8b744d51c..31b6cc462 100644 --- a/outscale/resource_outscale_load_balancer_vms_test.go +++ b/outscale/resource_outscale_load_balancer_vms_test.go @@ -16,7 +16,7 @@ func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { testCheckInstanceAttached := func(count int) resource.TestCheckFunc { return func(*terraform.State) error { if len(*conf.BackendVmIds) != count { - return fmt.Errorf("backend_vm_id count does not match") + return fmt.Errorf("backend_vm_ids count does not match") } return nil } @@ -60,6 +60,6 @@ resource "outscale_vm" "foo1" { resource "outscale_load_balancer_vms" "foo1" { load_balancer_name = "${outscale_load_balancer.bar.id}" - backend_vm_id = ["${outscale_vm.foo1.id}"] + backend_vm_ids = ["${outscale_vm.foo1.id}"] } ` From 7d62d58efc28db5a98d2293f58bed22c960fa3b3 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Wed, 17 Jun 2020 13:13:55 +0200 Subject: [PATCH 043/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_access_logs" This reverts commit 7a19b622e202b99875a2a85c300d31fb6a232b35. --- ...urce_outscale_load_balancer_access_logs.go | 105 ++++++++++++++++++ ...outscale_load_balancer_access_logs_test.go | 83 ++++++++++++++ 2 files changed, 188 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_access_logs.go create mode 100644 outscale/data_source_outscale_load_balancer_access_logs_test.go diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go new file mode 100644 index 000000000..241a037c1 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_access_logs.go @@ -0,0 +1,105 @@ +package outscale + +import ( + "fmt" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/terraform-providers/terraform-provider-outscale/utils" +) + +func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleLoadBalancerAccessLogsRead, + + Schema: map[string]*schema.Schema{ + "emit_interval": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "enabled": &schema.Schema{ + Type: schema.TypeBool, + Computed: true, + }, + "s3_bucket_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "s3_bucket_prefix": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + elbName, ok1 := d.GetOk("load_balancer_name") + + if !ok1 { + return fmt.Errorf("please provide the load_balancer_name required attribute") + } + + describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ + LoadBalancerName: aws.String(elbName.(string)), + } + + var resp *lbu.DescribeLoadBalancerAttributesOutput + var describeResp *lbu.DescribeLoadBalancerAttributesResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancerAttributesResult != nil { + describeResp = resp.DescribeLoadBalancerAttributesResult + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving LBU Attr: %s", err) + } + + if describeResp.LoadBalancerAttributes == nil { + return fmt.Errorf("NO Attributes FOUND") + } + + utils.PrintToJSON(describeResp, "RESPONSE =>") + + a := describeResp.LoadBalancerAttributes.AccessLog + + d.Set("emit_interval", aws.Int64Value(a.EmitInterval)) + d.Set("enabled", aws.BoolValue(a.Enabled)) + d.Set("s3_bucket_name", aws.StringValue(a.S3BucketName)) + d.Set("s3_bucket_prefix", aws.StringValue(a.S3BucketPrefix)) + + d.SetId(elbName.(string)) + d.Set("request_id", resp.ResponseMetadata.RequestID) + + return nil +} diff --git a/outscale/data_source_outscale_load_balancer_access_logs_test.go b/outscale/data_source_outscale_load_balancer_access_logs_test.go new file mode 100644 index 000000000..255080366 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_access_logs_test.go @@ -0,0 +1,83 @@ +package outscale + +import ( + "fmt" + "os" + "strconv" + "testing" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" +) + +func TestAccOutscaleLoadBalancerAccessLogs_basic(t *testing.T) { + t.Skip() + + o := os.Getenv("OUTSCALE_OAPI") + + oapi, err := strconv.ParseBool(o) + if err != nil { + oapi = false + } + + if oapi { + t.Skip() + } + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleLBUDSAccessLogsConfig, + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleLBUDSAccessLogsExists("data.outscale_load_balancer_access_logs.test"), + resource.TestCheckResourceAttr( + "data.outscale_load_balancer_access_logs.test", "enabled", "false"), + )}, + }, + }) +} + +func testAccCheckOutscaleLBUDSAccessLogsExists(n string) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[n] + if !ok { + return fmt.Errorf("Not found: %s", n) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No LBU Attr ID is set") + } + + return nil + } +} + +const testAccDSOutscaleLBUDSAccessLogsConfig = ` +resource "outscale_load_balancer" "bar" { + availability_zones = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-ds" + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } + + tag { + bar = "baz" + } + +} + +resource "outscale_load_balancer_attributes" "bar2" { + enabled = "false" + s3_bucket_name = "donustestbucket" + load_balancer_name = "${outscale_load_balancer.bar.id}" +} + +data "outscale_load_balancer_access_logs" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" +} +` From 6577f405246f6b1eccb9ca70a23345e2201ce07c Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Wed, 17 Jun 2020 16:12:11 +0200 Subject: [PATCH 044/218] data_source_outscale_load_balancer_access_logs.go Signed-off-by: matthias.gatto --- ...urce_outscale_load_balancer_access_logs.go | 70 +++++++++++-------- ...outscale_load_balancer_access_logs_test.go | 13 ++-- 2 files changed, 48 insertions(+), 35 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go index 241a037c1..e87496a54 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs.go +++ b/outscale/data_source_outscale_load_balancer_access_logs.go @@ -1,15 +1,16 @@ package outscale import ( + "context" "fmt" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" - "github.com/terraform-providers/terraform-provider-outscale/utils" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { @@ -17,28 +18,28 @@ func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { Read: dataSourceOutscaleLoadBalancerAccessLogsRead, Schema: map[string]*schema.Schema{ - "emit_interval": &schema.Schema{ + "emit_interval": { Type: schema.TypeInt, Computed: true, }, - "enabled": &schema.Schema{ + "enabled": { Type: schema.TypeBool, Computed: true, }, - "s3_bucket_name": &schema.Schema{ + "s3_bucket_name": { Type: schema.TypeString, Computed: true, }, - "s3_bucket_prefix": &schema.Schema{ + "s3_bucket_prefix": { Type: schema.TypeString, Computed: true, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -47,22 +48,31 @@ func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { } func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI elbName, ok1 := d.GetOk("load_balancer_name") if !ok1 { return fmt.Errorf("please provide the load_balancer_name required attribute") } - describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ - LoadBalancerName: aws.String(elbName.(string)), + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName.(string)}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancerAttributesOutput - var describeResp *lbu.DescribeLoadBalancerAttributesResult + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { @@ -70,9 +80,6 @@ func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta i } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancerAttributesResult != nil { - describeResp = resp.DescribeLoadBalancerAttributesResult - } return nil }) @@ -85,21 +92,28 @@ func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta i return fmt.Errorf("Error retrieving LBU Attr: %s", err) } - if describeResp.LoadBalancerAttributes == nil { + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName.(string)) + } + + lb := (lbs)[0] + + if lb.AccessLog == nil { return fmt.Errorf("NO Attributes FOUND") } - utils.PrintToJSON(describeResp, "RESPONSE =>") + //utils.PrintToJSON(resp, "RESPONSE =>") - a := describeResp.LoadBalancerAttributes.AccessLog + a := lb.AccessLog - d.Set("emit_interval", aws.Int64Value(a.EmitInterval)) - d.Set("enabled", aws.BoolValue(a.Enabled)) - d.Set("s3_bucket_name", aws.StringValue(a.S3BucketName)) - d.Set("s3_bucket_prefix", aws.StringValue(a.S3BucketPrefix)) + d.Set("publication_interval", a.PublicationInterval) + d.Set("is_enabled", a.IsEnabled) + d.Set("osu_bucket_name", a.OsuBucketName) + d.Set("osu_bucket_prefix", a.OsuBucketPrefix) d.SetId(elbName.(string)) - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) return nil } diff --git a/outscale/data_source_outscale_load_balancer_access_logs_test.go b/outscale/data_source_outscale_load_balancer_access_logs_test.go index 255080366..3fb9a4ee8 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs_test.go +++ b/outscale/data_source_outscale_load_balancer_access_logs_test.go @@ -6,8 +6,7 @@ import ( "strconv" "testing" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleLoadBalancerAccessLogs_basic(t *testing.T) { @@ -59,10 +58,10 @@ resource "outscale_load_balancer" "bar" { availability_zones = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-ds" listeners { - instance_port = 8000 - instance_protocol = "HTTP" + backend_port = 8000 + backend_protocol = "HTTP" load_balancer_port = 80 - protocol = "HTTP" + load_balancer_protocol = "HTTP" } tag { @@ -72,8 +71,8 @@ resource "outscale_load_balancer" "bar" { } resource "outscale_load_balancer_attributes" "bar2" { - enabled = "false" - s3_bucket_name = "donustestbucket" + is_enabled = "false" + osu_bucket_name = "donustestbucket" load_balancer_name = "${outscale_load_balancer.bar.id}" } From 4c6c996d1aec7ac1dab44eff7dfe93b655d77bbb Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Wed, 17 Jun 2020 17:03:05 +0200 Subject: [PATCH 045/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_attributes" This reverts commit 386ad919c55a40892ea4bd50d3e975ca51df108c. --- ...ource_outscale_load_balancer_attributes.go | 125 ++++++++++++++++++ ..._outscale_load_balancer_attributes_test.go | 63 +++++++++ 2 files changed, 188 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_attributes.go create mode 100644 outscale/data_source_outscale_load_balancer_attributes_test.go diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go new file mode 100644 index 000000000..67f67ba8a --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_attributes.go @@ -0,0 +1,125 @@ +package outscale + +import ( + "fmt" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerAttrRead, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "load_balancer_attributes": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "access_log": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "publication_interval": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "is_enabled": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + }, + }, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + ename, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + elbName := ename.(string) + + describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ + LoadBalancerName: aws.String(elbName), + } + + var describeResp *lbu.DescribeLoadBalancerAttributesResult + var resp *lbu.DescribeLoadBalancerAttributesOutput + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancerAttributesResult != nil { + describeResp = resp.DescribeLoadBalancerAttributesResult + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + if describeResp.LoadBalancerAttributes == nil { + return fmt.Errorf("NO ELB FOUND") + } + + a := describeResp.LoadBalancerAttributes.AccessLog + + ld := make([]map[string]interface{}, 1) + acc := make(map[string]interface{}) + + acc["publication_interval"] = strconv.Itoa(int(aws.Int64Value(a.EmitInterval))) + acc["is_enabled"] = strconv.FormatBool(aws.BoolValue(a.Enabled)) + acc["osu_bucket_name"] = aws.StringValue(a.S3BucketName) + acc["osu_bucket_prefix"] = aws.StringValue(a.S3BucketPrefix) + + ld[0] = map[string]interface{}{"access_log": acc} + + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(resource.UniqueId()) + + return d.Set("load_balancer_attributes", ld) +} diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go new file mode 100644 index 000000000..fcc1959a0 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_attributes_test.go @@ -0,0 +1,63 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPIDSLBUAttr_basic(t *testing.T) { + t.Skip() + + r := acctest.RandIntRange(0, 10) + + var conf lbu.LoadBalancerDescription + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleOAPILBUAttrConfig(r), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + resource.TestCheckResourceAttr("data.outscale_load_balancer_attributes.test", "load_balancer_attributes.0.access_log.is_enabled", "false"), + )}, + }, + }) +} + +func testAccDSOutscaleOAPILBUAttrConfig(r int) string { + return fmt.Sprintf(` + resource "outscale_load_balancer" "bar" { + sub_regions = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" + + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + resource "outscale_load_balancer_attributes" "bar2" { + is_enabled = "false" + osu_bucket_name = "donustestbucket" + load_balancer_name = "${outscale_load_balancer.bar.id}" + } + + data "outscale_load_balancer_attributes" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + } + `, r) +} From abf42f7d2560334602100077574caedb7f6ae73d Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 14:40:30 +0200 Subject: [PATCH 046/218] data_source_outscale_load_balancer_attributes.go Signed-off-by: matthias.gatto --- ...urce_outscale_load_balancer_access_logs.go | 8 +-- ...ource_outscale_load_balancer_attributes.go | 54 +++++++++++-------- 2 files changed, 36 insertions(+), 26 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go index e87496a54..357d17f4a 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs.go +++ b/outscale/data_source_outscale_load_balancer_access_logs.go @@ -18,19 +18,19 @@ func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { Read: dataSourceOutscaleLoadBalancerAccessLogsRead, Schema: map[string]*schema.Schema{ - "emit_interval": { + "publication_interval": { Type: schema.TypeInt, Computed: true, }, - "enabled": { + "is_enabled": { Type: schema.TypeBool, Computed: true, }, - "s3_bucket_name": { + "osu_bucket_name": { Type: schema.TypeString, Computed: true, }, - "s3_bucket_prefix": { + "osu_bucket_prefix": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go index 67f67ba8a..295b7cf80 100644 --- a/outscale/data_source_outscale_load_balancer_attributes.go +++ b/outscale/data_source_outscale_load_balancer_attributes.go @@ -1,15 +1,16 @@ package outscale import ( + "context" "fmt" - "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { @@ -62,7 +63,7 @@ func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -71,15 +72,24 @@ func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta int elbName := ename.(string) - describeElbOpts := &lbu.DescribeLoadBalancerAttributesInput{ - LoadBalancerName: aws.String(elbName), + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, } - var describeResp *lbu.DescribeLoadBalancerAttributesResult - var resp *lbu.DescribeLoadBalancerAttributesOutput + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancerAttributes(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { @@ -87,9 +97,6 @@ func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta int } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancerAttributesResult != nil { - describeResp = resp.DescribeLoadBalancerAttributesResult - } return nil }) @@ -102,23 +109,26 @@ func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta int return fmt.Errorf("Error retrieving ELB: %s", err) } - if describeResp.LoadBalancerAttributes == nil { - return fmt.Errorf("NO ELB FOUND") + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) } - a := describeResp.LoadBalancerAttributes.AccessLog + lb := (lbs)[0] + + a := lb.AccessLog ld := make([]map[string]interface{}, 1) acc := make(map[string]interface{}) - acc["publication_interval"] = strconv.Itoa(int(aws.Int64Value(a.EmitInterval))) - acc["is_enabled"] = strconv.FormatBool(aws.BoolValue(a.Enabled)) - acc["osu_bucket_name"] = aws.StringValue(a.S3BucketName) - acc["osu_bucket_prefix"] = aws.StringValue(a.S3BucketPrefix) + acc["publication_interval"] = a.PublicationInterval + acc["is_enabled"] = a.IsEnabled + acc["osu_bucket_name"] = a.OsuBucketName + acc["osu_bucket_prefix"] = a.OsuBucketPrefix ld[0] = map[string]interface{}{"access_log": acc} - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) return d.Set("load_balancer_attributes", ld) From 555ab2104861c974cedb2033f3a947d06f583ba3 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 14:41:45 +0200 Subject: [PATCH 047/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_health_check" This reverts commit 6f792483f231394b2eac3cdbb94a55906e6e353c. --- ...rce_outscale_load_balancer_health_check.go | 125 ++++++++++++++++++ ...utscale_load_balancer_health_check_test.go | 61 +++++++++ 2 files changed, 186 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_health_check.go create mode 100644 outscale/data_source_outscale_load_balancer_health_check_test.go diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go new file mode 100644 index 000000000..6386602f5 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -0,0 +1,125 @@ +package outscale + +import ( + "fmt" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerHealthCheckRead, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "healthy_threshold": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "unhealthy_threshold": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "checked_vm": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "check_interval": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "timeout": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + ename, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + elbName := ename.(string) + + // Retrieve the ELB properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(elbName)}, + } + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + if resp.DescribeLoadBalancersResult != nil { + describeResp = resp.DescribeLoadBalancersResult + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO ELB FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + } + + lb := describeResp.LoadBalancerDescriptions[0] + + h := int64(0) + i := int64(0) + t := "" + ti := int64(0) + u := int64(0) + + if *lb.HealthCheck.Target != "" { + h = aws.Int64Value(lb.HealthCheck.HealthyThreshold) + i = aws.Int64Value(lb.HealthCheck.Interval) + t = aws.StringValue(lb.HealthCheck.Target) + ti = aws.Int64Value(lb.HealthCheck.Timeout) + u = aws.Int64Value(lb.HealthCheck.UnhealthyThreshold) + } + + d.Set("healthy_threshold", h) + d.Set("check_interval", i) + d.Set("checked_vm", t) + d.Set("timeout", ti) + d.Set("unhealthy_threshold", u) + + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(*lb.LoadBalancerName) + + return nil +} diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go new file mode 100644 index 000000000..7bf092224 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_health_check_test.go @@ -0,0 +1,61 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerDescription + rs := acctest.RandString(5) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: getTestAccDSOutscaleOAPILBUHConfig(rs), + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + resource.TestCheckResourceAttrSet( + "data.outscale_load_balancer_health_check.test", "healthy_threshold"), + resource.TestCheckResourceAttrSet( + "data.outscale_load_balancer_health_check.test", "check_interval"), + )}, + }, + }) +} +func getTestAccDSOutscaleOAPILBUHConfig(r string) string { + return fmt.Sprintf(` + resource "outscale_load_balancer" "bar" { + sub_regions = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%s" + + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + data "outscale_load_balancer_health_check" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + } + `, r) +} From 03e36805f5dfab9c8d98c933b5e5063048f2e614 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 15:23:27 +0200 Subject: [PATCH 048/218] data_source_outscale_load_balancer_health_check.go Signed-off-by: matthias.gatto --- ...rce_outscale_load_balancer_health_check.go | 68 +++++++++++-------- 1 file changed, 39 insertions(+), 29 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go index 6386602f5..72681c4fc 100644 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -1,14 +1,16 @@ package outscale import ( + "context" "fmt" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { @@ -28,7 +30,7 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { Type: schema.TypeInt, Computed: true, }, - "checked_vm": &schema.Schema{ + "path": &schema.Schema{ Type: schema.TypeString, Computed: true, }, @@ -49,7 +51,7 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -58,24 +60,31 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, m elbName := ename.(string) - // Retrieve the ELB properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(elbName)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - if resp.DescribeLoadBalancersResult != nil { - describeResp = resp.DescribeLoadBalancersResult - } return nil }) @@ -88,15 +97,16 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, m return fmt.Errorf("Error retrieving ELB: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { - return fmt.Errorf("NO ELB FOUND") + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) } - if len(describeResp.LoadBalancerDescriptions) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) - } + lb := (lbs)[0] - lb := describeResp.LoadBalancerDescriptions[0] + if lb.AccessLog == nil { + return fmt.Errorf("NO Attributes FOUND") + } h := int64(0) i := int64(0) @@ -104,21 +114,21 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, m ti := int64(0) u := int64(0) - if *lb.HealthCheck.Target != "" { - h = aws.Int64Value(lb.HealthCheck.HealthyThreshold) - i = aws.Int64Value(lb.HealthCheck.Interval) - t = aws.StringValue(lb.HealthCheck.Target) - ti = aws.Int64Value(lb.HealthCheck.Timeout) - u = aws.Int64Value(lb.HealthCheck.UnhealthyThreshold) + if lb.HealthCheck.Path != "" { + h = lb.HealthCheck.HealthyThreshold + i = lb.HealthCheck.CheckInterval + t = lb.HealthCheck.Path + ti = lb.HealthCheck.Timeout + u = lb.HealthCheck.UnhealthyThreshold } d.Set("healthy_threshold", h) d.Set("check_interval", i) - d.Set("checked_vm", t) + d.Set("path", t) d.Set("timeout", ti) d.Set("unhealthy_threshold", u) - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(*lb.LoadBalancerName) return nil From d5148706f5f966c8b6b3732cba9ef05f87db9cb1 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 15:26:51 +0200 Subject: [PATCH 049/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_listener_description" This reverts commit 867c943dec844b5569a6b4502611df53594c8ed8. --- ...cale_load_balancer_listener_description.go | 130 ++++++++++++++++++ ...load_balancer_listener_description_test.go | 54 ++++++++ 2 files changed, 184 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_listener_description.go create mode 100644 outscale/data_source_outscale_load_balancer_listener_description_test.go diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go new file mode 100644 index 000000000..fe507eadd --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -0,0 +1,130 @@ +package outscale + +import ( + "fmt" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerLDRead, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "listener": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + ename, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + elbName := ename.(string) + + // Retrieve the ELB properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(elbName)}, + } + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + describeResp = resp.DescribeLoadBalancersResult + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO ELB FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + } + + lb := describeResp.LoadBalancerDescriptions[0] + + v := lb.ListenerDescriptions[0] + + l := make(map[string]interface{}) + l["backend_port"] = strconv.Itoa(int(aws.Int64Value(v.Listener.InstancePort))) + l["backend_protocol"] = aws.StringValue(v.Listener.InstanceProtocol) + l["load_balancer_port"] = strconv.Itoa(int(aws.Int64Value(v.Listener.LoadBalancerPort))) + l["load_balancer_protocol"] = aws.StringValue(v.Listener.Protocol) + l["server_certificate_id"] = aws.StringValue(v.Listener.SSLCertificateId) + + if err := d.Set("listener", l); err != nil { + return err + } + + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(resource.UniqueId()) + + return d.Set("policy_name", flattenStringList(lb.ListenerDescriptions[0].PolicyNames)) +} diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go new file mode 100644 index 000000000..0ea5d3f80 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_description_test.go @@ -0,0 +1,54 @@ +package outscale + +import ( + "testing" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPIDSLBUListenerDesc_basic(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerDescription + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleOAPILBUListenerDescConfig, + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + resource.TestCheckResourceAttr("data.outscale_load_balancer_listener_description.test", "listener.backend_port", "8000"), + )}, + }, + }) +} + +const testAccDSOutscaleOAPILBUListenerDescConfig = ` + resource "outscale_load_balancer" "bar" { + availability_zones = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb" + + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + data "outscale_load_balancer_listener_description" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + } +` From 166e0b4c7e53f49825e9eaf77d568ab80339a4c0 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 15:51:43 +0200 Subject: [PATCH 050/218] data_source_outscale_load_balancer_listener_description.go Signed-off-by: matthias.gatto --- ...cale_load_balancer_listener_description.go | 63 ++++++++++--------- 1 file changed, 35 insertions(+), 28 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go index fe507eadd..5b8840a77 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -1,15 +1,16 @@ package outscale import ( + "context" "fmt" - "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { @@ -63,7 +64,7 @@ func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -72,22 +73,31 @@ func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta inter elbName := ename.(string) - // Retrieve the ELB properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(elbName)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - describeResp = resp.DescribeLoadBalancersResult return nil }) @@ -100,31 +110,28 @@ func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta inter return fmt.Errorf("Error retrieving ELB: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { - return fmt.Errorf("NO ELB FOUND") - } - - if len(describeResp.LoadBalancerDescriptions) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) } - lb := describeResp.LoadBalancerDescriptions[0] + lb := (lbs)[0] - v := lb.ListenerDescriptions[0] + v := (*lb.Listeners)[0] l := make(map[string]interface{}) - l["backend_port"] = strconv.Itoa(int(aws.Int64Value(v.Listener.InstancePort))) - l["backend_protocol"] = aws.StringValue(v.Listener.InstanceProtocol) - l["load_balancer_port"] = strconv.Itoa(int(aws.Int64Value(v.Listener.LoadBalancerPort))) - l["load_balancer_protocol"] = aws.StringValue(v.Listener.Protocol) - l["server_certificate_id"] = aws.StringValue(v.Listener.SSLCertificateId) + l["backend_port"] = v.BackendPort + l["backend_protocol"] = v.BackendProtocol + l["load_balancer_port"] = v.LoadBalancerPort + l["load_balancer_protocol"] = v.LoadBalancerProtocol + l["server_certificate_id"] = v.ServerCertificateId if err := d.Set("listener", l); err != nil { return err } - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) - return d.Set("policy_name", flattenStringList(lb.ListenerDescriptions[0].PolicyNames)) + return d.Set("policy_name", flattenStringList(v.PolicyNames)) } From c7102a034b3301c27a37962c03bd38e3233cce83 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 15:52:14 +0200 Subject: [PATCH 051/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_listener_descriptions" This reverts commit 871a2808a24548a84e4d36ec5590643daca7cf40. --- ...ale_load_balancer_listener_descriptions.go | 145 ++++++++++++++++++ ...oad_balancer_listener_descriptions_test.go | 54 +++++++ 2 files changed, 199 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_listener_descriptions.go create mode 100644 outscale/data_source_outscale_load_balancer_listener_descriptions_test.go diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go new file mode 100644 index 000000000..5ab3e0278 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -0,0 +1,145 @@ +package outscale + +import ( + "fmt" + "strconv" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerLDsRead, + + Schema: map[string]*schema.Schema{ + "load_balancer_names": &schema.Schema{ + Type: schema.TypeList, + Required: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "listener": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "listener": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerLDsRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + e, ok := d.GetOk("load_balancer_names") + + if !ok { + return fmt.Errorf("please provide the name of the load balancers") + } + + // Retrieve the ELB properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: expandStringList(e.([]interface{})), + } + + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + describeResp = resp.DescribeLoadBalancersResult + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving LBU: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO LBU FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) < 1 { + return fmt.Errorf("Unable to find LBUS: %#v", describeResp.LoadBalancerDescriptions) + } + + lds := make([]map[string]interface{}, len(describeResp.LoadBalancerDescriptions)) + + for k, v1 := range describeResp.LoadBalancerDescriptions { + ld := make(map[string]interface{}) + ls := make([]map[string]interface{}, len(v1.ListenerDescriptions)) + + for k1, v2 := range v1.ListenerDescriptions { + l := make(map[string]interface{}) + l["backend_port"] = strconv.Itoa(int(aws.Int64Value(v2.Listener.InstancePort))) + l["backend_protocol"] = aws.StringValue(v2.Listener.InstanceProtocol) + l["load_balancer_port"] = strconv.Itoa(int(aws.Int64Value(v2.Listener.LoadBalancerPort))) + l["load_balancer_protocol"] = aws.StringValue(v2.Listener.Protocol) + l["server_certificate_id"] = aws.StringValue(v2.Listener.SSLCertificateId) + ls[k1] = l + } + + ld["listener"] = ls + ld["policy_name"] = flattenStringList(v1.ListenerDescriptions[0].PolicyNames) + + lds[k] = ld + } + + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(resource.UniqueId()) + + return d.Set("listener", lds) +} diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go new file mode 100644 index 000000000..20f51a386 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go @@ -0,0 +1,54 @@ +package outscale + +import ( + "testing" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerDescription + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleOAPILBUListenerDescsConfig, + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + resource.TestCheckResourceAttr("data.outscale_load_balancer_listener_descriptions.test", "listener_descriptions.0.listener.0.backend_port", "8000"), + )}, + }, + }) +} + +const testAccDSOutscaleOAPILBUListenerDescsConfig = ` + resource "outscale_load_balancer" "bar" { + sub_region = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb" + + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + data "outscale_load_balancer_listener_descriptions" "test" { + load_balancer_names = ["${outscale_load_balancer.bar.id}"] + } +` From 95a82414a7ceaa60d5d4596d3d453dac3b419280 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 16:41:09 +0200 Subject: [PATCH 052/218] data_source_outscale_load_balancer_listener_descriptions.go Signed-off-by: matthias.gatto --- ...ale_load_balancer_listener_descriptions.go | 68 ++++++++++--------- 1 file changed, 35 insertions(+), 33 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go index 5ab3e0278..584c3ee18 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -1,15 +1,16 @@ package outscale import ( + "context" "fmt" - "strconv" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { @@ -72,30 +73,40 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancerLDsRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI e, ok := d.GetOk("load_balancer_names") if !ok { return fmt.Errorf("please provide the name of the load balancers") } - // Retrieve the ELB properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: expandStringList(e.([]interface{})), + elbName := e.(string) + + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - describeResp = resp.DescribeLoadBalancersResult return nil }) @@ -108,37 +119,28 @@ func dataSourceOutscaleOAPILoadBalancerLDsRead(d *schema.ResourceData, meta inte return fmt.Errorf("Error retrieving LBU: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { - return fmt.Errorf("NO LBU FOUND") - } - - if len(describeResp.LoadBalancerDescriptions) < 1 { - return fmt.Errorf("Unable to find LBUS: %#v", describeResp.LoadBalancerDescriptions) - } - - lds := make([]map[string]interface{}, len(describeResp.LoadBalancerDescriptions)) - - for k, v1 := range describeResp.LoadBalancerDescriptions { + lds := make([]map[string]interface{}, len(*resp.LoadBalancers)) + for k, v1 := range *resp.LoadBalancers { ld := make(map[string]interface{}) - ls := make([]map[string]interface{}, len(v1.ListenerDescriptions)) + ls := make([]map[string]interface{}, len(*v1.Listeners)) - for k1, v2 := range v1.ListenerDescriptions { + for k1, v2 := range *v1.Listeners { l := make(map[string]interface{}) - l["backend_port"] = strconv.Itoa(int(aws.Int64Value(v2.Listener.InstancePort))) - l["backend_protocol"] = aws.StringValue(v2.Listener.InstanceProtocol) - l["load_balancer_port"] = strconv.Itoa(int(aws.Int64Value(v2.Listener.LoadBalancerPort))) - l["load_balancer_protocol"] = aws.StringValue(v2.Listener.Protocol) - l["server_certificate_id"] = aws.StringValue(v2.Listener.SSLCertificateId) + l["backend_port"] = v2.BackendPort + l["backend_protocol"] = v2.BackendProtocol + l["load_balancer_port"] = v2.LoadBalancerPort + l["load_balancer_protocol"] = v2.LoadBalancerProtocol + l["server_certificate_id"] = v2.ServerCertificateId + l["policy_name"] = flattenStringList(v2.PolicyNames) ls[k1] = l } ld["listener"] = ls - ld["policy_name"] = flattenStringList(v1.ListenerDescriptions[0].PolicyNames) lds[k] = ld } - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) return d.Set("listener", lds) From 2d1834cd5b38b58feaa7c52af08c9a982069b6c9 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 16:41:28 +0200 Subject: [PATCH 053/218] Revert "LBU-remove: rm data_source_outscale_load_balancer_tags" This reverts commit b68ca19367ef30fb98cc849f09cb8afc73892064. --- ...data_source_outscale_load_balancer_tags.go | 111 ++++++++++++++++++ ...source_outscale_load_balancer_tags_test.go | 81 +++++++++++++ 2 files changed, 192 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_tags.go create mode 100644 outscale/data_source_outscale_load_balancer_tags_test.go diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go new file mode 100644 index 000000000..3096b7348 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -0,0 +1,111 @@ +package outscale + +import ( + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" +) + +func dataSourceOutscaleOAPILBUTags() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILBUTagsRead, + + Schema: getDSOAPILBUTagsSchema(), + } +} + +func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + lbus := d.Get("load_balancer_names") + + params := &lbu.DescribeTagsInput{ + LoadBalancerNames: expandStringList(lbus.([]interface{})), + } + + var resp *lbu.DescribeTagsResult + var rs *lbu.DescribeTagsOutput + var err error + + err = resource.Retry(60*time.Second, func() *resource.RetryError { + rs, err = conn.API.DescribeTags(params) + if rs != nil { + resp = rs.DescribeTagsResult + } + return resource.RetryableError(err) + }) + + if err != nil { + return err + } + + td := make([]map[string]interface{}, len(resp.TagDescriptions)) + + for k, v := range resp.TagDescriptions { + t := make(map[string]interface{}) + t["load_balancer_name"] = aws.StringValue(v.LoadBalancerName) + + ta := make([]map[string]interface{}, len(v.Tags)) + for k1, v1 := range v.Tags { + t := make(map[string]interface{}) + t["key"] = aws.StringValue(v1.Key) + t["value"] = aws.StringValue(v1.Key) + ta[k1] = t + } + + t["tag"] = ta + + td[k] = t + } + + d.SetId(resource.UniqueId()) + d.Set("request_id", rs.ResponseMetadata.RequestID) + + return d.Set("tag", td) +} + +func getDSOAPILBUTagsSchema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeList, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "tag": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Computed: true, + }, + "tag": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "key": { + Type: schema.TypeString, + Computed: true, + }, + "value": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + }, + }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + } +} diff --git a/outscale/data_source_outscale_load_balancer_tags_test.go b/outscale/data_source_outscale_load_balancer_tags_test.go new file mode 100644 index 000000000..11c1d4d1a --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_tags_test.go @@ -0,0 +1,81 @@ +package outscale + +import ( + "fmt" + "testing" + + "github.com/hashicorp/terraform/helper/acctest" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/terraform" +) + +func TestAccOutscaleOAPIDSLoadBalancerTags_basic(t *testing.T) { + t.Skip() + + r := acctest.RandString(4) + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + Providers: testAccProviders, + Steps: []resource.TestStep{ + { + Config: getTestAccDSODSutscaleOAPILBUDSTagsConfig(r), + Check: resource.ComposeTestCheckFunc( + testAccCheckODSutscaleOAPILBUDSTagsExists("data.outscale_load_balancer_tags.testds"), + resource.TestCheckResourceAttr( + "data.outscale_load_balancer_tags.testds", "tag.#", "1"), + )}, + }, + }) +} + +func testAccCheckODSutscaleOAPILBUDSTagsExists(n string) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[n] + if !ok { + return fmt.Errorf("Not found: %s", n) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No LBU Tag DS ID is set") + } + + return nil + } +} + +func getTestAccDSODSutscaleOAPILBUDSTagsConfig(r string) string { + return fmt.Sprintf(` + resource "outscale_load_balancer" "bar" { + sub_region = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%s" + + listeners { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_port = 80 + load_balancer_protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + resource "outscale_load_balancer_tags" "tags" { + load_balancer_name = ["${outscale_load_balancer.bar.id}"] + + tag = [{ + key = "bar2" + value = "baz2" + }] + } + + data "outscale_load_balancer_tags" "testds" { + load_balancer_name = ["${outscale_load_balancer.bar.id}"] + } + `, r) +} From 50df807cc8d33c83697a40e9360fa161c7191870 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 17:34:53 +0200 Subject: [PATCH 054/218] data_source_outscale_load_balancer_tags.go Signed-off-by: matthias.gatto --- ...data_source_outscale_load_balancer_tags.go | 81 +++++++++++-------- 1 file changed, 48 insertions(+), 33 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index 3096b7348..4fb2a0d2b 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -1,13 +1,16 @@ package outscale import ( + "context" + "fmt" + "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILBUTags() *schema.Resource { @@ -19,53 +22,65 @@ func dataSourceOutscaleOAPILBUTags() *schema.Resource { } func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - lbus := d.Get("load_balancer_names") + elbName := d.Get("load_balancer_names").(string) - params := &lbu.DescribeTagsInput{ - LoadBalancerNames: expandStringList(lbus.([]interface{})), + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, } - var resp *lbu.DescribeTagsResult - var rs *lbu.DescribeTagsOutput - var err error + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } - err = resource.Retry(60*time.Second, func() *resource.RetryError { - rs, err = conn.API.DescribeTags(params) - if rs != nil { - resp = rs.DescribeTagsResult + var resp oscgo.ReadLoadBalancersResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) } - return resource.RetryableError(err) + return nil }) if err != nil { return err } - td := make([]map[string]interface{}, len(resp.TagDescriptions)) - - for k, v := range resp.TagDescriptions { - t := make(map[string]interface{}) - t["load_balancer_name"] = aws.StringValue(v.LoadBalancerName) - - ta := make([]map[string]interface{}, len(v.Tags)) - for k1, v1 := range v.Tags { - t := make(map[string]interface{}) - t["key"] = aws.StringValue(v1.Key) - t["value"] = aws.StringValue(v1.Key) - ta[k1] = t - } + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) + } - t["tag"] = ta + v := (lbs)[0] + t := make(map[string]interface{}) + t["load_balancer_name"] = elbName - td[k] = t + ta := make([]map[string]interface{}, len(*v.Tags)) + for k1, v1 := range *v.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Key + ta[k1] = t } + t["tag"] = ta + d.SetId(resource.UniqueId()) - d.Set("request_id", rs.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) - return d.Set("tag", td) + return d.Set("tag", t) } func getDSOAPILBUTagsSchema() map[string]*schema.Schema { From 7b2e971d58141659e104a712b5896b6c407f7387 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 18 Jun 2020 17:41:32 +0200 Subject: [PATCH 055/218] Revert "LBU-remove: rm data_source_outscale_load_balancers" This reverts commit 4db59b561cd8b60c908a64eb404e38c7a5e65bd4. --- .../data_source_outscale_load_balancers.go | 301 ++++++++++++++++++ ...ata_source_outscale_load_balancers_test.go | 52 +++ 2 files changed, 353 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancers.go create mode 100644 outscale/data_source_outscale_load_balancers_test.go diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go new file mode 100644 index 000000000..c7a7c5f6b --- /dev/null +++ b/outscale/data_source_outscale_load_balancers.go @@ -0,0 +1,301 @@ +package outscale + +import ( + "fmt" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancersRead, + + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeList, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "sub_region_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "public_dns_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "health_check": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "checked_vm": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "check_interval": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "timeout": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "backend_vm_id": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "vm_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "listeners": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "listener": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "policies": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "application_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "other_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "load_balancer_type": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "security_groups_member": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "account_alias": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "subnet_id": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "lin_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + + elbName, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("load_balancer_name(s) must be provided") + } + + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: expandStringList(elbName.([]interface{})), + } + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + if err != nil { + if strings.Contains(err.Error(), "RequestLimitExceeded:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + describeResp = resp.DescribeLoadBalancersResult + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + if len(describeResp.LoadBalancerDescriptions) < 1 { + return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + } + + lbs := make([]map[string]interface{}, len(describeResp.LoadBalancerDescriptions)) + + for k, v := range describeResp.LoadBalancerDescriptions { + l := make(map[string]interface{}) + + l["sub_region_name"] = flattenStringList(v.AvailabilityZones) + l["public_dns_name"] = aws.StringValue(v.DNSName) + l["health_check"] = flattenOAPIHealthCheck(v.HealthCheck) + l["backend_vm_id"] = flattenOAPIInstances(v.Instances) + l["listeners"] = flattenOAPIListeners(v.ListenerDescriptions) + l["load_balancer_name"] = aws.StringValue(v.LoadBalancerName) + + policies := make(map[string]interface{}) + pl := make([]map[string]interface{}, 1) + if v.Policies != nil { + app := make([]map[string]interface{}, len(v.Policies.AppCookieStickinessPolicies)) + for k, v := range v.Policies.AppCookieStickinessPolicies { + a := make(map[string]interface{}) + a["cookie_name"] = aws.StringValue(v.CookieName) + a["policy_name"] = aws.StringValue(v.PolicyName) + app[k] = a + } + policies["application_sticky_cookie_policy"] = app + vc := make([]map[string]interface{}, len(v.Policies.LBCookieStickinessPolicies)) + for k, v := range v.Policies.LBCookieStickinessPolicies { + a := make(map[string]interface{}) + a["policy_name"] = aws.StringValue(v.PolicyName) + vc[k] = a + } + policies["load_balancer_sticky_cookie_policy"] = vc + policies["other_policy"] = flattenStringList(v.Policies.OtherPolicies) + } + + pl[0] = policies + l["policies"] = pl + l["load_balancer_type"] = aws.StringValue(v.Scheme) + l["security_groups_member"] = flattenStringList(v.SecurityGroups) + ssg := make(map[string]string) + if v.SourceSecurityGroup != nil { + ssg["firewall_rules_set_name"] = aws.StringValue(v.SourceSecurityGroup.GroupName) + ssg["account_alias"] = aws.StringValue(v.SourceSecurityGroup.OwnerAlias) + } + l["firewall_rules_set_name"] = ssg + l["subnet_id"] = flattenStringList(v.Subnets) + l["lin_id"] = aws.StringValue(v.VPCId) + + lbs[k] = l + } + + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(resource.UniqueId()) + + return d.Set("load_balancer", lbs) +} diff --git a/outscale/data_source_outscale_load_balancers_test.go b/outscale/data_source_outscale_load_balancers_test.go new file mode 100644 index 000000000..9ce40fead --- /dev/null +++ b/outscale/data_source_outscale_load_balancers_test.go @@ -0,0 +1,52 @@ +package outscale + +import ( + "testing" + + "github.com/hashicorp/terraform/helper/resource" +) + +func TestAccOutscaleOAPIDSLBSU_basic(t *testing.T) { + t.Skip() + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleOAPILBsUConfig, + Check: resource.ComposeTestCheckFunc( + resource.TestCheckResourceAttr("data.outscale_load_balancers.test", "load_balancer_descriptions_member.#", "1"), + )}, + }, + }) +} + +const testAccDSOutscaleOAPILBsUConfig = ` + resource "outscale_load_balancer" "bar" { + availability_zones_member = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb" + + listeners_member { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + + // Protocol should be case insensitive + protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + data "outscale_load_balancers" "test" { + load_balancer_name = ["${outscale_load_balancer.bar.id}"] + } +` From bbcc3e53c6b8a0b8c9ef96136d13cca8c1c1190e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 22 Jun 2020 14:40:30 +0200 Subject: [PATCH 056/218] data_source_outscale_load_balancers.go Signed-off-by: matthias.gatto --- .../data_source_outscale_load_balancers.go | 167 ++++++++++-------- 1 file changed, 92 insertions(+), 75 deletions(-) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index c7a7c5f6b..d9c027ccc 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -1,14 +1,16 @@ package outscale import ( + "context" "fmt" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { @@ -16,103 +18,103 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancersRead, Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeList, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "load_balancer": &schema.Schema{ + "load_balancer": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Computed: true, }, - "sub_region_name": &schema.Schema{ + "sub_region_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "public_dns_name": &schema.Schema{ + "public_dns_name": { Type: schema.TypeString, Computed: true, }, - "health_check": &schema.Schema{ + "health_check": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "healthy_threshold": &schema.Schema{ + "healthy_threshold": { Type: schema.TypeString, Computed: true, }, - "unhealthy_threshold": &schema.Schema{ + "unhealthy_threshold": { Type: schema.TypeString, Computed: true, }, - "checked_vm": &schema.Schema{ + "checked_vm": { Type: schema.TypeString, Computed: true, }, - "check_interval": &schema.Schema{ + "check_interval": { Type: schema.TypeString, Computed: true, }, - "timeout": &schema.Schema{ + "timeout": { Type: schema.TypeString, Computed: true, }, }, }, }, - "backend_vm_id": &schema.Schema{ + "backend_vm_id": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "vm_id": &schema.Schema{ + "vm_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "listeners": &schema.Schema{ + "listeners": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "listener": &schema.Schema{ + "listener": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeInt, Computed: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Computed: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Computed: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Computed: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -120,40 +122,40 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { }, }, }, - "policies": &schema.Schema{ + "policies": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": &schema.Schema{ + "application_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "cookie_name": &schema.Schema{ + "cookie_name": { Type: schema.TypeString, Computed: true, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "load_balancer_sticky_cookie_policy": &schema.Schema{ + "load_balancer_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "other_policy": &schema.Schema{ + "other_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -161,44 +163,44 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { }, }, }, - "load_balancer_type": &schema.Schema{ + "load_balancer_type": { Type: schema.TypeString, Computed: true, }, - "security_groups_member": &schema.Schema{ + "security_groups_member": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeString, Computed: true, }, - "account_alias": &schema.Schema{ + "account_alias": { Type: schema.TypeString, Computed: true, }, }, }, }, - "subnet_id": &schema.Schema{ + "subnet_id": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "lin_id": &schema.Schema{ + "lin_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -207,29 +209,41 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI - elbName, ok := d.GetOk("load_balancer_name") + eName, ok := d.GetOk("load_balancer_name") if !ok { return fmt.Errorf("load_balancer_name(s) must be provided") } - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: expandStringList(elbName.([]interface{})), + elbName := eName.(string) + + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { - if strings.Contains(err.Error(), "RequestLimitExceeded:") { + if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - describeResp = resp.DescribeLoadBalancersResult return nil }) @@ -241,60 +255,63 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf return fmt.Errorf("Error retrieving ELB: %s", err) } - if len(describeResp.LoadBalancerDescriptions) < 1 { - return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) - } - lbs := make([]map[string]interface{}, len(describeResp.LoadBalancerDescriptions)) + lbs_len := len(*resp.LoadBalancers) + lbs_ret := make([]map[string]interface{}, lbs_len) + + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) + } - for k, v := range describeResp.LoadBalancerDescriptions { + for k, v := range lbs { l := make(map[string]interface{}) - l["sub_region_name"] = flattenStringList(v.AvailabilityZones) - l["public_dns_name"] = aws.StringValue(v.DNSName) - l["health_check"] = flattenOAPIHealthCheck(v.HealthCheck) - l["backend_vm_id"] = flattenOAPIInstances(v.Instances) - l["listeners"] = flattenOAPIListeners(v.ListenerDescriptions) - l["load_balancer_name"] = aws.StringValue(v.LoadBalancerName) + l["sub_region_name"] = v.SubregionNames + l["public_dns_name"] = v.DnsName + l["health_check"] = v.HealthCheck + l["backend_vm_id"] = v.BackendVmIds + l["listeners"] = flattenOAPIListeners(v.Listeners) + l["load_balancer_name"] = elbName policies := make(map[string]interface{}) pl := make([]map[string]interface{}, 1) - if v.Policies != nil { - app := make([]map[string]interface{}, len(v.Policies.AppCookieStickinessPolicies)) - for k, v := range v.Policies.AppCookieStickinessPolicies { + if v.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, len(*v.ApplicationStickyCookiePolicies)) + for k, v := range *v.ApplicationStickyCookiePolicies { a := make(map[string]interface{}) - a["cookie_name"] = aws.StringValue(v.CookieName) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName app[k] = a } policies["application_sticky_cookie_policy"] = app - vc := make([]map[string]interface{}, len(v.Policies.LBCookieStickinessPolicies)) - for k, v := range v.Policies.LBCookieStickinessPolicies { + vc := make([]map[string]interface{}, + len(*v.LoadBalancerStickyCookiePolicies)) + for k, v := range *v.LoadBalancerStickyCookiePolicies { a := make(map[string]interface{}) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["policy_name"] = v.PolicyName vc[k] = a } policies["load_balancer_sticky_cookie_policy"] = vc - policies["other_policy"] = flattenStringList(v.Policies.OtherPolicies) } pl[0] = policies l["policies"] = pl - l["load_balancer_type"] = aws.StringValue(v.Scheme) + l["load_balancer_type"] = v.LoadBalancerType l["security_groups_member"] = flattenStringList(v.SecurityGroups) ssg := make(map[string]string) if v.SourceSecurityGroup != nil { - ssg["firewall_rules_set_name"] = aws.StringValue(v.SourceSecurityGroup.GroupName) - ssg["account_alias"] = aws.StringValue(v.SourceSecurityGroup.OwnerAlias) + ssg["security_group_account_id"] = *v.SourceSecurityGroup.SecurityGroupAccountId + ssg["security_group_name"] = *v.SourceSecurityGroup.SecurityGroupName } l["firewall_rules_set_name"] = ssg l["subnet_id"] = flattenStringList(v.Subnets) - l["lin_id"] = aws.StringValue(v.VPCId) + l["net_id"] = v.NetId - lbs[k] = l + lbs_ret[k] = l } - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) return d.Set("load_balancer", lbs) From 9229dd34a3b1edf42bb4bfec86547d2ffc38a407 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 22 Jun 2020 14:40:55 +0200 Subject: [PATCH 057/218] Revert "LBU-remove: rm data_source_outscale_load_balancer" This reverts commit 7030ff751cfcf65858a3bc6b1e7abdb25bf0841e. --- .../data_source_outscale_load_balancer.go | 308 ++++++++++++++++++ ...data_source_outscale_load_balancer_test.go | 58 ++++ 2 files changed, 366 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer.go create mode 100644 outscale/data_source_outscale_load_balancer_test.go diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go new file mode 100644 index 000000000..cb456bf46 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer.go @@ -0,0 +1,308 @@ +package outscale + +import ( + "fmt" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws" + "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform/helper/schema" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerRead, + + Schema: map[string]*schema.Schema{ + "sub_region_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer_name": &schema.Schema{ + Type: schema.TypeString, + Required: true, + }, + "scheme": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "security_groups_member": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "subnets_member": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "tag": tagsSchema(), + + "public_dns_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "health_check": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "checked_vm": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "check_interval": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "timeout": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "backend_vm_id": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "vm_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "listeners": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "listener": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "backend_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "backend_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": &schema.Schema{ + Type: schema.TypeInt, + Computed: true, + }, + "load_balancer_protocol": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "server_certificate_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "firewall_rules_set_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "account_alias": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "lin_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "policies": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "application_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "other_policy": &schema.Schema{ + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + }, + }, + "request_id": &schema.Schema{ + Type: schema.TypeString, + Computed: true, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).LBU + ename, ok := d.GetOk("load_balancer_name") + + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } + + elbName := ename.(string) + + // Retrieve the ELB properties for updating the state + describeElbOpts := &lbu.DescribeLoadBalancersInput{ + LoadBalancerNames: []*string{aws.String(elbName)}, + } + var resp *lbu.DescribeLoadBalancersOutput + var describeResp *lbu.DescribeLoadBalancersResult + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + describeResp = resp.DescribeLoadBalancersResult + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + if describeResp.LoadBalancerDescriptions == nil { + return fmt.Errorf("NO ELB FOUND") + } + + if len(describeResp.LoadBalancerDescriptions) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) + } + + lb := describeResp.LoadBalancerDescriptions[0] + + d.Set("sub_region_name", flattenStringList(lb.AvailabilityZones)) + d.Set("public_dns_name", aws.StringValue(lb.DNSName)) + d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + + if lb.Instances != nil { + d.Set("backend_vm_id", flattenInstances(lb.Instances)) + } else { + d.Set("backend_vm_id", make([]map[string]interface{}, 0)) + } + if lb.ListenerDescriptions != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.ListenerDescriptions)); err != nil { + return err + } + } else { + if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { + return err + } + } + d.Set("load_balancer_name", aws.StringValue(lb.LoadBalancerName)) + + policies := make(map[string]interface{}) + if lb.Policies != nil { + app := make([]map[string]interface{}, len(lb.Policies.AppCookieStickinessPolicies)) + for k, v := range lb.Policies.AppCookieStickinessPolicies { + a := make(map[string]interface{}) + a["cookie_name"] = aws.StringValue(v.CookieName) + a["policy_name"] = aws.StringValue(v.PolicyName) + app[k] = a + } + policies["application_sticky_cookie_policy"] = app + lbc := make([]map[string]interface{}, len(lb.Policies.LBCookieStickinessPolicies)) + for k, v := range lb.Policies.LBCookieStickinessPolicies { + a := make(map[string]interface{}) + a["policy_name"] = aws.StringValue(v.PolicyName) + lbc[k] = a + } + policies["load_balancer_sticky_cookie_policy"] = lbc + policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) + } else { + lbc := make([]map[string]interface{}, 0) + policies["load_balancer_sticky_cookie_policy"] = lbc + policies["other_policy"] = lbc + } + d.Set("policies", policies) + d.Set("scheme", aws.StringValue(lb.Scheme)) + if lb.SecurityGroups != nil { + d.Set("security_groups_member", flattenStringList(lb.SecurityGroups)) + } else { + d.Set("security_groups_member", make([]map[string]interface{}, 0)) + } + ssg := make(map[string]string) + if lb.SourceSecurityGroup != nil { + ssg["firewall_rules_set_name"] = aws.StringValue(lb.SourceSecurityGroup.GroupName) + ssg["account_alias"] = aws.StringValue(lb.SourceSecurityGroup.OwnerAlias) + } + d.Set("firewall_rules_set_name", ssg) + d.Set("subnets_member", flattenStringList(lb.Subnets)) + d.Set("lin_id", aws.StringValue(lb.VPCId)) + d.Set("request_id", resp.ResponseMetadata.RequestID) + d.SetId(*lb.LoadBalancerName) + + return nil +} diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go new file mode 100644 index 000000000..c313134f7 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -0,0 +1,58 @@ +package outscale + +import ( + "testing" + + "github.com/hashicorp/terraform/helper/resource" + "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" +) + +func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { + t.Skip() + + var conf lbu.LoadBalancerDescription + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + skipIfNoOAPI(t) + testAccPreCheck(t) + }, + IDRefreshName: "outscale_load_balancer.bar", + Providers: testAccProviders, + CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, + Steps: []resource.TestStep{ + { + Config: testAccDSOutscaleOAPILBUConfig, + Check: resource.ComposeTestCheckFunc( + testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), + testAccCheckOutscaleOAPILBUAttributes(&conf), + resource.TestCheckResourceAttr( + "data.outscale_load_balancer.test", "sub_region_name.#", "1"), + resource.TestCheckResourceAttr( + "data.outscale_load_balancer.test", "sub_region_name.0", "eu-west-2a"), + )}, + }, + }) +} + +const testAccDSOutscaleOAPILBUConfig = ` + resource "outscale_load_balancer" "bar" { + sub_region_name = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb" + + listener { + backend_port = 8000 + backend_protocol = "HTTP" + load_balancer_protocol = 80 + protocol = "HTTP" + } + + tag { + bar = "baz" + } + } + + data "outscale_load_balancer" "test" { + load_balancer_name = "${outscale_load_balancer.bar.id}" + } +` From 6c1221391d45f771578130361b7b0bf568f22e8e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 22 Jun 2020 15:58:48 +0200 Subject: [PATCH 058/218] data_source_outscale_load_balancer.go Signed-off-by: matthias.gatto --- .../data_source_outscale_load_balancer.go | 162 +++++++++--------- .../data_source_outscale_load_balancers.go | 9 +- 2 files changed, 85 insertions(+), 86 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index cb456bf46..4145c0984 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -1,14 +1,16 @@ package outscale import ( + "context" "fmt" "strings" "time" - "github.com/aws/aws-sdk-go/aws" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/helper/schema" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { @@ -16,109 +18,109 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerRead, Schema: map[string]*schema.Schema{ - "sub_region_name": &schema.Schema{ + "sub_region_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, }, - "scheme": &schema.Schema{ + "load_balancer_type": { Type: schema.TypeString, Computed: true, }, - "security_groups_member": &schema.Schema{ + "security_groups_member": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "subnets_member": &schema.Schema{ + "subnets_member": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, "tag": tagsSchema(), - "public_dns_name": &schema.Schema{ + "public_dns_name": { Type: schema.TypeString, Computed: true, }, - "health_check": &schema.Schema{ + "health_check": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "healthy_threshold": &schema.Schema{ + "healthy_threshold": { Type: schema.TypeString, Computed: true, }, - "unhealthy_threshold": &schema.Schema{ + "unhealthy_threshold": { Type: schema.TypeString, Computed: true, }, - "checked_vm": &schema.Schema{ + "checked_vm": { Type: schema.TypeString, Computed: true, }, - "check_interval": &schema.Schema{ + "check_interval": { Type: schema.TypeString, Computed: true, }, - "timeout": &schema.Schema{ + "timeout": { Type: schema.TypeString, Computed: true, }, }, }, }, - "backend_vm_id": &schema.Schema{ + "backend_vm_id": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "vm_id": &schema.Schema{ + "vm_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "listeners": &schema.Schema{ + "listeners": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "listener": &schema.Schema{ + "listener": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeInt, Computed: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Computed: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeInt, Computed: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Computed: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -126,68 +128,63 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": &schema.Schema{ + "firewall_rules_set_name": { Type: schema.TypeString, Computed: true, }, - "account_alias": &schema.Schema{ + "account_alias": { Type: schema.TypeString, Computed: true, }, }, }, }, - "lin_id": &schema.Schema{ + "net_id": { Type: schema.TypeString, Computed: true, }, - "policies": &schema.Schema{ + "policies": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": &schema.Schema{ + "application_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "cookie_name": &schema.Schema{ + "cookie_name": { Type: schema.TypeString, Computed: true, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "load_balancer_sticky_cookie_policy": &schema.Schema{ + "load_balancer_sticky_cookie_policy": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeString, Computed: true, }, }, }, }, - "other_policy": &schema.Schema{ - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, }, }, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, @@ -196,7 +193,7 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { } func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).LBU + conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -205,22 +202,31 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa elbName := ename.(string) - // Retrieve the ELB properties for updating the state - describeElbOpts := &lbu.DescribeLoadBalancersInput{ - LoadBalancerNames: []*string{aws.String(elbName)}, + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, } - var resp *lbu.DescribeLoadBalancersOutput - var describeResp *lbu.DescribeLoadBalancersResult + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, err = conn.API.DescribeLoadBalancers(describeElbOpts) + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } - describeResp = resp.DescribeLoadBalancersResult return nil }) @@ -233,27 +239,24 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa return fmt.Errorf("Error retrieving ELB: %s", err) } - if describeResp.LoadBalancerDescriptions == nil { - return fmt.Errorf("NO ELB FOUND") + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", elbName) } - if len(describeResp.LoadBalancerDescriptions) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", describeResp.LoadBalancerDescriptions) - } + lb := lbs[0] - lb := describeResp.LoadBalancerDescriptions[0] - - d.Set("sub_region_name", flattenStringList(lb.AvailabilityZones)) - d.Set("public_dns_name", aws.StringValue(lb.DNSName)) + d.Set("sub_region_name", flattenStringList(lb.SubregionNames)) + d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) - if lb.Instances != nil { - d.Set("backend_vm_id", flattenInstances(lb.Instances)) + if lb.BackendVmIds != nil { + d.Set("backend_vm_id", lb.BackendVmIds) } else { d.Set("backend_vm_id", make([]map[string]interface{}, 0)) } - if lb.ListenerDescriptions != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.ListenerDescriptions)); err != nil { + if lb.Listeners != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { return err } } else { @@ -261,33 +264,34 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa return err } } - d.Set("load_balancer_name", aws.StringValue(lb.LoadBalancerName)) + d.Set("load_balancer_name", lb.LoadBalancerName) policies := make(map[string]interface{}) - if lb.Policies != nil { - app := make([]map[string]interface{}, len(lb.Policies.AppCookieStickinessPolicies)) - for k, v := range lb.Policies.AppCookieStickinessPolicies { + if lb.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, len(*lb.ApplicationStickyCookiePolicies)) + for k, v := range *lb.ApplicationStickyCookiePolicies { a := make(map[string]interface{}) - a["cookie_name"] = aws.StringValue(v.CookieName) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName app[k] = a } policies["application_sticky_cookie_policy"] = app - lbc := make([]map[string]interface{}, len(lb.Policies.LBCookieStickinessPolicies)) - for k, v := range lb.Policies.LBCookieStickinessPolicies { + } + if lb.LoadBalancerStickyCookiePolicies != nil { + lbc := make([]map[string]interface{}, len(*lb.LoadBalancerStickyCookiePolicies)) + for k, v := range *lb.LoadBalancerStickyCookiePolicies { a := make(map[string]interface{}) - a["policy_name"] = aws.StringValue(v.PolicyName) + a["policy_name"] = v.PolicyName lbc[k] = a } policies["load_balancer_sticky_cookie_policy"] = lbc - policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) } else { lbc := make([]map[string]interface{}, 0) policies["load_balancer_sticky_cookie_policy"] = lbc - policies["other_policy"] = lbc } d.Set("policies", policies) - d.Set("scheme", aws.StringValue(lb.Scheme)) + + d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { d.Set("security_groups_member", flattenStringList(lb.SecurityGroups)) } else { @@ -295,13 +299,13 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa } ssg := make(map[string]string) if lb.SourceSecurityGroup != nil { - ssg["firewall_rules_set_name"] = aws.StringValue(lb.SourceSecurityGroup.GroupName) - ssg["account_alias"] = aws.StringValue(lb.SourceSecurityGroup.OwnerAlias) + ssg["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId + ssg["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName } d.Set("firewall_rules_set_name", ssg) d.Set("subnets_member", flattenStringList(lb.Subnets)) - d.Set("lin_id", aws.StringValue(lb.VPCId)) - d.Set("request_id", resp.ResponseMetadata.RequestID) + d.Set("net_id", lb.NetId) + d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(*lb.LoadBalancerName) return nil diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index d9c027ccc..9bac7107b 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -155,11 +155,6 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { }, }, }, - "other_policy": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, }, }, }, @@ -193,7 +188,7 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "lin_id": { + "net_id": { Type: schema.TypeString, Computed: true, }, @@ -260,7 +255,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf lbs_ret := make([]map[string]interface{}, lbs_len) lbs := *resp.LoadBalancers - if len(lbs) != 1 { + if len(lbs) < 1 { return fmt.Errorf("Unable to find LBU: %s", elbName) } From 4748dfdaaf82e8afd53cc962f038c553a8c3cf8c Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Mon, 22 Jun 2020 16:02:06 +0200 Subject: [PATCH 059/218] sub_regions -> subregions Signed-off-by: matthias.gatto --- outscale/data_source_outscale_load_balancer.go | 4 ++-- outscale/data_source_outscale_load_balancers.go | 4 ++-- outscale/resource_outscale_load_balancer_health_check_test.go | 2 +- outscale/resource_outscale_load_balancer_listeners_test.go | 2 +- outscale/resource_outscale_load_balancer_policy_test.go | 2 +- .../resource_outscale_load_balancer_ssl_certificate_test.go | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 4145c0984..2e58417c8 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -18,7 +18,7 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerRead, Schema: map[string]*schema.Schema{ - "sub_region_name": { + "subregion_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -246,7 +246,7 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa lb := lbs[0] - d.Set("sub_region_name", flattenStringList(lb.SubregionNames)) + d.Set("subregion_name", flattenStringList(lb.SubregionNames)) d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 9bac7107b..06ae8e2c9 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -32,7 +32,7 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "sub_region_name": { + "subregion_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -262,7 +262,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf for k, v := range lbs { l := make(map[string]interface{}) - l["sub_region_name"] = v.SubregionNames + l["subregion_name"] = v.SubregionNames l["public_dns_name"] = v.DnsName l["health_check"] = v.HealthCheck l["backend_vm_id"] = v.BackendVmIds diff --git a/outscale/resource_outscale_load_balancer_health_check_test.go b/outscale/resource_outscale_load_balancer_health_check_test.go index a14efbae1..62085288f 100644 --- a/outscale/resource_outscale_load_balancer_health_check_test.go +++ b/outscale/resource_outscale_load_balancer_health_check_test.go @@ -40,7 +40,7 @@ func TestAccOutscaleOAPIHealthCheck_basic(t *testing.T) { func testAccOutscaleOAPIHealthCheckConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%d" listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go index e7ba1b508..6a471da96 100644 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -37,7 +37,7 @@ func TestAccOutscaleOAPILBUUpdate_Listener(t *testing.T) { func testAccOutscaleOAPILBUListenersConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-lbu-%d" listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index 85927abb4..2e09e1b20 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -28,7 +28,7 @@ func TestOutscaleOAPILoadBalancerPolicy_basic(t *testing.T) { const testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig = ` resource "outscale_load_balancer" "outscale_load_balancer" { load_balancer_name = "foobar-terraform-elb" - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go index 5de34d6d9..2869108ec 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go @@ -35,7 +35,7 @@ func TestAccOutscaleLBUOAPISSLCertificate_basic(t *testing.T) { func testAccOutscaleOAPISSLCertificateConfig(r int, fName string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-lbu-%d" listeners { backend_port = 8000 From 668bbc812071284c938f04ad94e8f6b48afd4122 Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 25 Jun 2020 11:26:32 +0200 Subject: [PATCH 060/218] name fixing (more or less) Signed-off-by: matthias.gatto --- ...ce_outscale_load_balancer_access_logs_test.go | 16 +--------------- ...rce_outscale_load_balancer_attributes_test.go | 9 ++++----- ...e_outscale_load_balancer_health_check_test.go | 10 +++++----- ...le_load_balancer_listener_description_test.go | 5 ++--- ...e_load_balancer_listener_descriptions_test.go | 5 ++--- .../data_source_outscale_load_balancer_test.go | 7 +++---- 6 files changed, 17 insertions(+), 35 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_access_logs_test.go b/outscale/data_source_outscale_load_balancer_access_logs_test.go index 3fb9a4ee8..42f5bac05 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs_test.go +++ b/outscale/data_source_outscale_load_balancer_access_logs_test.go @@ -2,27 +2,13 @@ package outscale import ( "fmt" - "os" - "strconv" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleLoadBalancerAccessLogs_basic(t *testing.T) { - t.Skip() - - o := os.Getenv("OUTSCALE_OAPI") - - oapi, err := strconv.ParseBool(o) - if err != nil { - oapi = false - } - - if oapi { - t.Skip() - } - resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, Providers: testAccProviders, diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go index fcc1959a0..7407f7b8c 100644 --- a/outscale/data_source_outscale_load_balancer_attributes_test.go +++ b/outscale/data_source_outscale_load_balancer_attributes_test.go @@ -4,9 +4,8 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBUAttr_basic(t *testing.T) { @@ -14,7 +13,7 @@ func TestAccOutscaleOAPIDSLBUAttr_basic(t *testing.T) { r := acctest.RandIntRange(0, 10) - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, @@ -35,7 +34,7 @@ func TestAccOutscaleOAPIDSLBUAttr_basic(t *testing.T) { func testAccDSOutscaleOAPILBUAttrConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_regions = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%d" listener { diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go index 7bf092224..aa0c93bc3 100644 --- a/outscale/data_source_outscale_load_balancer_health_check_test.go +++ b/outscale/data_source_outscale_load_balancer_health_check_test.go @@ -4,15 +4,15 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { t.Skip() - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer rs := acctest.RandString(5) resource.Test(t, resource.TestCase{ @@ -39,7 +39,7 @@ func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { func getTestAccDSOutscaleOAPILBUHConfig(r string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_regions = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%s" listener { diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go index 0ea5d3f80..44c925d56 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_description_test.go @@ -3,8 +3,7 @@ package outscale import ( "testing" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBUListenerDesc_basic(t *testing.T) { @@ -33,7 +32,7 @@ func TestAccOutscaleOAPIDSLBUListenerDesc_basic(t *testing.T) { const testAccDSOutscaleOAPILBUListenerDescConfig = ` resource "outscale_load_balancer" "bar" { - availability_zones = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listeners { diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go index 20f51a386..fba0381eb 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go @@ -3,8 +3,7 @@ package outscale import ( "testing" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { @@ -33,7 +32,7 @@ func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { const testAccDSOutscaleOAPILBUListenerDescsConfig = ` resource "outscale_load_balancer" "bar" { - sub_region = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listener { diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index c313134f7..830215311 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -3,8 +3,7 @@ package outscale import ( "testing" - "github.com/hashicorp/terraform/helper/resource" - "github.com/terraform-providers/terraform-provider-outscale/osc/lbu" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { @@ -37,14 +36,14 @@ func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { const testAccDSOutscaleOAPILBUConfig = ` resource "outscale_load_balancer" "bar" { - sub_region_name = ["eu-west-2a"] + subregion_name = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listener { backend_port = 8000 backend_protocol = "HTTP" load_balancer_protocol = 80 - protocol = "HTTP" + load_balancer_protocol = "HTTP" } tag { From e0244d745ce57b37194eabc090c6115067eb473e Mon Sep 17 00:00:00 2001 From: "matthias.gatto" Date: Thu, 25 Jun 2020 15:41:38 +0200 Subject: [PATCH 061/218] fix non acc tests Signed-off-by: matthias.gatto --- ...a_source_outscale_load_balancer_attributes_test.go | 2 ++ ...source_outscale_load_balancer_health_check_test.go | 8 +++----- ...utscale_load_balancer_listener_description_test.go | 7 +++---- ...tscale_load_balancer_listener_descriptions_test.go | 9 ++++----- .../data_source_outscale_load_balancer_tags_test.go | 11 ++++------- outscale/data_source_outscale_load_balancer_test.go | 9 ++++----- outscale/data_source_outscale_load_balancers.go | 4 ++-- outscale/data_source_outscale_load_balancers_test.go | 7 ++----- ...resource_outscale_load_balancer_attributes_test.go | 6 ++---- ...source_outscale_load_balancer_health_check_test.go | 2 +- .../resource_outscale_load_balancer_listeners_test.go | 2 +- .../resource_outscale_load_balancer_policy_test.go | 2 +- ...rce_outscale_load_balancer_ssl_certificate_test.go | 2 +- outscale/resource_outscale_load_balancer_test.go | 8 ++++---- 14 files changed, 34 insertions(+), 45 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go index 7407f7b8c..b863a548d 100644 --- a/outscale/data_source_outscale_load_balancer_attributes_test.go +++ b/outscale/data_source_outscale_load_balancer_attributes_test.go @@ -4,6 +4,8 @@ import ( "fmt" "testing" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go index aa0c93bc3..637c4c2df 100644 --- a/outscale/data_source_outscale_load_balancer_health_check_test.go +++ b/outscale/data_source_outscale_load_balancer_health_check_test.go @@ -4,20 +4,18 @@ import ( "fmt" "testing" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { - t.Skip() - var conf oscgo.LoadBalancer rs := acctest.RandString(5) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", @@ -39,7 +37,7 @@ func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { func getTestAccDSOutscaleOAPILBUHConfig(r string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%s" listener { diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go index 44c925d56..3dde07c78 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_description_test.go @@ -3,17 +3,16 @@ package outscale import ( "testing" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBUListenerDesc_basic(t *testing.T) { - t.Skip() - - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go index fba0381eb..d718a917c 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go @@ -3,17 +3,16 @@ package outscale import ( "testing" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { - t.Skip() - - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", @@ -32,7 +31,7 @@ func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { const testAccDSOutscaleOAPILBUListenerDescsConfig = ` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listener { diff --git a/outscale/data_source_outscale_load_balancer_tags_test.go b/outscale/data_source_outscale_load_balancer_tags_test.go index 11c1d4d1a..59b60acbf 100644 --- a/outscale/data_source_outscale_load_balancer_tags_test.go +++ b/outscale/data_source_outscale_load_balancer_tags_test.go @@ -4,19 +4,16 @@ import ( "fmt" "testing" - "github.com/hashicorp/terraform/helper/acctest" - "github.com/hashicorp/terraform/helper/resource" - "github.com/hashicorp/terraform/terraform" + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) func TestAccOutscaleOAPIDSLoadBalancerTags_basic(t *testing.T) { - t.Skip() - r := acctest.RandString(4) resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, Providers: testAccProviders, @@ -50,7 +47,7 @@ func testAccCheckODSutscaleOAPILBUDSTagsExists(n string) resource.TestCheckFunc func getTestAccDSODSutscaleOAPILBUDSTagsConfig(r string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_region = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%s" listeners { diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index 830215311..81c00b05f 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -3,17 +3,16 @@ package outscale import ( "testing" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { - t.Skip() - - var conf lbu.LoadBalancerDescription + var conf oscgo.LoadBalancer resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", @@ -36,7 +35,7 @@ func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { const testAccDSOutscaleOAPILBUConfig = ` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listener { diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 06ae8e2c9..ea312fc3d 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -32,7 +32,7 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "subregion_name": { + "subregion_names": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -262,7 +262,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf for k, v := range lbs { l := make(map[string]interface{}) - l["subregion_name"] = v.SubregionNames + l["subregion_names"] = v.SubregionNames l["public_dns_name"] = v.DnsName l["health_check"] = v.HealthCheck l["backend_vm_id"] = v.BackendVmIds diff --git a/outscale/data_source_outscale_load_balancers_test.go b/outscale/data_source_outscale_load_balancers_test.go index 9ce40fead..d6f3ee5f8 100644 --- a/outscale/data_source_outscale_load_balancers_test.go +++ b/outscale/data_source_outscale_load_balancers_test.go @@ -3,15 +3,12 @@ package outscale import ( "testing" - "github.com/hashicorp/terraform/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBSU_basic(t *testing.T) { - t.Skip() - resource.Test(t, resource.TestCase{ PreCheck: func() { - skipIfNoOAPI(t) testAccPreCheck(t) }, IDRefreshName: "outscale_load_balancer.bar", @@ -29,7 +26,7 @@ func TestAccOutscaleOAPIDSLBSU_basic(t *testing.T) { const testAccDSOutscaleOAPILBsUConfig = ` resource "outscale_load_balancer" "bar" { - availability_zones_member = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb" listeners_member { diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index 36b4bfbb0..c02b90219 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -12,8 +12,6 @@ import ( ) func TestAccOutscaleOAPILBUAttr_basic(t *testing.T) { - t.Skip() - var conf oscgo.AccessLog r := acctest.RandIntRange(0, 10) @@ -52,8 +50,8 @@ func testAccCheckOutscaleOAPILBUAttrExists(n string, res *oscgo.AccessLog) resou func testAccOutscaleOAPILBUAttrConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - sub_regions = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-%d" + subregion_names = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" listeners { backend_port = 8000 backend_protocol = "HTTP" diff --git a/outscale/resource_outscale_load_balancer_health_check_test.go b/outscale/resource_outscale_load_balancer_health_check_test.go index 62085288f..3e6cae2d8 100644 --- a/outscale/resource_outscale_load_balancer_health_check_test.go +++ b/outscale/resource_outscale_load_balancer_health_check_test.go @@ -40,7 +40,7 @@ func TestAccOutscaleOAPIHealthCheck_basic(t *testing.T) { func testAccOutscaleOAPIHealthCheckConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-elb-%d" listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go index 6a471da96..59eca7823 100644 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -37,7 +37,7 @@ func TestAccOutscaleOAPILBUUpdate_Listener(t *testing.T) { func testAccOutscaleOAPILBUListenersConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-lbu-%d" listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index 2e09e1b20..de83a9b8b 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -28,7 +28,7 @@ func TestOutscaleOAPILoadBalancerPolicy_basic(t *testing.T) { const testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig = ` resource "outscale_load_balancer" "outscale_load_balancer" { load_balancer_name = "foobar-terraform-elb" - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] listener { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go index 2869108ec..0b0d04145 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go @@ -35,7 +35,7 @@ func TestAccOutscaleLBUOAPISSLCertificate_basic(t *testing.T) { func testAccOutscaleOAPISSLCertificateConfig(r int, fName string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] load_balancer_name = "foobar-terraform-lbu-%d" listeners { backend_port = 8000 diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index 551ba933a..36e4956c6 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -36,9 +36,9 @@ func TestAccOutscaleOAPILBUBasic(t *testing.T) { testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), testAccCheckOutscaleOAPILBUAttributes(&conf), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "subregion_name.#", "1"), + "outscale_load_balancer.bar", "subregion_names.#", "1"), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "subregion_name.0", "eu-west-2a"), + "outscale_load_balancer.bar", "subregion_names.0", "eu-west-2a"), resource.TestCheckResourceAttr( "outscale_load_balancer.bar", "listener.0.backend_port", "8000"), resource.TestCheckResourceAttr( @@ -213,8 +213,8 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resour func testAccOutscaleOAPILBUConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-%d" + subregion_names = ["eu-west-2a"] + load_balancer_name = "foobar-terraform-elb-%d" listeners { backend_port = 8000 backend_protocol = "HTTP" From a360ec3a967db1b006d10d25a0516758c528019d Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 2 Jul 2020 18:01:08 +0200 Subject: [PATCH 062/218] fix lbu with tags Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index c47b590bb..fbcdc7e8d 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -222,7 +222,7 @@ func resourceOutscaleOAPILoadBalancerCreate_(d *schema.ResourceData, meta interf } if v, ok := d.GetOk("tags"); ok { - r := tagsFromSliceMap(v.([]interface{})) + r := tagsFromSliceMap(v.(*schema.Set)) req.Tags = &r } From efaa6c79b122fec1e3e56ea9b45c5ba8f7ef58f6 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 2 Jul 2020 17:49:25 +0200 Subject: [PATCH 063/218] fmt crap Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 16 +++++++-------- ...rce_outscale_load_balancer_health_check.go | 14 ++++++------- ...cale_load_balancer_listener_description.go | 18 ++++++++--------- ...ale_load_balancer_listener_descriptions.go | 20 +++++++++---------- outscale/provider.go | 16 +++++++-------- 5 files changed, 42 insertions(+), 42 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go index 295b7cf80..0fafbf818 100644 --- a/outscale/data_source_outscale_load_balancer_attributes.go +++ b/outscale/data_source_outscale_load_balancer_attributes.go @@ -18,33 +18,33 @@ func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerAttrRead, Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, }, - "load_balancer_attributes": &schema.Schema{ + "load_balancer_attributes": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "access_log": &schema.Schema{ + "access_log": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "publication_interval": &schema.Schema{ + "publication_interval": { Type: schema.TypeString, Computed: true, }, - "is_enabled": &schema.Schema{ + "is_enabled": { Type: schema.TypeString, Computed: true, }, - "osu_bucket_name": &schema.Schema{ + "osu_bucket_name": { Type: schema.TypeString, Computed: true, }, - "osu_bucket_prefix": &schema.Schema{ + "osu_bucket_prefix": { Type: schema.TypeString, Computed: true, }, @@ -54,7 +54,7 @@ func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { }, }, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go index 72681c4fc..f8e1f45a4 100644 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -18,31 +18,31 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerHealthCheckRead, Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, }, - "healthy_threshold": &schema.Schema{ + "healthy_threshold": { Type: schema.TypeInt, Computed: true, }, - "unhealthy_threshold": &schema.Schema{ + "unhealthy_threshold": { Type: schema.TypeInt, Computed: true, }, - "path": &schema.Schema{ + "path": { Type: schema.TypeString, Computed: true, }, - "check_interval": &schema.Schema{ + "check_interval": { Type: schema.TypeInt, Computed: true, }, - "timeout": &schema.Schema{ + "timeout": { Type: schema.TypeInt, Computed: true, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go index 5b8840a77..df0c8d097 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -18,44 +18,44 @@ func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerLDRead, Schema: map[string]*schema.Schema{ - "load_balancer_name": &schema.Schema{ + "load_balancer_name": { Type: schema.TypeString, Required: true, }, - "listener": &schema.Schema{ + "listener": { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeString, Computed: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Computed: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeString, Computed: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Computed: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go index 584c3ee18..6216bf79a 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -18,45 +18,45 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { Read: dataSourceOutscaleOAPILoadBalancerLDsRead, Schema: map[string]*schema.Schema{ - "load_balancer_names": &schema.Schema{ + "load_balancer_names": { Type: schema.TypeList, Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "listener": &schema.Schema{ + "listener": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "listener": &schema.Schema{ + "listener": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "backend_port": &schema.Schema{ + "backend_port": { Type: schema.TypeString, Computed: true, }, - "backend_protocol": &schema.Schema{ + "backend_protocol": { Type: schema.TypeString, Computed: true, }, - "load_balancer_port": &schema.Schema{ + "load_balancer_port": { Type: schema.TypeString, Computed: true, }, - "load_balancer_protocol": &schema.Schema{ + "load_balancer_protocol": { Type: schema.TypeString, Computed: true, }, - "server_certificate_id": &schema.Schema{ + "server_certificate_id": { Type: schema.TypeString, Computed: true, }, }, }, }, - "policy_name": &schema.Schema{ + "policy_name": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -64,7 +64,7 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { }, }, }, - "request_id": &schema.Schema{ + "request_id": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/provider.go b/outscale/provider.go index 206942a9b..56770a3e3 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -75,14 +75,14 @@ func Provider() terraform.ResourceProvider { "outscale_vpn_connection": resourceOutscaleVPNConnection(), "outscale_vpn_connection_route": resourceOutscaleVPNConnectionRoute(), "outscale_access_key": resourceOutscaleAccessKey(), - "outscale_load_balancer": resourceOutscaleOAPILoadBalancer(), - "outscale_load_balancer_cookiepolicy": resourceOutscaleAppCookieStickinessPolicy(), - "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), - "outscale_load_balancer_listeners": resourceOutscaleOAPILoadBalancerListeners(), - "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), - "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), - "outscale_load_balancer_policy": resourceOutscaleOAPILoadBalancerPolicy(), - "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), + "outscale_load_balancer": resourceOutscaleOAPILoadBalancer(), + "outscale_load_balancer_cookiepolicy": resourceOutscaleAppCookieStickinessPolicy(), + "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), + "outscale_load_balancer_listeners": resourceOutscaleOAPILoadBalancerListeners(), + "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), + "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), + "outscale_load_balancer_policy": resourceOutscaleOAPILoadBalancerPolicy(), + "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), }, DataSourcesMap: map[string]*schema.Resource{ "outscale_vm": dataSourceOutscaleOAPIVM(), From cef40739af6182750add0d2f3968c481372e9d62 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 24 Jul 2020 14:07:03 +0200 Subject: [PATCH 064/218] add lbu to datapath + fmt Signed-off-by: Matthias Gatto --- outscale/provider.go | 94 ++++++++++++++++++++++++-------------------- 1 file changed, 51 insertions(+), 43 deletions(-) diff --git a/outscale/provider.go b/outscale/provider.go index 56770a3e3..7f9c9ac16 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -85,49 +85,57 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), }, DataSourcesMap: map[string]*schema.Resource{ - "outscale_vm": dataSourceOutscaleOAPIVM(), - "outscale_vms": datasourceOutscaleOApiVMS(), - "outscale_security_group": dataSourceOutscaleOAPISecurityGroup(), - "outscale_security_groups": dataSourceOutscaleOAPISecurityGroups(), - "outscale_image": dataSourceOutscaleOAPIImage(), - "outscale_images": dataSourceOutscaleOAPIImages(), - "outscale_tag": dataSourceOutscaleOAPITag(), - "outscale_tags": dataSourceOutscaleOAPITags(), - "outscale_public_ip": dataSourceOutscaleOAPIPublicIP(), - "outscale_public_ips": dataSourceOutscaleOAPIPublicIPS(), - "outscale_volume": datasourceOutscaleOAPIVolume(), - "outscale_volumes": datasourceOutscaleOAPIVolumes(), - "outscale_nat_service": dataSourceOutscaleOAPINatService(), - "outscale_nat_services": dataSourceOutscaleOAPINatServices(), - "outscale_keypair": datasourceOutscaleOAPIKeyPair(), - "outscale_keypairs": datasourceOutscaleOAPIKeyPairs(), - "outscale_vm_state": dataSourceOutscaleOAPIVMState(), - "outscale_vms_state": dataSourceOutscaleOAPIVMSState(), - "outscale_internet_service": datasourceOutscaleOAPIInternetService(), - "outscale_internet_services": datasourceOutscaleOAPIInternetServices(), - "outscale_subnet": dataSourceOutscaleOAPISubnet(), - "outscale_subnets": dataSourceOutscaleOAPISubnets(), - "outscale_net": dataSourceOutscaleOAPIVpc(), - "outscale_nets": dataSourceOutscaleOAPIVpcs(), - "outscale_net_attributes": dataSourceOutscaleOAPIVpcAttr(), - "outscale_route_table": dataSourceOutscaleOAPIRouteTable(), - "outscale_route_tables": dataSourceOutscaleOAPIRouteTables(), - "outscale_snapshot": dataSourceOutscaleOAPISnapshot(), - "outscale_snapshots": dataSourceOutscaleOAPISnapshots(), - "outscale_net_peering": dataSourceOutscaleOAPILinPeeringConnection(), - "outscale_net_peerings": dataSourceOutscaleOAPILinPeeringsConnection(), - "outscale_nics": dataSourceOutscaleOAPINics(), - "outscale_nic": dataSourceOutscaleOAPINic(), - "outscale_client_gateway": dataSourceOutscaleClientGateway(), - "outscale_client_gateways": dataSourceOutscaleClientGateways(), - "outscale_virtual_gateway": dataSourceOutscaleOAPIVirtualGateway(), - "outscale_virtual_gateways": dataSourceOutscaleOAPIVirtualGateways(), - "outscale_vpn_connection": dataSourceOutscaleVPNConnection(), - "outscale_vpn_connections": dataSourceOutscaleVPNConnections(), - "outscale_access_key": dataSourceOutscaleAccessKey(), - "outscale_access_keys": dataSourceOutscaleAccessKeys(), - "outscale_dhcp_option": dataSourceOutscaleDHCPOption(), - "outscale_dhcp_options": dataSourceOutscaleDHCPOptions(), + "outscale_vm": dataSourceOutscaleOAPIVM(), + "outscale_vms": datasourceOutscaleOApiVMS(), + "outscale_security_group": dataSourceOutscaleOAPISecurityGroup(), + "outscale_security_groups": dataSourceOutscaleOAPISecurityGroups(), + "outscale_image": dataSourceOutscaleOAPIImage(), + "outscale_images": dataSourceOutscaleOAPIImages(), + "outscale_tag": dataSourceOutscaleOAPITag(), + "outscale_tags": dataSourceOutscaleOAPITags(), + "outscale_public_ip": dataSourceOutscaleOAPIPublicIP(), + "outscale_public_ips": dataSourceOutscaleOAPIPublicIPS(), + "outscale_volume": datasourceOutscaleOAPIVolume(), + "outscale_volumes": datasourceOutscaleOAPIVolumes(), + "outscale_nat_service": dataSourceOutscaleOAPINatService(), + "outscale_nat_services": dataSourceOutscaleOAPINatServices(), + "outscale_keypair": datasourceOutscaleOAPIKeyPair(), + "outscale_keypairs": datasourceOutscaleOAPIKeyPairs(), + "outscale_vm_state": dataSourceOutscaleOAPIVMState(), + "outscale_vms_state": dataSourceOutscaleOAPIVMSState(), + "outscale_internet_service": datasourceOutscaleOAPIInternetService(), + "outscale_internet_services": datasourceOutscaleOAPIInternetServices(), + "outscale_subnet": dataSourceOutscaleOAPISubnet(), + "outscale_subnets": dataSourceOutscaleOAPISubnets(), + "outscale_net": dataSourceOutscaleOAPIVpc(), + "outscale_nets": dataSourceOutscaleOAPIVpcs(), + "outscale_net_attributes": dataSourceOutscaleOAPIVpcAttr(), + "outscale_route_table": dataSourceOutscaleOAPIRouteTable(), + "outscale_route_tables": dataSourceOutscaleOAPIRouteTables(), + "outscale_snapshot": dataSourceOutscaleOAPISnapshot(), + "outscale_snapshots": dataSourceOutscaleOAPISnapshots(), + "outscale_net_peering": dataSourceOutscaleOAPILinPeeringConnection(), + "outscale_net_peerings": dataSourceOutscaleOAPILinPeeringsConnection(), + "outscale_nics": dataSourceOutscaleOAPINics(), + "outscale_nic": dataSourceOutscaleOAPINic(), + "outscale_client_gateway": dataSourceOutscaleClientGateway(), + "outscale_client_gateways": dataSourceOutscaleClientGateways(), + "outscale_virtual_gateway": dataSourceOutscaleOAPIVirtualGateway(), + "outscale_virtual_gateways": dataSourceOutscaleOAPIVirtualGateways(), + "outscale_vpn_connection": dataSourceOutscaleVPNConnection(), + "outscale_vpn_connections": dataSourceOutscaleVPNConnections(), + "outscale_access_key": dataSourceOutscaleAccessKey(), + "outscale_access_keys": dataSourceOutscaleAccessKeys(), + "outscale_dhcp_option": dataSourceOutscaleDHCPOption(), + "outscale_dhcp_options": dataSourceOutscaleDHCPOptions(), + "outscale_load_balancer": dataSourceOutscaleOAPILoadBalancer(), + "outscale_load_balancer_access_logs": dataSourceOutscaleLoadBalancerAccessLogs(), + "outscale_load_balancer_attributes": dataSourceOutscaleOAPILoadBalancerAttr(), + "outscale_load_balancer_health_check": dataSourceOutscaleOAPILoadBalancerHealthCheck(), + "outscale_load_balancer_listener_description": dataSourceOutscaleOAPILoadBalancerLD(), + "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), + "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), + "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, ConfigureFunc: providerConfigureClient, From 6fdcbe06a12551beb810d9a5dd72f836c3e34d5b Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 14 Aug 2020 17:26:34 +0200 Subject: [PATCH 065/218] add datapath for outscale_load_balancer_vms Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 20 +++++-------------- outscale/provider.go | 1 + 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 2e58417c8..d67844f45 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -75,17 +75,11 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "backend_vm_id": { + "backend_vm_ids": { Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "vm_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, + ForceNew: true, + Required: true, + Elem: &schema.Schema{Type: schema.TypeString}, }, "listeners": { Type: schema.TypeList, @@ -250,11 +244,7 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa d.Set("public_dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) - if lb.BackendVmIds != nil { - d.Set("backend_vm_id", lb.BackendVmIds) - } else { - d.Set("backend_vm_id", make([]map[string]interface{}, 0)) - } + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) if lb.Listeners != nil { if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { return err diff --git a/outscale/provider.go b/outscale/provider.go index 7f9c9ac16..8cf0022c2 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -135,6 +135,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_description": dataSourceOutscaleOAPILoadBalancerLD(), "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), + "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, From 0a3a9a22fb4b4876c5aa4d3010eafefc5684b66a Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 14 Aug 2020 17:27:12 +0200 Subject: [PATCH 066/218] it's better with this file Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer_vms.go | 86 +++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_vms.go diff --git a/outscale/data_source_outscale_load_balancer_vms.go b/outscale/data_source_outscale_load_balancer_vms.go new file mode 100644 index 000000000..03438ae27 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_vms.go @@ -0,0 +1,86 @@ +package outscale + +import ( + "context" + "fmt" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" +) + +func dataSourceOutscaleLoadBalancerVms() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleLoadBalancerVmsRead, + Schema: map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + ForceNew: true, + Required: true, + }, + + "backend_vm_ids": { + Type: schema.TypeList, + ForceNew: true, + Required: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + }, + } +} + +func dataSourceOutscaleLoadBalancerVmsRead(d *schema.ResourceData, + meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + e := d.Get("load_balancer_name").(string) + expected := d.Get("backend_vm_ids").([]interface{}) + + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{e}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancersResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Error retrieving LBU: %s", err) + } + + lbs := *resp.LoadBalancers + if len(lbs) != 1 { + return fmt.Errorf("Unable to find LBU: %s", expected) + } + + lb := (lbs)[0] + + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) + + return nil +} From c17090df6ced40a20feb3fed6411910de9c2605a Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 8 Sep 2020 15:42:09 +0200 Subject: [PATCH 067/218] still broken but simplefied listener Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 54 +--- ...source_outscale_load_balancer_listeners.go | 248 ++++++++---------- 2 files changed, 122 insertions(+), 180 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index fbcdc7e8d..c4122d48a 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -103,33 +103,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeSet, Required: true, Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Required: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Required: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - }, + Schema: lb_listener_schema(), }, }, "source_security_group": { @@ -370,6 +344,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } + log.Printf("[DEBUG] read lb.Listeners %v", lb.Listeners) d.Set("load_balancer_name", lb.LoadBalancerName) policies := make(map[string]interface{}) @@ -424,6 +399,8 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa d.Partial(true) + log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") + log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") if d.HasChange("security_groups") || d.HasChange("subregion_names") || d.HasChange("subnets") { log.Printf("[INFO] update Load Balancer: %s", d.Id()) @@ -435,11 +412,13 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerCreate_(d, meta, true) } + log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") if d.HasChange("listeners") { o, n := d.GetChange("listeners") os := o.(*schema.Set).List() ns := n.(*schema.Set).List() + log.Printf("[DEBUG] it change !: %v %v", os, ns) remove, _ := expandListeners(os) add, _ := expandListenerForCreation(ns) @@ -694,27 +673,6 @@ func expandInstanceString(list []interface{}) []string { return result } -// Flattens an array of Listeners into a []map[string]interface{} -func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { - result := make([]map[string]interface{}, 0, len(*list)) - - for _, i := range *list { - listener := map[string]interface{}{ - "backend_port": int(*i.BackendPort), - "backend_protocol": *i.BackendProtocol, - "load_balancer_port": int(*i.LoadBalancerPort), - "load_balancer_protocol": *i.LoadBalancerProtocol, - } - if i.ServerCertificateId != nil { - listener["server_certificate_id"] = - *i.ServerCertificateId - } - listener["policy_name"] = flattenStringList(i.PolicyNames) - result = append(result, listener) - } - return result -} - func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { chk := make(map[string]interface{}) diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index ea589cd54..292394466 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -14,6 +14,39 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) +func lb_listener_schema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "backend_port": { + Type: schema.TypeInt, + Required: true, + }, + "backend_protocol": { + Type: schema.TypeString, + Required: true, + }, + + "load_balancer_port": { + Type: schema.TypeInt, + Required: true, + }, + + "load_balancer_protocol": { + Type: schema.TypeString, + Required: true, + }, + "server_certificate_id": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "policy_names": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + } +} + func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { return &schema.Resource{ Create: resourceOutscaleOAPILoadBalancerListenersCreate, @@ -29,31 +62,7 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { Required: true, ForceNew: true, Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Required: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Required: true, - }, - - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - }, - - "load_balancer_protocol": { - Type: schema.TypeString, - Required: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Optional: true, - Computed: true, - }, - }, + Schema: lb_listener_schema(), }, }, "load_balancer_name": { @@ -61,14 +70,36 @@ func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { Required: true, ForceNew: true, }, - // "request_id": &schema.Schema{ - // Type: schema.TypeString, - // Computed: true, - // }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, }, } } +// Flattens an array of Listeners into a []map[string]interface{} +func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { + result := make([]map[string]interface{}, 0, len(*list)) + + for _, i := range *list { + listener := map[string]interface{}{ + "backend_port": int(*i.BackendPort), + "backend_protocol": *i.BackendProtocol, + "load_balancer_port": int(*i.LoadBalancerPort), + "load_balancer_protocol": *i.LoadBalancerProtocol, + } + log.Printf("[DEBUG] read listener %v", listener, i.PolicyNames) + if i.ServerCertificateId != nil { + listener["server_certificate_id"] = + *i.ServerCertificateId + } + listener["policy_names"] = flattenStringList(i.PolicyNames) + result = append(result, listener) + } + return result +} + func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { listeners := make([]*oscgo.Listener, 0, len(configured)) @@ -86,7 +117,7 @@ func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { LoadBalancerProtocol: &lproto, } - if v, ok := data["ssl_certificate_id"]; ok && v != "" { + if v, ok := data["server_certificate_id"]; ok && v != "" { vs := v.(string) l.ServerCertificateId = &vs } @@ -107,7 +138,7 @@ func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { if valid { listeners = append(listeners, l) } else { - return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") + return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") } } @@ -131,7 +162,7 @@ func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCre LoadBalancerProtocol: lproto, } - if v, ok := data["ssl_certificate_id"]; ok && v != "" { + if v, ok := data["server_certificate_id"]; ok && v != "" { vs := v.(string) l.ServerCertificateId = &vs } @@ -152,7 +183,7 @@ func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCre if valid { listeners = append(listeners, l) } else { - return nil, fmt.Errorf("[ERR] ELB Listener: ssl_certificate_id may be set only when protocol is 'https' or 'ssl'") + return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") } } @@ -211,123 +242,76 @@ func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, met } func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta interface{}) error { - listener, err := expandListeners(d.Get("listeners").(*schema.Set).List()) - if err != nil { - return err - } - - result := make([]map[string]interface{}, 0, len(listener)) - for _, i := range listener { - listener := map[string]interface{}{ - "backend_port": i.BackendPort, - "backend_protocol": i.BackendProtocol, - "load_balancer_port": i.LoadBalancerPort, - "load_balancer_protocol": i.LoadBalancerProtocol, - "server_certificate_id": i.ServerCertificateId, - } - result = append(result, listener) - } - if err := d.Set("listeners", result); err != nil { - return err - } - d.Set("load_balancer_name", d.Id()) - - // d.Set("request_id", describeResp.ResponseMetadata.RequestID) - - return nil -} - -func resourceOutscaleOAPILoadBalancerListenersUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI + ename, ok := d.GetOk("load_balancer_name") - d.Partial(true) + if !ok { + return fmt.Errorf("please provide the name of the load balancer") + } - if d.HasChange("listeners") { - o, n := d.GetChange("listeners") - os := o.(*schema.Set).List() - ns := n.(*schema.Set).List() + elbName := ename.(string) - remove, _ := expandListeners(os) - add, _ := expandListenerForCreation(ns) + // Retrieve the ELB properties for updating the state + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } - if len(remove) > 0 { - ports := make([]int64, 0, len(remove)) - for _, listener := range remove { - ports = append(ports, *listener.LoadBalancerPort) - } + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } - req := oscgo.DeleteLoadBalancerListenersRequest{ - LoadBalancerName: d.Id(), - LoadBalancerPorts: ports, - } + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } - deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ - optional.NewInterface(req), + var resp oscgo.ReadLoadBalancersResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) } + return resource.NonRetryableError(err) + } + return nil + }) - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( - context.Background(), deleteListenersOpts) + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return nil + } - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) + return fmt.Errorf("Error retrieving ELB: %s", err) + } - if err != nil { - return fmt.Errorf("Failure removing outdated ELB listener: %s", err) - } - } + if resp.LoadBalancers == nil { + return fmt.Errorf("NO ELB FOUND") + } - if len(add) > 0 { - req := oscgo.CreateLoadBalancerListenersRequest{ - LoadBalancerName: d.Id(), - Listeners: add, - } + if len(*resp.LoadBalancers) != 1 { + return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) + } - createListenersOpts := &oscgo.CreateLoadBalancerListenersOpts{ - optional.NewInterface(req), - } + lb := (*resp.LoadBalancers)[0] - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - log.Printf("[DEBUG] Load Balancer Create Listeners opts: %v", createListenersOpts) - _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( - context.Background(), createListenersOpts) - if err != nil { - if strings.Contains(fmt.Sprint(err), "DuplicateListener") { - log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "Throttling") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(err) - } - - return resource.NonRetryableError(err) - } - return nil - }) - if err != nil { - return fmt.Errorf("Failure adding new or updated ELB listener: %s", err) - } + log.Printf("[DEBUG] read lb.Listeners %v", lb.Listeners) + if lb.Listeners != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { + log.Printf("[DEBUG] out err %v", err) + return err } - - d.SetPartial("listeners") + } else { + return fmt.Errorf("Something very wrong happen on Load Balancer: %s", elbName) } - d.Partial(false) + d.Set("load_balancer_name", *lb.LoadBalancerName) + d.Set("request_id", *resp.ResponseContext.RequestId) - return resourceOutscaleOAPILoadBalancerListenersRead(d, meta) + return nil } func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { From f8759d57e6ea3dafa9cafe7a3bcc4cdf9ee887cd Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 8 Sep 2020 16:35:14 +0200 Subject: [PATCH 068/218] public_dns_name -> dns_name Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancer.go | 4 ++-- outscale/data_source_outscale_load_balancers.go | 2 +- outscale/resource_outscale_load_balancer.go | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index d67844f45..6db931cc4 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -43,7 +43,7 @@ func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { }, "tag": tagsSchema(), - "public_dns_name": { + "dns_name": { Type: schema.TypeString, Computed: true, }, @@ -241,7 +241,7 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa lb := lbs[0] d.Set("subregion_name", flattenStringList(lb.SubregionNames)) - d.Set("public_dns_name", lb.DnsName) + d.Set("dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index ea312fc3d..0c181e1cd 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -37,7 +37,7 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "public_dns_name": { + "dns_name": { Type: schema.TypeString, Computed: true, }, diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index c4122d48a..9801a9b30 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -59,7 +59,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, "tags": tagsListOAPISchema(), - "public_dns_name": { + "dns_name": { Type: schema.TypeString, Computed: true, }, @@ -326,7 +326,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface lb := (*resp.LoadBalancers)[0] d.Set("subregion_names", flattenStringList(lb.SubregionNames)) - d.Set("public_dns_name", lb.DnsName) + d.Set("dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) if lb.BackendVmIds != nil { From e57ca1c0533ec18dbec1d58bdc185f4d14711262 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 8 Sep 2020 16:38:11 +0200 Subject: [PATCH 069/218] interval -> check_interval Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 9801a9b30..c805f9ae6 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -681,7 +681,7 @@ func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { chk["healthy_threshold"] = strconv.Itoa(int(check.HealthyThreshold)) chk["path"] = check.Path chk["timeout"] = strconv.Itoa(int(check.Timeout)) - chk["interval"] = strconv.Itoa(int(check.CheckInterval)) + chk["check_interval"] = strconv.Itoa(int(check.CheckInterval)) } return chk From ee7267b7f2c599373f3897c5c38486ba311ed5a9 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 8 Sep 2020 16:39:31 +0200 Subject: [PATCH 070/218] vpc_id -> net_id Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index c805f9ae6..cebee59e1 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -122,7 +122,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { }, }, }, - "vpc_id": { + "net_id": { Type: schema.TypeString, Computed: true, }, @@ -388,7 +388,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface } d.Set("source_security_group", ssg) d.Set("subnets", flattenStringList(lb.Subnets)) - d.Set("vpc_id", lb.NetId) + d.Set("net_id", lb.NetId) d.Set("request_id", resp.ResponseContext.RequestId) return nil From bd6fe36c1ff275c2f991154eca978f3f59e414a9 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 8 Sep 2020 17:31:59 +0200 Subject: [PATCH 071/218] heal check: do not crash anymore when a needed variable isn't present Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 3 -- ...rce_outscale_load_balancer_health_check.go | 33 ++++++++++++------- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index cebee59e1..9cbbe4f9b 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -399,8 +399,6 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa d.Partial(true) - log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") - log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") if d.HasChange("security_groups") || d.HasChange("subregion_names") || d.HasChange("subnets") { log.Printf("[INFO] update Load Balancer: %s", d.Id()) @@ -412,7 +410,6 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerCreate_(d, meta, true) } - log.Printf("[DEBUG] resourceOutscaleOAPILoadBalancerUpdate") if d.HasChange("listeners") { o, n := d.GetChange("listeners") os := o.(*schema.Set).List() diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index 069fd6f5e..17d03515e 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -80,6 +80,17 @@ func isLoadBalancerNotFound(err error) bool { return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") } +func lb_atoi_at(hc map[string]interface{}, el string) (int, bool) { + hc_el := hc[el] + + if hc_el == nil { + return 0, false + } + + r, err := strconv.Atoi(hc_el.(string)) + return r, err == nil +} + func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI @@ -96,29 +107,29 @@ func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, m check := hc.(map[string]interface{}) - ht, hterr := strconv.Atoi(check["healthy_threshold"].(string)) - ut, uterr := strconv.Atoi(check["unhealthy_threshold"].(string)) - i, ierr := strconv.Atoi(check["check_interval"].(string)) - t, terr := strconv.Atoi(check["timeout"].(string)) - p, perr := strconv.Atoi(check["port"].(string)) - - if hterr != nil { + ht, ut, sucess := 0, 0, false + if ht, sucess = lb_atoi_at(check, "healthy_threshold"); sucess == false { return fmt.Errorf("please provide an number in health_check.healthy_threshold argument") + } - if uterr != nil { + if ut, sucess = lb_atoi_at(check, "unhealthy_threshold"); sucess == false { return fmt.Errorf("please provide an number in health_check.unhealthy_threshold argument") } - if ierr != nil { + i, ierr := lb_atoi_at(check, "check_interval") + t, terr := lb_atoi_at(check, "timeout") + p, perr := lb_atoi_at(check, "port") + + if ierr != true { return fmt.Errorf("please provide an number in health_check.check_interval argument") } - if terr != nil { + if terr != true { return fmt.Errorf("please provide an number in health_check.timeout argument") } - if perr != nil { + if perr != true { return fmt.Errorf("please provide an number in health_check.port argument") } From cc171c320a394d57f207dc82ac0c5c1f6fb3cf2d Mon Sep 17 00:00:00 2001 From: thiery Date: Thu, 10 Sep 2020 12:40:29 +0000 Subject: [PATCH 072/218] remove debug ligne Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_listeners.go | 1 - 1 file changed, 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 292394466..93a2bcbc9 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -89,7 +89,6 @@ func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { "load_balancer_port": int(*i.LoadBalancerPort), "load_balancer_protocol": *i.LoadBalancerProtocol, } - log.Printf("[DEBUG] read listener %v", listener, i.PolicyNames) if i.ServerCertificateId != nil { listener["server_certificate_id"] = *i.ServerCertificateId From 01f054add9fa2afd9f668dae52b67d17ea87b164 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 11:45:51 +0200 Subject: [PATCH 073/218] LB data path less broken Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 341 ++++++++++-------- outscale/data_source_outscale_vm.go | 1 - 2 files changed, 183 insertions(+), 159 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 6db931cc4..e572d4554 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -3,6 +3,7 @@ package outscale import ( "context" "fmt" + "log" "strings" "time" @@ -13,192 +14,216 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) -func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerRead, - - Schema: map[string]*schema.Schema{ - "subregion_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_type": { - Type: schema.TypeString, - Computed: true, - }, - "security_groups_member": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "subnets_member": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "tag": tagsSchema(), +func attrLBSchema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "subregion_name": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer_name": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "load_balancer_type": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "security_groups_member": { + Type: schema.TypeList, + Computed: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "subnets_member": { + Type: schema.TypeList, + Computed: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "tag": tagsSchema(), - "dns_name": { - Type: schema.TypeString, - Computed: true, - }, - "health_check": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "healthy_threshold": { - Type: schema.TypeString, - Computed: true, - }, - "unhealthy_threshold": { - Type: schema.TypeString, - Computed: true, - }, - "checked_vm": { - Type: schema.TypeString, - Computed: true, - }, - "check_interval": { - Type: schema.TypeString, - Computed: true, - }, - "timeout": { - Type: schema.TypeString, - Computed: true, - }, + "dns_name": { + Type: schema.TypeString, + Computed: true, + Optional: true, + }, + "health_check": { + Type: schema.TypeMap, + Computed: true, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "checked_vm": { + Type: schema.TypeString, + Computed: true, + }, + "check_interval": { + Type: schema.TypeString, + Computed: true, + }, + "timeout": { + Type: schema.TypeString, + Computed: true, }, }, }, - "backend_vm_ids": { - Type: schema.TypeList, - ForceNew: true, - Required: true, - Elem: &schema.Schema{Type: schema.TypeString}, + }, + "backend_vm_ids": { + Type: schema.TypeList, + Computed: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "listeners": { + Type: schema.TypeSet, + Computed: true, + Optional: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), }, - "listeners": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "listener": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Computed: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Computed: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "policy_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, + }, + "firewall_rules_set_name": { + Type: schema.TypeMap, + Computed: true, + Optional: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "firewall_rules_set_name": { + Type: schema.TypeString, + Computed: true, }, - }, - }, - "firewall_rules_set_name": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": { - Type: schema.TypeString, - Computed: true, - }, - "account_alias": { - Type: schema.TypeString, - Computed: true, - }, + "account_alias": { + Type: schema.TypeString, + Computed: true, }, }, }, - "net_id": { - Type: schema.TypeString, - Computed: true, - }, - "policies": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "cookie_name": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, + }, + "net_id": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "policies": { + Type: schema.TypeList, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "application_sticky_cookie_policy": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": { + Type: schema.TypeString, + Computed: true, + }, + "policy_name": { + Type: schema.TypeString, + Computed: true, }, }, }, - "load_balancer_sticky_cookie_policy": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, + }, + "load_balancer_sticky_cookie_policy": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, + Computed: true, }, }, }, }, }, }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, }, } } +func getDataSourceSchemas(attrsSchema map[string]*schema.Schema) map[string]*schema.Schema { + wholeSchema := map[string]*schema.Schema{ + "filter": dataSourceFiltersSchema(), + } + + for k, v := range attrsSchema { + wholeSchema[k] = v + } + + wholeSchema["request_id"] = &schema.Schema{ + Type: schema.TypeString, + Computed: true, + } + + return wholeSchema + +} + +func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerRead, + Schema: getDataSourceSchemas(attrLBSchema()), + } +} + +func buildOutscaleDataSourceLBFilters(set *schema.Set) *oscgo.FiltersLoadBalancer { + filters := new(oscgo.FiltersLoadBalancer) + + for _, v := range set.List() { + m := v.(map[string]interface{}) + filterValues := make([]string, 0) + for _, e := range m["values"].([]interface{}) { + filterValues = append(filterValues, e.(string)) + } + + switch name := m["name"].(string); name { + case "load_balancer_name": + filters.LoadBalancerNames = &filterValues + default: + filters.LoadBalancerNames = &filterValues + log.Printf("[Debug] Unknown Filter Name: %s. default to 'load_balancer_name'", name) + } + } + return filters +} + func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") + ename, nameOk := d.GetOk("load_balancer_name") + filters, filtersOk := d.GetOk("filter") + filter := new(oscgo.FiltersLoadBalancer) - if !ok { - return fmt.Errorf("please provide the name of the load balancer") + if !nameOk && !filtersOk { + return fmt.Errorf("One of filters, or load_balancer_name must be assigned") } - elbName := ename.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, + if filtersOk { + filter = buildOutscaleDataSourceLBFilters(filters.(*schema.Set)) + } else { + elbName := ename.(string) + filter = &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } } + elbName := (*filter.LoadBalancerNames)[0] req := oscgo.ReadLoadBalancersRequest{ Filters: filter, diff --git a/outscale/data_source_outscale_vm.go b/outscale/data_source_outscale_vm.go index 8ae5c4c22..974417022 100644 --- a/outscale/data_source_outscale_vm.go +++ b/outscale/data_source_outscale_vm.go @@ -29,7 +29,6 @@ func dataSourceOutscaleOAPIVMRead(d *schema.ResourceData, meta interface{}) erro if !filtersOk && !instanceIDOk { return fmt.Errorf("One of filters, or instance_id must be assigned") } - // Build up search parameters params := oscgo.ReadVmsRequest{} if filtersOk { From b63b7b66f064aeff3abf588762595e0b44cd3395 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 13:37:28 +0200 Subject: [PATCH 074/218] start nuking deplicated code, and unbrke data path Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 18 ++- ...cale_load_balancer_listener_description.go | 111 ++++-------------- 2 files changed, 37 insertions(+), 92 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index e572d4554..b4fdb82d1 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -205,14 +205,13 @@ func buildOutscaleDataSourceLBFilters(set *schema.Set) *oscgo.FiltersLoadBalance return filters } -func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI +func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBalancersResponse, *string, error) { ename, nameOk := d.GetOk("load_balancer_name") filters, filtersOk := d.GetOk("filter") filter := new(oscgo.FiltersLoadBalancer) if !nameOk && !filtersOk { - return fmt.Errorf("One of filters, or load_balancer_name must be assigned") + return nil, nil, fmt.Errorf("One of filters, or load_balancer_name must be assigned") } if filtersOk { @@ -252,12 +251,21 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa if err != nil { if isLoadBalancerNotFound(err) { d.SetId("") - return nil + return nil, nil, fmt.Errorf("Unknow error") } - return fmt.Errorf("Error retrieving ELB: %s", err) + return nil, nil, fmt.Errorf("Error retrieving ELB: %s", err) } + return &resp, &elbName, nil +} + +func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + resp, elbName, err := readLbs(conn, d) + if err != nil { + return err + } lbs := *resp.LoadBalancers if len(lbs) != 1 { return fmt.Errorf("Unable to find LBU: %s", elbName) diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go index df0c8d097..f1f190ff8 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -13,103 +13,40 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) -func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerLDRead, - - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "listener": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeString, - Computed: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_port": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "policy_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, +func attrLBListenerDesc() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + }, + "listener": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), }, }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, } } -func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - elbName := ename.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), +func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerRead, + Schema: getDataSourceSchemas(attrLBListenerDesc()), } +} - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) +func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + resp, elbName, err := readLbs(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) + return err } - lbs := *resp.LoadBalancers if len(lbs) != 1 { return fmt.Errorf("Unable to find LBU: %s", elbName) From ea3dc05d3007ada441588d3b6deebcc22c40b9c0 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 15:09:25 +0200 Subject: [PATCH 075/218] nuke part 2 Signed-off-by: Matthias Gatto --- ...urce_outscale_load_balancer_access_logs.go | 111 +++++----------- ...ource_outscale_load_balancer_attributes.go | 124 ++++++------------ ...cale_load_balancer_listener_description.go | 8 +- 3 files changed, 76 insertions(+), 167 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go index 357d17f4a..70b96b0a8 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs.go +++ b/outscale/data_source_outscale_load_balancer_access_logs.go @@ -1,100 +1,57 @@ package outscale import ( - "context" "fmt" - "strings" - "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { return &schema.Resource{ - Read: dataSourceOutscaleLoadBalancerAccessLogsRead, + Read: dataSourceOutscaleLoadBalancerAccessLogsRead, + Schema: getDataSourceSchemas(attrLBAccessLogsSchema()), + } +} - Schema: map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeInt, - Computed: true, - }, - "is_enabled": { - Type: schema.TypeBool, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, +func attrLBAccessLogsSchema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, }, } } func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - elbName, ok1 := d.GetOk("load_balancer_name") - - if !ok1 { - return fmt.Errorf("please provide the load_balancer_name required attribute") - } - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName.(string)}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - + resp, elbName, err := readLbs(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving LBU Attr: %s", err) + return err } - lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName.(string)) + return fmt.Errorf("Unable to find LBU: %s", elbName) } lb := (lbs)[0] @@ -112,7 +69,7 @@ func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta i d.Set("osu_bucket_name", a.OsuBucketName) d.Set("osu_bucket_prefix", a.OsuBucketPrefix) - d.SetId(elbName.(string)) + d.SetId(*elbName) d.Set("request_id", resp.ResponseContext.RequestId) return nil diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go index 0fafbf818..01704f2cc 100644 --- a/outscale/data_source_outscale_load_balancer_attributes.go +++ b/outscale/data_source_outscale_load_balancer_attributes.go @@ -1,13 +1,7 @@ package outscale import ( - "context" "fmt" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -15,98 +9,62 @@ import ( func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerAttrRead, + Read: dataSourceOutscaleOAPILoadBalancerAttrRead, + Schema: getDataSourceSchemas(lbAttrAttributes()), + } +} - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_attributes": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "access_log": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeString, - Computed: true, - }, - "is_enabled": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, +func lbAttrAttributes() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + }, + "load_balancer_attributes": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "access_log": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "publication_interval": { + Type: schema.TypeString, + Computed: true, + }, + "is_enabled": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, }, }, }, }, }, }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, }, } } func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - elbName := ename.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) + resp, elbName, err := readLbs(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) + return err } lbs := *resp.LoadBalancers diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go index f1f190ff8..84173fdd1 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -1,13 +1,7 @@ package outscale import ( - "context" "fmt" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" @@ -49,7 +43,7 @@ func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta inter } lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) + return fmt.Errorf("Unable to find LBU: %s", *elbName) } lb := (lbs)[0] From 16f2c06a1695a82847f5b37dd324122c95d3a35f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 15:22:30 +0200 Subject: [PATCH 076/218] nuke refacto of data_source_outscale_load_balancer_health_check.go Signed-off-by: Matthias Gatto --- ...rce_outscale_load_balancer_health_check.go | 113 +++++------------- 1 file changed, 33 insertions(+), 80 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go index f8e1f45a4..d072a86a2 100644 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -1,100 +1,53 @@ package outscale import ( - "context" "fmt" - "strings" - "time" - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { return &schema.Resource{ Read: dataSourceOutscaleOAPILoadBalancerHealthCheckRead, - - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "healthy_threshold": { - Type: schema.TypeInt, - Computed: true, - }, - "unhealthy_threshold": { - Type: schema.TypeInt, - Computed: true, - }, - "path": { - Type: schema.TypeString, - Computed: true, - }, - "check_interval": { - Type: schema.TypeInt, - Computed: true, - }, - "timeout": { - Type: schema.TypeInt, - Computed: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, + Schema: getDataSourceSchemas( + map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Required: true, + }, + "healthy_threshold": { + Type: schema.TypeInt, + Computed: true, + }, + "unhealthy_threshold": { + Type: schema.TypeInt, + Computed: true, + }, + "path": { + Type: schema.TypeString, + Computed: true, + }, + "check_interval": { + Type: schema.TypeInt, + Computed: true, + }, + "timeout": { + Type: schema.TypeInt, + Computed: true, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + }), } } func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - elbName := ename.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - + resp, elbName, err := readLbs(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) + return err } lbs := *resp.LoadBalancers From 9dad750d88be8a470ebdb450917f75d5c4e41291 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 15:50:33 +0200 Subject: [PATCH 077/218] data_source_outscale_load_balancer_listener_descriptions.go refacto nuke Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 18 ++- ...ale_load_balancer_listener_descriptions.go | 119 ++---------------- 2 files changed, 25 insertions(+), 112 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index b4fdb82d1..39a0adf03 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -259,19 +259,25 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala return &resp, &elbName, nil } -func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - +func readLbs0(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.LoadBalancer, *oscgo.ReadLoadBalancersResponse, error) { resp, elbName, err := readLbs(conn, d) if err != nil { - return err + return nil, nil, err } lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) + return nil, nil, fmt.Errorf("Unable to find LBU: %s", elbName) } + return &lbs[0], resp, nil +} - lb := lbs[0] +func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + lb, resp, err := readLbs0(conn, d) + if err != nil { + return err + } d.Set("subregion_name", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go index 6216bf79a..f23ef80b2 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -1,14 +1,6 @@ package outscale import ( - "context" - "fmt" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) @@ -23,45 +15,11 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "listener": { - Type: schema.TypeList, + "listeners": { + Type: schema.TypeSet, Computed: true, Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "listener": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeString, - Computed: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_port": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "policy_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - }, + Schema: lb_listener_schema(), }, }, "request_id": { @@ -74,74 +32,23 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { func dataSourceOutscaleOAPILoadBalancerLDsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - e, ok := d.GetOk("load_balancer_names") - - if !ok { - return fmt.Errorf("please provide the name of the load balancers") - } - - elbName := e.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) + lb, resp, err := readLbs0(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving LBU: %s", err) + return err } - lds := make([]map[string]interface{}, len(*resp.LoadBalancers)) - for k, v1 := range *resp.LoadBalancers { - ld := make(map[string]interface{}) - ls := make([]map[string]interface{}, len(*v1.Listeners)) - - for k1, v2 := range *v1.Listeners { - l := make(map[string]interface{}) - l["backend_port"] = v2.BackendPort - l["backend_protocol"] = v2.BackendProtocol - l["load_balancer_port"] = v2.LoadBalancerPort - l["load_balancer_protocol"] = v2.LoadBalancerProtocol - l["server_certificate_id"] = v2.ServerCertificateId - l["policy_name"] = flattenStringList(v2.PolicyNames) - ls[k1] = l + if lb.Listeners != nil { + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { + return err + } + } else { + if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { + return err } - - ld["listener"] = ls - - lds[k] = ld } - d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) - return d.Set("listener", lds) + return nil } From 4270b65ef55c17f0a700834e3ec855574f93d573 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 15:53:38 +0200 Subject: [PATCH 078/218] fix data_source_outscale_load_balancer_listener_descriptions.go Signed-off-by: Matthias Gatto --- ...ale_load_balancer_listener_descriptions.go | 35 ++++++++++--------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go index f23ef80b2..f79937e2a 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -9,24 +9,25 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { return &schema.Resource{ Read: dataSourceOutscaleOAPILoadBalancerLDsRead, - Schema: map[string]*schema.Schema{ - "load_balancer_names": { - Type: schema.TypeList, - Required: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "listeners": { - Type: schema.TypeSet, - Computed: true, - Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: getDataSourceSchemas( + map[string]*schema.Schema{ + "load_balancer_names": { + Type: schema.TypeList, + Required: true, + Elem: &schema.Schema{Type: schema.TypeString}, }, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, + "listeners": { + Type: schema.TypeSet, + Computed: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), + }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + }), } } From da3e0ad257be1c1be9f8b5a32dd3dd6c67127657 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 15:58:51 +0200 Subject: [PATCH 079/218] nuke refacto: data_source_outscale_load_balancer_tags.go Signed-off-by: Matthias Gatto --- ...data_source_outscale_load_balancer_tags.go | 49 ++----------------- 1 file changed, 3 insertions(+), 46 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index 4fb2a0d2b..7e94a818e 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -1,14 +1,6 @@ package outscale import ( - "context" - "fmt" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) @@ -17,55 +9,20 @@ func dataSourceOutscaleOAPILBUTags() *schema.Resource { return &schema.Resource{ Read: dataSourceOutscaleOAPILBUTagsRead, - Schema: getDSOAPILBUTagsSchema(), + Schema: getDataSourceSchemas(getDSOAPILBUTagsSchema()), } } func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - elbName := d.Get("load_balancer_names").(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - + v, resp, err := readLbs0(conn, d) if err != nil { return err } - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) - } - - v := (lbs)[0] t := make(map[string]interface{}) - t["load_balancer_name"] = elbName + t["load_balancer_name"] = v.LoadBalancerName ta := make([]map[string]interface{}, len(*v.Tags)) for k1, v1 := range *v.Tags { From db730b24cff45c59d045270e1f676bc6e0a36a4a Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 10 Sep 2020 16:11:20 +0200 Subject: [PATCH 080/218] nuke refacto: data_source_outscale_load_balancer_vms.go Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer_vms.go | 55 ++----------------- 1 file changed, 4 insertions(+), 51 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_vms.go b/outscale/data_source_outscale_load_balancer_vms.go index 03438ae27..baddb0add 100644 --- a/outscale/data_source_outscale_load_balancer_vms.go +++ b/outscale/data_source_outscale_load_balancer_vms.go @@ -1,22 +1,13 @@ package outscale import ( - "context" - "fmt" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) func dataSourceOutscaleLoadBalancerVms() *schema.Resource { return &schema.Resource{ Read: dataSourceOutscaleLoadBalancerVmsRead, - Schema: map[string]*schema.Schema{ + Schema: getDataSourceSchemas(map[string]*schema.Schema{ "load_balancer_name": { Type: schema.TypeString, ForceNew: true, @@ -29,7 +20,7 @@ func dataSourceOutscaleLoadBalancerVms() *schema.Resource { Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - }, + }), } } @@ -37,49 +28,11 @@ func dataSourceOutscaleLoadBalancerVmsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - e := d.Get("load_balancer_name").(string) - expected := d.Get("backend_vm_ids").([]interface{}) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{e}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - + lb, _, err := readLbs0(conn, d) if err != nil { - return fmt.Errorf("Error retrieving LBU: %s", err) + return err } - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", expected) - } - - lb := (lbs)[0] - d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) return nil From a625897f4bc6feab01f5bd5d2faced980896228f Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 14 Sep 2020 12:15:44 +0000 Subject: [PATCH 081/218] fixed error messages Signed-off-by: Thiery Ouattara --- outscale/data_source_outscale_load_balancer.go | 2 +- outscale/data_source_outscale_load_balancer_access_logs.go | 2 +- outscale/data_source_outscale_load_balancer_attributes.go | 2 +- outscale/data_source_outscale_load_balancer_health_check.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 39a0adf03..6f1a76d3d 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -266,7 +266,7 @@ func readLbs0(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.LoadBalance } lbs := *resp.LoadBalancers if len(lbs) != 1 { - return nil, nil, fmt.Errorf("Unable to find LBU: %s", elbName) + return nil, nil, fmt.Errorf("Unable to find LBU: %s", *elbName) } return &lbs[0], resp, nil } diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go index 70b96b0a8..7daa3af59 100644 --- a/outscale/data_source_outscale_load_balancer_access_logs.go +++ b/outscale/data_source_outscale_load_balancer_access_logs.go @@ -51,7 +51,7 @@ func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta i } lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) + return fmt.Errorf("Unable to find LBU: %s", *elbName) } lb := (lbs)[0] diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go index 01704f2cc..86f89435a 100644 --- a/outscale/data_source_outscale_load_balancer_attributes.go +++ b/outscale/data_source_outscale_load_balancer_attributes.go @@ -69,7 +69,7 @@ func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta int lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) + return fmt.Errorf("Unable to find LBU: %s", *elbName) } lb := (lbs)[0] diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go index d072a86a2..b6976e9db 100644 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -52,7 +52,7 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, m lbs := *resp.LoadBalancers if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) + return fmt.Errorf("Unable to find LBU: %s", *elbName) } lb := (lbs)[0] From a5d8175d46e192011610a63c68f99e62fd9cb780 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 17 Sep 2020 12:22:36 +0200 Subject: [PATCH 082/218] fix heal check Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 8 +++++++ ...rce_outscale_load_balancer_health_check.go | 22 ++++++++++++++++--- ...source_outscale_load_balancer_listeners.go | 2 -- 3 files changed, 27 insertions(+), 5 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 9cbbe4f9b..7bedfc16d 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -84,6 +84,14 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "port": { + Type: schema.TypeString, + Computed: true, + }, + "protocol": { + Type: schema.TypeString, + Computed: true, + }, "timeout": { Type: schema.TypeString, Computed: true, diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index 17d03515e..c8c5e3438 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -48,6 +48,16 @@ func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { Computed: true, ForceNew: true, }, + "port": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "protocol": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, "check_interval": { Type: schema.TypeString, Optional: true, @@ -235,7 +245,9 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met h := "" i := "" - t := "" + pa := "" + pr := "" + po := "" ti := "" u := "" @@ -244,14 +256,18 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met if lb.HealthCheck.Path != "" { h = strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) i = strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) - t = lb.HealthCheck.Path + pa = lb.HealthCheck.Path + po = strconv.FormatInt(lb.HealthCheck.Port, 10) + pr = lb.HealthCheck.Protocol ti = strconv.FormatInt(lb.HealthCheck.Timeout, 10) u = strconv.FormatInt(lb.HealthCheck.UnhealthyThreshold, 10) } healthCheck["healthy_threshold"] = h healthCheck["check_interval"] = i - healthCheck["path"] = t + healthCheck["path"] = pa + healthCheck["port"] = po + healthCheck["protocol"] = pr healthCheck["timeout"] = ti healthCheck["unhealthy_threshold"] = u diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go index 93a2bcbc9..bddcfe0c2 100644 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ b/outscale/resource_outscale_load_balancer_listeners.go @@ -24,12 +24,10 @@ func lb_listener_schema() map[string]*schema.Schema { Type: schema.TypeString, Required: true, }, - "load_balancer_port": { Type: schema.TypeInt, Required: true, }, - "load_balancer_protocol": { Type: schema.TypeString, Required: true, From 99c688f93d98075708fece08afb344aaf52efdc3 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 17 Sep 2020 14:54:20 +0200 Subject: [PATCH 083/218] resource_outscale_load_balancer_vms.go request id Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_vms.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index f5cc3c06e..74b902822 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -156,7 +156,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac d.SetId("") } - return nil + return d.Set("request_id", *resp.ResponseContext.RequestId) } func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interface{}) error { From c365ef5cab4164848867fce1fb04976ab12d7ca7 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 17 Sep 2020 15:00:54 +0200 Subject: [PATCH 084/218] data_source_outscale_load_balancers.go: public_dns_name -> dns_name Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 0c181e1cd..b55ee40d6 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -263,7 +263,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf l := make(map[string]interface{}) l["subregion_names"] = v.SubregionNames - l["public_dns_name"] = v.DnsName + l["dns_name"] = v.DnsName l["health_check"] = v.HealthCheck l["backend_vm_id"] = v.BackendVmIds l["listeners"] = flattenOAPIListeners(v.Listeners) From db54d95562d37b3b736d188a9f1d55efad2af3c6 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 18 Sep 2020 18:13:21 +0200 Subject: [PATCH 085/218] maybe fix lb destroy --- outscale/resource_outscale_load_balancer.go | 61 +++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 7bedfc16d..f090493c3 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -281,6 +281,51 @@ func flattenStringList(list *[]string) []interface{} { return vs } +func readResourceLb(conn *oscgo.APIClient, elbName string) (*oscgo.LoadBalancer, *oscgo.ReadLoadBalancersResponse, error) { + filter := &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + req := oscgo.ReadLoadBalancersRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadLoadBalancersOpts{ + ReadLoadBalancersRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancersResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return nil, nil, fmt.Errorf("Error retrieving Load Balancer: %s", err) + } + + if resp.LoadBalancers == nil { + return nil, nil, fmt.Errorf("NO Load Balancer FOUND") + } + + if len(*resp.LoadBalancers) != 1 { + return nil, nil, fmt.Errorf("Unable to find Load Balancer: %#v", + elbName) + } + + lb := (*resp.LoadBalancers)[0] + return &lb, &resp, nil +} + func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() @@ -666,6 +711,22 @@ func resourceOutscaleOAPILoadBalancerDelete_(d *schema.ResourceData, meta interf d.SetId("") } + stateConf := &resource.StateChangeConf{ + Pending: []string{"ready"}, + Target: []string{}, + Refresh: func() (interface{}, string, error) { + lb, _, _ := readResourceLb(conn, d.Id()) + if lb == nil { + return nil, "", nil + } + return lb, "ready", nil + }, + Timeout: 5 * time.Minute, + } + if _, err := stateConf.WaitForState(); err != nil { + return fmt.Errorf("Error waiting for load balancer (%s) to become null: %s", d.Id(), err) + } + return nil } From c82601c6cb3a58fe4791213ea816762ffd9aaac7 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 29 Oct 2020 17:28:02 +0100 Subject: [PATCH 086/218] waiting time and error type subnet --- outscale/resource_outscale_load_balancer.go | 1 + outscale/resource_outscale_security_group.go | 10 +++++----- outscale/resource_outscale_subnet.go | 8 ++++++-- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index f090493c3..eb6575105 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -672,6 +672,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerRead(d, meta) } + func resourceOutscaleOAPILoadBalancerDelete(d *schema.ResourceData, meta interface{}) error { return resourceOutscaleOAPILoadBalancerDelete_(d, meta, true) } diff --git a/outscale/resource_outscale_security_group.go b/outscale/resource_outscale_security_group.go index ef8b7b784..9a03f8b08 100644 --- a/outscale/resource_outscale_security_group.go +++ b/outscale/resource_outscale_security_group.go @@ -242,14 +242,14 @@ func resourceOutscaleOAPISecurityGroupDelete(d *schema.ResourceData, meta interf if err != nil { var errString string - if strings.Contains(err.Error(), "RequestLimitExceeded") || strings.Contains(err.Error(), "DependencyViolation") { + if strings.Contains(err.Error(), "RequestLimitExceeded") || + strings.Contains(err.Error(), "DependencyViolation") || + strings.Contains(err.Error(), "Conflict") { return resource.RetryableError(err) - } else if strings.Contains(err.Error(), "InvalidGroup.NotFound") { - return nil + } else if !strings.Contains(err.Error(), "InvalidGroup.NotFound") { + return resource.NonRetryableError(fmt.Errorf("Error on SGStateRefresh: %s", errString)) } - return resource.NonRetryableError(fmt.Errorf("Error on SGStateRefresh: %s", errString)) } - return nil }) } diff --git a/outscale/resource_outscale_subnet.go b/outscale/resource_outscale_subnet.go index 8cd935b7f..864839133 100644 --- a/outscale/resource_outscale_subnet.go +++ b/outscale/resource_outscale_subnet.go @@ -135,10 +135,14 @@ func resourceOutscaleOAPISubNetDelete(d *schema.ResourceData, meta interface{}) SubnetId: id, } var err error - err = resource.Retry(120*time.Second, func() *resource.RetryError { + err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.SubnetApi.DeleteSubnet(context.Background()).DeleteSubnetRequest(req).Execute() if err != nil { - if strings.Contains(err.Error(), "RequestLimitExceeded:") { + if strings.Contains(err.Error(), + "RequestLimitExceeded:") || + strings.Contains(err.Error(), "Conflict") { + log.Printf("[DEBUG] Subnet waiting delete: (%s)", + err) return resource.RetryableError(err) } return resource.NonRetryableError(err) From d678272205f9c511e35555acd92db2980e4eefdb Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 21 Sep 2020 11:37:43 +0200 Subject: [PATCH 087/218] resource_outscale_load_balancer.go: refacto to use readResourceLb Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 48 +-------------------- 1 file changed, 2 insertions(+), 46 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index eb6575105..254b874f6 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -330,54 +330,10 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() - // Retrieve the Load Balancer properties for updating the state - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - + lb, resp, err := readResourceLb(conn, elbName) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving Load Balancer: %s", err) - } - - if resp.LoadBalancers == nil { - return fmt.Errorf("NO Load Balancer FOUND") - } - - if len(*resp.LoadBalancers) != 1 { - return fmt.Errorf("Unable to find Load Balancer: %#v", - elbName) + return err } - - lb := (*resp.LoadBalancers)[0] - d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) From 959652b4406aadf037da03bdaae5c07a6fd2bf88 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 21 Sep 2020 11:48:51 +0200 Subject: [PATCH 088/218] load_balancer_vms.go/_attributes.go: refacto --- ...ource_outscale_load_balancer_attributes.go | 46 +---------------- .../resource_outscale_load_balancer_vms.go | 50 ++----------------- 2 files changed, 5 insertions(+), 91 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index f67c956ec..0adb45419 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -154,53 +154,11 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() - // Retrieve the LBU Attr properties for updating the state - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - + lb_resp, resp, err := readResourceLb(conn, elbName) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving LBU Attr: %s", err) - } - - if resp.LoadBalancers == nil { - return fmt.Errorf("NO ELB FOUND") - } - - if len(*resp.LoadBalancers) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) + return err } - lb_resp := (*resp.LoadBalancers)[0] if lb_resp.AccessLog == nil { return fmt.Errorf("NO Attributes FOUND") } diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 74b902822..2d7427ec3 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -89,58 +89,14 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - + found := false e := d.Get("load_balancer_name").(string) + lb, resp, err := readResourceLb(conn, e) expected := d.Get("backend_vm_ids").([]interface{}) - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{e}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - if err != nil { - /* - if isLoadBalancerNotFound(err) { - log.Printf("[ERROR] LBU %s not found", e) - d.SetId("") - return nil - } - */ - return fmt.Errorf("Error retrieving LBU: %s", err) - } - - found := false - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", expected) + return err } - - lb := (lbs)[0] - for _, v := range *lb.BackendVmIds { for k1 := range expected { sid := expected[k1].(string) From cfe33d3c16d5260efe687d34becb0cf46c508ba3 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 21 Sep 2020 16:09:30 +0200 Subject: [PATCH 089/218] add data_source_outscale_load_balancer_vms_health.go --- .../data_source_outscale_load_balancer_vms.go | 4 +- ...ource_outscale_load_balancer_vms_health.go | 116 ++++++++++++++++++ outscale/provider.go | 1 + 3 files changed, 119 insertions(+), 2 deletions(-) create mode 100644 outscale/data_source_outscale_load_balancer_vms_health.go diff --git a/outscale/data_source_outscale_load_balancer_vms.go b/outscale/data_source_outscale_load_balancer_vms.go index baddb0add..58df7c664 100644 --- a/outscale/data_source_outscale_load_balancer_vms.go +++ b/outscale/data_source_outscale_load_balancer_vms.go @@ -28,12 +28,12 @@ func dataSourceOutscaleLoadBalancerVmsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - lb, _, err := readLbs0(conn, d) + lb, resp, err := readLbs0(conn, d) if err != nil { return err } d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) - + d.Set("request_id", resp.ResponseContext.RequestId) return nil } diff --git a/outscale/data_source_outscale_load_balancer_vms_health.go b/outscale/data_source_outscale_load_balancer_vms_health.go new file mode 100644 index 000000000..655d84ef4 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_vms_health.go @@ -0,0 +1,116 @@ +package outscale + +import ( + "context" + "errors" + "fmt" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" +) + +func dataSourceOutscaleLoadBalancerVmsHeals() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleLoadBalancerVmsHealRead, + Schema: getDataSourceSchemas(map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + ForceNew: true, + Required: true, + }, + + "backend_vm_ids": { + Type: schema.TypeList, + ForceNew: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "backend_vm_health": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "description": { + Type: schema.TypeString, + Computed: true, + }, + "state": { + Type: schema.TypeString, + Computed: true, + }, + "state_reason": { + Type: schema.TypeString, + Computed: true, + }, + "vm_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + }), + } +} + +func dataSourceOutscaleLoadBalancerVmsHealRead(d *schema.ResourceData, + meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + ename, ok := d.GetOk("load_balancer_name") + if ok == false { + return errors.New("load_balancer_name is require") + } + + req := oscgo.ReadVmsHealthRequest{ + LoadBalancerName: ename.(string), + } + + vm_ids, ok := d.GetOk("backend_vm_ids") + if ok { + vm_ids_i := vm_ids.([]interface{}) + vm_ids_s := make([]string, 0, len(vm_ids_i)) + for _, v := range vm_ids_i { + vm_ids_s = append(vm_ids_s, v.(string)) + } + + req.BackendVmIds = &vm_ids_s + } + + describeElbOpts := &oscgo.ReadVmsHealthOpts{ + ReadVmsHealthRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadVmsHealthResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadVmsHealth( + context.Background(), + describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + if isLoadBalancerNotFound(err) { + d.SetId("") + return fmt.Errorf("Unknow error") + } + + return fmt.Errorf("Error retrieving ELB: %s", err) + } + + d.Set("request_id", resp.ResponseContext.RequestId) + return nil +} diff --git a/outscale/provider.go b/outscale/provider.go index 8cf0022c2..63bcc97c7 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -136,6 +136,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), + "outscale_load_balancer_vms_heals": dataSourceOutscaleLoadBalancerVmsHeals(), "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, From 2c98d86489ff2e5c211d35b901949fb65cddd538 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 24 Sep 2020 14:23:20 +0200 Subject: [PATCH 090/218] remove resource_outscale_load_balancer_listeners.go Signed-off-by: Matthias Gatto --- outscale/provider.go | 1 - outscale/resource_outscale_load_balancer.go | 142 +++++++ ...source_outscale_load_balancer_listeners.go | 355 ------------------ 3 files changed, 142 insertions(+), 356 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_listeners.go diff --git a/outscale/provider.go b/outscale/provider.go index 63bcc97c7..31061ddbb 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -78,7 +78,6 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer": resourceOutscaleOAPILoadBalancer(), "outscale_load_balancer_cookiepolicy": resourceOutscaleAppCookieStickinessPolicy(), "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), - "outscale_load_balancer_listeners": resourceOutscaleOAPILoadBalancerListeners(), "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), "outscale_load_balancer_policy": resourceOutscaleOAPILoadBalancerPolicy(), diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 254b874f6..9d6bf740b 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -183,6 +183,148 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { } } +// Flattens an array of Listeners into a []map[string]interface{} +func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { + result := make([]map[string]interface{}, 0, len(*list)) + + for _, i := range *list { + listener := map[string]interface{}{ + "backend_port": int(*i.BackendPort), + "backend_protocol": *i.BackendProtocol, + "load_balancer_port": int(*i.LoadBalancerPort), + "load_balancer_protocol": *i.LoadBalancerProtocol, + } + if i.ServerCertificateId != nil { + listener["server_certificate_id"] = + *i.ServerCertificateId + } + listener["policy_names"] = flattenStringList(i.PolicyNames) + result = append(result, listener) + } + return result +} + +func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { + listeners := make([]*oscgo.Listener, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["backend_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + bproto := data["backend_protocol"].(string) + lproto := data["load_balancer_protocol"].(string) + l := &oscgo.Listener{ + BackendPort: &ip, + BackendProtocol: &bproto, + LoadBalancerPort: &lp, + LoadBalancerProtocol: &lproto, + } + + if v, ok := data["server_certificate_id"]; ok && v != "" { + vs := v.(string) + l.ServerCertificateId = &vs + } + + var valid bool + if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { + // validate the protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.BackendProtocol) == p) || + (strings.ToLower(*l.LoadBalancerProtocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + +func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCreation, error) { + listeners := make([]oscgo.ListenerForCreation, 0, len(configured)) + + for _, lRaw := range configured { + data := lRaw.(map[string]interface{}) + + ip := int64(data["backend_port"].(int)) + lp := int64(data["load_balancer_port"].(int)) + bproto := data["backend_protocol"].(string) + lproto := data["load_balancer_protocol"].(string) + l := oscgo.ListenerForCreation{ + BackendPort: ip, + BackendProtocol: &bproto, + LoadBalancerPort: lp, + LoadBalancerProtocol: lproto, + } + + if v, ok := data["server_certificate_id"]; ok && v != "" { + vs := v.(string) + l.ServerCertificateId = &vs + } + + var valid bool + if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { + // validate the protocol is correct + for _, p := range []string{"https", "ssl"} { + if (strings.ToLower(*l.BackendProtocol) == p) || + (strings.ToLower(l.LoadBalancerProtocol) == p) { + valid = true + } + } + } else { + valid = true + } + + if valid { + listeners = append(listeners, l) + } else { + return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") + } + } + + return listeners, nil +} + +func lb_listener_schema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "backend_port": { + Type: schema.TypeInt, + Required: true, + }, + "backend_protocol": { + Type: schema.TypeString, + Required: true, + }, + "load_balancer_port": { + Type: schema.TypeInt, + Required: true, + }, + "load_balancer_protocol": { + Type: schema.TypeString, + Required: true, + }, + "server_certificate_id": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "policy_names": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + } +} + func resourceOutscaleOAPILoadBalancerCreate(d *schema.ResourceData, meta interface{}) error { return resourceOutscaleOAPILoadBalancerCreate_(d, meta, false) } diff --git a/outscale/resource_outscale_load_balancer_listeners.go b/outscale/resource_outscale_load_balancer_listeners.go deleted file mode 100644 index bddcfe0c2..000000000 --- a/outscale/resource_outscale_load_balancer_listeners.go +++ /dev/null @@ -1,355 +0,0 @@ -package outscale - -import ( - "context" - "fmt" - "log" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func lb_listener_schema() map[string]*schema.Schema { - return map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Required: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Required: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Optional: true, - Computed: true, - }, - "policy_names": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - } -} - -func resourceOutscaleOAPILoadBalancerListeners() *schema.Resource { - return &schema.Resource{ - Create: resourceOutscaleOAPILoadBalancerListenersCreate, - Read: resourceOutscaleOAPILoadBalancerListenersRead, - Delete: resourceOutscaleOAPILoadBalancerListenersDelete, - Importer: &schema.ResourceImporter{ - State: schema.ImportStatePassthrough, - }, - - Schema: map[string]*schema.Schema{ - "listeners": { - Type: schema.TypeSet, - Required: true, - ForceNew: true, - Elem: &schema.Resource{ - Schema: lb_listener_schema(), - }, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - } -} - -// Flattens an array of Listeners into a []map[string]interface{} -func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { - result := make([]map[string]interface{}, 0, len(*list)) - - for _, i := range *list { - listener := map[string]interface{}{ - "backend_port": int(*i.BackendPort), - "backend_protocol": *i.BackendProtocol, - "load_balancer_port": int(*i.LoadBalancerPort), - "load_balancer_protocol": *i.LoadBalancerProtocol, - } - if i.ServerCertificateId != nil { - listener["server_certificate_id"] = - *i.ServerCertificateId - } - listener["policy_names"] = flattenStringList(i.PolicyNames) - result = append(result, listener) - } - return result -} - -func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { - listeners := make([]*oscgo.Listener, 0, len(configured)) - - for _, lRaw := range configured { - data := lRaw.(map[string]interface{}) - - ip := int64(data["backend_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) - bproto := data["backend_protocol"].(string) - lproto := data["load_balancer_protocol"].(string) - l := &oscgo.Listener{ - BackendPort: &ip, - BackendProtocol: &bproto, - LoadBalancerPort: &lp, - LoadBalancerProtocol: &lproto, - } - - if v, ok := data["server_certificate_id"]; ok && v != "" { - vs := v.(string) - l.ServerCertificateId = &vs - } - - var valid bool - if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { - // validate the protocol is correct - for _, p := range []string{"https", "ssl"} { - if (strings.ToLower(*l.BackendProtocol) == p) || - (strings.ToLower(*l.LoadBalancerProtocol) == p) { - valid = true - } - } - } else { - valid = true - } - - if valid { - listeners = append(listeners, l) - } else { - return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") - } - } - - return listeners, nil -} - -func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCreation, error) { - listeners := make([]oscgo.ListenerForCreation, 0, len(configured)) - - for _, lRaw := range configured { - data := lRaw.(map[string]interface{}) - - ip := int64(data["backend_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) - bproto := data["backend_protocol"].(string) - lproto := data["load_balancer_protocol"].(string) - l := oscgo.ListenerForCreation{ - BackendPort: ip, - BackendProtocol: &bproto, - LoadBalancerPort: lp, - LoadBalancerProtocol: lproto, - } - - if v, ok := data["server_certificate_id"]; ok && v != "" { - vs := v.(string) - l.ServerCertificateId = &vs - } - - var valid bool - if l.ServerCertificateId != nil && *l.ServerCertificateId != "" { - // validate the protocol is correct - for _, p := range []string{"https", "ssl"} { - if (strings.ToLower(*l.BackendProtocol) == p) || - (strings.ToLower(l.LoadBalancerProtocol) == p) { - valid = true - } - } - } else { - valid = true - } - - if valid { - listeners = append(listeners, l) - } else { - return nil, fmt.Errorf("[ERR] ELB Listener: server_certificate_id may be set only when protocol is 'https' or 'ssl'") - } - } - - return listeners, nil -} - -func resourceOutscaleOAPILoadBalancerListenersCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - req := oscgo.CreateLoadBalancerListenersRequest{} - - listener, err := expandListenerForCreation(d.Get("listeners").(*schema.Set).List()) - if err != nil { - return err - } - - req.Listeners = listener - - if v, ok := d.GetOk("load_balancer_name"); ok { - req.LoadBalancerName = v.(string) - } - - elbOpts := oscgo.CreateLoadBalancerListenersOpts{ - optional.NewInterface(req), - } - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( - context.Background(), &elbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "DuplicateListener") { - log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "CertificateNotFound") && strings.Contains(fmt.Sprint(err), "Server Certificate not found for the key: arn") { - log.Printf("[DEBUG] SSL Cert not found for given ARN, retrying") - return resource.RetryableError(err) - } - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return err - } - - d.SetId(req.LoadBalancerName) - log.Printf("[INFO] ELB ID: %s", d.Id()) - - return resourceOutscaleOAPILoadBalancerListenersRead(d, meta) -} - -func resourceOutscaleOAPILoadBalancerListenersRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - elbName := ename.(string) - - // Retrieve the ELB properties for updating the state - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) - } - - if resp.LoadBalancers == nil { - return fmt.Errorf("NO ELB FOUND") - } - - if len(*resp.LoadBalancers) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) - } - - lb := (*resp.LoadBalancers)[0] - - log.Printf("[DEBUG] read lb.Listeners %v", lb.Listeners) - if lb.Listeners != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { - log.Printf("[DEBUG] out err %v", err) - return err - } - } else { - return fmt.Errorf("Something very wrong happen on Load Balancer: %s", elbName) - } - - d.Set("load_balancer_name", *lb.LoadBalancerName) - d.Set("request_id", *resp.ResponseContext.RequestId) - - return nil -} - -func resourceOutscaleOAPILoadBalancerListenersDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - remove, _ := expandListeners(d.Get("listeners").(*schema.Set).List()) - - ports := make([]int64, 0, len(remove)) - for _, listener := range remove { - ports = append(ports, *listener.LoadBalancerPort) - } - - req := oscgo.DeleteLoadBalancerListenersRequest{ - LoadBalancerName: d.Id(), - LoadBalancerPorts: ports, - } - - deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ - optional.NewInterface(req), - } - - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( - context.Background(), - deleteListenersOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure removing outdated ELB listener: %s", err) - } - - d.SetId("") - - return nil -} From 1c9bdcef3814d124fab924e8751a8eba182b4532 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 24 Sep 2020 14:14:22 +0200 Subject: [PATCH 091/218] data_source_outscale_load_balancer_vms_health.go --- .../data_source_outscale_load_balancer.go | 5 --- .../data_source_outscale_load_balancer_vms.go | 4 +++ ...ource_outscale_load_balancer_vms_health.go | 34 ++++++++++++++----- outscale/provider.go | 2 +- .../resource_outscale_load_balancer_vms.go | 4 +++ 5 files changed, 35 insertions(+), 14 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 6f1a76d3d..7ff1195ab 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -168,11 +168,6 @@ func getDataSourceSchemas(attrsSchema map[string]*schema.Schema) map[string]*sch wholeSchema[k] = v } - wholeSchema["request_id"] = &schema.Schema{ - Type: schema.TypeString, - Computed: true, - } - return wholeSchema } diff --git a/outscale/data_source_outscale_load_balancer_vms.go b/outscale/data_source_outscale_load_balancer_vms.go index 58df7c664..e7e044f70 100644 --- a/outscale/data_source_outscale_load_balancer_vms.go +++ b/outscale/data_source_outscale_load_balancer_vms.go @@ -20,6 +20,10 @@ func dataSourceOutscaleLoadBalancerVms() *schema.Resource { Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, }), } } diff --git a/outscale/data_source_outscale_load_balancer_vms_health.go b/outscale/data_source_outscale_load_balancer_vms_health.go index 655d84ef4..e1efb7d2d 100644 --- a/outscale/data_source_outscale_load_balancer_vms_health.go +++ b/outscale/data_source_outscale_load_balancer_vms_health.go @@ -4,6 +4,7 @@ import ( "context" "errors" "fmt" + "log" "strings" "time" @@ -54,6 +55,10 @@ func dataSourceOutscaleLoadBalancerVmsHeals() *schema.Resource { }, }, }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, }), } } @@ -94,23 +99,36 @@ func dataSourceOutscaleLoadBalancerVmsHealRead(d *schema.ResourceData, describeElbOpts) if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { + log.Printf("[DEBUG] err: (%s)", err) + if strings.Contains(fmt.Sprint(err), "Throttling:") || + strings.Contains(fmt.Sprint(err), "InvalidResource") || + strings.Contains(fmt.Sprint(err), "Bad Request") { return resource.RetryableError(err) } return resource.NonRetryableError(err) } return nil }) - if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return fmt.Errorf("Unknow error") - } - - return fmt.Errorf("Error retrieving ELB: %s", err) + return fmt.Errorf("Error retrieving Load Balacer Vms Heal: %s", err) } + if resp.BackendVmHealth == nil { + return fmt.Errorf("lb.BackendVmHealth not found") + } + lbvh := make([]map[string]interface{}, len(*resp.BackendVmHealth)) + for k, v := range *resp.BackendVmHealth { + a := make(map[string]interface{}) + a["description"] = v.Description + a["state"] = v.State + a["state_reason"] = v.StateReason + a["vm_id"] = v.VmId + lbvh[k] = a + } + d.Set("backend_vm_health", lbvh) d.Set("request_id", resp.ResponseContext.RequestId) + // ename.(string) "-heal-" resource.UniqueId() + id := ename.(string) + "-heal-" + d.SetId(resource.PrefixedUniqueId(id)) return nil } diff --git a/outscale/provider.go b/outscale/provider.go index 31061ddbb..72eec31e8 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -135,7 +135,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), - "outscale_load_balancer_vms_heals": dataSourceOutscaleLoadBalancerVmsHeals(), + "outscale_load_balancer_vms_health": dataSourceOutscaleLoadBalancerVmsHeals(), "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 2d7427ec3..38d2bd207 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -33,6 +33,10 @@ func resourceOutscaleOAPILBUAttachment() *schema.Resource { Required: true, Elem: &schema.Schema{Type: schema.TypeString}, }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, }, } } From 0b4696bce09586792bd9e97bef12fe4631a1571f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 25 Sep 2020 15:39:11 +0200 Subject: [PATCH 092/218] fix load_balancer_policy Signed-off-by: Matthias Gatto --- outscale/provider.go | 3 +- outscale/resource_outscale_load_balancer.go | 9 + ...rce_outscale_load_balancer_cookiepolicy.go | 26 ++- .../resource_outscale_load_balancer_policy.go | 159 ------------------ 4 files changed, 28 insertions(+), 169 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_policy.go diff --git a/outscale/provider.go b/outscale/provider.go index 72eec31e8..481006f2b 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -76,11 +76,10 @@ func Provider() terraform.ResourceProvider { "outscale_vpn_connection_route": resourceOutscaleVPNConnectionRoute(), "outscale_access_key": resourceOutscaleAccessKey(), "outscale_load_balancer": resourceOutscaleOAPILoadBalancer(), - "outscale_load_balancer_cookiepolicy": resourceOutscaleAppCookieStickinessPolicy(), + "outscale_load_balancer_policy": resourceOutscaleAppCookieStickinessPolicy(), "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), - "outscale_load_balancer_policy": resourceOutscaleOAPILoadBalancerPolicy(), "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), }, DataSourcesMap: map[string]*schema.Resource{ diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 9d6bf740b..f5dcc5a05 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -183,6 +183,15 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { } } +func expandStringList(ifs []interface{}) *[]string { + r := make([]string, len(ifs)) + + for k, v := range ifs { + r[k] = v.(string) + } + return &r +} + // Flattens an array of Listeners into a []map[string]interface{} func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { result := make([]map[string]interface{}, 0, len(*list)) diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_cookiepolicy.go index 72ea07c46..c343d5547 100644 --- a/outscale/resource_outscale_load_balancer_cookiepolicy.go +++ b/outscale/resource_outscale_load_balancer_cookiepolicy.go @@ -34,7 +34,11 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { return }, }, - + "policy_type": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, "load_balancer_name": { Type: schema.TypeString, Required: true, @@ -42,7 +46,7 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { }, "cookie_name": { Type: schema.TypeString, - Required: true, + Optional: true, ForceNew: true, }, "request_id": { @@ -58,17 +62,21 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met l, lok := d.GetOk("load_balancer_name") p, pok := d.GetOk("policy_name") - v, ok := d.GetOk("cookie_name") + v, cnok := d.GetOk("cookie_name") + pt, pok := d.GetOk("policy_type") - if !lok && !pok && !ok { - return fmt.Errorf("please provide the required attributes load_balancer_name, policy_name and cookie_name") + if !lok && !pok && !pok { + return fmt.Errorf("please provide the required attributes load_balancer_name, policy_name and policy_type") } vs := v.(string) req := oscgo.CreateLoadBalancerPolicyRequest{ LoadBalancerName: l.(string), PolicyName: p.(string), - CookieName: &vs, + PolicyType: pt.(string), + } + if cnok { + req.CookieName = &vs } acspOpts := oscgo.CreateLoadBalancerPolicyOpts{ optional.NewInterface(req), @@ -106,8 +114,10 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met d.SetId(resource.UniqueId()) d.Set("load_balancer_name", l.(string)) d.Set("policy_name", p.(string)) - d.Set("cookie_name", v.(string)) - + d.Set("policy_type", pt.(string)) + if cnok { + d.Set("cookie_name", v.(string)) + } return resourceOutscaleAppCookieStickinessPolicyRead(d, meta) } diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go deleted file mode 100644 index c33319c64..000000000 --- a/outscale/resource_outscale_load_balancer_policy.go +++ /dev/null @@ -1,159 +0,0 @@ -package outscale - -import ( - "context" - "fmt" - "log" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func resourceOutscaleOAPILoadBalancerPolicy() *schema.Resource { - return &schema.Resource{ - Create: resourceOutscaleOAPILoadBalancerPolicyCreate, - Read: resourceOutscaleOAPILoadBalancerPolicyRead, - Delete: resourceOutscaleOAPILoadBalancerPolicyDelete, - Importer: &schema.ResourceImporter{ - State: schema.ImportStatePassthrough, - }, - - Schema: map[string]*schema.Schema{ - "policy_names": { - Type: schema.TypeList, - Optional: true, - ForceNew: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Optional: true, - ForceNew: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - } -} - -func expandStringList(ifs []interface{}) *[]string { - r := make([]string, len(ifs)) - - for k, v := range ifs { - r[k] = v.(string) - } - return &r -} - -func resourceOutscaleOAPILoadBalancerPolicyCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - pInput := oscgo.UpdateLoadBalancerRequest{} - - pInput.PolicyNames = expandStringList(d.Get("policy_names").([]interface{})) - - if v, ok := d.GetOk("load_balancer_name"); ok { - pInput.LoadBalancerName = v.(string) - } - - if v, ok := d.GetOk("load_balancer_port"); ok { - port := int64(v.(int)) - pInput.LoadBalancerPort = &port - } - - opts := &oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(pInput), - } - - var err error - var resp oscgo.UpdateLoadBalancerResponse - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), opts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating ELB Policy, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - fmt.Printf("POLICY ERROR:%s", err) - return err - } - - if resp.ResponseContext != nil { - d.Set("request_id", resp.ResponseContext.RequestId) - } - - d.SetId(pInput.LoadBalancerName) - log.Printf("[INFO] ELB Policies Listener ID: %s", d.Id()) - - return nil -} - -func resourceOutscaleOAPILoadBalancerPolicyRead(d *schema.ResourceData, meta interface{}) error { - return nil -} - -func resourceOutscaleOAPILoadBalancerPolicyDelete(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - pInput := oscgo.UpdateLoadBalancerRequest{} - - pols := make([]string, 0) - pInput.PolicyNames = &pols - - if v, ok := d.GetOk("load_balancer_name"); ok { - pInput.LoadBalancerName = v.(string) - } - - if v, ok := d.GetOk("load_balancer_port"); ok { - p := int64(v.(int)) - pInput.LoadBalancerPort = &p - } - - opts := &oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(pInput), - } - - var err error - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), opts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating ELB Policy, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return err - } - - d.SetId("") - - return nil -} From 0ba4df5d47bbdf804e9ca65dc41f41f1e9c20a68 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 25 Sep 2020 17:04:06 +0200 Subject: [PATCH 093/218] resource_outscale_load_balancer_cookiepolicy.go -> resource_outscale_load_balancer_policy.go Signed-off-by: Matthias Gatto --- ...utscale_load_balancer_cookiepolicy_test.go | 187 ------------------ ...resource_outscale_load_balancer_policy.go} | 0 ...urce_outscale_load_balancer_policy_test.go | 187 +++++++++++++++--- 3 files changed, 164 insertions(+), 210 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_cookiepolicy_test.go rename outscale/{resource_outscale_load_balancer_cookiepolicy.go => resource_outscale_load_balancer_policy.go} (100%) diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy_test.go b/outscale/resource_outscale_load_balancer_cookiepolicy_test.go deleted file mode 100644 index dcfd98c2c..000000000 --- a/outscale/resource_outscale_load_balancer_cookiepolicy_test.go +++ /dev/null @@ -1,187 +0,0 @@ -package outscale - -import ( - "context" - "fmt" - "strings" - "testing" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/terraform" -) - -func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { - lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) - - resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, - Steps: []resource.TestStep{ - { - Config: testAccAppCookieStickinessPolicyConfig(lbName), - Check: resource.ComposeTestCheckFunc( - testAccCheckAppCookieStickinessPolicy( - "outscale_load_balancer.lb", - "outscale_load_balancer_cookiepolicy.foo", - ), - ), - }, - { - Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName), - Check: resource.ComposeTestCheckFunc( - testAccCheckAppCookieStickinessPolicy( - "outscale_load_balancer.lb", - "outscale_load_balancer_cookiepolicy.foo", - ), - ), - }, - }, - }) -} - -func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { - lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) - - // check that we can destroy the policy if the LB is missing - removeLB := func() { - conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI - - request := oscgo.DeleteLoadBalancerRequest{ - LoadBalancerName: lbName, - } - - deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ - optional.NewInterface(request), - } - - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer(context.Background(), &deleteElbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - t.Fatalf("Error deleting ELB: %s", err) - } - } - - resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, - Steps: []resource.TestStep{ - { - Config: testAccAppCookieStickinessPolicyConfig(lbName), - Check: resource.ComposeTestCheckFunc( - testAccCheckAppCookieStickinessPolicy( - "outscale_load_balancer.lb", - "outscale_load_balancer_cookiepolicy.foo", - ), - ), - }, - { - PreConfig: removeLB, - Config: testAccAppCookieStickinessPolicyConfigDestroy(lbName), - }, - }, - }) -} - -func testAccCheckAppCookieStickinessPolicyDestroy(s *terraform.State) error { - - for _, rs := range s.RootModule().Resources { - if rs.Type != "outscale_load_balancer_cookiepolicy" { - continue - } - } - return nil -} - -func testAccCheckAppCookieStickinessPolicy(elbResource string, policyResource string) resource.TestCheckFunc { - return func(s *terraform.State) error { - rs, ok := s.RootModule().Resources[elbResource] - if !ok { - return fmt.Errorf("Not found: %s", elbResource) - } - - if rs.Primary.ID == "" { - return fmt.Errorf("No ID is set") - } - - if !ok { - return fmt.Errorf("Not found: %s", policyResource) - } - - return nil - } -} - -func testAccAppCookieStickinessPolicyConfig(rName string) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "lb" { - load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] - listeners { - instance_port = 8000 - instance_protocol = "HTTP" - load_balancer_port = 80 - protocol = "HTTP" - } -} - -resource "outscale_load_balancer_cookiepolicy" "foo" { - policy_name = "foo-policy" - load_balancer_name = "${outscale_load_balancer.lb.id}" - cookie_name = "MyAppCookie" -}`, rName) -} - -// Change the cookie_name to "MyOtherAppCookie". -func testAccAppCookieStickinessPolicyConfigUpdate(rName string) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "lb" { - load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] - listeners { - instance_port = 8000 - instance_protocol = "HTTP" - load_balancer_port = 80 - protocol = "HTTP" - } -} - -resource "outscale_load_balancer_cookiepolicy" "foo" { - policy_name = "foo-policy" - load_balancer_name = "${outscale_load_balancer.lb.id}" - cookie_name = "MyOtherAppCookie" -}`, rName) -} - -// attempt to destroy the policy, but we'll delete the LB in the PreConfig -func testAccAppCookieStickinessPolicyConfigDestroy(rName string) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "lb" { - load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] - listeners { - instance_port = 8000 - instance_protocol = "HTTP" - load_balancer_port = 80 - protocol = "HTTP" - } -}`, rName) -} diff --git a/outscale/resource_outscale_load_balancer_cookiepolicy.go b/outscale/resource_outscale_load_balancer_policy.go similarity index 100% rename from outscale/resource_outscale_load_balancer_cookiepolicy.go rename to outscale/resource_outscale_load_balancer_policy.go diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index de83a9b8b..dcfd98c2c 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -1,46 +1,187 @@ package outscale import ( + "context" + "fmt" + "strings" "testing" + "time" + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" ) -func TestOutscaleOAPILoadBalancerPolicy_basic(t *testing.T) { +func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { + lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) + resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) + PreCheck: func() { testAccPreCheck(t) }, + Providers: testAccProviders, + CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, + Steps: []resource.TestStep{ + { + Config: testAccAppCookieStickinessPolicyConfig(lbName), + Check: resource.ComposeTestCheckFunc( + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), + ), + }, + { + Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName), + Check: resource.ComposeTestCheckFunc( + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), + ), + }, }, - Providers: testAccProviders, - // CheckDestroy: testAccCheckOutscaleLoadBalancerDestroy, + }) +} + +func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { + lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) + + // check that we can destroy the policy if the LB is missing + removeLB := func() { + conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI + + request := oscgo.DeleteLoadBalancerRequest{ + LoadBalancerName: lbName, + } + + deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ + optional.NewInterface(request), + } + + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer(context.Background(), &deleteElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling") { + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + t.Fatalf("Error deleting ELB: %s", err) + } + } + + resource.Test(t, resource.TestCase{ + PreCheck: func() { testAccPreCheck(t) }, + Providers: testAccProviders, + CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, Steps: []resource.TestStep{ { - Config: testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig, + Config: testAccAppCookieStickinessPolicyConfig(lbName), Check: resource.ComposeTestCheckFunc( - resource.TestCheckResourceAttr( - "outscale_load_balancer_policy.outscale_load_balancer_policy", "load_balancer_port", "25"), + testAccCheckAppCookieStickinessPolicy( + "outscale_load_balancer.lb", + "outscale_load_balancer_cookiepolicy.foo", + ), ), }, + { + PreConfig: removeLB, + Config: testAccAppCookieStickinessPolicyConfigDestroy(lbName), + }, }, }) } -const testAccOutscaleOAPILoadBalancerPolicyPrefixNameConfig = ` -resource "outscale_load_balancer" "outscale_load_balancer" { - load_balancer_name = "foobar-terraform-elb" - subregion_names = ["eu-west-2a"] +func testAccCheckAppCookieStickinessPolicyDestroy(s *terraform.State) error { + + for _, rs := range s.RootModule().Resources { + if rs.Type != "outscale_load_balancer_cookiepolicy" { + continue + } + } + return nil +} + +func testAccCheckAppCookieStickinessPolicy(elbResource string, policyResource string) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[elbResource] + if !ok { + return fmt.Errorf("Not found: %s", elbResource) + } + + if rs.Primary.ID == "" { + return fmt.Errorf("No ID is set") + } + + if !ok { + return fmt.Errorf("Not found: %s", policyResource) + } + + return nil + } +} + +func testAccAppCookieStickinessPolicyConfig(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +} + +resource "outscale_load_balancer_cookiepolicy" "foo" { + policy_name = "foo-policy" + load_balancer_name = "${outscale_load_balancer.lb.id}" + cookie_name = "MyAppCookie" +}`, rName) +} + +// Change the cookie_name to "MyOtherAppCookie". +func testAccAppCookieStickinessPolicyConfigUpdate(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +} - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } +resource "outscale_load_balancer_cookiepolicy" "foo" { + policy_name = "foo-policy" + load_balancer_name = "${outscale_load_balancer.lb.id}" + cookie_name = "MyOtherAppCookie" +}`, rName) } -resource "outscale_load_balancer_policy" "outscale_load_balancer_policy" { - load_balancer_name = "${outscale_load_balancer.outscale_load_balancer.load_balancer_name}" - - load_balancer_port = "${outscale_load_balancer.outscale_load_balancer.listeners.0.load_balancer_port}" +// attempt to destroy the policy, but we'll delete the LB in the PreConfig +func testAccAppCookieStickinessPolicyConfigDestroy(rName string) string { + return fmt.Sprintf(` +resource "outscale_load_balancer" "lb" { + load_balancer_name = "%s" + availability_zones = ["eu-west-2a"] + listeners { + instance_port = 8000 + instance_protocol = "HTTP" + load_balancer_port = 80 + protocol = "HTTP" + } +}`, rName) } -` From 3dfa411cf772ddc042f4e349ed4e7a1d595b7139 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 28 Sep 2020 15:04:08 +0200 Subject: [PATCH 094/218] better debug Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_health_check.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go index c8c5e3438..1fdbac5bc 100644 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ b/outscale/resource_outscale_load_balancer_health_check.go @@ -238,7 +238,8 @@ func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, met } if len(*resp.LoadBalancers) != 1 { - return fmt.Errorf("Unable to find ELB: %#v", resp.LoadBalancers) + return fmt.Errorf("Unable to find ELB %s: %#v", elbName, + resp.LoadBalancers) } lb := (*resp.LoadBalancers)[0] From d6d3a276ee195c353a2266ce16dad95492cce18d Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 29 Sep 2020 16:22:37 +0200 Subject: [PATCH 095/218] resource_outscale_load_balancer_ssl_certificate.go Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_ssl_certificate.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate.go b/outscale/resource_outscale_load_balancer_ssl_certificate.go index 712cbd0e2..e9daae60a 100644 --- a/outscale/resource_outscale_load_balancer_ssl_certificate.go +++ b/outscale/resource_outscale_load_balancer_ssl_certificate.go @@ -64,11 +64,12 @@ func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData if !sok { return fmt.Errorf("please provide server_certificate_id argument") } - port_i := port.(int64) + port_i := port.(int) + port_i64 := int64(port_i) ssl_s := ssl.(string) req := oscgo.UpdateLoadBalancerRequest{ LoadBalancerName: ename.(string), - LoadBalancerPort: &port_i, + LoadBalancerPort: &port_i64, ServerCertificateId: &ssl_s, } From dd326d3eef7ee04cd1d721038a47a280c68ad412 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Thu, 1 Oct 2020 10:06:12 +0000 Subject: [PATCH 096/218] rename redundant variable Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_policy.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index c343d5547..43ad98b6c 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -61,11 +61,11 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met conn := meta.(*OutscaleClient).OSCAPI l, lok := d.GetOk("load_balancer_name") - p, pok := d.GetOk("policy_name") + p, pon := d.GetOk("policy_name") v, cnok := d.GetOk("cookie_name") - pt, pok := d.GetOk("policy_type") + pt, pot := d.GetOk("policy_type") - if !lok && !pok && !pok { + if !lok && !pon && !pot { return fmt.Errorf("please provide the required attributes load_balancer_name, policy_name and policy_type") } From b36092c0aa9a975ce7b96c5f289e6dd5658f12d8 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 1 Oct 2020 14:06:57 +0200 Subject: [PATCH 097/218] merge everything into attribute Signed-off-by: Matthias Gatto --- outscale/provider.go | 1 - ...ource_outscale_load_balancer_attributes.go | 123 +++++++------ ..._outscale_load_balancer_ssl_certificate.go | 166 ------------------ 3 files changed, 59 insertions(+), 231 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_ssl_certificate.go diff --git a/outscale/provider.go b/outscale/provider.go index 481006f2b..49a01da23 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -80,7 +80,6 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), - "outscale_load_balancer_ssl_certificate": resourceOutscaleOAPILoadBalancerSSLCertificate(), }, DataSourcesMap: map[string]*schema.Resource{ "outscale_vm": dataSourceOutscaleOAPIVM(), diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 0adb45419..1711b38fc 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -30,46 +30,31 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Type: schema.TypeInt, Optional: true, }, - "is_enabled": { - Type: schema.TypeBool, - Required: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, + "load_balancer_port": { + Type: schema.TypeInt, Optional: true, + ForceNew: true, }, - "osu_bucket_prefix": { + "server_certificate_id": { Type: schema.TypeString, Optional: true, }, - "load_balancer_attributes": { - Type: schema.TypeList, - Computed: true, + "access_log": { + Type: schema.TypeMap, + Optional: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "access_log": { - Type: schema.TypeMap, + "is_enabled": { + Type: schema.TypeBool, Required: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeInt, - Computed: true, - }, - "is_enabled": { - Type: schema.TypeBool, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Optional: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Optional: true, }, }, }, @@ -90,36 +75,49 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - v, ok := d.GetOk("is_enabled") - v1, ok1 := d.GetOk("load_balancer_name") + ename, ok := d.GetOk("load_balancer_name") - if !ok && !ok1 { + if !ok { return fmt.Errorf("please provide the is_enabled and load_balancer_name required attributes") } req := oscgo.UpdateLoadBalancerRequest{ - LoadBalancerName: v1.(string), + LoadBalancerName: ename.(string), } - is_enable := v.(bool) - access := &oscgo.AccessLog{ - IsEnabled: &is_enable, - } - - if v, ok := d.GetOk("publication_interval"); ok { - pi := int64(v.(int)) - access.PublicationInterval = &pi - } - if v, ok := d.GetOk("osu_bucket_name"); ok { - obn := v.(string) - access.OsuBucketName = &obn + if port, pok := d.GetOk("load_balancer_port"); pok { + port_i := int64(port.(int)) + req.LoadBalancerPort = &port_i } - if v, ok := d.GetOk("osu_bucket_prefix"); ok { - obp := v.(string) - access.OsuBucketPrefix = &obp + if ssl, sok := d.GetOk("server_certificate_id"); sok { + ssl_s := ssl.(string) + req.ServerCertificateId = &ssl_s } - req.AccessLog = access + if al, alok := d.GetOk("access_log"); alok { + dal := al.(map[string]interface{}) + + is_enable := dal["is_enable"].(bool) + access := &oscgo.AccessLog{ + IsEnabled: &is_enable, + } + + if v, ok := lb_atoi_at(dal, "publication_interval"); ok { + pi := int64(v) + access.PublicationInterval = &pi + } + obn := dal["osu_bucket_name"] + if obn != nil { + obn_s := obn.(string) + access.OsuBucketName = &obn_s + } + obp := dal["osu_bucket_prefix"] + if obp != nil { + obp_s := obp.(string) + access.OsuBucketPrefix = &obp_s + } + req.AccessLog = access + } elbOpts := oscgo.UpdateLoadBalancerOpts{ optional.NewInterface(req), @@ -165,20 +163,17 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta a := lb_resp.AccessLog - access := make(map[string]string) - ac := make(map[string]interface{}) - access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) - access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) - access["osu_bucket_name"] = *a.OsuBucketName - access["osu_bucket_prefix"] = *a.OsuBucketPrefix - ac["access_log"] = access - - l := make([]map[string]interface{}, 1) - l[0] = ac + if a != nil { + access := make(map[string]string) + access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) + access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) + access["osu_bucket_name"] = *a.OsuBucketName + access["osu_bucket_prefix"] = *a.OsuBucketPrefix + d.Set("access_log", access) + } d.Set("request_id", resp.ResponseContext.RequestId) - - return d.Set("load_balancer_attributes", l) + return nil } func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, meta interface{}) error { diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate.go b/outscale/resource_outscale_load_balancer_ssl_certificate.go deleted file mode 100644 index e9daae60a..000000000 --- a/outscale/resource_outscale_load_balancer_ssl_certificate.go +++ /dev/null @@ -1,166 +0,0 @@ -package outscale - -import ( - "context" - "fmt" - "strings" - "time" - - "github.com/antihax/optional" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" - oscgo "github.com/marinsalinas/osc-sdk-go" -) - -func resourceOutscaleOAPILoadBalancerSSLCertificate() *schema.Resource { - return &schema.Resource{ - Read: resourceOutscaleOAPILoadBalancerSSLCertificateRead, - Create: resourceOutscaleOAPILoadBalancerSSLCertificateCreate, - Update: resourceOutscaleOAPILoadBalancerSSLCertificateUpdate, - Importer: &schema.ResourceImporter{ - State: schema.ImportStatePassthrough, - }, - Delete: resourceOutscaleOAPILoadBalancerSSLCertificateDelete, - - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - ForceNew: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Required: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - } -} - -func resourceOutscaleOAPILoadBalancerSSLCertificateCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - ename, ok := d.GetOk("load_balancer_name") - port, pok := d.GetOk("load_balancer_port") - ssl, sok := d.GetOk("server_certificate_id") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - if !pok { - return fmt.Errorf("please provide the load_balancer_port argument") - } - - if !sok { - return fmt.Errorf("please provide server_certificate_id argument") - } - port_i := port.(int) - port_i64 := int64(port_i) - ssl_s := ssl.(string) - req := oscgo.UpdateLoadBalancerRequest{ - LoadBalancerName: ename.(string), - LoadBalancerPort: &port_i64, - ServerCertificateId: &ssl_s, - } - - opts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } - - var err error - var resp = oscgo.UpdateLoadBalancerResponse{} - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &opts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) - } - - if resp.ResponseContext != nil { - d.Set("request_id", resp.ResponseContext.RequestId) - } - - d.SetId(ename.(string)) - - return resourceOutscaleOAPILoadBalancerSSLCertificateRead(d, meta) -} - -func resourceOutscaleOAPILoadBalancerSSLCertificateUpdate(d *schema.ResourceData, meta interface{}) error { - if !d.HasChange("server_certificate_id") { - return nil - } - - conn := meta.(*OutscaleClient).OSCAPI - - port := d.Get("load_balancer_port").(int64) - ssl := d.Get("server_certificate_id").(string) - - req := oscgo.UpdateLoadBalancerRequest{ - LoadBalancerName: d.Get("load_balancer_name").(string), - LoadBalancerPort: &port, - ServerCertificateId: &ssl, - } - - opts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } - - var err error - var resp = oscgo.UpdateLoadBalancerResponse{} - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &opts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure setting Load Balancer Listeners SSL Certificate for LBU: %s", err) - } - - if resp.ResponseContext != nil { - d.Set("request_id", resp.ResponseContext.RequestId) - } - - d.SetId(req.LoadBalancerName) - - return resourceOutscaleOAPILoadBalancerSSLCertificateRead(d, meta) -} - -func resourceOutscaleOAPILoadBalancerSSLCertificateRead(d *schema.ResourceData, meta interface{}) error { - return nil -} - -func resourceOutscaleOAPILoadBalancerSSLCertificateDelete(d *schema.ResourceData, meta interface{}) error { - d.SetId("") - - return nil -} From 66b6623df692feedfdb62b8a17e7aa637480cd24 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 1 Oct 2020 18:13:34 +0200 Subject: [PATCH 098/218] make update superflous and add policy_names Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 91 ++++--------------- 1 file changed, 19 insertions(+), 72 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 1711b38fc..62474c48d 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -19,7 +19,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { return &schema.Resource{ Create: resourceOutscaleOAPILoadBalancerAttributesCreate, Read: resourceOutscaleOAPILoadBalancerAttributesRead, - Update: resourceOutscaleOAPILoadBalancerAttributesUpdate, Delete: resourceOutscaleOAPILoadBalancerAttributesDelete, Importer: &schema.ResourceImporter{ State: schema.ImportStatePassthrough, @@ -29,6 +28,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "publication_interval": { Type: schema.TypeInt, Optional: true, + ForceNew: true, }, "load_balancer_port": { Type: schema.TypeInt, @@ -38,10 +38,12 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "server_certificate_id": { Type: schema.TypeString, Optional: true, + ForceNew: true, }, "access_log": { Type: schema.TypeMap, Optional: true, + ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "is_enabled": { @@ -64,6 +66,12 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Required: true, ForceNew: true, }, + "policy_names": { + Type: schema.TypeList, + ForceNew: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, "request_id": { Type: schema.TypeString, Computed: true, @@ -89,11 +97,21 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me port_i := int64(port.(int)) req.LoadBalancerPort = &port_i } + if ssl, sok := d.GetOk("server_certificate_id"); sok { ssl_s := ssl.(string) req.ServerCertificateId = &ssl_s } + if pol_names, plnok := d.GetOk("policy_names"); plnok { + m := pol_names.([]interface{}) + a := make([]string, len(m)) + for k, v := range m { + a[k] = v.(string) + } + req.PolicyNames = &a + } + if al, alok := d.GetOk("access_log"); alok { dal := al.(map[string]interface{}) @@ -176,77 +194,6 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta return nil } -func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - req := oscgo.UpdateLoadBalancerRequest{} - access := &oscgo.AccessLog{} - if d.HasChange("load_balancer_name") { - _, n := d.GetChange("load_balancer_name") - - req.LoadBalancerName = n.(string) - } - if d.HasChange("is_enabled") { - _, n := d.GetChange("is_enabled") - - b, err := strconv.ParseBool(n.(string)) - if err != nil { - return err - } - - access.IsEnabled = &b - } - if d.HasChange("publication_interval") { - _, n := d.GetChange("publication_interval") - - i, err := strconv.Atoi(n.(string)) - if err != nil { - return err - } - i64 := int64(i) - access.PublicationInterval = &i64 - } - if d.HasChange("osu_bucket_name") { - _, n := d.GetChange("osu_bucket_name") - - s := n.(string) - access.OsuBucketName = &s - } - if d.HasChange("osu_bucket_prefix") { - _, n := d.GetChange("osu_bucket_prefix") - - s := n.(string) - access.OsuBucketPrefix = &s - } - - req.AccessLog = access - - elbOpts := &oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } - - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), elbOpts) - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return err - } - - return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) -} - func resourceOutscaleOAPILoadBalancerAttributesDelete(d *schema.ResourceData, meta interface{}) error { d.SetId("") From 12c839ebaf6084db72a6af985c34260f45c3650c Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 2 Oct 2020 17:39:50 +0200 Subject: [PATCH 099/218] finish merged Signed-off-by: Matthias Gatto --- outscale/provider.go | 1 - ...ource_outscale_load_balancer_attributes.go | 133 +++++++- ...rce_outscale_load_balancer_health_check.go | 290 ------------------ 3 files changed, 130 insertions(+), 294 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_health_check.go diff --git a/outscale/provider.go b/outscale/provider.go index 49a01da23..2cf519f76 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -79,7 +79,6 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_policy": resourceOutscaleAppCookieStickinessPolicy(), "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), - "outscale_load_balancer_health_check": resourceOutscaleOAPILoadBalancerHealthCheck(), }, DataSourcesMap: map[string]*schema.Resource{ "outscale_vm": dataSourceOutscaleOAPIVM(), diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 62474c48d..43e9113bc 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -61,6 +61,55 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, + "health_check": { + Type: schema.TypeMap, + Optional: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "unhealthy_threshold": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "path": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "port": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "protocol": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "check_interval": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "timeout": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + }, + }, + }, "load_balancer_name": { Type: schema.TypeString, Required: true, @@ -80,6 +129,21 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { } } +func isLoadBalancerNotFound(err error) bool { + return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") +} + +func lb_atoi_at(hc map[string]interface{}, el string) (int, bool) { + hc_el := hc[el] + + if hc_el == nil { + return 0, false + } + + r, err := strconv.Atoi(hc_el.(string)) + return r, err == nil +} + func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI @@ -137,6 +201,47 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me req.AccessLog = access } + hc, hok := d.GetOk("health_check") + if hok { + check := hc.(map[string]interface{}) + + ht, ut, sucess := 0, 0, false + if ht, sucess = lb_atoi_at(check, "healthy_threshold"); sucess == false { + return fmt.Errorf("please provide an number in health_check.healthy_threshold argument") + + } + + if ut, sucess = lb_atoi_at(check, "unhealthy_threshold"); sucess == false { + return fmt.Errorf("please provide an number in health_check.unhealthy_threshold argument") + } + + i, ierr := lb_atoi_at(check, "check_interval") + t, terr := lb_atoi_at(check, "timeout") + p, perr := lb_atoi_at(check, "port") + + if ierr != true { + return fmt.Errorf("please provide an number in health_check.check_interval argument") + } + + if terr != true { + return fmt.Errorf("please provide an number in health_check.timeout argument") + } + + if perr != true { + return fmt.Errorf("please provide an number in health_check.port argument") + } + + var hc_req oscgo.HealthCheck + hc_req.HealthyThreshold = int64(ht) + hc_req.UnhealthyThreshold = int64(ut) + hc_req.CheckInterval = int64(i) + hc_req.Protocol = check["protocol"].(string) + hc_req.Port = int64(p) + hc_req.Timeout = int64(t) + req.HealthCheck = &hc_req + + } + elbOpts := oscgo.UpdateLoadBalancerOpts{ optional.NewInterface(req), } @@ -170,16 +275,16 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() - lb_resp, resp, err := readResourceLb(conn, elbName) + lb, resp, err := readResourceLb(conn, elbName) if err != nil { return err } - if lb_resp.AccessLog == nil { + if lb.AccessLog == nil { return fmt.Errorf("NO Attributes FOUND") } - a := lb_resp.AccessLog + a := lb.AccessLog if a != nil { access := make(map[string]string) @@ -190,6 +295,28 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } + healthCheck := make(map[string]interface{}) + + if lb.HealthCheck.Path != "" { + h := strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) + i := strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) + pa := lb.HealthCheck.Path + po := strconv.FormatInt(lb.HealthCheck.Port, 10) + pr := lb.HealthCheck.Protocol + ti := strconv.FormatInt(lb.HealthCheck.Timeout, 10) + u := strconv.FormatInt(lb.HealthCheck.UnhealthyThreshold, 10) + + healthCheck["healthy_threshold"] = h + healthCheck["check_interval"] = i + healthCheck["path"] = pa + healthCheck["port"] = po + healthCheck["protocol"] = pr + healthCheck["timeout"] = ti + healthCheck["unhealthy_threshold"] = u + + d.Set("health_check", healthCheck) + } + d.Set("request_id", resp.ResponseContext.RequestId) return nil } diff --git a/outscale/resource_outscale_load_balancer_health_check.go b/outscale/resource_outscale_load_balancer_health_check.go deleted file mode 100644 index 1fdbac5bc..000000000 --- a/outscale/resource_outscale_load_balancer_health_check.go +++ /dev/null @@ -1,290 +0,0 @@ -package outscale - -import ( - "context" - "fmt" - "strconv" - "strings" - "time" - - "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func resourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { - return &schema.Resource{ - Read: resourceOutscaleOAPILoadBalancerHealthCheckRead, - Create: resourceOutscaleOAPILoadBalancerHealthCheckCreate, - Importer: &schema.ResourceImporter{ - State: schema.ImportStatePassthrough, - }, - Delete: resourceOutscaleOAPILoadBalancerHealthCheckDelete, - - Schema: map[string]*schema.Schema{ - "health_check": { - Type: schema.TypeMap, - Required: true, - ForceNew: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "healthy_threshold": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - }, - "unhealthy_threshold": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - }, - "path": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - }, - "port": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "protocol": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "check_interval": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - }, - "timeout": { - Type: schema.TypeString, - Optional: true, - Computed: true, - ForceNew: true, - }, - }, - }, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - } -} - -func isLoadBalancerNotFound(err error) bool { - return strings.Contains(fmt.Sprint(err), "LoadBalancerNotFound") -} - -func lb_atoi_at(hc map[string]interface{}, el string) (int, bool) { - hc_el := hc[el] - - if hc_el == nil { - return 0, false - } - - r, err := strconv.Atoi(hc_el.(string)) - return r, err == nil -} - -func resourceOutscaleOAPILoadBalancerHealthCheckCreate(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - ename, ok := d.GetOk("load_balancer_name") - hc, hok := d.GetOk("health_check") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - if !hok { - return fmt.Errorf("please provide health check values") - } - - check := hc.(map[string]interface{}) - - ht, ut, sucess := 0, 0, false - if ht, sucess = lb_atoi_at(check, "healthy_threshold"); sucess == false { - return fmt.Errorf("please provide an number in health_check.healthy_threshold argument") - - } - - if ut, sucess = lb_atoi_at(check, "unhealthy_threshold"); sucess == false { - return fmt.Errorf("please provide an number in health_check.unhealthy_threshold argument") - } - - i, ierr := lb_atoi_at(check, "check_interval") - t, terr := lb_atoi_at(check, "timeout") - p, perr := lb_atoi_at(check, "port") - - if ierr != true { - return fmt.Errorf("please provide an number in health_check.check_interval argument") - } - - if terr != true { - return fmt.Errorf("please provide an number in health_check.timeout argument") - } - - if perr != true { - return fmt.Errorf("please provide an number in health_check.port argument") - } - - req := oscgo.UpdateLoadBalancerRequest{ - LoadBalancerName: ename.(string), - HealthCheck: &oscgo.HealthCheck{ - HealthyThreshold: int64(ht), - UnhealthyThreshold: int64(ut), - CheckInterval: int64(i), - Protocol: check["protocol"].(string), - Port: int64(p), - Timeout: int64(t), - }, - } - if check["path"] != nil { - req.HealthCheck.Path = check["path"].(string) - } - - configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } - - var err error - - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &configureHealthCheckOpts) - - if err != nil { - if strings.Contains(err.Error(), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - return fmt.Errorf("Failure configuring health check for ELB: %s", err) - } - - d.SetId(ename.(string)) - - return resourceOutscaleOAPILoadBalancerHealthCheckRead(d, meta) -} - -func resourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - ename, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("please provide the name of the load balancer") - } - - elbName := ename.(string) - - // Retrieve the ELB properties for updating the state - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, - } - - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) - } - - if resp.LoadBalancers == nil { - return fmt.Errorf("NO ELB FOUND") - } - - if len(*resp.LoadBalancers) != 1 { - return fmt.Errorf("Unable to find ELB %s: %#v", elbName, - resp.LoadBalancers) - } - - lb := (*resp.LoadBalancers)[0] - - h := "" - i := "" - pa := "" - pr := "" - po := "" - ti := "" - u := "" - - healthCheck := make(map[string]interface{}) - - if lb.HealthCheck.Path != "" { - h = strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) - i = strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) - pa = lb.HealthCheck.Path - po = strconv.FormatInt(lb.HealthCheck.Port, 10) - pr = lb.HealthCheck.Protocol - ti = strconv.FormatInt(lb.HealthCheck.Timeout, 10) - u = strconv.FormatInt(lb.HealthCheck.UnhealthyThreshold, 10) - } - - healthCheck["healthy_threshold"] = h - healthCheck["check_interval"] = i - healthCheck["path"] = pa - healthCheck["port"] = po - healthCheck["protocol"] = pr - healthCheck["timeout"] = ti - healthCheck["unhealthy_threshold"] = u - - d.Set("health_check", healthCheck) - d.Set("load_balancer_name", *lb.LoadBalancerName) - - reqID := "" - if resp.ResponseContext != nil { - reqID = *resp.ResponseContext.RequestId - } - - return d.Set("request_id", reqID) -} - -func resourceOutscaleOAPILoadBalancerHealthCheckDelete(d *schema.ResourceData, meta interface{}) error { - d.SetId("") - - return nil -} From c25cf3f99e365910b5ebf3edf82bd3d047d02fb6 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 9 Oct 2020 18:04:08 +0200 Subject: [PATCH 100/218] resource_outscale_internet_service.go: remove crash if resp.GetInternetServices is nil Signed-off-by: Matthias Gatto --- outscale/resource_outscale_internet_service.go | 4 ++++ outscale/resource_outscale_subnet.go | 1 + 2 files changed, 5 insertions(+) diff --git a/outscale/resource_outscale_internet_service.go b/outscale/resource_outscale_internet_service.go index 1cfeadc0b..f68d1e1e2 100644 --- a/outscale/resource_outscale_internet_service.go +++ b/outscale/resource_outscale_internet_service.go @@ -103,6 +103,10 @@ func resourceOutscaleOAPIInternetServiceRead(d *schema.ResourceData, meta interf if err := d.Set("request_id", resp.ResponseContext.GetRequestId()); err != nil { return err } + if len(resp.GetInternetServices()) == 0 { + d.SetId("") + return fmt.Errorf("InternetServices not found") + } if err := d.Set("internet_service_id", resp.GetInternetServices()[0].GetInternetServiceId()); err != nil { return err } diff --git a/outscale/resource_outscale_subnet.go b/outscale/resource_outscale_subnet.go index 864839133..3a48e510f 100644 --- a/outscale/resource_outscale_subnet.go +++ b/outscale/resource_outscale_subnet.go @@ -199,6 +199,7 @@ func readOutscaleOAPISubNet(d *schema.ResourceData, subnet *oscgo.Subnet) error } return d.Set("tags", tagsOSCAPIToMap(subnet.GetTags())) } + func SubnetStateOApiRefreshFunc(conn *oscgo.APIClient, subnetID string) resource.StateRefreshFunc { return func() (interface{}, string, error) { resp, _, err := conn.SubnetApi.ReadSubnets(context.Background()).ReadSubnetsRequest(oscgo.ReadSubnetsRequest{ From baff8f3a69b97c3375044dc80dfc9bb21c7ce641 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 12 Oct 2020 15:01:26 +0200 Subject: [PATCH 101/218] fix TPD 1919 Signed-off-by: Matthias Gatto --- ...resource_outscale_internet_service_link.go | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/outscale/resource_outscale_internet_service_link.go b/outscale/resource_outscale_internet_service_link.go index 677570810..26df4c1c3 100644 --- a/outscale/resource_outscale_internet_service_link.go +++ b/outscale/resource_outscale_internet_service_link.go @@ -185,22 +185,17 @@ func resourceOutscaleOAPIInternetServiceLinkDelete(d *schema.ResourceData, meta NetId: internetService.GetNetId(), } - err = resource.Retry(60*time.Second, func() *resource.RetryError { - _, res, err := conn.InternetServiceApi.UnlinkInternetService(context.Background()).UnlinkInternetServiceRequest(req).Execute() + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, _, err = conn.InternetServiceApi.UnlinkInternetService( + context.Background()). + UnlinkInternetServiceRequest(req).Execute() if err != nil { - if strings.Contains(fmt.Sprint(err), "Failed Dependency") { - return resource.RetryableError(err) // retry - } - return resource.NonRetryableError(err) - } - if res != nil && res.StatusCode == 424 { - return resource.RetryableError(err) // retry + return resource.RetryableError( + fmt.Errorf("error unlink Internet Service (%s): %s", + d.Id(), err)) } return nil }) - if err != nil { - return fmt.Errorf("error unlink Internet Service (%s): %s", d.Id(), err) - } return nil } From 55c22cb3e9ed059af6cf457786fdf28b8718d8d1 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 12 Oct 2020 17:54:37 +0200 Subject: [PATCH 102/218] retry to fix TPD-1919 --- outscale/resource_outscale_load_balancer.go | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index f5dcc5a05..02752a268 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -45,7 +45,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { ForceNew: true, }, "security_groups": { - Type: schema.TypeList, + Type: schema.TypeSet, Optional: true, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -192,6 +192,15 @@ func expandStringList(ifs []interface{}) *[]string { return &r } +func expandSetStringList(ifs *schema.Set) *[]string { + r := make([]string, ifs.Len()) + + for k, v := range ifs.List() { + r[k] = v.(string) + } + return &r +} + // Flattens an array of Listeners into a []map[string]interface{} func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { result := make([]map[string]interface{}, 0, len(*list)) @@ -365,7 +374,7 @@ func resourceOutscaleOAPILoadBalancerCreate_(d *schema.ResourceData, meta interf } if v, ok := d.GetOk("security_groups"); ok { - req.SecurityGroups = expandStringList(v.([]interface{})) + req.SecurityGroups = expandSetStringList(v.(*schema.Set)) } v_sb, sb_ok := d.GetOk("subnets") From e23ff755691cbaedac0ebe09d91200e4d087dc71 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 13 Oct 2020 16:00:36 +0200 Subject: [PATCH 103/218] Fix resource_outscale_load_balancer_attributes crash Signed-off-by: Matthias Gatto --- .../resource_outscale_load_balancer_attributes.go | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 43e9113bc..88c126cab 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -43,6 +43,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "access_log": { Type: schema.TypeMap, Optional: true, + Computed: true, ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -64,6 +65,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "health_check": { Type: schema.TypeMap, Optional: true, + Computed: true, ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -236,6 +238,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me hc_req.UnhealthyThreshold = int64(ut) hc_req.CheckInterval = int64(i) hc_req.Protocol = check["protocol"].(string) + hc_req.Path = check["path"].(string) hc_req.Port = int64(p) hc_req.Timeout = int64(t) req.HealthCheck = &hc_req @@ -290,14 +293,18 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta access := make(map[string]string) access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) - access["osu_bucket_name"] = *a.OsuBucketName - access["osu_bucket_prefix"] = *a.OsuBucketPrefix + if a.OsuBucketName != nil { + access["osu_bucket_name"] = *a.OsuBucketName + } + if a.OsuBucketPrefix != nil { + access["osu_bucket_prefix"] = *a.OsuBucketPrefix + } d.Set("access_log", access) } healthCheck := make(map[string]interface{}) - if lb.HealthCheck.Path != "" { + if lb.HealthCheck != nil { h := strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) i := strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) pa := lb.HealthCheck.Path From 58a4327f6a7417f685cc67423f3922b0e24b4275 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 15 Oct 2020 12:18:50 +0200 Subject: [PATCH 104/218] resourceOutscaleOAPILoadBalancerAttributesCreate less crasshy Signed-off-by: Matthias Gatto --- .../resource_outscale_load_balancer_attributes.go | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 88c126cab..ab55ba17f 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -238,7 +238,9 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me hc_req.UnhealthyThreshold = int64(ut) hc_req.CheckInterval = int64(i) hc_req.Protocol = check["protocol"].(string) - hc_req.Path = check["path"].(string) + if check["path"] != nil { + hc_req.Path = check["path"].(string) + } hc_req.Port = int64(p) hc_req.Timeout = int64(t) req.HealthCheck = &hc_req @@ -255,11 +257,11 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me context.Background(), &elbOpts) if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating LBU Attr Listener with SSL Cert, retrying: %s", err)) + if strings.Contains(fmt.Sprint(err), "400 Bad Request") { + return resource.NonRetryableError(err) } - return resource.NonRetryableError(err) + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) } return nil }) From c9d613b63b4933d9947c05e678b01494c977ff63 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 15 Oct 2020 15:44:34 +0200 Subject: [PATCH 105/218] TPD-1898 Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 2 +- outscale/resource_outscale_load_balancer.go | 27 ++++++++++++++----- ...ource_outscale_load_balancer_attributes.go | 23 +--------------- 3 files changed, 22 insertions(+), 30 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 7ff1195ab..06fe8cf55 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -276,7 +276,7 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa d.Set("subregion_name", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) - d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) if lb.Listeners != nil { diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 02752a268..1054e81e1 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -496,7 +496,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface } d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) - d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) if lb.BackendVmIds != nil { d.Set("backend_vm_ids", lb.BackendVmIds) @@ -856,15 +856,28 @@ func expandInstanceString(list []interface{}) []string { return result } -func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { +func flattenOAPIHealthCheck(d *schema.ResourceData, check *oscgo.HealthCheck) map[string]interface{} { chk := make(map[string]interface{}) if check != nil { - chk["unhealthy_threshold"] = strconv.Itoa(int(check.UnhealthyThreshold)) - chk["healthy_threshold"] = strconv.Itoa(int(check.HealthyThreshold)) - chk["path"] = check.Path - chk["timeout"] = strconv.Itoa(int(check.Timeout)) - chk["check_interval"] = strconv.Itoa(int(check.CheckInterval)) + h := strconv.FormatInt(check.HealthyThreshold, 10) + i := strconv.FormatInt(check.CheckInterval, 10) + pa := check.Path + po := strconv.FormatInt(check.Port, 10) + pr := check.Protocol + ti := strconv.FormatInt(check.Timeout, 10) + u := strconv.FormatInt(check.UnhealthyThreshold, 10) + + chk["healthy_threshold"] = h + chk["check_interval"] = i + chk["path"] = pa + chk["port"] = po + chk["protocol"] = pr + chk["timeout"] = ti + chk["unhealthy_threshold"] = u + if d != nil { + d.Set("health_check", chk) + } } return chk diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index ab55ba17f..5012249f1 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -304,28 +304,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } - healthCheck := make(map[string]interface{}) - - if lb.HealthCheck != nil { - h := strconv.FormatInt(lb.HealthCheck.HealthyThreshold, 10) - i := strconv.FormatInt(lb.HealthCheck.CheckInterval, 10) - pa := lb.HealthCheck.Path - po := strconv.FormatInt(lb.HealthCheck.Port, 10) - pr := lb.HealthCheck.Protocol - ti := strconv.FormatInt(lb.HealthCheck.Timeout, 10) - u := strconv.FormatInt(lb.HealthCheck.UnhealthyThreshold, 10) - - healthCheck["healthy_threshold"] = h - healthCheck["check_interval"] = i - healthCheck["path"] = pa - healthCheck["port"] = po - healthCheck["protocol"] = pr - healthCheck["timeout"] = ti - healthCheck["unhealthy_threshold"] = u - - d.Set("health_check", healthCheck) - } - + flattenOAPIHealthCheck(d, lb.HealthCheck) d.Set("request_id", resp.ResponseContext.RequestId) return nil } From b6d992674065e0d8c025f702ad587df46b3799bb Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 22 Oct 2020 18:58:41 +0200 Subject: [PATCH 106/218] add resource_outscale_load_balancer_listeners_rule.go Signed-off-by: Matthias Gatto --- outscale/provider.go | 1 + ...e_outscale_load_balancer_listeners_rule.go | 348 ++++++++++++++++++ 2 files changed, 349 insertions(+) create mode 100644 outscale/resource_outscale_load_balancer_listeners_rule.go diff --git a/outscale/provider.go b/outscale/provider.go index 2cf519f76..f4bcd9e96 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -79,6 +79,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_policy": resourceOutscaleAppCookieStickinessPolicy(), "outscale_load_balancer_vms": resourceOutscaleOAPILBUAttachment(), "outscale_load_balancer_attributes": resourceOutscaleOAPILoadBalancerAttributes(), + "outscale_load_balancer_listener_rule": resourceOutscaleLoadBalancerListenerRule(), }, DataSourcesMap: map[string]*schema.Resource{ "outscale_vm": dataSourceOutscaleOAPIVM(), diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go new file mode 100644 index 000000000..e410922ca --- /dev/null +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -0,0 +1,348 @@ +package outscale + +import ( + "context" + "fmt" + "log" + "strconv" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" +) + +func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { + return &schema.Resource{ + Create: resourceOutscaleLoadBalancerListenerRuleCreate, + Read: resourceOutscaleLoadBalancerListenerRuleRead, + Update: resourceOutscaleLoadBalancerListenerRuleUpdate, + Delete: resourceOutscaleLoadBalancerListenerRuleDelete, + Schema: map[string]*schema.Schema{ + "vm_ids": { + Type: schema.TypeSet, + Required: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "listener": { + Type: schema.TypeMap, + ForceNew: true, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Computed: true, + }, + "load_balancer_port": { + Type: schema.TypeInt, + Computed: true, + }, + }, + }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + "listener_rule": { + Type: schema.TypeMap, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action": { + Type: schema.TypeString, + ForceNew: true, + Computed: true, + }, + "host_name_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "listener_rule_name": { + Type: schema.TypeString, + Required: true, + }, + "path_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "priority": { + Type: schema.TypeInt, + Required: true, + ForceNew: true, + }, + }, + }, + }, + }, + } +} + +func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + req := &oscgo.CreateListenerRuleRequest{} + + if vids, ok := d.GetOk("vm_ids"); ok { + req.VmIds = *expandSetStringList(vids.(*schema.Set)) + } else { + return fmt.Errorf("expect vm_ids") + } + + if li, lok := d.GetOk("listener"); lok { + l := li.(map[string]interface{}) + ll := oscgo.LoadBalancerLight{} + if l["load_balancer_name"] == nil || l["load_balancer_port"] == nil { + return fmt.Errorf("listener missing argument ") + } + lbpii, erratoi := strconv.Atoi(l["load_balancer_port"].(string)) + if erratoi != nil { + return fmt.Errorf("can't convert load_balancer_port") + } + lbpi := int64(lbpii) + ll.SetLoadBalancerName(l["load_balancer_name"].(string)) + ll.SetLoadBalancerPort(lbpi) + req.SetListener(ll) + } else { + return fmt.Errorf("expect listener") + } + + if lri, lok := d.GetOk("listener_rule"); lok { + lr := lri.(map[string]interface{}) + lrfc := oscgo.ListenerRuleForCreation{} + if lr["priority"] == nil { + return fmt.Errorf("listener priority argument missing") + } + if lr["action"] != nil { + lrfc.SetAction(lr["action"].(string)) + } + if lr["path_pattern"] != nil { + lrfc.SetPathPattern(lr["path_pattern"].(string)) + } + if lr["host_name_pattern"] != nil { + lrfc.SetHostNamePattern(lr["host_name_pattern"].(string)) + } + if lr["listener_rule_name"] != nil { + lrfc.SetListenerRuleName(lr["listener_rule_name"].(string)) + } + p, erratoi := strconv.Atoi(lr["priority"].(string)) + if erratoi != nil { + return fmt.Errorf("can't convert priority") + } + lrfc.SetPriority(int64(p)) + req.SetListenerRule(lrfc) + } else { + return fmt.Errorf("expect listener rule") + } + + elbOpts := &oscgo.CreateListenerRuleOpts{ + optional.NewInterface(*req), + } + + var err error + var resp oscgo.CreateListenerRuleResponse + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.CreateListenerRule( + context.Background(), elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "400 Bad Request") { + return resource.NonRetryableError(err) + } + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId(*resp.ListenerRule.ListenerRuleName) + d.Set("request_id", resp.ResponseContext.RequestId) + return resourceOutscaleLoadBalancerListenerRuleRead(d, meta) +} + +func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + lrName := d.Id() + + filter := &oscgo.FiltersListenerRule{ + ListenerRuleNames: &[]string{lrName}, + } + + req := oscgo.ReadListenerRulesRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadListenerRulesOpts{ + ReadListenerRulesRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadListenerRulesResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.ReadListenerRules( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + if len(*resp.ListenerRules) < 1 { + return fmt.Errorf("can't find listener rule") + } + lr := (*resp.ListenerRules)[0] + lrs := make(map[string]interface{}) + + if lr.Action != nil { + lrs["action"] = lr.Action + } + if lr.HostNamePattern != nil { + lrs["host_name_pattern"] = lr.HostNamePattern + } + if lr.ListenerRuleName != nil { + lrs["listener_rule_name"] = lr.ListenerRuleName + } + if lr.PathPattern != nil { + lrs["path_pattern"] = lr.PathPattern + } + if lr.Priority != nil { + lrs["priority"] = lr.Priority + } + d.Set("listener_rule %p", lrs) + if lr.VmIds != nil { + d.Set("vm_ids", flattenStringList(lr.VmIds)) + } + return nil +} + +func resourceOutscaleLoadBalancerListenerRuleUpdate(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + if d.HasChange("listener_rule") { + _, n := d.GetChange("listener_rule") + ns := n.(map[string]interface{}) + + req := oscgo.UpdateListenerRuleRequest{ + ListenerRuleName: d.Id(), + } + req.SetHostPattern(ns["host_name_pattern"].(string)) + req.SetListenerRuleName(ns["listener_rule_name"].(string)) + elbOpts := &oscgo.UpdateListenerRuleOpts{ + optional.NewInterface(req), + } + var err error + var resp oscgo.UpdateListenerRuleResponse + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.UpdateListenerRule( + context.Background(), elbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "400 Bad Request") { + return resource.NonRetryableError(err) + } + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) + } + return nil + }) + + if err != nil { + return err + } + + } + return resourceOutscaleLoadBalancerListenerRuleRead(d, meta) +} + +func resourceOutscaleLoadBalancerListenerRuleDelete(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + log.Printf("[INFO] Deleting Listener Rule: %s", d.Id()) + + // Destroy the listener rule + req := oscgo.DeleteListenerRuleRequest{ + ListenerRuleName: d.Id(), + } + + deleteLrOpts := oscgo.DeleteListenerRuleOpts{ + optional.NewInterface(req), + } + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, _, err = conn.ListenerApi.DeleteListenerRule( + context.Background(), &deleteLrOpts) + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Error deleting listener rule: %s", err) + } + + stateConf := &resource.StateChangeConf{ + Pending: []string{"ready"}, + Target: []string{}, + Refresh: func() (interface{}, string, error) { + filter := &oscgo.FiltersListenerRule{ + ListenerRuleNames: &[]string{d.Id()}, + } + + req := oscgo.ReadListenerRulesRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadListenerRulesOpts{ + ReadListenerRulesRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadListenerRulesResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.ReadListenerRules( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil || len(*resp.ListenerRules) < 1 { + return nil, "", nil + } + + return &(*resp.ListenerRules)[0], "ready", nil + }, + Timeout: 5 * time.Minute, + } + if _, err := stateConf.WaitForState(); err != nil { + return fmt.Errorf("Error waiting for listener rule (%s) to become nil: %s", d.Id(), err) + } + + return nil +} From 399c7810a21909a728d80e4b771b19ac85fc2e4c Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 23 Oct 2020 17:29:28 +0200 Subject: [PATCH 107/218] listener rule datapath Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 2 +- ...ce_outscale_load_balancer_listener_rule.go | 131 ++++++++++++++++++ outscale/provider.go | 1 + 3 files changed, 133 insertions(+), 1 deletion(-) create mode 100644 outscale/data_source_outscale_load_balancer_listener_rule.go diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 06fe8cf55..c740b4b34 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -206,7 +206,7 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala filter := new(oscgo.FiltersLoadBalancer) if !nameOk && !filtersOk { - return nil, nil, fmt.Errorf("One of filters, or load_balancer_name must be assigned") + return nil, nil, fmt.Errorf("One of filters, or listener_rule_name must be assigned") } if filtersOk { diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go new file mode 100644 index 000000000..b3eb23561 --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -0,0 +1,131 @@ +package outscale + +import ( + "context" + "fmt" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" +) + +func attrLBListenerRule() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "action": { + Type: schema.TypeString, + Computed: true, + }, + "host_name_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "listener_rule_name": { + Type: schema.TypeString, + Required: true, + }, + "path_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "priority": { + Type: schema.TypeInt, + Computed: true, + }, + "vm_ids": { + Type: schema.TypeSet, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerLDRule() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerLDRuleRead, + Schema: getDataSourceSchemas(attrLBListenerRule()), + } +} + +func dataSourceOutscaleOAPILoadBalancerLDRuleRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + lrNamei, nameOk := d.GetOk("listener_rule_name") + + lrName := lrNamei.(string) + if !nameOk { + return fmt.Errorf("listener_rule_name must be assigned") + } + + filter := &oscgo.FiltersListenerRule{ + ListenerRuleNames: &[]string{lrName}, + } + + req := oscgo.ReadListenerRulesRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadListenerRulesOpts{ + ReadListenerRulesRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadListenerRulesResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.ReadListenerRules( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + if len(*resp.ListenerRules) < 1 { + return fmt.Errorf("can't find listener rule") + } + lr := (*resp.ListenerRules)[0] + if lr.Action != nil { + d.Set("action", lr.Action) + } + if lr.HostNamePattern != nil { + d.Set("host_name_pattern", lr.HostNamePattern) + } + if lr.ListenerRuleName != nil { + d.Set("listener_rule_name", lr.ListenerRuleName) + } + if lr.PathPattern != nil { + d.Set("path_pattern", lr.PathPattern) + } + + if lr.Priority != nil { + d.Set("priority", lr.Priority) + } else { + fmt.Errorf("Malformated listener rule") + } + + if lr.VmIds != nil { + d.Set("vm_ids", flattenStringList(lr.VmIds)) + } else { + fmt.Errorf("Malformated listener rule") + } + + d.Set("request_id", resp.ResponseContext.RequestId) + d.SetId(resource.UniqueId()) + + return nil +} diff --git a/outscale/provider.go b/outscale/provider.go index f4bcd9e96..c797ba38f 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -131,6 +131,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_health_check": dataSourceOutscaleOAPILoadBalancerHealthCheck(), "outscale_load_balancer_listener_description": dataSourceOutscaleOAPILoadBalancerLD(), "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), + "outscale_load_balancer_listener_rule": dataSourceOutscaleOAPILoadBalancerLDRule(), "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), "outscale_load_balancer_vms_health": dataSourceOutscaleLoadBalancerVmsHeals(), From d4b979fa83bf4fd970c27fb91dcaf38cd1559635 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 23 Oct 2020 18:35:23 +0200 Subject: [PATCH 108/218] fix update I guess Signed-off-by: Matthias Gatto --- ...ce_outscale_load_balancer_listener_rule.go | 36 ++++++++++++++++--- ...e_outscale_load_balancer_listeners_rule.go | 19 ++++++++-- 2 files changed, 47 insertions(+), 8 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go index b3eb23561..fdfcad377 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rule.go +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -3,6 +3,7 @@ package outscale import ( "context" "fmt" + "log" "strings" "time" @@ -25,7 +26,8 @@ func attrLBListenerRule() map[string]*schema.Schema { }, "listener_rule_name": { Type: schema.TypeString, - Required: true, + Optional: true, + Computed: true, }, "path_pattern": { Type: schema.TypeString, @@ -58,14 +60,38 @@ func dataSourceOutscaleOAPILoadBalancerLDRuleRead(d *schema.ResourceData, meta i conn := meta.(*OutscaleClient).OSCAPI lrNamei, nameOk := d.GetOk("listener_rule_name") + filters, filtersOk := d.GetOk("filter") + filter := &oscgo.FiltersListenerRule{} - lrName := lrNamei.(string) - if !nameOk { + if !nameOk && !filtersOk { return fmt.Errorf("listener_rule_name must be assigned") } - filter := &oscgo.FiltersListenerRule{ - ListenerRuleNames: &[]string{lrName}, + if filtersOk { + set := filters.(*schema.Set) + + if set.Len() < 1 { + return fmt.Errorf("filter can't be empty") + } + for _, v := range set.List() { + m := v.(map[string]interface{}) + filterValues := make([]string, 0) + for _, e := range m["values"].([]interface{}) { + filterValues = append(filterValues, e.(string)) + } + + switch name := m["name"].(string); name { + case "listener_rule_name": + filter.ListenerRuleNames = &filterValues + default: + filter.ListenerRuleNames = &filterValues + log.Printf("[Debug] Unknown Filter Name: %s. default to 'load_balancer_name'", name) + } + } + } else { + filter = &oscgo.FiltersListenerRule{ + ListenerRuleNames: &[]string{lrNamei.(string)}, + } } req := oscgo.ReadListenerRulesRequest{ diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index e410922ca..a54cfafc5 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -235,14 +235,27 @@ func resourceOutscaleLoadBalancerListenerRuleUpdate(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI if d.HasChange("listener_rule") { - _, n := d.GetChange("listener_rule") + n, ok := d.GetOk("listener_rule") + + if ok != true { + return fmt.Errorf("can't get listener_rule") + } + //_, n := d.GetChange("listener_rule") ns := n.(map[string]interface{}) req := oscgo.UpdateListenerRuleRequest{ ListenerRuleName: d.Id(), } - req.SetHostPattern(ns["host_name_pattern"].(string)) - req.SetListenerRuleName(ns["listener_rule_name"].(string)) + if ns["host_name_pattern"] != nil { + req.SetHostPattern(ns["host_name_pattern"].(string)) + } else { + req.SetHostPattern("") + } + if ns["listener_rule_name"] != nil { + req.SetListenerRuleName(ns["listener_rule_name"].(string)) + } else { + req.SetListenerRuleName("") + } elbOpts := &oscgo.UpdateListenerRuleOpts{ optional.NewInterface(req), } From aa4f6e944fe43a17c2939b634f413f4986d0da8a Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 23 Oct 2020 18:59:47 +0200 Subject: [PATCH 109/218] data_source_outscale_load_balancer_listener_rules.go Signed-off-by: Matthias Gatto --- ...e_outscale_load_balancer_listener_rules.go | 174 ++++++++++++++++++ outscale/provider.go | 1 + 2 files changed, 175 insertions(+) create mode 100644 outscale/data_source_outscale_load_balancer_listener_rules.go diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go new file mode 100644 index 000000000..30c7ad1ea --- /dev/null +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -0,0 +1,174 @@ +package outscale + +import ( + "context" + "fmt" + "log" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" +) + +func attrLBListenerRules() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "listener_rules": { + Type: schema.TypeList, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "action": { + Type: schema.TypeString, + Computed: true, + }, + "host_name_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "listener_rule_name": { + Type: schema.TypeString, + Optional: true, + Computed: true, + }, + "path_pattern": { + Type: schema.TypeString, + Computed: true, + }, + "priority": { + Type: schema.TypeInt, + Computed: true, + }, + "vm_ids": { + Type: schema.TypeSet, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + } +} + +func dataSourceOutscaleOAPILoadBalancerLDRules() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancerLDRulesRead, + Schema: getDataSourceSchemas(attrLBListenerRules()), + } +} + +func dataSourceOutscaleOAPILoadBalancerLDRulesRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + + lrNamei, nameOk := d.GetOk("listener_rule_name") + filters, filtersOk := d.GetOk("filter") + filter := &oscgo.FiltersListenerRule{} + + if !nameOk && !filtersOk { + return fmt.Errorf("listener_rule_name must be assigned") + } + + if filtersOk { + set := filters.(*schema.Set) + + if set.Len() < 1 { + return fmt.Errorf("filter can't be empty") + } + for _, v := range set.List() { + m := v.(map[string]interface{}) + filterValues := make([]string, 0) + for _, e := range m["values"].([]interface{}) { + filterValues = append(filterValues, e.(string)) + } + + switch name := m["name"].(string); name { + case "listener_rule_name": + filter.ListenerRuleNames = &filterValues + default: + filter.ListenerRuleNames = &filterValues + log.Printf("[Debug] Unknown Filter Name: %s. default to 'load_balancer_name'", name) + } + } + } else { + filter = &oscgo.FiltersListenerRule{ + ListenerRuleNames: &[]string{lrNamei.(string)}, + } + } + + req := oscgo.ReadListenerRulesRequest{ + Filters: filter, + } + + describeElbOpts := &oscgo.ReadListenerRulesOpts{ + ReadListenerRulesRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadListenerRulesResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.ListenerApi.ReadListenerRules( + context.Background(), + describeElbOpts) + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return err + } + + lrs := *resp.ListenerRules + lrs_len := len(lrs) + if lrs_len < 1 { + return fmt.Errorf("can't find listener rule") + } + + lrs_ret := make([]map[string]interface{}, lrs_len) + for k, lr := range lrs { + l := make(map[string]interface{}) + if lr.Action != nil { + l["action"] = lr.Action + } + if lr.HostNamePattern != nil { + l["host_name_pattern"] = lr.HostNamePattern + } + if lr.ListenerRuleName != nil { + l["listener_rule_name"] = lr.ListenerRuleName + } + if lr.PathPattern != nil { + l["path_pattern"] = lr.PathPattern + } + + if lr.Priority != nil { + l["priority"] = lr.Priority + } else { + fmt.Errorf("Malformated listener rule") + } + + if lr.VmIds != nil { + l["vm_ids"] = flattenStringList(lr.VmIds) + } else { + fmt.Errorf("Malformated listener rule") + } + lrs_ret[k] = l + } + + d.Set("listener_rules", lrs_ret) + d.Set("request_id", resp.ResponseContext.RequestId) + d.SetId(resource.UniqueId()) + + return nil +} diff --git a/outscale/provider.go b/outscale/provider.go index c797ba38f..31a8f3092 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -132,6 +132,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_description": dataSourceOutscaleOAPILoadBalancerLD(), "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), "outscale_load_balancer_listener_rule": dataSourceOutscaleOAPILoadBalancerLDRule(), + "outscale_load_balancer_listener_rules": dataSourceOutscaleOAPILoadBalancerLDRules(), "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), "outscale_load_balancer_vms_health": dataSourceOutscaleLoadBalancerVmsHeals(), From f470dd6d79a5550ebc05d17a280076ac4e5920bc Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 27 Oct 2020 18:08:00 +0100 Subject: [PATCH 110/218] datasource tags, seems resource might be broken Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 19 ++++++- ...data_source_outscale_load_balancer_tags.go | 56 +++++++++---------- outscale/provider.go | 2 +- outscale/resource_outscale_load_balancer.go | 16 +++++- 4 files changed, 59 insertions(+), 34 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index c740b4b34..a7ef338a9 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -212,9 +212,22 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala if filtersOk { filter = buildOutscaleDataSourceLBFilters(filters.(*schema.Set)) } else { - elbName := ename.(string) - filter = &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, + switch ename.(type) { + case string: + elbName := ename.(string) + filter = &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, + } + + // for tags it's a list.... + case []interface{}: + names := ename.([]interface{}) + filter = &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: expandStringList(names), + } + default: + return nil, nil, + fmt.Errorf("wrong type to load_balancer_name") } } elbName := (*filter.LoadBalancerNames)[0] diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index 7e94a818e..d5bfe8402 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -16,28 +16,32 @@ func dataSourceOutscaleOAPILBUTags() *schema.Resource { func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - v, resp, err := readLbs0(conn, d) + resp, _, err := readLbs(conn, d) if err != nil { return err } + lbs := resp.LoadBalancers + l := 0 - t := make(map[string]interface{}) - t["load_balancer_name"] = v.LoadBalancerName - - ta := make([]map[string]interface{}, len(*v.Tags)) - for k1, v1 := range *v.Tags { - t := make(map[string]interface{}) - t["key"] = v1.Key - t["value"] = v1.Key - ta[k1] = t + for _, v := range *lbs { + l += len(*v.Tags) } - t["tag"] = ta + ta := make([]map[string]interface{}, l) + for _, v := range *lbs { + for k1, v1 := range *v.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + t["load_balancer_name"] = v.LoadBalancerName + ta[k1] = t + } + } + d.Set("tags", ta) d.SetId(resource.UniqueId()) d.Set("request_id", resp.ResponseContext.RequestId) - - return d.Set("tag", t) + return nil } func getDSOAPILBUTagsSchema() map[string]*schema.Schema { @@ -45,32 +49,26 @@ func getDSOAPILBUTagsSchema() map[string]*schema.Schema { "load_balancer_name": { Type: schema.TypeList, Optional: true, - Elem: &schema.Schema{Type: schema.TypeString}, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, }, - "tag": { + "tags": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ + "key": { + Type: schema.TypeString, + Computed: true, + }, "load_balancer_name": { Type: schema.TypeString, Computed: true, }, - "tag": { - Type: schema.TypeList, + "value": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "key": { - Type: schema.TypeString, - Computed: true, - }, - "value": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, }, }, diff --git a/outscale/provider.go b/outscale/provider.go index 31a8f3092..2b7f29073 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -133,7 +133,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), "outscale_load_balancer_listener_rule": dataSourceOutscaleOAPILoadBalancerLDRule(), "outscale_load_balancer_listener_rules": dataSourceOutscaleOAPILoadBalancerLDRules(), - "outscale_load_balancer_listener_tags": dataSourceOutscaleOAPILBUTags(), + "outscale_load_balancer_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), "outscale_load_balancer_vms_health": dataSourceOutscaleLoadBalancerVmsHeals(), "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 1054e81e1..59564aa18 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -513,9 +513,23 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface return err } } - log.Printf("[DEBUG] read lb.Listeners %v", lb.Listeners) d.Set("load_balancer_name", lb.LoadBalancerName) + if lb.Tags != nil { + ta := make([]map[string]interface{}, len(*lb.Tags)) + for k1, v1 := range *lb.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + + } + policies := make(map[string]interface{}) if lb.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, From 994684b6b2022af708715cf27dddf6ae6f9c1135 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 27 Oct 2020 19:05:41 +0100 Subject: [PATCH 111/218] use ReadLoadBalancerTags Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 19 +----- ...data_source_outscale_load_balancer_tags.go | 61 ++++++++++++++----- 2 files changed, 48 insertions(+), 32 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index a7ef338a9..c740b4b34 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -212,22 +212,9 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala if filtersOk { filter = buildOutscaleDataSourceLBFilters(filters.(*schema.Set)) } else { - switch ename.(type) { - case string: - elbName := ename.(string) - filter = &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } - - // for tags it's a list.... - case []interface{}: - names := ename.([]interface{}) - filter = &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: expandStringList(names), - } - default: - return nil, nil, - fmt.Errorf("wrong type to load_balancer_name") + elbName := ename.(string) + filter = &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: &[]string{elbName}, } } elbName := (*filter.LoadBalancerNames)[0] diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index d5bfe8402..f8793e66f 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -1,6 +1,14 @@ package outscale import ( + "context" + "fmt" + "strings" + "time" + + "github.com/antihax/optional" + oscgo "github.com/marinsalinas/osc-sdk-go" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) @@ -16,26 +24,47 @@ func dataSourceOutscaleOAPILBUTags() *schema.Resource { func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - resp, _, err := readLbs(conn, d) - if err != nil { - return err + ename, nameOk := d.GetOk("load_balancer_names") + if !nameOk { + return fmt.Errorf("load_balancer_names is required") } - lbs := resp.LoadBalancers - l := 0 - for _, v := range *lbs { - l += len(*v.Tags) + names := ename.([]interface{}) + + req := oscgo.ReadLoadBalancerTagsRequest{ + LoadBalancerNames: *expandStringList(names), } - ta := make([]map[string]interface{}, l) - for _, v := range *lbs { - for k1, v1 := range *v.Tags { - t := make(map[string]interface{}) - t["key"] = v1.Key - t["value"] = v1.Value - t["load_balancer_name"] = v.LoadBalancerName - ta[k1] = t + describeElbOpts := &oscgo.ReadLoadBalancerTagsOpts{ + ReadLoadBalancerTagsRequest: optional.NewInterface(req), + } + + var resp oscgo.ReadLoadBalancerTagsResponse + var err error + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.ReadLoadBalancerTags( + context.Background(), + describeElbOpts) + + if err != nil { + if strings.Contains(fmt.Sprint(err), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) } + return nil + }) + + tags := *resp.Tags + l := len(*resp.Tags) + + ta := make([]map[string]interface{}, l) + for k1, v1 := range tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + t["load_balancer_name"] = v1.LoadBalancerName + ta[k1] = t } d.Set("tags", ta) @@ -46,7 +75,7 @@ func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) func getDSOAPILBUTagsSchema() map[string]*schema.Schema { return map[string]*schema.Schema{ - "load_balancer_name": { + "load_balancer_names": { Type: schema.TypeList, Optional: true, Elem: &schema.Schema{ From 1be5cc2224f6b1915eeef5cca31dca52dc3c89cd Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 29 Oct 2020 14:15:58 +0100 Subject: [PATCH 112/218] resource_outscale_load_balancer update tags Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 69 +++++++++++++++++++++ 1 file changed, 69 insertions(+) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 59564aa18..a94725c41 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -580,6 +580,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI + var err error d.Partial(true) if d.HasChange("security_groups") || d.HasChange("subregion_names") || @@ -593,6 +594,74 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa return resourceOutscaleOAPILoadBalancerCreate_(d, meta, true) } + if d.HasChange("tags") { + oraw, nraw := d.GetChange("tags") + o := oraw.(*schema.Set) + n := nraw.(*schema.Set) + create := tagsFromSliceMap(n) + var remove []oscgo.ResourceLoadBalancerTag + for _, t := range o.List() { + tag := t.(map[string]interface{}) + s := tag["key"].(string) + remove = append(remove, + oscgo.ResourceLoadBalancerTag{ + Key: &s, + }) + } + if len(remove) < 1 { + goto skip_delete + } + + err = resource.Retry(60*time.Second, func() *resource.RetryError { + _, _, err := conn.LoadBalancerApi.DeleteLoadBalancerTags( + context.Background(), + &oscgo.DeleteLoadBalancerTagsOpts{ + DeleteLoadBalancerTagsRequest: optional.NewInterface( + oscgo.DeleteLoadBalancerTagsRequest{ + LoadBalancerNames: []string{d.Id()}, + Tags: remove, + })}) + if err != nil { + if strings.Contains(fmt.Sprint(err), ".NotFound") { + return resource.RetryableError(err) // retry + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return err + } + + skip_delete: + if len(create) < 1 { + goto skip_create + } + + err = resource.Retry(60*time.Second, func() *resource.RetryError { + _, _, err := conn.LoadBalancerApi.CreateLoadBalancerTags( + context.Background(), + &oscgo.CreateLoadBalancerTagsOpts{ + CreateLoadBalancerTagsRequest: optional.NewInterface( + oscgo.CreateLoadBalancerTagsRequest{ + LoadBalancerNames: []string{d.Id()}, + Tags: create, + })}) + if err != nil { + if strings.Contains(fmt.Sprint(err), ".NotFound") { + return resource.RetryableError(err) // retry + } + return resource.NonRetryableError(err) + } + return nil + }) + if err != nil { + return err + } + + skip_create: + } + if d.HasChange("listeners") { o, n := d.GetChange("listeners") os := o.(*schema.Set).List() From 67fdb21f99ae1986d5e89a3ae93bac97aa0f5897 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 30 Oct 2020 12:24:29 +0100 Subject: [PATCH 113/218] use new sdk Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancer.go | 2 +- outscale/data_source_outscale_load_balancer_attributes_test.go | 2 +- .../data_source_outscale_load_balancer_health_check_test.go | 2 +- ...a_source_outscale_load_balancer_listener_description_test.go | 2 +- ..._source_outscale_load_balancer_listener_descriptions_test.go | 2 +- outscale/data_source_outscale_load_balancer_listener_rule.go | 2 +- outscale/data_source_outscale_load_balancer_listener_rules.go | 2 +- outscale/data_source_outscale_load_balancer_tags.go | 2 +- outscale/data_source_outscale_load_balancer_test.go | 2 +- outscale/data_source_outscale_load_balancer_vms_health.go | 2 +- outscale/data_source_outscale_load_balancers.go | 2 +- outscale/resource_outscale_load_balancer.go | 2 +- outscale/resource_outscale_load_balancer_attributes.go | 2 +- outscale/resource_outscale_load_balancer_attributes_test.go | 2 +- outscale/resource_outscale_load_balancer_listeners_rule.go | 2 +- outscale/resource_outscale_load_balancer_listeners_test.go | 2 +- outscale/resource_outscale_load_balancer_policy.go | 2 +- outscale/resource_outscale_load_balancer_policy_test.go | 2 +- outscale/resource_outscale_load_balancer_test.go | 2 +- outscale/resource_outscale_load_balancer_vms.go | 2 +- outscale/resource_outscale_load_balancer_vms_test.go | 2 +- 21 files changed, 21 insertions(+), 21 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index c740b4b34..fd747c708 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go index b863a548d..e60c33369 100644 --- a/outscale/data_source_outscale_load_balancer_attributes_test.go +++ b/outscale/data_source_outscale_load_balancer_attributes_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go index 637c4c2df..3a48fe6da 100644 --- a/outscale/data_source_outscale_load_balancer_health_check_test.go +++ b/outscale/data_source_outscale_load_balancer_health_check_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go index 3dde07c78..51e482d0f 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_description_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go index d718a917c..f8466cf23 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go index fdfcad377..ecad83388 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rule.go +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index 30c7ad1ea..6a80e9060 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index f8793e66f..6e6c9c00d 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -7,7 +7,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index 81c00b05f..bfe6fa0d1 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_vms_health.go b/outscale/data_source_outscale_load_balancer_vms_health.go index e1efb7d2d..2096ce11a 100644 --- a/outscale/data_source_outscale_load_balancer_vms_health.go +++ b/outscale/data_source_outscale_load_balancer_vms_health.go @@ -9,7 +9,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index b55ee40d6..d8bd20cf8 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -7,7 +7,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index a94725c41..6a07be26b 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -9,7 +9,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 5012249f1..13a4a51e2 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -9,7 +9,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index c02b90219..af396d600 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index a54cfafc5..b178498e4 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -9,7 +9,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go index 59eca7823..a1ebe3df3 100644 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -2,7 +2,7 @@ package outscale import ( "fmt" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index 43ad98b6c..87d0d88a2 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index dcfd98c2c..ff7973656 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index 36e4956c6..eaa3d0930 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -10,7 +10,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 38d2bd207..7893d37bf 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -8,7 +8,7 @@ import ( "time" "github.com/antihax/optional" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_vms_test.go b/outscale/resource_outscale_load_balancer_vms_test.go index 31b6cc462..2d9d5f511 100644 --- a/outscale/resource_outscale_load_balancer_vms_test.go +++ b/outscale/resource_outscale_load_balancer_vms_test.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/marinsalinas/osc-sdk-go" + oscgo "github.com/outscale/osc-sdk-go/osc" ) func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { From e41afa9542d17214bb5e35988ffa12f30ac8196f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 30 Oct 2020 17:55:06 +0100 Subject: [PATCH 114/218] refactorise request for the new sdk Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 12 +- ...rce_outscale_load_balancer_health_check.go | 20 ++- ...ce_outscale_load_balancer_listener_rule.go | 9 +- ...e_outscale_load_balancer_listener_rules.go | 9 +- ...data_source_outscale_load_balancer_tags.go | 9 +- ...ource_outscale_load_balancer_vms_health.go | 9 +- .../data_source_outscale_load_balancers.go | 9 +- outscale/resource_outscale_load_balancer.go | 127 ++++++++---------- ...ource_outscale_load_balancer_attributes.go | 24 ++-- ...e_outscale_load_balancer_listeners_rule.go | 39 ++---- .../resource_outscale_load_balancer_policy.go | 15 +-- .../resource_outscale_load_balancer_vms.go | 18 +-- 12 files changed, 107 insertions(+), 193 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index fd747c708..151b498f6 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -7,7 +7,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -223,16 +222,13 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala Filters: filter, } - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) + resp, _, err = conn.LoadBalancerApi. + ReadLoadBalancers(context.Background()). + ReadLoadBalancersRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go index b6976e9db..a362d7186 100644 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ b/outscale/data_source_outscale_load_balancer_health_check.go @@ -61,19 +61,17 @@ func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, m return fmt.Errorf("NO Attributes FOUND") } - h := int64(0) - i := int64(0) + h := int32(0) + i := int32(0) t := "" - ti := int64(0) - u := int64(0) + ti := int32(0) + u := int32(0) - if lb.HealthCheck.Path != "" { - h = lb.HealthCheck.HealthyThreshold - i = lb.HealthCheck.CheckInterval - t = lb.HealthCheck.Path - ti = lb.HealthCheck.Timeout - u = lb.HealthCheck.UnhealthyThreshold - } + h = lb.HealthCheck.HealthyThreshold + i = lb.HealthCheck.CheckInterval + t = *lb.HealthCheck.Path + ti = lb.HealthCheck.Timeout + u = lb.HealthCheck.UnhealthyThreshold d.Set("healthy_threshold", h) d.Set("check_interval", i) diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go index ecad83388..14d683999 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rule.go +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -7,7 +7,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -98,16 +97,12 @@ func dataSourceOutscaleOAPILoadBalancerLDRuleRead(d *schema.ResourceData, meta i Filters: filter, } - describeElbOpts := &oscgo.ReadListenerRulesOpts{ - ReadListenerRulesRequest: optional.NewInterface(req), - } - var resp oscgo.ReadListenerRulesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.ReadListenerRules( - context.Background(), - describeElbOpts) + context.Background()). + ReadListenerRulesRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index 6a80e9060..c77bb6e3e 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -7,7 +7,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -107,16 +106,12 @@ func dataSourceOutscaleOAPILoadBalancerLDRulesRead(d *schema.ResourceData, meta Filters: filter, } - describeElbOpts := &oscgo.ReadListenerRulesOpts{ - ReadListenerRulesRequest: optional.NewInterface(req), - } - var resp oscgo.ReadListenerRulesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.ReadListenerRules( - context.Background(), - describeElbOpts) + context.Background()). + ReadListenerRulesRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index 6e6c9c00d..c80b727b4 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -6,7 +6,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -35,16 +34,12 @@ func dataSourceOutscaleOAPILBUTagsRead(d *schema.ResourceData, meta interface{}) LoadBalancerNames: *expandStringList(names), } - describeElbOpts := &oscgo.ReadLoadBalancerTagsOpts{ - ReadLoadBalancerTagsRequest: optional.NewInterface(req), - } - var resp oscgo.ReadLoadBalancerTagsResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.LoadBalancerApi.ReadLoadBalancerTags( - context.Background(), - describeElbOpts) + context.Background()). + ReadLoadBalancerTagsRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { diff --git a/outscale/data_source_outscale_load_balancer_vms_health.go b/outscale/data_source_outscale_load_balancer_vms_health.go index 2096ce11a..205d4eef9 100644 --- a/outscale/data_source_outscale_load_balancer_vms_health.go +++ b/outscale/data_source_outscale_load_balancer_vms_health.go @@ -8,7 +8,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -87,16 +86,12 @@ func dataSourceOutscaleLoadBalancerVmsHealRead(d *schema.ResourceData, req.BackendVmIds = &vm_ids_s } - describeElbOpts := &oscgo.ReadVmsHealthOpts{ - ReadVmsHealthRequest: optional.NewInterface(req), - } - var resp oscgo.ReadVmsHealthResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.LoadBalancerApi.ReadVmsHealth( - context.Background(), - describeElbOpts) + context.Background()).ReadVmsHealthRequest(req). + Execute() if err != nil { log.Printf("[DEBUG] err: (%s)", err) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index d8bd20cf8..37b8a8bfe 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -6,7 +6,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -222,16 +221,12 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf Filters: filter, } - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) + context.Background()). + ReadLoadBalancersRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 6a07be26b..28b75a39b 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -8,7 +8,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -228,8 +227,8 @@ func expandListeners(configured []interface{}) ([]*oscgo.Listener, error) { for _, lRaw := range configured { data := lRaw.(map[string]interface{}) - ip := int64(data["backend_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) + ip := int32(data["backend_port"].(int)) + lp := int32(data["load_balancer_port"].(int)) bproto := data["backend_protocol"].(string) lproto := data["load_balancer_protocol"].(string) l := &oscgo.Listener{ @@ -273,8 +272,8 @@ func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCre for _, lRaw := range configured { data := lRaw.(map[string]interface{}) - ip := int64(data["backend_port"].(int)) - lp := int64(data["load_balancer_port"].(int)) + ip := int32(data["backend_port"].(int)) + lp := int32(data["load_balancer_port"].(int)) bproto := data["backend_protocol"].(string) lproto := data["load_balancer_protocol"].(string) l := oscgo.ListenerForCreation{ @@ -391,14 +390,11 @@ func resourceOutscaleOAPILoadBalancerCreate_(d *schema.ResourceData, meta interf req.SubregionNames = expandStringList(v_srn.([]interface{})) } - elbOpts := &oscgo.CreateLoadBalancerOpts{ - optional.NewInterface(*req), - } - - log.Printf("[DEBUG] Load Balancer create configuration: %#v", elbOpts) + log.Printf("[DEBUG] Load Balancer request configuration: %#v", *req) err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi.CreateLoadBalancer( - context.Background(), elbOpts) + context.Background()). + CreateLoadBalancerRequest(*req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "CertificateNotFound") { @@ -450,16 +446,12 @@ func readResourceLb(conn *oscgo.APIClient, elbName string) (*oscgo.LoadBalancer, Filters: filter, } - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - var resp oscgo.ReadLoadBalancersResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) + context.Background()). + ReadLoadBalancersRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) @@ -614,13 +606,12 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa err = resource.Retry(60*time.Second, func() *resource.RetryError { _, _, err := conn.LoadBalancerApi.DeleteLoadBalancerTags( - context.Background(), - &oscgo.DeleteLoadBalancerTagsOpts{ - DeleteLoadBalancerTagsRequest: optional.NewInterface( - oscgo.DeleteLoadBalancerTagsRequest{ - LoadBalancerNames: []string{d.Id()}, - Tags: remove, - })}) + context.Background()). + DeleteLoadBalancerTagsRequest( + oscgo.DeleteLoadBalancerTagsRequest{ + LoadBalancerNames: []string{d.Id()}, + Tags: remove, + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), ".NotFound") { return resource.RetryableError(err) // retry @@ -640,13 +631,12 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa err = resource.Retry(60*time.Second, func() *resource.RetryError { _, _, err := conn.LoadBalancerApi.CreateLoadBalancerTags( - context.Background(), - &oscgo.CreateLoadBalancerTagsOpts{ - CreateLoadBalancerTagsRequest: optional.NewInterface( - oscgo.CreateLoadBalancerTagsRequest{ - LoadBalancerNames: []string{d.Id()}, - Tags: create, - })}) + context.Background()). + CreateLoadBalancerTagsRequest( + oscgo.CreateLoadBalancerTagsRequest{ + LoadBalancerNames: []string{d.Id()}, + Tags: create, + }).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), ".NotFound") { return resource.RetryableError(err) // retry @@ -672,7 +662,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa add, _ := expandListenerForCreation(ns) if len(remove) > 0 { - ports := make([]int64, 0, len(remove)) + ports := make([]int32, 0, len(remove)) for _, listener := range remove { ports = append(ports, *listener.LoadBalancerPort) } @@ -682,16 +672,14 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa LoadBalancerPorts: ports, } - deleteListenersOpts := &oscgo.DeleteLoadBalancerListenersOpts{ - optional.NewInterface(req), - } - - log.Printf("[DEBUG] Load Balancer Delete Listeners opts: %v", deleteListenersOpts) + log.Printf("[DEBUG] Load Balancer Delete Listeners") var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.ListenerApi.DeleteLoadBalancerListeners( - context.Background(), deleteListenersOpts) + context.Background()). + DeleteLoadBalancerListenersRequest(req). + Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -713,17 +701,13 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa Listeners: add, } - createListenersOpts := oscgo.CreateLoadBalancerListenersOpts{ - optional.NewInterface(req), - } - // Occasionally AWS will error with a 'duplicate listener', without any // other listeners on the Load Balancer. Retry here to eliminate that. var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - log.Printf("[DEBUG] Load Balancer Create Listeners opts: %v", createListenersOpts) + log.Printf("[DEBUG] Load Balancer Create Listeners") _, _, err = conn.ListenerApi.CreateLoadBalancerListeners( - context.Background(), &createListenersOpts) + context.Background()).CreateLoadBalancerListenersRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "DuplicateListener") { log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id()) @@ -764,15 +748,12 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa BackendVmIds: add, } - registerInstancesOpts := oscgo.RegisterVmsInLoadBalancerOpts{ - optional.NewInterface(req), - } - var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi. - RegisterVmsInLoadBalancer(context.Background(), - ®isterInstancesOpts) + RegisterVmsInLoadBalancer(context.Background()). + RegisterVmsInLoadBalancerRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -792,16 +773,14 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa LoadBalancerName: d.Id(), BackendVmIds: remove, } - deRegisterInstancesOpts := oscgo.DeregisterVmsInLoadBalancerOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err := conn.LoadBalancerApi. DeregisterVmsInLoadBalancer( - context.Background(), - &deRegisterInstancesOpts) + context.Background()). + DeregisterVmsInLoadBalancerRequest(req). + Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -827,26 +806,25 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa req := oscgo.UpdateLoadBalancerRequest{ LoadBalancerName: d.Id(), HealthCheck: &oscgo.HealthCheck{ - HealthyThreshold: int64(check["healthy_threshold"].(int)), - UnhealthyThreshold: int64(check["unhealthy_threshold"].(int)), - CheckInterval: int64(check["check_interval"].(int)), + HealthyThreshold: int32(check["healthy_threshold"].(int)), + UnhealthyThreshold: int32(check["unhealthy_threshold"].(int)), + CheckInterval: int32(check["check_interval"].(int)), Protocol: check["protocol"].(string), - Port: int64(check["port"].(int)), - Timeout: int64(check["timeout"].(int)), + Port: int32(check["port"].(int)), + Timeout: int32(check["timeout"].(int)), }, } if check["path"] != nil { - req.HealthCheck.Path = check["path"].(string) + p := check["path"].(string) + req.HealthCheck.Path = &p } - configureHealthCheckOpts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &configureHealthCheckOpts) + context.Background()).UpdateLoadBalancerRequest(req). + Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { @@ -886,14 +864,11 @@ func resourceOutscaleOAPILoadBalancerDelete_(d *schema.ResourceData, meta interf LoadBalancerName: d.Id(), } - deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer( - context.Background(), &deleteElbOpts) + context.Background()).DeleteLoadBalancerRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { return resource.RetryableError(err) @@ -939,17 +914,21 @@ func expandInstanceString(list []interface{}) []string { return result } +func formatInt32(n int32) string { + return strconv.FormatInt(int64(n), 10) +} + func flattenOAPIHealthCheck(d *schema.ResourceData, check *oscgo.HealthCheck) map[string]interface{} { chk := make(map[string]interface{}) if check != nil { - h := strconv.FormatInt(check.HealthyThreshold, 10) - i := strconv.FormatInt(check.CheckInterval, 10) + h := formatInt32(check.HealthyThreshold) + i := formatInt32(check.CheckInterval) pa := check.Path - po := strconv.FormatInt(check.Port, 10) + po := formatInt32(check.Port) pr := check.Protocol - ti := strconv.FormatInt(check.Timeout, 10) - u := strconv.FormatInt(check.UnhealthyThreshold, 10) + ti := formatInt32(check.Timeout) + u := formatInt32(check.UnhealthyThreshold) chk["healthy_threshold"] = h chk["check_interval"] = i diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 13a4a51e2..84d449f0a 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -8,7 +8,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -160,7 +159,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } if port, pok := d.GetOk("load_balancer_port"); pok { - port_i := int64(port.(int)) + port_i := int32(port.(int)) req.LoadBalancerPort = &port_i } @@ -187,7 +186,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } if v, ok := lb_atoi_at(dal, "publication_interval"); ok { - pi := int64(v) + pi := int32(v) access.PublicationInterval = &pi } obn := dal["osu_bucket_name"] @@ -234,27 +233,24 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } var hc_req oscgo.HealthCheck - hc_req.HealthyThreshold = int64(ht) - hc_req.UnhealthyThreshold = int64(ut) - hc_req.CheckInterval = int64(i) + hc_req.HealthyThreshold = int32(ht) + hc_req.UnhealthyThreshold = int32(ut) + hc_req.CheckInterval = int32(i) hc_req.Protocol = check["protocol"].(string) if check["path"] != nil { - hc_req.Path = check["path"].(string) + p := check["path"].(string) + hc_req.Path = &p } - hc_req.Port = int64(p) - hc_req.Timeout = int64(t) + hc_req.Port = int32(p) + hc_req.Timeout = int32(t) req.HealthCheck = &hc_req } - elbOpts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } - var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &elbOpts) + context.Background()).UpdateLoadBalancerRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "400 Bad Request") { diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index b178498e4..d6ed0f780 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -8,7 +8,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -103,7 +102,7 @@ func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta if erratoi != nil { return fmt.Errorf("can't convert load_balancer_port") } - lbpi := int64(lbpii) + lbpi := int32(lbpii) ll.SetLoadBalancerName(l["load_balancer_name"].(string)) ll.SetLoadBalancerPort(lbpi) req.SetListener(ll) @@ -133,21 +132,17 @@ func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta if erratoi != nil { return fmt.Errorf("can't convert priority") } - lrfc.SetPriority(int64(p)) + lrfc.SetPriority(int32(p)) req.SetListenerRule(lrfc) } else { return fmt.Errorf("expect listener rule") } - elbOpts := &oscgo.CreateListenerRuleOpts{ - optional.NewInterface(*req), - } - var err error var resp oscgo.CreateListenerRuleResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.CreateListenerRule( - context.Background(), elbOpts) + context.Background()).CreateListenerRuleRequest(*req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "400 Bad Request") { @@ -180,16 +175,12 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i Filters: filter, } - describeElbOpts := &oscgo.ReadListenerRulesOpts{ - ReadListenerRulesRequest: optional.NewInterface(req), - } - var resp oscgo.ReadListenerRulesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.ReadListenerRules( - context.Background(), - describeElbOpts) + context.Background()).ReadListenerRulesRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) @@ -256,14 +247,13 @@ func resourceOutscaleLoadBalancerListenerRuleUpdate(d *schema.ResourceData, meta } else { req.SetListenerRuleName("") } - elbOpts := &oscgo.UpdateListenerRuleOpts{ - optional.NewInterface(req), - } + var err error var resp oscgo.UpdateListenerRuleResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.UpdateListenerRule( - context.Background(), elbOpts) + context.Background()).UpdateListenerRuleRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "400 Bad Request") { @@ -293,14 +283,11 @@ func resourceOutscaleLoadBalancerListenerRuleDelete(d *schema.ResourceData, meta ListenerRuleName: d.Id(), } - deleteLrOpts := oscgo.DeleteListenerRuleOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.ListenerApi.DeleteListenerRule( - context.Background(), &deleteLrOpts) + context.Background()).DeleteListenerRuleRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { return resource.RetryableError(err) @@ -326,16 +313,12 @@ func resourceOutscaleLoadBalancerListenerRuleDelete(d *schema.ResourceData, meta Filters: filter, } - describeElbOpts := &oscgo.ReadListenerRulesOpts{ - ReadListenerRulesRequest: optional.NewInterface(req), - } - var resp oscgo.ReadListenerRulesResponse var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.ListenerApi.ReadListenerRules( - context.Background(), - describeElbOpts) + context.Background()). + ReadListenerRulesRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling:") { return resource.RetryableError(err) diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index 87d0d88a2..995db6006 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -7,7 +7,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -78,17 +77,14 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met if cnok { req.CookieName = &vs } - acspOpts := oscgo.CreateLoadBalancerPolicyOpts{ - optional.NewInterface(req), - } var err error var resp oscgo.CreateLoadBalancerPolicyResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { resp, _, err = conn.LoadBalancerPolicyApi. CreateLoadBalancerPolicy( - context.Background(), - &acspOpts) + context.Background()). + CreateLoadBalancerPolicyRequest(req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -136,15 +132,12 @@ func resourceOutscaleAppCookieStickinessPolicyDelete(d *schema.ResourceData, met PolicyName: p, } - opts := &oscgo.DeleteLoadBalancerPolicyOpts{ - optional.NewInterface(request), - } - var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = elbconn.LoadBalancerPolicyApi. DeleteLoadBalancerPolicy( - context.Background(), opts) + context.Background()). + DeleteLoadBalancerPolicyRequest(request).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 7893d37bf..439c730d4 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -7,7 +7,6 @@ import ( "strings" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -62,15 +61,12 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf BackendVmIds: a, } - registerInstancesOpts := oscgo.RegisterVmsInLoadBalancerOpts{ - optional.NewInterface(req), - } - var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi. - RegisterVmsInLoadBalancer(context.Background(), - ®isterInstancesOpts) + RegisterVmsInLoadBalancer(context.Background()). + RegisterVmsInLoadBalancerRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -134,15 +130,13 @@ func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interf LoadBalancerName: e, BackendVmIds: lb, } - deRegisterInstancesOpts := oscgo.DeregisterVmsInLoadBalancerOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err := conn.LoadBalancerApi. - DeregisterVmsInLoadBalancer(context.Background(), - &deRegisterInstancesOpts) + DeregisterVmsInLoadBalancer(context.Background()). + DeregisterVmsInLoadBalancerRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { From 79eeb6c85b35dd399520a8cfa1cd687a146930df Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 28 Sep 2020 14:42:34 +0000 Subject: [PATCH 115/218] fixed AccessLog and HealthCheck blocks Signed-off-by: Thiery Ouattara --- .../data_source_outscale_load_balancers.go | 33 ++++ outscale/resource_outscale_load_balancer.go | 147 +++++++++++++----- 2 files changed, 139 insertions(+), 41 deletions(-) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 37b8a8bfe..201640306 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -40,6 +40,30 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "access_log": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, + }, + }, + }, "health_check": { Type: schema.TypeMap, Computed: true, @@ -61,6 +85,14 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "port": { + Type: schema.TypeInt, + Computed: true, + }, + "protocol": { + Type: schema.TypeString, + Computed: true, + }, "timeout": { Type: schema.TypeString, Computed: true, @@ -259,6 +291,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf l["subregion_names"] = v.SubregionNames l["dns_name"] = v.DnsName + l["access_log"] = v.AccessLog l["health_check"] = v.HealthCheck l["backend_vm_id"] = v.BackendVmIds l["listeners"] = flattenOAPIListeners(v.Listeners) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 28b75a39b..02918c1fc 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -62,6 +62,31 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeString, Computed: true, }, + "access_log": { + Type: schema.TypeMap, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, + }, + }, + }, "health_check": { Type: schema.TypeMap, Computed: true, @@ -133,43 +158,30 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeString, Computed: true, }, - "policies": { + "application_sticky_cookie_policies": { Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": { - Type: schema.TypeList, + "cookie_name": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "cookie_name": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, - "load_balancer_sticky_cookie_policy": { - Type: schema.TypeList, + "policy_name": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, - "other_policy": { - Type: schema.TypeList, + }, + }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, }, }, }, @@ -421,7 +433,6 @@ func resourceOutscaleOAPILoadBalancerCreate_(d *schema.ResourceData, meta interf if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { return err } - d.Set("policies", make([]map[string]interface{}, 0)) return resourceOutscaleOAPILoadBalancerRead(d, meta) } @@ -486,9 +497,11 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface if err != nil { return err } + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) + d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) if lb.BackendVmIds != nil { d.Set("backend_vm_ids", lb.BackendVmIds) @@ -522,7 +535,6 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface } - policies := make(map[string]interface{}) if lb.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, len(*lb.ApplicationStickyCookiePolicies)) @@ -532,7 +544,9 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface a["policy_name"] = v.PolicyName app[k] = a } - policies["application_sticky_cookie_policy"] = app + d.Set("application_sticky_cookie_policies", app) + } + if lb.LoadBalancerStickyCookiePolicies != nil { lbc := make([]map[string]interface{}, len(*lb.LoadBalancerStickyCookiePolicies)) for k, v := range *lb.LoadBalancerStickyCookiePolicies { @@ -540,16 +554,9 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface a["policy_name"] = v.PolicyName lbc[k] = a } - policies["load_balancer_sticky_cookie_policy"] = lbc - // TODO: check this can be remove V - // policies["other_policy"] = flattenStringList(lb.Policies.OtherPolicies) - } else { - lbc := make([]map[string]interface{}, 0) - policies["load_balancer_sticky_cookie_policy"] = lbc - // TODO: check this can be remove V - // policies["other_policy"] = lbc + d.Set("load_balancer_sticky_cookie_policies", lbc) } - d.Set("policies", policies) + d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { d.Set("security_groups", flattenStringList(lb.SecurityGroups)) @@ -842,8 +849,53 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa } } + if d.HasChange("access_log") { + acg := d.Get("access_log").([]interface{}) + if len(acg) > 0 { + + aclg := acg[0].(map[string]interface{}) + isEnabled := aclg["is_enabled"].(bool) + osuBucketName := aclg["osu_bucket_name"].(string) + osuBucketPrefix := aclg["osu_bucket_prefix"].(string) + publicationInterval := int64(aclg["publication_interval"].(int64)) + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: d.Id(), + AccessLog: &oscgo.AccessLog{ + IsEnabled: &isEnabled, + OsuBucketName: &osuBucketName, + OsuBucketPrefix: &osuBucketPrefix, + PublicationInterval: &publicationInterval, + }, + } + + configureAccessLogOpts := oscgo.UpdateLoadBalancerOpts{ + optional.NewInterface(req), + } + var err error + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background(), &configureAccessLogOpts) + + if err != nil { + if strings.Contains(err.Error(), "Throttling:") { + return resource.RetryableError(err) + } + return resource.NonRetryableError(err) + } + return nil + }) + + if err != nil { + return fmt.Errorf("Failure configuring access log for Load Balancer: %s", err) + } + d.SetPartial("access_log") + } + } + d.SetPartial("listeners") - d.SetPartial("policies") + d.SetPartial("application_sticky_cookie_policies") + d.SetPartial("load_balancer_sticky_cookie_policies") d.Partial(false) @@ -944,3 +996,16 @@ func flattenOAPIHealthCheck(d *schema.ResourceData, check *oscgo.HealthCheck) ma return chk } + +func flattenOAPIAccessLog(aclog *oscgo.AccessLog) map[string]interface{} { + accl := make(map[string]interface{}) + + if aclog != nil { + accl["is_enabled"] = strconv.FormatBool(*aclog.IsEnabled) + accl["osu_bucket_name"] = aclog.OsuBucketName + accl["osu_bucket_prefix"] = aclog.OsuBucketPrefix + accl["publication_interval"] = strconv.Itoa(int(*aclog.PublicationInterval)) + } + + return accl +} From 829a0de9a7da2f535fc91165ba3de886910b93af Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 2 Nov 2020 09:51:09 +0000 Subject: [PATCH 116/218] fix terraform crash TPD-1932 Signed-off-by: Thiery Ouattara --- ...ource_outscale_load_balancer_attributes.go | 36 ++++++++++--------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 84d449f0a..90563d0a9 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -24,21 +24,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, Schema: map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeInt, - Optional: true, - ForceNew: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Optional: true, - ForceNew: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Optional: true, - ForceNew: true, - }, "access_log": { Type: schema.TypeMap, Optional: true, @@ -58,6 +43,10 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Type: schema.TypeString, Optional: true, }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, }, }, }, @@ -111,6 +100,16 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, + "load_balancer_port": { + Type: schema.TypeInt, + Optional: true, + ForceNew: true, + }, + "server_certificate_id": { + Type: schema.TypeString, + Optional: true, + ForceNew: true, + }, "load_balancer_name": { Type: schema.TypeString, Required: true, @@ -179,8 +178,11 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me if al, alok := d.GetOk("access_log"); alok { dal := al.(map[string]interface{}) - - is_enable := dal["is_enable"].(bool) + check, _ := dal["is_enabled"] + is_enable := false + if check == "true" { + is_enable = true + } access := &oscgo.AccessLog{ IsEnabled: &is_enable, } From 0569af41d1fd682d211f3152b49c5b166fd436c9 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 2 Nov 2020 10:54:02 +0000 Subject: [PATCH 117/218] remove useless variable Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_listeners_rule.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index d6ed0f780..db1a3ffbf 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -249,11 +249,9 @@ func resourceOutscaleLoadBalancerListenerRuleUpdate(d *schema.ResourceData, meta } var err error - var resp oscgo.UpdateListenerRuleResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.ListenerApi.UpdateListenerRule( - context.Background()).UpdateListenerRuleRequest(req). - Execute() + _, _, err = conn.ListenerApi.UpdateListenerRule( + context.Background(), elbOpts) if err != nil { if strings.Contains(fmt.Sprint(err), "400 Bad Request") { From 4b71f1945f94b0e2cd9a95a690b33d9bea32c1cd Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 2 Nov 2020 14:25:16 +0100 Subject: [PATCH 118/218] fix rebase Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 7 ++----- outscale/resource_outscale_load_balancer_listeners_rule.go | 3 ++- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 02918c1fc..e6033914b 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -857,7 +857,7 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa isEnabled := aclg["is_enabled"].(bool) osuBucketName := aclg["osu_bucket_name"].(string) osuBucketPrefix := aclg["osu_bucket_prefix"].(string) - publicationInterval := int64(aclg["publication_interval"].(int64)) + publicationInterval := int32(aclg["publication_interval"].(int)) req := oscgo.UpdateLoadBalancerRequest{ LoadBalancerName: d.Id(), AccessLog: &oscgo.AccessLog{ @@ -868,14 +868,11 @@ func resourceOutscaleOAPILoadBalancerUpdate(d *schema.ResourceData, meta interfa }, } - configureAccessLogOpts := oscgo.UpdateLoadBalancerOpts{ - optional.NewInterface(req), - } var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background(), &configureAccessLogOpts) + context.Background()).UpdateLoadBalancerRequest(req).Execute() if err != nil { if strings.Contains(err.Error(), "Throttling:") { diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index db1a3ffbf..335975986 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -251,7 +251,8 @@ func resourceOutscaleLoadBalancerListenerRuleUpdate(d *schema.ResourceData, meta var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { _, _, err = conn.ListenerApi.UpdateListenerRule( - context.Background(), elbOpts) + context.Background()).UpdateListenerRuleRequest(req). + Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "400 Bad Request") { From 56cbc1cd2dba2afbe0ef59597722714a2f14e136 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 2 Nov 2020 15:12:18 +0000 Subject: [PATCH 119/218] fix tests Signed-off-by: Thiery Ouattara --- .../resource_outscale_load_balancer_policy_test.go | 8 ++------ outscale/resource_outscale_load_balancer_test.go | 14 ++------------ 2 files changed, 4 insertions(+), 18 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index ff7973656..23e48583d 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -7,7 +7,6 @@ import ( "testing" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" @@ -56,13 +55,10 @@ func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { LoadBalancerName: lbName, } - deleteElbOpts := oscgo.DeleteLoadBalancerOpts{ - optional.NewInterface(request), - } - var err error err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer(context.Background(), &deleteElbOpts) + _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer( + context.Background()).DeleteLoadBalancerRequest(request).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index eaa3d0930..c3de248ce 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -9,7 +9,6 @@ import ( "testing" "time" - "github.com/antihax/optional" oscgo "github.com/outscale/osc-sdk-go/osc" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" @@ -71,12 +70,8 @@ func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { Filters: filter, } - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) + context.Background()).ReadLoadBalancersRequest(*req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { @@ -171,13 +166,8 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resour Filters: filter, } - describeElbOpts := &oscgo.ReadLoadBalancersOpts{ - ReadLoadBalancersRequest: optional.NewInterface(req), - } - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background(), - describeElbOpts) + context.Background()).ReadLoadBalancersRequest(*req).Execute() if err != nil { if strings.Contains(fmt.Sprint(err), "Throttling") { From 66208e084c29bb7417c6506ec762ecffa1b3c202 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 2 Nov 2020 17:09:06 +0100 Subject: [PATCH 120/218] set resource load_balancer_vms request_id Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_vms.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 439c730d4..9c8f4ad7f 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -62,8 +62,9 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf } var err error + var resp oscgo.RegisterVmsInLoadBalancerResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi. + resp, _, err = conn.LoadBalancerApi. RegisterVmsInLoadBalancer(context.Background()). RegisterVmsInLoadBalancerRequest(req). Execute() @@ -83,15 +84,16 @@ func resourceOutscaleOAPILBUAttachmentCreate(d *schema.ResourceData, meta interf } d.SetId(resource.PrefixedUniqueId(fmt.Sprintf("%s-", e))) + d.Set("request_id", *resp.ResponseContext.RequestId) - return nil + return resourceOutscaleOAPILBUAttachmentRead(d, meta) } func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI found := false e := d.Get("load_balancer_name").(string) - lb, resp, err := readResourceLb(conn, e) + lb, _, err := readResourceLb(conn, e) expected := d.Get("backend_vm_ids").([]interface{}) if err != nil { @@ -112,7 +114,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac d.SetId("") } - return d.Set("request_id", *resp.ResponseContext.RequestId) + return nil } func resourceOutscaleOAPILBUAttachmentDelete(d *schema.ResourceData, meta interface{}) error { From eb87c2a11438456c4e3df37d83bcd770f0cda0e6 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Tue, 3 Nov 2020 17:36:17 +0000 Subject: [PATCH 121/218] add listeners in attributes Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_attributes.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 90563d0a9..c209ac663 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -100,6 +100,15 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, + "listeners": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), + }, + }, "load_balancer_port": { Type: schema.TypeInt, Optional: true, @@ -302,6 +311,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } + d.Set("listeners", flattenOAPIListeners(lb.Listeners)) flattenOAPIHealthCheck(d, lb.HealthCheck) d.Set("request_id", resp.ResponseContext.RequestId) return nil From bcda75ecdf4f58bc09a04984fafac366fb154d85 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 3 Nov 2020 19:21:54 +0100 Subject: [PATCH 122/218] fix lbu data Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 6 +- ...e_outscale_load_balancer_listener_rules.go | 1 - .../data_source_outscale_load_balancers.go | 442 ++++++++---------- outscale/resource_outscale_load_balancer.go | 6 +- 4 files changed, 188 insertions(+), 267 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 151b498f6..c0508027c 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) -func attrLBSchema() map[string]*schema.Schema { +func attrLBchema() map[string]*schema.Schema { return map[string]*schema.Schema{ "subregion_name": { Type: schema.TypeList, @@ -174,7 +174,7 @@ func getDataSourceSchemas(attrsSchema map[string]*schema.Schema) map[string]*sch func dataSourceOutscaleOAPILoadBalancer() *schema.Resource { return &schema.Resource{ Read: dataSourceOutscaleOAPILoadBalancerRead, - Schema: getDataSourceSchemas(attrLBSchema()), + Schema: getDataSourceSchemas(attrLBchema()), } } @@ -256,7 +256,7 @@ func readLbs0(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.LoadBalance return nil, nil, err } lbs := *resp.LoadBalancers - if len(lbs) != 1 { + if len(lbs) < 1 { return nil, nil, fmt.Errorf("Unable to find LBU: %s", *elbName) } return &lbs[0], resp, nil diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index c77bb6e3e..6768e61da 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -18,7 +18,6 @@ func attrLBListenerRules() map[string]*schema.Schema { "listener_rules": { Type: schema.TypeList, Computed: true, - ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "action": { diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 201640306..34a585415 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -1,304 +1,224 @@ package outscale import ( - "context" - "fmt" - "strings" - "time" - - oscgo "github.com/outscale/osc-sdk-go/osc" + "log" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) -func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancersRead, - - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeList, - Optional: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "load_balancer": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Computed: true, - }, - "subregion_names": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "dns_name": { - Type: schema.TypeString, - Computed: true, - }, - "access_log": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "is_enabled": { - Type: schema.TypeBool, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, - "publication_interval": { - Type: schema.TypeInt, - Computed: true, - }, +func attrLBSchema() map[string]*schema.Schema { + return map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeList, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "load_balancer_name": { + Type: schema.TypeString, + Computed: true, + }, + "subregion_names": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "dns_name": { + Type: schema.TypeString, + Computed: true, + }, + "access_log": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, }, }, }, - "health_check": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "healthy_threshold": { - Type: schema.TypeString, - Computed: true, - }, - "unhealthy_threshold": { - Type: schema.TypeString, - Computed: true, - }, - "checked_vm": { - Type: schema.TypeString, - Computed: true, - }, - "check_interval": { - Type: schema.TypeString, - Computed: true, - }, - "port": { - Type: schema.TypeInt, - Computed: true, - }, - "protocol": { - Type: schema.TypeString, - Computed: true, - }, - "timeout": { - Type: schema.TypeString, - Computed: true, - }, + }, + "health_check": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "checked_vm": { + Type: schema.TypeString, + Computed: true, + }, + "check_interval": { + Type: schema.TypeString, + Computed: true, + }, + "port": { + Type: schema.TypeInt, + Computed: true, + }, + "protocol": { + Type: schema.TypeString, + Computed: true, + }, + "timeout": { + Type: schema.TypeString, + Computed: true, }, }, }, - "backend_vm_id": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "vm_id": { - Type: schema.TypeString, - Computed: true, - }, + }, + "backend_vm_ids": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "vm_id": { + Type: schema.TypeString, + Computed: true, }, }, }, - "listeners": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "listener": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Computed: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Computed: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, - Computed: true, - }, - "server_certificate_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "policy_name": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, + }, + "listeners": { + Type: schema.TypeSet, + Required: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), + }, + }, + "application_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": { + Type: schema.TypeString, + Computed: true, + }, + "policy_name": { + Type: schema.TypeString, + Computed: true, }, }, }, - "policies": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "cookie_name": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "load_balancer_sticky_cookie_policy": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, + Computed: true, }, }, }, - "load_balancer_type": { - Type: schema.TypeString, - Computed: true, - }, - "security_groups_member": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "firewall_rules_set_name": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": { - Type: schema.TypeString, - Computed: true, - }, - "account_alias": { - Type: schema.TypeString, - Computed: true, - }, + }, + "load_balancer_type": { + Type: schema.TypeString, + Computed: true, + }, + "security_groups": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "source_security_group": { + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "security_group_name": { + Type: schema.TypeString, + Computed: true, + }, + "security_group_account_id": { + Type: schema.TypeString, + Computed: true, }, }, }, - "subnet_id": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "net_id": { - Type: schema.TypeString, - Computed: true, - }, + }, + "subnet_id": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "net_id": { + Type: schema.TypeString, + Computed: true, }, }, }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, + }, + "request_id": { + Type: schema.TypeString, + Computed: true, }, } } -func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - eName, ok := d.GetOk("load_balancer_name") - - if !ok { - return fmt.Errorf("load_balancer_name(s) must be provided") - } - - elbName := eName.(string) - - filter := &oscgo.FiltersLoadBalancer{ - LoadBalancerNames: &[]string{elbName}, - } +func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { + return &schema.Resource{ + Read: dataSourceOutscaleOAPILoadBalancersRead, - req := oscgo.ReadLoadBalancersRequest{ - Filters: filter, + Schema: getDataSourceSchemas(attrLBSchema()), } +} - var resp oscgo.ReadLoadBalancersResponse - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.ReadLoadBalancers( - context.Background()). - ReadLoadBalancersRequest(req).Execute() - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling:") { - return resource.RetryableError(err) - } - return resource.NonRetryableError(err) - } - return nil - }) +func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interface{}) error { + conn := meta.(*OutscaleClient).OSCAPI + resp, _, err := readLbs(conn, d) if err != nil { - if isLoadBalancerNotFound(err) { - d.SetId("") - return nil - } - - return fmt.Errorf("Error retrieving ELB: %s", err) + return err } lbs_len := len(*resp.LoadBalancers) lbs_ret := make([]map[string]interface{}, lbs_len) lbs := *resp.LoadBalancers - if len(lbs) < 1 { - return fmt.Errorf("Unable to find LBU: %s", elbName) - } for k, v := range lbs { l := make(map[string]interface{}) l["subregion_names"] = v.SubregionNames - l["dns_name"] = v.DnsName - l["access_log"] = v.AccessLog - l["health_check"] = v.HealthCheck - l["backend_vm_id"] = v.BackendVmIds - l["listeners"] = flattenOAPIListeners(v.Listeners) - l["load_balancer_name"] = elbName + l["dns_name"] = *v.DnsName + l["access_log"] = flattenOAPIAccessLog(v.AccessLog) + l["health_check"] = flattenOAPIHealthCheck(nil, v.HealthCheck) + l["backend_vm_ids"] = flattenStringList(v.BackendVmIds) + if v.Listeners != nil { + l["listeners"] = flattenOAPIListeners(v.Listeners) + } else { + l["listeners"] = make([]interface{}, 0) + } + l["load_balancer_name"] = v.LoadBalancerName - policies := make(map[string]interface{}) - pl := make([]map[string]interface{}, 1) if v.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, len(*v.ApplicationStickyCookiePolicies)) for k, v := range *v.ApplicationStickyCookiePolicies { @@ -307,7 +227,10 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf a["policy_name"] = v.PolicyName app[k] = a } - policies["application_sticky_cookie_policy"] = app + l["application_sticky_cookie_policies"] = app + } + + if v.LoadBalancerStickyCookiePolicies != nil { vc := make([]map[string]interface{}, len(*v.LoadBalancerStickyCookiePolicies)) for k, v := range *v.LoadBalancerStickyCookiePolicies { @@ -315,27 +238,30 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf a["policy_name"] = v.PolicyName vc[k] = a } - policies["load_balancer_sticky_cookie_policy"] = vc + l["load_balancer_sticky_cookie_policies"] = vc } - pl[0] = policies - l["policies"] = pl l["load_balancer_type"] = v.LoadBalancerType - l["security_groups_member"] = flattenStringList(v.SecurityGroups) + l["security_groups"] = flattenStringList(v.SecurityGroups) ssg := make(map[string]string) + if v.SourceSecurityGroup != nil { ssg["security_group_account_id"] = *v.SourceSecurityGroup.SecurityGroupAccountId ssg["security_group_name"] = *v.SourceSecurityGroup.SecurityGroupName } - l["firewall_rules_set_name"] = ssg + l["source_security_group"] = ssg l["subnet_id"] = flattenStringList(v.Subnets) l["net_id"] = v.NetId lbs_ret[k] = l } + err = d.Set("load_balancer", lbs_ret) + if err != nil { + return err + } d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(resource.UniqueId()) - return d.Set("load_balancer", lbs) + return nil } diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index e6033914b..d39fc046d 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -503,11 +503,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) - if lb.BackendVmIds != nil { - d.Set("backend_vm_ids", lb.BackendVmIds) - } else { - d.Set("backend_vm_ids", make([]interface{}, 0)) - } + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) if lb.Listeners != nil { if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { log.Printf("[DEBUG] out err %v", err) From 96bba4d283733e4bead11bedb6883d86bdd15753 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 5 Nov 2020 12:06:37 +0100 Subject: [PATCH 123/218] lbu data fix missing attributes Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 54 ++++++++----------- .../data_source_outscale_load_balancers.go | 8 ++- 2 files changed, 29 insertions(+), 33 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index c0508027c..6f4f7693f 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -114,39 +114,30 @@ func attrLBchema() map[string]*schema.Schema { Optional: true, Computed: true, }, - "policies": { + "application_sticky_cookie_policies": { Type: schema.TypeList, - Optional: true, Computed: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ - "application_sticky_cookie_policy": { - Type: schema.TypeList, + "cookie_name": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "cookie_name": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, - "load_balancer_sticky_cookie_policy": { - Type: schema.TypeList, + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, }, }, }, @@ -286,7 +277,6 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa } d.Set("load_balancer_name", lb.LoadBalancerName) - policies := make(map[string]interface{}) if lb.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, len(*lb.ApplicationStickyCookiePolicies)) for k, v := range *lb.ApplicationStickyCookiePolicies { @@ -295,7 +285,10 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa a["policy_name"] = v.PolicyName app[k] = a } - policies["application_sticky_cookie_policy"] = app + d.Set("application_sticky_cookie_policies", app) + } else { + app := make([]map[string]interface{}, 0) + d.Set("application_sticky_cookie_policies", app) } if lb.LoadBalancerStickyCookiePolicies != nil { lbc := make([]map[string]interface{}, len(*lb.LoadBalancerStickyCookiePolicies)) @@ -304,12 +297,11 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa a["policy_name"] = v.PolicyName lbc[k] = a } - policies["load_balancer_sticky_cookie_policy"] = lbc + d.Set("load_balancer_sticky_cookie_policies", lbc) } else { lbc := make([]map[string]interface{}, 0) - policies["load_balancer_sticky_cookie_policy"] = lbc + d.Set("load_balancer_sticky_cookie_policies", lbc) } - d.Set("policies", policies) d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 34a585415..27101184f 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -1,8 +1,6 @@ package outscale import ( - "log" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) @@ -228,6 +226,9 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf app[k] = a } l["application_sticky_cookie_policies"] = app + } else { + l["application_sticky_cookie_policies"] = + make([]map[string]interface{}, 0) } if v.LoadBalancerStickyCookiePolicies != nil { @@ -239,6 +240,9 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf vc[k] = a } l["load_balancer_sticky_cookie_policies"] = vc + } else { + l["load_balancer_sticky_cookie_policies"] = + make([]map[string]interface{}, 0) } l["load_balancer_type"] = v.LoadBalancerType From 2eff1a07bbed47f23a5781f026b4c5825f0dea38 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Thu, 5 Nov 2020 15:15:37 +0000 Subject: [PATCH 124/218] fix load_balancer_attributes Signed-off-by: Thiery Ouattara --- ...ource_outscale_load_balancer_attributes.go | 184 +++++++++++++++--- 1 file changed, 162 insertions(+), 22 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index c209ac663..17e2c3756 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -109,8 +109,108 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Schema: lb_listener_schema(), }, }, - "load_balancer_port": { - Type: schema.TypeInt, + "source_security_group": { + Type: schema.TypeMap, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "security_group_name": { + Type: schema.TypeString, + Computed: true, + }, + "security_group_account_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "application_sticky_cookie_policies": { + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": { + Type: schema.TypeString, + Computed: true, + }, + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "tags": { + Type: schema.TypeSet, + Computed: true, + Optional: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "key": { + Type: schema.TypeString, + Computed: true, + }, + "value": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "security_groups": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "backend_vm_ids": { + Type: schema.TypeList, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + }, + "subnets": { + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Computed: true, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + }, + "subregion_names": { + Type: schema.TypeList, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "dns_name": { + Type: schema.TypeString, + Computed: true, Optional: true, ForceNew: true, }, @@ -121,14 +221,15 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "load_balancer_name": { Type: schema.TypeString, - Required: true, + Optional: true, + Computed: true, ForceNew: true, }, - "policy_names": { - Type: schema.TypeList, - ForceNew: true, + "load_balancer_type": { + Type: schema.TypeString, Optional: true, - Elem: &schema.Schema{Type: schema.TypeString}, + Computed: true, + ForceNew: true, }, "request_id": { Type: schema.TypeString, @@ -166,25 +267,11 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me LoadBalancerName: ename.(string), } - if port, pok := d.GetOk("load_balancer_port"); pok { - port_i := int32(port.(int)) - req.LoadBalancerPort = &port_i - } - if ssl, sok := d.GetOk("server_certificate_id"); sok { ssl_s := ssl.(string) req.ServerCertificateId = &ssl_s } - if pol_names, plnok := d.GetOk("policy_names"); plnok { - m := pol_names.([]interface{}) - a := make([]string, len(m)) - for k, v := range m { - a[k] = v.(string) - } - req.PolicyNames = &a - } - if al, alok := d.GetOk("access_log"); alok { dal := al.(map[string]interface{}) check, _ := dal["is_enabled"] @@ -311,8 +398,61 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } + if lb.Tags != nil { + ta := make([]map[string]interface{}, len(*lb.Tags)) + for k1, v1 := range *lb.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + } + + if lb.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, + len(*lb.ApplicationStickyCookiePolicies)) + for k, v := range *lb.ApplicationStickyCookiePolicies { + a := make(map[string]interface{}) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName + app[k] = a + } + d.Set("application_sticky_cookie_policies", app) + } else { + d.Set("application_sticky_cookie_policies", make([]map[string]interface{}, 0)) + } + + if lb.LoadBalancerStickyCookiePolicies == nil { + d.Set("load_balancer_sticky_cookie_policies", make([]map[string]interface{}, 0)) + } else { + lbc := make([]map[string]interface{}, + len(*lb.LoadBalancerStickyCookiePolicies)) + for k, v := range *lb.LoadBalancerStickyCookiePolicies { + a := make(map[string]interface{}) + a["policy_name"] = v.PolicyName + lbc[k] = a + } + d.Set("load_balancer_sticky_cookie_policies", lbc) + } + + sgr := make(map[string]string) + if lb.SourceSecurityGroup != nil { + sgr["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName + sgr["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId + } + d.Set("source_security_group", sgr) + d.Set("dns_name", lb.DnsName) + d.Set("load_balancer_type", lb.LoadBalancerType) + d.Set("security_groups", flattenStringList(lb.SecurityGroups)) + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) + d.Set("subnets", flattenStringList(lb.Subnets)) + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) d.Set("listeners", flattenOAPIListeners(lb.Listeners)) - flattenOAPIHealthCheck(d, lb.HealthCheck) + d.Set("health_check", flattenOAPIHealthCheck(d, lb.HealthCheck)) d.Set("request_id", resp.ResponseContext.RequestId) return nil } From fac0d63e7cd2a4a4182eea76cac15259dbb70aa9 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 5 Nov 2020 17:23:08 +0100 Subject: [PATCH 125/218] Revert "fix load_balancer_attributes" Add new bugs This reverts commit 39839ad8a18251b59aafad81dd571a4ab72ee42f. --- ...ource_outscale_load_balancer_attributes.go | 184 +++--------------- 1 file changed, 22 insertions(+), 162 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 17e2c3756..c209ac663 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -109,108 +109,8 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Schema: lb_listener_schema(), }, }, - "source_security_group": { - Type: schema.TypeMap, - Optional: true, - Computed: true, - ForceNew: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "security_group_name": { - Type: schema.TypeString, - Computed: true, - }, - "security_group_account_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "application_sticky_cookie_policies": { - Type: schema.TypeList, - Optional: true, - ForceNew: true, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "cookie_name": { - Type: schema.TypeString, - Computed: true, - }, - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "load_balancer_sticky_cookie_policies": { - Type: schema.TypeList, - Optional: true, - ForceNew: true, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "policy_name": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "tags": { - Type: schema.TypeSet, - Computed: true, - Optional: true, - ForceNew: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "key": { - Type: schema.TypeString, - Computed: true, - }, - "value": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - "security_groups": { - Type: schema.TypeSet, - Optional: true, - Computed: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "backend_vm_ids": { - Type: schema.TypeList, - Optional: true, - Computed: true, - ForceNew: true, - Elem: &schema.Schema{ - Type: schema.TypeString, - }, - }, - "subnets": { - Type: schema.TypeList, - Optional: true, - ForceNew: true, - Computed: true, - Elem: &schema.Schema{ - Type: schema.TypeString, - }, - }, - "subregion_names": { - Type: schema.TypeList, - Optional: true, - Computed: true, - ForceNew: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "dns_name": { - Type: schema.TypeString, - Computed: true, + "load_balancer_port": { + Type: schema.TypeInt, Optional: true, ForceNew: true, }, @@ -221,15 +121,14 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "load_balancer_name": { Type: schema.TypeString, - Optional: true, - Computed: true, + Required: true, ForceNew: true, }, - "load_balancer_type": { - Type: schema.TypeString, - Optional: true, - Computed: true, + "policy_names": { + Type: schema.TypeList, ForceNew: true, + Optional: true, + Elem: &schema.Schema{Type: schema.TypeString}, }, "request_id": { Type: schema.TypeString, @@ -267,11 +166,25 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me LoadBalancerName: ename.(string), } + if port, pok := d.GetOk("load_balancer_port"); pok { + port_i := int32(port.(int)) + req.LoadBalancerPort = &port_i + } + if ssl, sok := d.GetOk("server_certificate_id"); sok { ssl_s := ssl.(string) req.ServerCertificateId = &ssl_s } + if pol_names, plnok := d.GetOk("policy_names"); plnok { + m := pol_names.([]interface{}) + a := make([]string, len(m)) + for k, v := range m { + a[k] = v.(string) + } + req.PolicyNames = &a + } + if al, alok := d.GetOk("access_log"); alok { dal := al.(map[string]interface{}) check, _ := dal["is_enabled"] @@ -398,61 +311,8 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } - if lb.Tags != nil { - ta := make([]map[string]interface{}, len(*lb.Tags)) - for k1, v1 := range *lb.Tags { - t := make(map[string]interface{}) - t["key"] = v1.Key - t["value"] = v1.Value - ta[k1] = t - } - - d.Set("tags", ta) - } else { - d.Set("tags", make([]map[string]interface{}, 0)) - } - - if lb.ApplicationStickyCookiePolicies != nil { - app := make([]map[string]interface{}, - len(*lb.ApplicationStickyCookiePolicies)) - for k, v := range *lb.ApplicationStickyCookiePolicies { - a := make(map[string]interface{}) - a["cookie_name"] = v.CookieName - a["policy_name"] = v.PolicyName - app[k] = a - } - d.Set("application_sticky_cookie_policies", app) - } else { - d.Set("application_sticky_cookie_policies", make([]map[string]interface{}, 0)) - } - - if lb.LoadBalancerStickyCookiePolicies == nil { - d.Set("load_balancer_sticky_cookie_policies", make([]map[string]interface{}, 0)) - } else { - lbc := make([]map[string]interface{}, - len(*lb.LoadBalancerStickyCookiePolicies)) - for k, v := range *lb.LoadBalancerStickyCookiePolicies { - a := make(map[string]interface{}) - a["policy_name"] = v.PolicyName - lbc[k] = a - } - d.Set("load_balancer_sticky_cookie_policies", lbc) - } - - sgr := make(map[string]string) - if lb.SourceSecurityGroup != nil { - sgr["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName - sgr["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId - } - d.Set("source_security_group", sgr) - d.Set("dns_name", lb.DnsName) - d.Set("load_balancer_type", lb.LoadBalancerType) - d.Set("security_groups", flattenStringList(lb.SecurityGroups)) - d.Set("subregion_names", flattenStringList(lb.SubregionNames)) - d.Set("subnets", flattenStringList(lb.Subnets)) - d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) d.Set("listeners", flattenOAPIListeners(lb.Listeners)) - d.Set("health_check", flattenOAPIHealthCheck(d, lb.HealthCheck)) + flattenOAPIHealthCheck(d, lb.HealthCheck) d.Set("request_id", resp.ResponseContext.RequestId) return nil } From a2208a827d0ebcf3b7821ab4887d9222dea2fa9e Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 10 Nov 2020 18:54:16 +0100 Subject: [PATCH 126/218] TPD-1932 path and accesslog ? Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 2 +- .../data_source_outscale_load_balancers.go | 2 +- outscale/resource_outscale_load_balancer.go | 7 +-- ...ource_outscale_load_balancer_attributes.go | 43 ++++++++----------- 4 files changed, 23 insertions(+), 31 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 6f4f7693f..be160a800 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -263,7 +263,7 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa d.Set("subregion_name", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) - d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) + d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) if lb.Listeners != nil { diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 27101184f..10e135b42 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -208,7 +208,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf l["subregion_names"] = v.SubregionNames l["dns_name"] = *v.DnsName l["access_log"] = flattenOAPIAccessLog(v.AccessLog) - l["health_check"] = flattenOAPIHealthCheck(nil, v.HealthCheck) + l["health_check"] = flattenOAPIHealthCheck(v.HealthCheck) l["backend_vm_ids"] = flattenStringList(v.BackendVmIds) if v.Listeners != nil { l["listeners"] = flattenOAPIListeners(v.Listeners) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index d39fc046d..d41b514a9 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -500,7 +500,7 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) - d.Set("health_check", flattenOAPIHealthCheck(nil, lb.HealthCheck)) + d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) @@ -963,7 +963,7 @@ func formatInt32(n int32) string { return strconv.FormatInt(int64(n), 10) } -func flattenOAPIHealthCheck(d *schema.ResourceData, check *oscgo.HealthCheck) map[string]interface{} { +func flattenOAPIHealthCheck(check *oscgo.HealthCheck) map[string]interface{} { chk := make(map[string]interface{}) if check != nil { @@ -982,9 +982,6 @@ func flattenOAPIHealthCheck(d *schema.ResourceData, check *oscgo.HealthCheck) ma chk["protocol"] = pr chk["timeout"] = ti chk["unhealthy_threshold"] = u - if d != nil { - d.Set("health_check", chk) - } } return chk diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index c209ac663..b0e7ba571 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -33,14 +33,17 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Schema: map[string]*schema.Schema{ "is_enabled": { Type: schema.TypeBool, + Computed: true, Required: true, }, "osu_bucket_name": { Type: schema.TypeString, + Computed: true, Optional: true, }, "osu_bucket_prefix": { Type: schema.TypeString, + Computed: true, Optional: true, }, "publication_interval": { @@ -51,10 +54,11 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, "health_check": { - Type: schema.TypeMap, + Type: schema.TypeList, Optional: true, Computed: true, ForceNew: true, + MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "healthy_threshold": { @@ -71,9 +75,8 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "path": { Type: schema.TypeString, - Optional: true, Computed: true, - ForceNew: true, + Optional: true, }, "port": { Type: schema.TypeString, @@ -100,15 +103,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, - "listeners": { - Type: schema.TypeSet, - Optional: true, - Computed: true, - ForceNew: true, - Elem: &schema.Resource{ - Schema: lb_listener_schema(), - }, - }, "load_balancer_port": { Type: schema.TypeInt, Optional: true, @@ -213,9 +207,10 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me req.AccessLog = access } - hc, hok := d.GetOk("health_check") + hcs, hok := d.GetOk("health_check") if hok { - check := hc.(map[string]interface{}) + hc := hcs.([]interface{}) + check := hc[0].(map[string]interface{}) ht, ut, sucess := 0, 0, false if ht, sucess = lb_atoi_at(check, "healthy_threshold"); sucess == false { @@ -250,7 +245,9 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me hc_req.Protocol = check["protocol"].(string) if check["path"] != nil { p := check["path"].(string) - hc_req.Path = &p + if p != "" { + hc_req.Path = &p + } } hc_req.Port = int32(p) hc_req.Timeout = int32(t) @@ -259,8 +256,9 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } var err error + var resp oscgo.UpdateLoadBalancerResponse err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( context.Background()).UpdateLoadBalancerRequest(req).Execute() if err != nil { @@ -280,6 +278,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me d.SetId(req.LoadBalancerName) log.Printf("[INFO] LBU Attr ID: %s", d.Id()) + d.Set("request_id", resp.ResponseContext.RequestId) return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) } @@ -287,15 +286,11 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta conn := meta.(*OutscaleClient).OSCAPI elbName := d.Id() - lb, resp, err := readResourceLb(conn, elbName) + lb, _, err := readResourceLb(conn, elbName) if err != nil { return err } - if lb.AccessLog == nil { - return fmt.Errorf("NO Attributes FOUND") - } - a := lb.AccessLog if a != nil { @@ -311,9 +306,9 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", access) } - d.Set("listeners", flattenOAPIListeners(lb.Listeners)) - flattenOAPIHealthCheck(d, lb.HealthCheck) - d.Set("request_id", resp.ResponseContext.RequestId) + hls := make([]interface{}, 1) + hls[0] = flattenOAPIHealthCheck(lb.HealthCheck) + d.Set("health_check", hls) return nil } From c71765497e1e388a57e2356f852f1143baa11947 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 13 Nov 2020 17:28:23 +0100 Subject: [PATCH 127/218] fix path for real ? --- outscale/resource_outscale_load_balancer_attributes.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index b0e7ba571..f7a26fc89 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -75,7 +75,13 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "path": { Type: schema.TypeString, - Computed: true, + ForceNew: true, + DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool { + if new == "" && old == "/" { + return true + } + return old == new + }, Optional: true, }, "port": { From 1bbd82b449b384c46688c54ef8285a94ca1bdf03 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 13 Nov 2020 18:05:29 +0100 Subject: [PATCH 128/218] lbu attributes: use schema.TypeList instead of TypeMap Signed-off-by: Matthias Gatto --- .../resource_outscale_load_balancer_attributes.go | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index f7a26fc89..b4f37cc94 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -25,16 +25,16 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Schema: map[string]*schema.Schema{ "access_log": { - Type: schema.TypeMap, + Type: schema.TypeList, Optional: true, Computed: true, - ForceNew: true, + MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "is_enabled": { Type: schema.TypeBool, + Optional: true, Computed: true, - Required: true, }, "osu_bucket_name": { Type: schema.TypeString, @@ -48,6 +48,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "publication_interval": { Type: schema.TypeInt, + Optional: true, Computed: true, }, }, @@ -186,7 +187,8 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } if al, alok := d.GetOk("access_log"); alok { - dal := al.(map[string]interface{}) + dals := al.([]interface{}) + dal := dals[0].(map[string]interface{}) check, _ := dal["is_enabled"] is_enable := false if check == "true" { @@ -300,6 +302,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta a := lb.AccessLog if a != nil { + ac := make([]interface{}, 1) access := make(map[string]string) access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) @@ -309,7 +312,8 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta if a.OsuBucketPrefix != nil { access["osu_bucket_prefix"] = *a.OsuBucketPrefix } - d.Set("access_log", access) + ac[0] = access + d.Set("access_log", ac) } hls := make([]interface{}, 1) From c724d0a97c5eaba4f545721b760867849e58dd59 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 16 Nov 2020 16:51:28 +0100 Subject: [PATCH 129/218] try to fix access log Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 28 +++++++++++-------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index b4f37cc94..bddb141bc 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -28,6 +28,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Type: schema.TypeList, Optional: true, Computed: true, + ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ @@ -35,20 +36,22 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Type: schema.TypeBool, Optional: true, Computed: true, + ForceNew: true, }, "osu_bucket_name": { Type: schema.TypeString, - Computed: true, + ForceNew: true, Optional: true, }, "osu_bucket_prefix": { Type: schema.TypeString, - Computed: true, + ForceNew: true, Optional: true, }, "publication_interval": { Type: schema.TypeInt, Optional: true, + ForceNew: true, Computed: true, }, }, @@ -303,17 +306,18 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta if a != nil { ac := make([]interface{}, 1) - access := make(map[string]string) - access["publication_interval"] = strconv.Itoa(int(*a.PublicationInterval)) - access["is_enabled"] = strconv.FormatBool(*a.IsEnabled) - if a.OsuBucketName != nil { - access["osu_bucket_name"] = *a.OsuBucketName - } - if a.OsuBucketPrefix != nil { - access["osu_bucket_prefix"] = *a.OsuBucketPrefix - } + access := make(map[string]interface{}) + access["publication_interval"] = int(*a.PublicationInterval) + access["is_enabled"] = *a.IsEnabled + access["osu_bucket_name"] = a.OsuBucketName + access["osu_bucket_prefix"] = a.OsuBucketPrefix ac[0] = access - d.Set("access_log", ac) + err := d.Set("access_log", ac) + if err != nil { + return err + } + } else { + d.Set("access_log", make([]interface{}, 0)) } hls := make([]interface{}, 1) From d2c8687ed77dee5194792c64fa00d27e1d5d0c67 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Mon, 16 Nov 2020 16:33:52 +0000 Subject: [PATCH 130/218] fix missing request_id TPD-1907 Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_vms.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 9c8f4ad7f..9ce8526d7 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -93,7 +93,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac conn := meta.(*OutscaleClient).OSCAPI found := false e := d.Get("load_balancer_name").(string) - lb, _, err := readResourceLb(conn, e) + lb, resp, err := readResourceLb(conn, e) expected := d.Get("backend_vm_ids").([]interface{}) if err != nil { @@ -113,6 +113,7 @@ func resourceOutscaleOAPILBUAttachmentRead(d *schema.ResourceData, meta interfac log.Printf("[WARN] i %s not found in lbu attachments", expected) d.SetId("") } + d.Set("request_id", resp.ResponseContext.RequestId) return nil } From 1baa28719e502d9df846177d245e2eac5d37fc2f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 17 Nov 2020 15:34:28 +0100 Subject: [PATCH 131/218] small refacto Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer.go | 36 ++++++++++++--------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index d41b514a9..74acb863d 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -14,6 +14,25 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) +func lb_sg_schema() *schema.Schema { + return &schema.Schema{ + Type: schema.TypeMap, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "security_group_name": { + Type: schema.TypeString, + Computed: true, + }, + "security_group_account_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + } +} + func resourceOutscaleOAPILoadBalancer() *schema.Resource { return &schema.Resource{ Create: resourceOutscaleOAPILoadBalancerCreate, @@ -138,22 +157,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Schema: lb_listener_schema(), }, }, - "source_security_group": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "security_group_name": { - Type: schema.TypeString, - Computed: true, - }, - "security_group_account_id": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, + "source_security_group": lb_sg_schema(), "net_id": { Type: schema.TypeString, Computed: true, From 2970b1c309cf0fd6bd2fbed7ea2929dbb7662592 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 17 Nov 2020 15:37:54 +0100 Subject: [PATCH 132/218] Revert "fix load_balancer_attributes" This reverts commit 39839ad8a18251b59aafad81dd571a4ab72ee42f. --- outscale/resource_outscale_load_balancer_attributes.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index bddb141bc..aae763992 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -113,6 +113,15 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, + "listeners": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(), + }, + }, "load_balancer_port": { Type: schema.TypeInt, Optional: true, @@ -323,6 +332,7 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta hls := make([]interface{}, 1) hls[0] = flattenOAPIHealthCheck(lb.HealthCheck) d.Set("health_check", hls) + d.Set("listeners", flattenOAPIListeners(lb.Listeners)) return nil } From 32725acf8a8fbc824bcd8b6791c3f776827b0093 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 17 Nov 2020 16:54:12 +0100 Subject: [PATCH 133/218] add arguments Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 74 ++++++++++++++++++- 1 file changed, 73 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index aae763992..ab644a1f9 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -115,7 +115,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "listeners": { Type: schema.TypeSet, - Optional: true, Computed: true, ForceNew: true, Elem: &schema.Resource{ @@ -127,16 +126,53 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Optional: true, ForceNew: true, }, + + "server_certificate_id": { Type: schema.TypeString, Optional: true, ForceNew: true, }, + "source_security_group": lb_sg_schema(), + "application_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": { + Type: schema.TypeString, + Computed: true, + }, + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_name": { Type: schema.TypeString, Required: true, ForceNew: true, }, + "load_balancer_type": { + Type: schema.TypeString, + Computed: true, + ForceNew: true, + }, "policy_names": { Type: schema.TypeList, ForceNew: true, @@ -329,6 +365,42 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("access_log", make([]interface{}, 0)) } + sgr := make(map[string]string) + if lb.SourceSecurityGroup != nil { + sgr["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName + sgr["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId + } + d.Set("source_security_group", sgr) + + if lb.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, + len(*lb.ApplicationStickyCookiePolicies)) + for k, v := range *lb.ApplicationStickyCookiePolicies { + a := make(map[string]interface{}) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName + app[k] = a + } + d.Set("application_sticky_cookie_policies", app) + } else { + d.Set("application_sticky_cookie_policies", + make([]map[string]interface{}, 0)) + } + + if lb.LoadBalancerStickyCookiePolicies == nil { + d.Set("load_balancer_sticky_cookie_policies", + make([]map[string]interface{}, 0)) + } else { + lbc := make([]map[string]interface{}, + len(*lb.LoadBalancerStickyCookiePolicies)) + for k, v := range *lb.LoadBalancerStickyCookiePolicies { + a := make(map[string]interface{}) + a["policy_name"] = v.PolicyName + lbc[k] = a + } + d.Set("load_balancer_sticky_cookie_policies", lbc) + } + hls := make([]interface{}, 1) hls[0] = flattenOAPIHealthCheck(lb.HealthCheck) d.Set("health_check", hls) From f831d4e2abd902d55959ab4207ec8377d8ebf73f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 17 Nov 2020 17:01:14 +0100 Subject: [PATCH 134/218] add tags Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index ab644a1f9..d3cc777f5 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -127,6 +127,24 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { ForceNew: true, }, + "tags": { + Type: schema.TypeSet, + Computed: true, + Optional: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "key": { + Type: schema.TypeString, + Computed: true, + }, + "value": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, "server_certificate_id": { Type: schema.TypeString, @@ -372,6 +390,20 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta } d.Set("source_security_group", sgr) + if lb.Tags != nil { + ta := make([]map[string]interface{}, len(*lb.Tags)) + for k1, v1 := range *lb.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + } + if lb.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, len(*lb.ApplicationStickyCookiePolicies)) From ffec807d8fa048c2fe56d2b5e241f8e9d606cb24 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 17 Nov 2020 17:31:00 +0100 Subject: [PATCH 135/218] add all load_balancer_attributes arguments Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 52 ++++++++++++++++++- 1 file changed, 50 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index d3cc777f5..1b5fb793b 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -121,6 +121,19 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Schema: lb_listener_schema(), }, }, + + "subnets": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + + "subregion_names": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer_port": { Type: schema.TypeInt, Optional: true, @@ -130,8 +143,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "tags": { Type: schema.TypeSet, Computed: true, - Optional: true, - ForceNew: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "key": { @@ -146,12 +157,33 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, + "dns_name": { + Type: schema.TypeString, + Computed: true, + }, + + "security_groups": { + Type: schema.TypeSet, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "server_certificate_id": { Type: schema.TypeString, Optional: true, ForceNew: true, }, + "source_security_group": lb_sg_schema(), + + "backend_vm_ids": { + Type: schema.TypeList, + Computed: true, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + }, + "application_sticky_cookie_policies": { Type: schema.TypeList, Computed: true, @@ -168,6 +200,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, }, + "load_balancer_sticky_cookie_policies": { Type: schema.TypeList, Computed: true, @@ -390,6 +423,12 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta } d.Set("source_security_group", sgr) + if lb.SecurityGroups != nil { + d.Set("security_groups", flattenStringList(lb.SecurityGroups)) + } else { + d.Set("security_groups", make([]map[string]interface{}, 0)) + } + if lb.Tags != nil { ta := make([]map[string]interface{}, len(*lb.Tags)) for k1, v1 := range *lb.Tags { @@ -404,6 +443,12 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta d.Set("tags", make([]map[string]interface{}, 0)) } + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) + + d.Set("subnets", flattenStringList(lb.Subnets)) + + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) + if lb.ApplicationStickyCookiePolicies != nil { app := make([]map[string]interface{}, len(*lb.ApplicationStickyCookiePolicies)) @@ -437,6 +482,9 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta hls[0] = flattenOAPIHealthCheck(lb.HealthCheck) d.Set("health_check", hls) d.Set("listeners", flattenOAPIListeners(lb.Listeners)) + + d.Set("dns_name", lb.DnsName) + return nil } From 381b857cc9e4bed98071ae89d2b2211d48b8ba4d Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 19 Nov 2020 15:55:48 +0100 Subject: [PATCH 136/218] add code for nothing ? Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 2 +- ...cale_load_balancer_listener_description.go | 2 +- ...ale_load_balancer_listener_descriptions.go | 2 +- .../data_source_outscale_load_balancers.go | 2 +- outscale/oapi_tags.go | 16 ++++++ outscale/resource_outscale_load_balancer.go | 55 +++++++++++-------- ...ource_outscale_load_balancer_attributes.go | 21 +------ 7 files changed, 54 insertions(+), 46 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index be160a800..f4e922276 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -89,7 +89,7 @@ func attrLBchema() map[string]*schema.Schema { Computed: true, Optional: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(true), }, }, "firewall_rules_set_name": { diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go index 84173fdd1..f2fb9e4c9 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ b/outscale/data_source_outscale_load_balancer_listener_description.go @@ -17,7 +17,7 @@ func attrLBListenerDesc() map[string]*schema.Schema { Type: schema.TypeMap, Computed: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(true), }, }, "request_id": { diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go index f79937e2a..60a873fea 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions.go @@ -20,7 +20,7 @@ func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { Type: schema.TypeSet, Computed: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(true), }, }, "request_id": { diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 10e135b42..21d0e1d91 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -106,7 +106,7 @@ func attrLBSchema() map[string]*schema.Schema { Type: schema.TypeSet, Required: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(true), }, }, "application_sticky_cookie_policies": { diff --git a/outscale/oapi_tags.go b/outscale/oapi_tags.go index 09bf0d082..07e0a4009 100644 --- a/outscale/oapi_tags.go +++ b/outscale/oapi_tags.go @@ -82,6 +82,22 @@ func tagsOAPIListSchemaComputed() *schema.Schema { } } +func tagsListOAPISchema2(computed bool) *schema.Schema { + return &schema.Schema{ + Type: schema.TypeSet, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "key": mk_elem(computed, false, !computed, + schema.TypeString), + "value": mk_elem(computed, false, !computed, + schema.TypeString), + }, + }, + Optional: true, + Computed: computed, + } +} + func tagsListOAPISchema() *schema.Schema { return &schema.Schema{ Type: schema.TypeSet, diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 74acb863d..c304999c6 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -75,7 +75,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "tags": tagsListOAPISchema(), + "tags": tagsListOAPISchema2(false), "dns_name": { Type: schema.TypeString, @@ -154,7 +154,7 @@ func resourceOutscaleOAPILoadBalancer() *schema.Resource { Type: schema.TypeSet, Required: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(false), }, }, "source_security_group": lb_sg_schema(), @@ -327,29 +327,38 @@ func expandListenerForCreation(configured []interface{}) ([]oscgo.ListenerForCre return listeners, nil } -func lb_listener_schema() map[string]*schema.Schema { - return map[string]*schema.Schema{ - "backend_port": { - Type: schema.TypeInt, - Required: true, - }, - "backend_protocol": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_port": { - Type: schema.TypeInt, - Required: true, - }, - "load_balancer_protocol": { - Type: schema.TypeString, +func mk_elem(computed bool, required bool, optional bool, + t schema.ValueType) *schema.Schema { + if computed { + return &schema.Schema{ + Type: t, + Computed: true, + } + } else if required { + return &schema.Schema{ + Type: t, Required: true, - }, - "server_certificate_id": { - Type: schema.TypeString, + } + } else { + return &schema.Schema{ + Type: t, Optional: true, - Computed: true, - }, + } + } +} + +func lb_listener_schema(computed bool) map[string]*schema.Schema { + return map[string]*schema.Schema{ + "backend_port": mk_elem(computed, !computed, false, + schema.TypeInt), + "backend_protocol": mk_elem(computed, !computed, false, + schema.TypeString), + "load_balancer_port": mk_elem(computed, !computed, false, + schema.TypeInt), + "load_balancer_protocol": mk_elem(computed, !computed, false, + schema.TypeString), + "server_certificate_id": mk_elem(computed, false, !computed, + schema.TypeString), "policy_names": { Type: schema.TypeList, Computed: true, diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 1b5fb793b..c2ba8538f 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -116,9 +116,8 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { "listeners": { Type: schema.TypeSet, Computed: true, - ForceNew: true, Elem: &schema.Resource{ - Schema: lb_listener_schema(), + Schema: lb_listener_schema(true), }, }, @@ -140,23 +139,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { ForceNew: true, }, - "tags": { - Type: schema.TypeSet, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "key": { - Type: schema.TypeString, - Computed: true, - }, - "value": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - + "tags": tagsListOAPISchema2(true), "dns_name": { Type: schema.TypeString, Computed: true, From 1df6c871b0bf5172fac6820d3dbd6ee6d93509b3 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 19 Nov 2020 16:06:50 +0100 Subject: [PATCH 137/218] simplify faltten listener Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancer.go | 10 ++-------- outscale/resource_outscale_load_balancer.go | 16 +++++++--------- 2 files changed, 9 insertions(+), 17 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index f4e922276..7ee5c54fe 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -266,14 +266,8 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) - if lb.Listeners != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { - return err - } - } else { - if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { - return err - } + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { + return err } d.Set("load_balancer_name", lb.LoadBalancerName) diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index c304999c6..3d2c58fdd 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -218,6 +218,10 @@ func expandSetStringList(ifs *schema.Set) *[]string { // Flattens an array of Listeners into a []map[string]interface{} func flattenOAPIListeners(list *[]oscgo.Listener) []map[string]interface{} { + if list == nil { + return make([]map[string]interface{}, 0) + } + result := make([]map[string]interface{}, 0, len(*list)) for _, i := range *list { @@ -517,15 +521,9 @@ func resourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interface d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) - if lb.Listeners != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { - log.Printf("[DEBUG] out err %v", err) - return err - } - } else { - if err := d.Set("listeners", make([]interface{}, 0)); err != nil { - return err - } + if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { + log.Printf("[DEBUG] out err %v", err) + return err } d.Set("load_balancer_name", lb.LoadBalancerName) From fb09ea13f2ee6ad7669252c32793462e554f1c20 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 19 Nov 2020 16:57:39 +0100 Subject: [PATCH 138/218] TPD-1926 outscale_load_balancer_vms_health -> outscale_load_balancer_vm_health Signed-off-by: Matthias Gatto --- outscale/provider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/provider.go b/outscale/provider.go index 2b7f29073..e7dd24610 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -135,7 +135,7 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_rules": dataSourceOutscaleOAPILoadBalancerLDRules(), "outscale_load_balancer_tags": dataSourceOutscaleOAPILBUTags(), "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), - "outscale_load_balancer_vms_health": dataSourceOutscaleLoadBalancerVmsHeals(), + "outscale_load_balancer_vm_health": dataSourceOutscaleLoadBalancerVmsHeals(), "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, From 6520dddad6f5de43ee99b0dda6af9594746d1a4c Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 19 Nov 2020 17:09:16 +0100 Subject: [PATCH 139/218] mv data_source_outscale_load_balancer_vms_health.go data_source_outscale_load_balancer_vm_health.go --- ..._health.go => data_source_outscale_load_balancer_vm_health.go} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename outscale/{data_source_outscale_load_balancer_vms_health.go => data_source_outscale_load_balancer_vm_health.go} (100%) diff --git a/outscale/data_source_outscale_load_balancer_vms_health.go b/outscale/data_source_outscale_load_balancer_vm_health.go similarity index 100% rename from outscale/data_source_outscale_load_balancer_vms_health.go rename to outscale/data_source_outscale_load_balancer_vm_health.go From a13c5299e51f00917d42775d63220ca54f870520 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Thu, 19 Nov 2020 15:14:12 +0000 Subject: [PATCH 140/218] fix load balancer policy TPD-1922 Signed-off-by: Thiery Ouattara --- .../resource_outscale_load_balancer_policy.go | 226 ++++++++++++++++++ 1 file changed, 226 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index 995db6006..86b026a11 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -33,6 +33,173 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { return }, }, + "access_log": { + Type: schema.TypeMap, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, + }, + }, + }, + "health_check": { + Type: schema.TypeMap, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "healthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "unhealthy_threshold": { + Type: schema.TypeString, + Computed: true, + }, + "path": { + Type: schema.TypeString, + Computed: true, + }, + "check_interval": { + Type: schema.TypeString, + Computed: true, + }, + "port": { + Type: schema.TypeString, + Computed: true, + }, + "protocol": { + Type: schema.TypeString, + Computed: true, + }, + "timeout": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "application_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "cookie_name": { + Type: schema.TypeString, + Computed: true, + }, + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "load_balancer_sticky_cookie_policies": { + Type: schema.TypeList, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "policy_name": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "listeners": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: lb_listener_schema(true), + }, + }, + "source_security_group": { + Type: schema.TypeMap, + Computed: true, + ForceNew: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "security_group_name": { + Type: schema.TypeString, + Computed: true, + }, + "security_group_account_id": { + Type: schema.TypeString, + Computed: true, + }, + }, + }, + }, + "net_id": { + Type: schema.TypeString, + Computed: true, + ForceNew: true, + }, + "backend_vm_ids": { + Type: schema.TypeList, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + }, + "subregion_names": { + Type: schema.TypeList, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "load_balancer_type": { + Type: schema.TypeString, + Optional: true, + Computed: true, + ForceNew: true, + }, + "security_groups": { + Type: schema.TypeSet, + Optional: true, + Computed: true, + ForceNew: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "subnets": { + Type: schema.TypeList, + Optional: true, + ForceNew: true, + Computed: true, + Elem: &schema.Schema{Type: schema.TypeString}, + }, + "tags": tagsListOAPISchema2(true), + + "dns_name": { + Type: schema.TypeString, + Computed: true, + ForceNew: true, + }, "policy_type": { Type: schema.TypeString, Required: true, @@ -106,11 +273,70 @@ func resourceOutscaleAppCookieStickinessPolicyCreate(d *schema.ResourceData, met if resp.ResponseContext != nil { reqID = *resp.ResponseContext.RequestId } + + if resp.LoadBalancer != nil { + lb := resp.LoadBalancer + d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) + d.Set("listeners", flattenOAPIListeners(lb.Listeners)) + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) + d.Set("load_balancer_type", lb.LoadBalancerType) + if lb.SecurityGroups != nil { + d.Set("security_groups", flattenStringList(lb.SecurityGroups)) + } else { + d.Set("security_groups", make([]map[string]interface{}, 0)) + } + d.Set("dns_name", lb.DnsName) + d.Set("subnets", flattenStringList(lb.Subnets)) + d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) + if lb.Tags != nil { + ta := make([]map[string]interface{}, len(*lb.Tags)) + for k1, v1 := range *lb.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + } + if lb.ApplicationStickyCookiePolicies != nil { + app := make([]map[string]interface{}, + len(*lb.ApplicationStickyCookiePolicies)) + for k, v := range *lb.ApplicationStickyCookiePolicies { + a := make(map[string]interface{}) + a["cookie_name"] = v.CookieName + a["policy_name"] = v.PolicyName + app[k] = a + } + d.Set("application_sticky_cookie_policies", app) + } + if lb.LoadBalancerStickyCookiePolicies != nil { + lbc := make([]map[string]interface{}, + len(*lb.LoadBalancerStickyCookiePolicies)) + for k, v := range *lb.LoadBalancerStickyCookiePolicies { + a := make(map[string]interface{}) + a["policy_name"] = v.PolicyName + lbc[k] = a + } + d.Set("load_balancer_sticky_cookie_policies", lbc) + } + ssg := make(map[string]string) + if lb.SourceSecurityGroup != nil { + ssg["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName + ssg["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId + } + d.Set("source_security_group", ssg) + d.Set("net_id", lb.NetId) + } + d.Set("request_id", reqID) d.SetId(resource.UniqueId()) d.Set("load_balancer_name", l.(string)) d.Set("policy_name", p.(string)) d.Set("policy_type", pt.(string)) + if cnok { d.Set("cookie_name", v.(string)) } From b3cd5bd2caf8efa846ac64aaf34982198d76f6b5 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 19 Nov 2020 17:49:05 +0100 Subject: [PATCH 141/218] TPD-1925: fix import Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_listeners_rule.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index 335975986..04fb536fc 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -20,6 +20,10 @@ func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { Read: resourceOutscaleLoadBalancerListenerRuleRead, Update: resourceOutscaleLoadBalancerListenerRuleUpdate, Delete: resourceOutscaleLoadBalancerListenerRuleDelete, + Importer: &schema.ResourceImporter{ + State: schema.ImportStatePassthrough, + }, + Schema: map[string]*schema.Schema{ "vm_ids": { Type: schema.TypeSet, From 28cee59b933e8c14495d5be1dac2dbb371ccd3ad Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 20 Nov 2020 12:41:03 +0100 Subject: [PATCH 142/218] access log Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index c2ba8538f..5af627f6e 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -272,25 +272,26 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me dals := al.([]interface{}) dal := dals[0].(map[string]interface{}) check, _ := dal["is_enabled"] - is_enable := false - if check == "true" { - is_enable = true - } - access := &oscgo.AccessLog{ - IsEnabled: &is_enable, + access := &oscgo.AccessLog{} + + if check != nil { + is_enable := check.(bool) + access.IsEnabled = &is_enable } - if v, ok := lb_atoi_at(dal, "publication_interval"); ok { - pi := int32(v) + if v := dal["publication_interval"]; v != nil { + pi := int32(v.(int)) access.PublicationInterval = &pi } + obn := dal["osu_bucket_name"] - if obn != nil { + if obn != nil && obn.(string) != "" { obn_s := obn.(string) access.OsuBucketName = &obn_s } + obp := dal["osu_bucket_prefix"] - if obp != nil { + if obp != nil && obp.(string) != "" { obp_s := obp.(string) access.OsuBucketPrefix = &obp_s } From 0aac6ccaf00c7908f0ff48e8140c9ac7f4265ede Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 10:50:43 +0100 Subject: [PATCH 143/218] data_source_outscale_load_balancer_listener_rules.go request_id Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer_listener_rules.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index 6768e61da..2fe4c5cc2 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -46,13 +46,13 @@ func attrLBListenerRules() map[string]*schema.Schema { Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, }, }, }, + "request_id": { + Type: schema.TypeString, + Computed: true, + }, } } From fdbbd4798f99fdd1301c0fa6be1b99485f48700f Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 11:01:26 +0100 Subject: [PATCH 144/218] resource_outscale_load_balancer_listeners_rule.go listener_id and listener_rule_id Signed-off-by: Matthias Gatto --- ...source_outscale_load_balancer_listeners_rule.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index 04fb536fc..18011726c 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -70,6 +70,14 @@ func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { Type: schema.TypeString, Required: true, }, + "listener_rule_id": { + Type: schema.TypeInt, + Computed: true, + }, + "listener_id": { + Type: schema.TypeInt, + Computed: true, + }, "path_pattern": { Type: schema.TypeString, Computed: true, @@ -213,6 +221,12 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i if lr.ListenerRuleName != nil { lrs["listener_rule_name"] = lr.ListenerRuleName } + if lr.ListenerRuleId != nil { + lrs["listener_rule_id"] = lr.ListenerRuleId + } + if lr.ListenerId != nil { + lrs["listener_id"] = lr.ListenerId + } if lr.PathPattern != nil { lrs["path_pattern"] = lr.PathPattern } From 1c07b8382f4d2ebc5f48f88b781315e035537d4c Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 16:32:55 +0100 Subject: [PATCH 145/218] resource_outscale_load_balancer_attributes: try to fix policy Signed-off-by: Matthias Gatto --- ...ource_outscale_load_balancer_attributes.go | 128 +++++++++++++----- 1 file changed, 96 insertions(+), 32 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 5af627f6e..53fc63988 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -17,6 +17,7 @@ import ( func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { return &schema.Resource{ Create: resourceOutscaleOAPILoadBalancerAttributesCreate, + Update: resourceOutscaleOAPILoadBalancerAttributesUpdate, Read: resourceOutscaleOAPILoadBalancerAttributesRead, Delete: resourceOutscaleOAPILoadBalancerAttributesDelete, Importer: &schema.ResourceImporter{ @@ -209,7 +210,6 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "policy_names": { Type: schema.TypeList, - ForceNew: true, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}, }, @@ -236,9 +236,46 @@ func lb_atoi_at(hc map[string]interface{}, el string) (int, bool) { return r, err == nil } +func resourceOutscaleOAPILoadBalancerAttributesUpdate(d *schema.ResourceData, + meta interface{}) error { + return resourceOutscaleOAPILoadBalancerAttributesCreate_(d, meta, true) +} + func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, meta interface{}) error { + return resourceOutscaleOAPILoadBalancerAttributesCreate_(d, meta, false) +} + +func loadBalancerAttributesDoRequest(d *schema.ResourceData, meta interface{}, req oscgo.UpdateLoadBalancerRequest) error { conn := meta.(*OutscaleClient).OSCAPI + var err error + var resp oscgo.UpdateLoadBalancerResponse + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background()).UpdateLoadBalancerRequest(req).Execute() + + if err != nil { + if strings.Contains(fmt.Sprint(err), "400 Bad Request") { + return resource.NonRetryableError(err) + } + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId(req.LoadBalancerName) + log.Printf("[INFO] LBU Attr ID: %s", d.Id()) + d.Set("request_id", resp.ResponseContext.RequestId) + return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) + +} + +func resourceOutscaleOAPILoadBalancerAttributesCreate_(d *schema.ResourceData, meta interface{}, isUpdate bool) error { ename, ok := d.GetOk("load_balancer_name") if !ok { @@ -254,11 +291,6 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me req.LoadBalancerPort = &port_i } - if ssl, sok := d.GetOk("server_certificate_id"); sok { - ssl_s := ssl.(string) - req.ServerCertificateId = &ssl_s - } - if pol_names, plnok := d.GetOk("policy_names"); plnok { m := pol_names.([]interface{}) a := make([]string, len(m)) @@ -266,6 +298,18 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me a[k] = v.(string) } req.PolicyNames = &a + } else if isUpdate { + a := make([]string, 0) + + req.PolicyNames = &a + } + if isUpdate { + return loadBalancerAttributesDoRequest(d, meta, req) + } + + if ssl, sok := d.GetOk("server_certificate_id"); sok { + ssl_s := ssl.(string) + req.ServerCertificateId = &ssl_s } if al, alok := d.GetOk("access_log"); alok { @@ -346,31 +390,7 @@ func resourceOutscaleOAPILoadBalancerAttributesCreate(d *schema.ResourceData, me } - var err error - var resp oscgo.UpdateLoadBalancerResponse - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( - context.Background()).UpdateLoadBalancerRequest(req).Execute() - - if err != nil { - if strings.Contains(fmt.Sprint(err), "400 Bad Request") { - return resource.NonRetryableError(err) - } - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) - } - return nil - }) - - if err != nil { - return err - } - - d.SetId(req.LoadBalancerName) - log.Printf("[INFO] LBU Attr ID: %s", d.Id()) - - d.Set("request_id", resp.ResponseContext.RequestId) - return resourceOutscaleOAPILoadBalancerAttributesRead(d, meta) + return loadBalancerAttributesDoRequest(d, meta, req) } func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta interface{}) error { @@ -473,8 +493,52 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta } func resourceOutscaleOAPILoadBalancerAttributesDelete(d *schema.ResourceData, meta interface{}) error { + var err error + var resp oscgo.UpdateLoadBalancerResponse - d.SetId("") + conn := meta.(*OutscaleClient).OSCAPI + ename, ok := d.GetOk("load_balancer_name") + if !ok { + return fmt.Errorf("required load_balancer_name attributes") + } + + _, ok = d.GetOk("policy_names") + if !ok { + return nil + } + a := make([]string, 0) + + p, pok := d.GetOk("load_balancer_port") + if !pok { + return fmt.Errorf("required load_balancer_port attributes") + } + p32 := int32(p.(int)) + + req := oscgo.UpdateLoadBalancerRequest{ + LoadBalancerName: ename.(string), + PolicyNames: &a, + LoadBalancerPort: &p32, + } + + err = resource.Retry(5*time.Minute, func() *resource.RetryError { + resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + context.Background()).UpdateLoadBalancerRequest(req).Execute() + + if err != nil { + if strings.Contains(fmt.Sprint(err), "400 Bad Request") { + return resource.NonRetryableError(err) + } + return resource.RetryableError( + fmt.Errorf("[WARN] Error creating LBU Attr: %s", err)) + } + return nil + }) + + if err != nil { + return err + } + + d.SetId("") return nil } From 418b4162e268d45b69de05a6adebb458b1db7d12 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 17:07:57 +0100 Subject: [PATCH 146/218] lbu policy: fix conflict Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_policy.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index 86b026a11..f2f6752af 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -366,7 +366,8 @@ func resourceOutscaleAppCookieStickinessPolicyDelete(d *schema.ResourceData, met DeleteLoadBalancerPolicyRequest(request).Execute() if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { + if strings.Contains(fmt.Sprint(err), "Throttling") || + strings.Contains(fmt.Sprint(err), "Conflict") { return resource.RetryableError( fmt.Errorf("[WARN] Error deleting App stickiness policy, retrying: %s", err)) } From 07fca82e51c4d180597dc4593024d648aadc9ffc Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 17:42:10 +0100 Subject: [PATCH 147/218] resource_outscale_load_balancer_attributes: remove unused variable Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_attributes.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 53fc63988..69b459ceb 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -494,7 +494,6 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta func resourceOutscaleOAPILoadBalancerAttributesDelete(d *schema.ResourceData, meta interface{}) error { var err error - var resp oscgo.UpdateLoadBalancerResponse conn := meta.(*OutscaleClient).OSCAPI ename, ok := d.GetOk("load_balancer_name") @@ -522,7 +521,7 @@ func resourceOutscaleOAPILoadBalancerAttributesDelete(d *schema.ResourceData, me } err = resource.Retry(5*time.Minute, func() *resource.RetryError { - resp, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( + _, _, err = conn.LoadBalancerApi.UpdateLoadBalancer( context.Background()).UpdateLoadBalancerRequest(req).Execute() if err != nil { From 1bdb7f85722c3defee0280a86dc3d919ef5de54d Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Mon, 23 Nov 2020 18:21:20 +0100 Subject: [PATCH 148/218] fix listeners not showinf in lbu policy and attributes Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_attributes.go | 5 ++--- outscale/resource_outscale_load_balancer_policy.go | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index 69b459ceb..dd3509e8b 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -115,7 +115,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, }, "listeners": { - Type: schema.TypeSet, + Type: schema.TypeList, Computed: true, Elem: &schema.Resource{ Schema: lb_listener_schema(true), @@ -147,7 +147,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { }, "security_groups": { - Type: schema.TypeSet, + Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, }, @@ -486,7 +486,6 @@ func resourceOutscaleOAPILoadBalancerAttributesRead(d *schema.ResourceData, meta hls[0] = flattenOAPIHealthCheck(lb.HealthCheck) d.Set("health_check", hls) d.Set("listeners", flattenOAPIListeners(lb.Listeners)) - d.Set("dns_name", lb.DnsName) return nil diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index f2f6752af..e812bb367 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -127,7 +127,7 @@ func resourceOutscaleAppCookieStickinessPolicy() *schema.Resource { }, }, "listeners": { - Type: schema.TypeSet, + Type: schema.TypeList, Optional: true, Computed: true, ForceNew: true, From a7da1c7e0044eab069329dd5507094ab8ba66bd6 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 14:16:02 +0100 Subject: [PATCH 149/218] tags Signed-off-by: Matthias Gatto --- outscale/oapi_tags.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/outscale/oapi_tags.go b/outscale/oapi_tags.go index 07e0a4009..9309fb8cf 100644 --- a/outscale/oapi_tags.go +++ b/outscale/oapi_tags.go @@ -83,8 +83,14 @@ func tagsOAPIListSchemaComputed() *schema.Schema { } func tagsListOAPISchema2(computed bool) *schema.Schema { + stype := schema.TypeSet + + if computed { + stype = schema.TypeList + } + return &schema.Schema{ - Type: schema.TypeSet, + Type: stype, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "key": mk_elem(computed, false, !computed, From 0f7e22ab85cd64b2f1b5b3a38a5f8dd0227badfc Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Tue, 24 Nov 2020 15:25:50 +0000 Subject: [PATCH 150/218] fix load balancer datasource TPD-1906 Signed-off-by: Thiery Ouattara --- .../data_source_outscale_load_balancer.go | 78 ++++++++++++------- 1 file changed, 51 insertions(+), 27 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 7ee5c54fe..2ddff6049 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -15,7 +15,7 @@ import ( func attrLBchema() map[string]*schema.Schema { return map[string]*schema.Schema{ - "subregion_name": { + "subregion_names": { Type: schema.TypeList, Computed: true, Elem: &schema.Schema{Type: schema.TypeString}, @@ -30,25 +30,50 @@ func attrLBchema() map[string]*schema.Schema { Optional: true, Computed: true, }, - "security_groups_member": { + "security_groups": { Type: schema.TypeList, Computed: true, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "subnets_member": { + "subnets": { Type: schema.TypeList, Computed: true, Optional: true, Elem: &schema.Schema{Type: schema.TypeString}, }, - "tag": tagsSchema(), - + "source_security_group": lb_sg_schema(), + "tag": tagsListOAPISchema2(true), "dns_name": { Type: schema.TypeString, Computed: true, Optional: true, }, + "access_log": { + Type: schema.TypeMap, + Optional: true, + Computed: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "is_enabled": { + Type: schema.TypeBool, + Computed: true, + }, + "osu_bucket_name": { + Type: schema.TypeString, + Computed: true, + }, + "osu_bucket_prefix": { + Type: schema.TypeString, + Computed: true, + }, + "publication_interval": { + Type: schema.TypeInt, + Computed: true, + }, + }, + }, + }, "health_check": { Type: schema.TypeMap, Computed: true, @@ -92,27 +117,11 @@ func attrLBchema() map[string]*schema.Schema { Schema: lb_listener_schema(true), }, }, - "firewall_rules_set_name": { - Type: schema.TypeMap, - Computed: true, - Optional: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "firewall_rules_set_name": { - Type: schema.TypeString, - Computed: true, - }, - "account_alias": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, "net_id": { Type: schema.TypeString, Optional: true, Computed: true, + ForceNew: true, }, "application_sticky_cookie_policies": { Type: schema.TypeList, @@ -257,13 +266,15 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa conn := meta.(*OutscaleClient).OSCAPI lb, resp, err := readLbs0(conn, d) + if err != nil { return err } - d.Set("subregion_name", flattenStringList(lb.SubregionNames)) + d.Set("subregion_names", flattenStringList(lb.SubregionNames)) d.Set("dns_name", lb.DnsName) d.Set("health_check", flattenOAPIHealthCheck(lb.HealthCheck)) + d.Set("access_log", flattenOAPIAccessLog(lb.AccessLog)) d.Set("backend_vm_ids", flattenStringList(lb.BackendVmIds)) if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { @@ -297,20 +308,33 @@ func dataSourceOutscaleOAPILoadBalancerRead(d *schema.ResourceData, meta interfa d.Set("load_balancer_sticky_cookie_policies", lbc) } + if lb.Tags != nil { + ta := make([]map[string]interface{}, len(*lb.Tags)) + for k1, v1 := range *lb.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + } d.Set("load_balancer_type", lb.LoadBalancerType) if lb.SecurityGroups != nil { - d.Set("security_groups_member", flattenStringList(lb.SecurityGroups)) + d.Set("security_groups", flattenStringList(lb.SecurityGroups)) } else { - d.Set("security_groups_member", make([]map[string]interface{}, 0)) + d.Set("security_groups", make([]map[string]interface{}, 0)) } ssg := make(map[string]string) if lb.SourceSecurityGroup != nil { ssg["security_group_account_id"] = *lb.SourceSecurityGroup.SecurityGroupAccountId ssg["security_group_name"] = *lb.SourceSecurityGroup.SecurityGroupName } - d.Set("firewall_rules_set_name", ssg) - d.Set("subnets_member", flattenStringList(lb.Subnets)) + d.Set("net_id", lb.NetId) + d.Set("source_security_group", ssg) + d.Set("subnets", flattenStringList(lb.Subnets)) d.Set("request_id", resp.ResponseContext.RequestId) d.SetId(*lb.LoadBalancerName) From 4e2c0c522dfde811e03818e34c9ae8442e86479c Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Tue, 24 Nov 2020 15:52:57 +0000 Subject: [PATCH 151/218] fix tags Signed-off-by: Thiery Ouattara --- outscale/data_source_outscale_load_balancer.go | 2 +- outscale/data_source_outscale_load_balancers.go | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 2ddff6049..e4a6212bd 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -43,7 +43,7 @@ func attrLBchema() map[string]*schema.Schema { Elem: &schema.Schema{Type: schema.TypeString}, }, "source_security_group": lb_sg_schema(), - "tag": tagsListOAPISchema2(true), + "tags": tagsListOAPISchema2(true), "dns_name": { Type: schema.TypeString, Computed: true, diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 21d0e1d91..410f15f96 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -141,6 +141,7 @@ func attrLBSchema() map[string]*schema.Schema { Type: schema.TypeString, Computed: true, }, + "tags": tagsListOAPISchema2(true), "security_groups": { Type: schema.TypeList, Computed: true, @@ -244,6 +245,18 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf l["load_balancer_sticky_cookie_policies"] = make([]map[string]interface{}, 0) } + if v.Tags != nil { + ta := make([]map[string]interface{}, len(*v.Tags)) + for k1, v1 := range *v.Tags { + t := make(map[string]interface{}) + t["key"] = v1.Key + t["value"] = v1.Value + ta[k1] = t + } + d.Set("tags", ta) + } else { + d.Set("tags", make([]map[string]interface{}, 0)) + } l["load_balancer_type"] = v.LoadBalancerType l["security_groups"] = flattenStringList(v.SecurityGroups) From 9ae63e2ef60c72ba2227a5d322cacaaf5e8477ae Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Tue, 24 Nov 2020 16:02:32 +0000 Subject: [PATCH 152/218] fix multi_listeners Signed-off-by: Thiery Ouattara --- outscale/data_source_outscale_load_balancer.go | 2 +- outscale/data_source_outscale_load_balancers.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index e4a6212bd..604eda4ca 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -110,7 +110,7 @@ func attrLBchema() map[string]*schema.Schema { Elem: &schema.Schema{Type: schema.TypeString}, }, "listeners": { - Type: schema.TypeSet, + Type: schema.TypeList, Computed: true, Optional: true, Elem: &schema.Resource{ diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 410f15f96..c00a97427 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -103,7 +103,7 @@ func attrLBSchema() map[string]*schema.Schema { }, }, "listeners": { - Type: schema.TypeSet, + Type: schema.TypeList, Required: true, Elem: &schema.Resource{ Schema: lb_listener_schema(true), From 67a181401a2e9d97f8401dcb2052f7af94ae4e88 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 17:52:11 +0100 Subject: [PATCH 153/218] listener_rule use TypeList instead of TypeMap Signed-off-by: Matthias Gatto --- ...e_outscale_load_balancer_listeners_rule.go | 42 ++++++++++++------- 1 file changed, 26 insertions(+), 16 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index 18011726c..c6b31fd85 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -4,7 +4,6 @@ import ( "context" "fmt" "log" - "strconv" "strings" "time" @@ -32,18 +31,21 @@ func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { Elem: &schema.Schema{Type: schema.TypeString}, }, "listener": { - Type: schema.TypeMap, + Type: schema.TypeList, + MaxItems: 1, ForceNew: true, Required: true, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "load_balancer_name": { Type: schema.TypeString, - Computed: true, + ForceNew: true, + Required: true, }, "load_balancer_port": { Type: schema.TypeInt, - Computed: true, + ForceNew: true, + Required: true, }, }, }, @@ -53,17 +55,20 @@ func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { Computed: true, }, "listener_rule": { - Type: schema.TypeMap, + Type: schema.TypeList, Required: true, + MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "action": { Type: schema.TypeString, + Optional: true, ForceNew: true, Computed: true, }, "host_name_pattern": { Type: schema.TypeString, + Optional: true, Computed: true, }, "listener_rule_name": { @@ -80,6 +85,8 @@ func resourceOutscaleLoadBalancerListenerRule() *schema.Resource { }, "path_pattern": { Type: schema.TypeString, + Optional: true, + ForceNew: true, Computed: true, }, "priority": { @@ -105,15 +112,13 @@ func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta } if li, lok := d.GetOk("listener"); lok { - l := li.(map[string]interface{}) + ls := li.([]interface{}) + l := ls[0].(map[string]interface{}) ll := oscgo.LoadBalancerLight{} if l["load_balancer_name"] == nil || l["load_balancer_port"] == nil { return fmt.Errorf("listener missing argument ") } - lbpii, erratoi := strconv.Atoi(l["load_balancer_port"].(string)) - if erratoi != nil { - return fmt.Errorf("can't convert load_balancer_port") - } + lbpii := l["load_balancer_port"].(int) lbpi := int32(lbpii) ll.SetLoadBalancerName(l["load_balancer_name"].(string)) ll.SetLoadBalancerPort(lbpi) @@ -123,7 +128,9 @@ func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta } if lri, lok := d.GetOk("listener_rule"); lok { - lr := lri.(map[string]interface{}) + lrs := lri.([]interface{}) + lr := lrs[0].(map[string]interface{}) + lrfc := oscgo.ListenerRuleForCreation{} if lr["priority"] == nil { return fmt.Errorf("listener priority argument missing") @@ -140,10 +147,7 @@ func resourceOutscaleLoadBalancerListenerRuleCreate(d *schema.ResourceData, meta if lr["listener_rule_name"] != nil { lrfc.SetListenerRuleName(lr["listener_rule_name"].(string)) } - p, erratoi := strconv.Atoi(lr["priority"].(string)) - if erratoi != nil { - return fmt.Errorf("can't convert priority") - } + p := lr["priority"].(int) lrfc.SetPriority(int32(p)) req.SetListenerRule(lrfc) } else { @@ -210,6 +214,7 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i return fmt.Errorf("can't find listener rule") } lr := (*resp.ListenerRules)[0] + lrsl := make([]interface{}, 1) lrs := make(map[string]interface{}) if lr.Action != nil { @@ -226,6 +231,7 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i } if lr.ListenerId != nil { lrs["listener_id"] = lr.ListenerId + log.Printf("set listener_id") } if lr.PathPattern != nil { lrs["path_pattern"] = lr.PathPattern @@ -233,7 +239,11 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i if lr.Priority != nil { lrs["priority"] = lr.Priority } - d.Set("listener_rule %p", lrs) + lrsl[0] = lrs + err = d.Set("listener_rule", lrsl) + if err != nil { + return err + } if lr.VmIds != nil { d.Set("vm_ids", flattenStringList(lr.VmIds)) } From 16f3672780a60c1150a8840a3f9c723631b2028c Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 17:55:09 +0100 Subject: [PATCH 154/218] remove printf Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_listeners_rule.go | 1 - 1 file changed, 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index c6b31fd85..fe00867da 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -231,7 +231,6 @@ func resourceOutscaleLoadBalancerListenerRuleRead(d *schema.ResourceData, meta i } if lr.ListenerId != nil { lrs["listener_id"] = lr.ListenerId - log.Printf("set listener_id") } if lr.PathPattern != nil { lrs["path_pattern"] = lr.PathPattern From 9ab1e8e3252d15dda6f4b599178513095e46d660 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 18:01:29 +0100 Subject: [PATCH 155/218] data_source_outscale_load_balancers tags Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancers.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index c00a97427..72488691d 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -253,9 +253,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf t["value"] = v1.Value ta[k1] = t } - d.Set("tags", ta) - } else { - d.Set("tags", make([]map[string]interface{}, 0)) + l["tags"] = ta; } l["load_balancer_type"] = v.LoadBalancerType From 42d6e0783d7c589402d961a1aadd041b1986f2ad Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 18:13:26 +0100 Subject: [PATCH 156/218] fmt code Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index 72488691d..b1245a5cc 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -253,7 +253,7 @@ func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interf t["value"] = v1.Value ta[k1] = t } - l["tags"] = ta; + l["tags"] = ta } l["load_balancer_type"] = v.LoadBalancerType From 6282484ad72d7abc2d36640ea612484ac5e9ff2d Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 19:08:57 +0100 Subject: [PATCH 157/218] datasource load_balancer_listener_rules: add listener_rule_id and listener_id Signed-off-by: Matthias Gatto --- ...source_outscale_load_balancer_listener_rule.go | 15 +++++++++++++++ ...ource_outscale_load_balancer_listener_rules.go | 15 +++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go index 14d683999..243b140d3 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rule.go +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -36,6 +36,14 @@ func attrLBListenerRule() map[string]*schema.Schema { Type: schema.TypeInt, Computed: true, }, + "listener_rule_id": { + Type: schema.TypeInt, + Computed: true, + }, + "listener_id": { + Type: schema.TypeInt, + Computed: true, + }, "vm_ids": { Type: schema.TypeSet, Computed: true, @@ -133,6 +141,13 @@ func dataSourceOutscaleOAPILoadBalancerLDRuleRead(d *schema.ResourceData, meta i d.Set("path_pattern", lr.PathPattern) } + if lr.ListenerRuleId != nil { + d.Set("listener_rule_id", lr.ListenerRuleId) + } + if lr.ListenerId != nil { + d.Set("listener_id", lr.ListenerId) + } + if lr.Priority != nil { d.Set("priority", lr.Priority) } else { diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index 2fe4c5cc2..0fcb24b21 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -41,6 +41,14 @@ func attrLBListenerRules() map[string]*schema.Schema { Type: schema.TypeInt, Computed: true, }, + "listener_rule_id": { + Type: schema.TypeInt, + Computed: true, + }, + "listener_id": { + Type: schema.TypeInt, + Computed: true, + }, "vm_ids": { Type: schema.TypeSet, Computed: true, @@ -146,6 +154,13 @@ func dataSourceOutscaleOAPILoadBalancerLDRulesRead(d *schema.ResourceData, meta l["path_pattern"] = lr.PathPattern } + if lr.ListenerRuleId != nil { + l["listener_rule_id"] = lr.ListenerRuleId + } + if lr.ListenerId != nil { + l["listener_id"] = lr.ListenerId + } + if lr.Priority != nil { l["priority"] = lr.Priority } else { From aec108e552f173dc0968350138195fcaca58cbfc Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Tue, 24 Nov 2020 20:05:11 +0100 Subject: [PATCH 158/218] re rebase Signed-off-by: Matthias Gatto --- outscale/data_source_outscale_load_balancer.go | 2 +- outscale/data_source_outscale_load_balancer_attributes_test.go | 2 +- .../data_source_outscale_load_balancer_health_check_test.go | 2 +- ...a_source_outscale_load_balancer_listener_description_test.go | 2 +- ..._source_outscale_load_balancer_listener_descriptions_test.go | 2 +- outscale/data_source_outscale_load_balancer_listener_rule.go | 2 +- outscale/data_source_outscale_load_balancer_listener_rules.go | 2 +- outscale/data_source_outscale_load_balancer_tags.go | 2 +- outscale/data_source_outscale_load_balancer_test.go | 2 +- outscale/data_source_outscale_load_balancer_vm_health.go | 2 +- outscale/resource_outscale_internet_service_link.go | 1 - outscale/resource_outscale_load_balancer.go | 2 +- outscale/resource_outscale_load_balancer_attributes.go | 2 +- outscale/resource_outscale_load_balancer_attributes_test.go | 2 +- outscale/resource_outscale_load_balancer_listeners_rule.go | 2 +- outscale/resource_outscale_load_balancer_listeners_test.go | 2 +- outscale/resource_outscale_load_balancer_policy.go | 2 +- outscale/resource_outscale_load_balancer_policy_test.go | 2 +- outscale/resource_outscale_load_balancer_test.go | 2 +- outscale/resource_outscale_load_balancer_vms.go | 2 +- outscale/resource_outscale_load_balancer_vms_test.go | 2 +- 21 files changed, 20 insertions(+), 21 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 604eda4ca..64fb8ea69 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go index e60c33369..a65b0e65a 100644 --- a/outscale/data_source_outscale_load_balancer_attributes_test.go +++ b/outscale/data_source_outscale_load_balancer_attributes_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go index 3a48fe6da..70bc90272 100644 --- a/outscale/data_source_outscale_load_balancer_health_check_test.go +++ b/outscale/data_source_outscale_load_balancer_health_check_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go index 51e482d0f..e15e28bbd 100644 --- a/outscale/data_source_outscale_load_balancer_listener_description_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_description_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go index f8466cf23..22a919bbd 100644 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go +++ b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_listener_rule.go b/outscale/data_source_outscale_load_balancer_listener_rule.go index 243b140d3..ddc3af24a 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rule.go +++ b/outscale/data_source_outscale_load_balancer_listener_rule.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_listener_rules.go b/outscale/data_source_outscale_load_balancer_listener_rules.go index 0fcb24b21..7f7f3fc3d 100644 --- a/outscale/data_source_outscale_load_balancer_listener_rules.go +++ b/outscale/data_source_outscale_load_balancer_listener_rules.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_tags.go b/outscale/data_source_outscale_load_balancer_tags.go index c80b727b4..9d2f86343 100644 --- a/outscale/data_source_outscale_load_balancer_tags.go +++ b/outscale/data_source_outscale_load_balancer_tags.go @@ -6,7 +6,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index bfe6fa0d1..3466ea174 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -3,7 +3,7 @@ package outscale import ( "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) diff --git a/outscale/data_source_outscale_load_balancer_vm_health.go b/outscale/data_source_outscale_load_balancer_vm_health.go index 205d4eef9..e86396857 100644 --- a/outscale/data_source_outscale_load_balancer_vm_health.go +++ b/outscale/data_source_outscale_load_balancer_vm_health.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_internet_service_link.go b/outscale/resource_outscale_internet_service_link.go index 26df4c1c3..3e98bdf47 100644 --- a/outscale/resource_outscale_internet_service_link.go +++ b/outscale/resource_outscale_internet_service_link.go @@ -3,7 +3,6 @@ package outscale import ( "context" "fmt" - "strings" "time" oscgo "github.com/outscale/osc-sdk-go/v2" diff --git a/outscale/resource_outscale_load_balancer.go b/outscale/resource_outscale_load_balancer.go index 3d2c58fdd..055833f7e 100644 --- a/outscale/resource_outscale_load_balancer.go +++ b/outscale/resource_outscale_load_balancer.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index dd3509e8b..c367e48d8 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -8,7 +8,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index af396d600..166afbe46 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -4,7 +4,7 @@ import ( "fmt" "testing" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listeners_rule.go index fe00867da..892ba2cfa 100644 --- a/outscale/resource_outscale_load_balancer_listeners_rule.go +++ b/outscale/resource_outscale_load_balancer_listeners_rule.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go index a1ebe3df3..ea74eebb7 100644 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ b/outscale/resource_outscale_load_balancer_listeners_test.go @@ -2,7 +2,7 @@ package outscale import ( "fmt" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" diff --git a/outscale/resource_outscale_load_balancer_policy.go b/outscale/resource_outscale_load_balancer_policy.go index e812bb367..3f9fcc45e 100644 --- a/outscale/resource_outscale_load_balancer_policy.go +++ b/outscale/resource_outscale_load_balancer_policy.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index 23e48583d..a58ae5841 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index c3de248ce..9932a897c 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" diff --git a/outscale/resource_outscale_load_balancer_vms.go b/outscale/resource_outscale_load_balancer_vms.go index 9ce8526d7..7f427d11d 100644 --- a/outscale/resource_outscale_load_balancer_vms.go +++ b/outscale/resource_outscale_load_balancer_vms.go @@ -7,7 +7,7 @@ import ( "strings" "time" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/helper/schema" diff --git a/outscale/resource_outscale_load_balancer_vms_test.go b/outscale/resource_outscale_load_balancer_vms_test.go index 2d9d5f511..fc6fbb66b 100644 --- a/outscale/resource_outscale_load_balancer_vms_test.go +++ b/outscale/resource_outscale_load_balancer_vms_test.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" "github.com/hashicorp/terraform-plugin-sdk/terraform" - oscgo "github.com/outscale/osc-sdk-go/osc" + oscgo "github.com/outscale/osc-sdk-go/v2" ) func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { From 4df9095f76b54cc395dbcdc95adc60db6a2ea1aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20L=C3=B3pez?= Date: Tue, 7 Jul 2020 14:37:44 -0500 Subject: [PATCH 159/218] refactor: changed the name of ds from outscale_vms_state to outscale_vm_states --- outscale/data_source_outscale_vms_state.go | 14 +++++++------- outscale/data_source_outscale_vms_state_test.go | 8 ++++---- outscale/dictionary.go | 2 +- outscale/provider.go | 2 +- website/docs/d/vms_state.html.markdown | 4 ++-- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/outscale/data_source_outscale_vms_state.go b/outscale/data_source_outscale_vms_state.go index 32570f529..9dbce5af6 100644 --- a/outscale/data_source_outscale_vms_state.go +++ b/outscale/data_source_outscale_vms_state.go @@ -13,14 +13,14 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/schema" ) -func dataSourceOutscaleOAPIVMSState() *schema.Resource { +func dataSourceOutscaleOAPIVMStates() *schema.Resource { return &schema.Resource{ - Read: dataSourceOutscaleOAPIVMSStateRead, - Schema: getOAPIVMSStateDataSourceSchema(), + Read: dataSourceOutscaleOAPIVMStatesRead, + Schema: getOAPIVMStatesDataSourceSchema(), } } -func getOAPIVMSStateDataSourceSchema() map[string]*schema.Schema { +func getOAPIVMStatesDataSourceSchema() map[string]*schema.Schema { wholeSchema := map[string]*schema.Schema{ "filter": dataSourceFiltersSchema(), "vm_ids": { @@ -44,7 +44,7 @@ func getOAPIVMSStateDataSourceSchema() map[string]*schema.Schema { return wholeSchema } -func dataSourceOutscaleOAPIVMSStateRead(d *schema.ResourceData, meta interface{}) error { +func dataSourceOutscaleOAPIVMStatesRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI filters, filtersOk := d.GetOk("filter") @@ -90,10 +90,10 @@ func dataSourceOutscaleOAPIVMSStateRead(d *schema.ResourceData, meta interface{} if err := d.Set("request_id", resp.ResponseContext.GetRequestId()); err != nil { return err } - return statusDescriptionOAPIVMSStateAttributes(d, filteredStates) + return statusDescriptionOAPIVMStatesAttributes(d, filteredStates) } -func statusDescriptionOAPIVMSStateAttributes(d *schema.ResourceData, status []oscgo.VmStates) error { +func statusDescriptionOAPIVMStatesAttributes(d *schema.ResourceData, status []oscgo.VmStates) error { d.SetId(resource.UniqueId()) states := make([]map[string]interface{}, len(status)) diff --git a/outscale/data_source_outscale_vms_state_test.go b/outscale/data_source_outscale_vms_state_test.go index 15431cc9c..4e89db433 100644 --- a/outscale/data_source_outscale_vms_state_test.go +++ b/outscale/data_source_outscale_vms_state_test.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) -func TestAccDataSourceOutscaleOAPIVMSState(t *testing.T) { +func TestAccDataSourceOutscaleOAPIVMStates(t *testing.T) { omi := os.Getenv("OUTSCALE_IMAGEID") resource.Test(t, resource.TestCase{ @@ -16,13 +16,13 @@ func TestAccDataSourceOutscaleOAPIVMSState(t *testing.T) { Providers: testAccProviders, Steps: []resource.TestStep{ { - Config: testAccDataSourceOutscaleOAPIVMSStateConfig(omi, "tinav4.c2r2p2"), + Config: testAccDataSourceOutscaleOAPIVMStatesConfig(omi, "tinav4.c2r2p2"), }, }, }) } -func testAccDataSourceOutscaleOAPIVMSStateConfig(omi, vmType string) string { +func testAccDataSourceOutscaleOAPIVMStatesConfig(omi, vmType string) string { return fmt.Sprintf(` resource "outscale_vm" "basic" { image_id = "%s" @@ -30,7 +30,7 @@ func testAccDataSourceOutscaleOAPIVMSStateConfig(omi, vmType string) string { keypair_name = "terraform-basic" } - data "outscale_vms_state" "state" { + data "outscale_vm_states" "state" { vm_ids = ["${outscale_vm.basic.id}"] } `, omi, vmType) diff --git a/outscale/dictionary.go b/outscale/dictionary.go index f6d1433b4..022e0670f 100644 --- a/outscale/dictionary.go +++ b/outscale/dictionary.go @@ -69,7 +69,7 @@ func init() { "outscale_subnet": dataSourceOutscaleOAPISubnet, "outscale_subnets": dataSourceOutscaleOAPISubnets, "outscale_vm_state": dataSourceOutscaleOAPIVMState, - "outscale_vms_state": dataSourceOutscaleOAPIVMSState, + "outscale_vm_states": dataSourceOutscaleOAPIVMStates, "outscale_net": dataSourceOutscaleOAPIVpc, "outscale_nets": dataSourceOutscaleOAPIVpcs, "outscale_net_attributes": dataSourceOutscaleOAPIVpcAttr, diff --git a/outscale/provider.go b/outscale/provider.go index e7dd24610..21cddbed0 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -99,7 +99,7 @@ func Provider() terraform.ResourceProvider { "outscale_keypair": datasourceOutscaleOAPIKeyPair(), "outscale_keypairs": datasourceOutscaleOAPIKeyPairs(), "outscale_vm_state": dataSourceOutscaleOAPIVMState(), - "outscale_vms_state": dataSourceOutscaleOAPIVMSState(), + "outscale_vm_states": dataSourceOutscaleOAPIVMStates(), "outscale_internet_service": datasourceOutscaleOAPIInternetService(), "outscale_internet_services": datasourceOutscaleOAPIInternetServices(), "outscale_subnet": dataSourceOutscaleOAPISubnet(), diff --git a/website/docs/d/vms_state.html.markdown b/website/docs/d/vms_state.html.markdown index 7470baef5..9b04884a4 100644 --- a/website/docs/d/vms_state.html.markdown +++ b/website/docs/d/vms_state.html.markdown @@ -6,7 +6,7 @@ description: |- [Provides information about VM states.] --- -# outscale_vms_state Data Source +# outscale_vm_states Data Source Provides information about VM states. For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Instance+Lifecycle). @@ -16,7 +16,7 @@ For more information on this resource actions, see the [API documentation](https ```hcl -data "outscale_vms_state" "vm_states01" { +data "outscale_vm_states" "vm_states01" { filter { name = "vm_ids" values = ["i-12345678", "i-12345679"] From db9cc9fee3c86603a89b9938a700fbc208b43cc2 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 26 Nov 2020 15:14:45 +0100 Subject: [PATCH 160/218] fix test ? Signed-off-by: Matthias Gatto --- ..._outscale_load_balancer_attributes_test.go | 6 ++++-- ...urce_outscale_load_balancer_policy_test.go | 20 +++++++++---------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index 166afbe46..95f2b4845 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -66,8 +66,10 @@ resource "outscale_load_balancer" "bar" { } resource "outscale_load_balancer_attributes" "bar2" { - is_enabled = "false" - osu_bucket_prefix = "donustestbucket" + "access_log" { + is_enabled = "false" + osu_bucket_prefix = "donustestbucket" + } load_balancer_name = "${outscale_load_balancer.bar.id}" } `, r) diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index a58ae5841..a1ea7bfac 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -132,14 +132,14 @@ resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" availability_zones = ["eu-west-2a"] listeners { - instance_port = 8000 - instance_protocol = "HTTP" + backend_port = 8000 + backend_protocol = "HTTP" load_balancer_port = 80 - protocol = "HTTP" + load_balancer_protocol = "HTTP" } } -resource "outscale_load_balancer_cookiepolicy" "foo" { +resource "outscale_load_balancer_policy" "foo" { policy_name = "foo-policy" load_balancer_name = "${outscale_load_balancer.lb.id}" cookie_name = "MyAppCookie" @@ -153,10 +153,10 @@ resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" availability_zones = ["eu-west-2a"] listeners { - instance_port = 8000 - instance_protocol = "HTTP" + backend_port = 8000 + backend_protocol = "HTTP" load_balancer_port = 80 - protocol = "HTTP" + load_balancer_protocol = "HTTP" } } @@ -174,10 +174,10 @@ resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" availability_zones = ["eu-west-2a"] listeners { - instance_port = 8000 - instance_protocol = "HTTP" + backend_port = 8000 + backend_protocol = "HTTP" load_balancer_port = 80 - protocol = "HTTP" + load_balancer_protocol = "HTTP" } }`, rName) } From 6c186b6474a126237a9920a5a732b47f6c158a02 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 26 Nov 2020 16:22:04 +0100 Subject: [PATCH 161/218] TPD-1914 Signed-off-by: Francisco Preciado --- outscale/resource_outscale_client_gateway.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_client_gateway.go b/outscale/resource_outscale_client_gateway.go index 4c22f74de..bb7b7818f 100644 --- a/outscale/resource_outscale_client_gateway.go +++ b/outscale/resource_outscale_client_gateway.go @@ -185,11 +185,11 @@ func clientGatewayRefreshFunc(conn *oscgo.APIClient, gatewayID *string) resource } resp, _, err := conn.ClientGatewayApi.ReadClientGateways(context.Background()).ReadClientGatewaysRequest(filter).Execute() - if err != nil { + if err != nil || len(resp.GetClientGateways()) == 0 { switch { case strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:"): return nil, "pending", nil - case strings.Contains(fmt.Sprint(err), "404"): + case strings.Contains(fmt.Sprint(err), "404") || len(resp.GetClientGateways()) == 0: return nil, "deleted", nil default: return nil, "failed", fmt.Errorf("Error on clientGatewayRefresh: %s", err) From 85365378b43e86ff5b05b60ab0014987696b1f20 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 26 Nov 2020 16:33:02 +0100 Subject: [PATCH 162/218] make fmt Signed-off-by: Matthias Gatto --- outscale/resource_outscale_client_gateway.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_client_gateway.go b/outscale/resource_outscale_client_gateway.go index bb7b7818f..740700936 100644 --- a/outscale/resource_outscale_client_gateway.go +++ b/outscale/resource_outscale_client_gateway.go @@ -189,7 +189,7 @@ func clientGatewayRefreshFunc(conn *oscgo.APIClient, gatewayID *string) resource switch { case strings.Contains(fmt.Sprint(err), "RequestLimitExceeded:"): return nil, "pending", nil - case strings.Contains(fmt.Sprint(err), "404") || len(resp.GetClientGateways()) == 0: + case strings.Contains(fmt.Sprint(err), "404") || len(resp.GetClientGateways()) == 0: return nil, "deleted", nil default: return nil, "failed", fmt.Errorf("Error on clientGatewayRefresh: %s", err) From 4131bfd398dd4580769d8cd28fd35f893dec97b0 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Thu, 26 Nov 2020 19:03:02 +0100 Subject: [PATCH 163/218] remove unused test Signed-off-by: Matthias Gatto --- ...utscale_load_balancer_health_check_test.go | 69 ---------------- ...cale_load_balancer_ssl_certificate_test.go | 82 ------------------- 2 files changed, 151 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_health_check_test.go delete mode 100644 outscale/resource_outscale_load_balancer_ssl_certificate_test.go diff --git a/outscale/resource_outscale_load_balancer_health_check_test.go b/outscale/resource_outscale_load_balancer_health_check_test.go deleted file mode 100644 index 3e6cae2d8..000000000 --- a/outscale/resource_outscale_load_balancer_health_check_test.go +++ /dev/null @@ -1,69 +0,0 @@ -package outscale - -import ( - "fmt" - "testing" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPIHealthCheck_basic(t *testing.T) { - r := acctest.RandIntRange(0, 10) - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer_health_check.test", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccOutscaleOAPIHealthCheckConfig(r), - Check: resource.ComposeTestCheckFunc( - resource.TestCheckResourceAttr( - "outscale_load_balancer_health_check.test", "health_check.healthy_threshold", "2"), - resource.TestCheckResourceAttr( - "outscale_load_balancer_health_check.test", "health_check.unhealthy_threshold", "4"), - resource.TestCheckResourceAttr( - "outscale_load_balancer_health_check.test", "health_check.checked_vm", "HTTP:8000/index.html"), - resource.TestCheckResourceAttr( - "outscale_load_balancer_health_check.test", "health_check.interval", "5"), - resource.TestCheckResourceAttr( - "outscale_load_balancer_health_check.test", "health_check.timeout", "5"), - )}, - }, - }) -} - -func testAccOutscaleOAPIHealthCheckConfig(r int) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-%d" - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - -} - -resource "outscale_load_balancer_health_check" "test" { - load_balancer_name = "${outscale_load_balancer.bar.id}" - health_check { - healthy_threshold = 2 - unhealthy_threshold = 4 - check_interval = 5 - timeout = 5 - checked_vm = "HTTP:8000/index.html" - } -} -`, r) -} diff --git a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go b/outscale/resource_outscale_load_balancer_ssl_certificate_test.go deleted file mode 100644 index 0b0d04145..000000000 --- a/outscale/resource_outscale_load_balancer_ssl_certificate_test.go +++ /dev/null @@ -1,82 +0,0 @@ -package outscale - -import ( - "fmt" - "testing" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleLBUOAPISSLCertificate_basic(t *testing.T) { - //WIP: Missing correct test case - rInt := acctest.RandIntRange(0, 10) - unixFile := "test-fixtures/eim-ssl-unix-line-endings.pem" - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer_ssl_certificate.test", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccOutscaleOAPISSLCertificateConfig(rInt, unixFile), - Check: resource.ComposeTestCheckFunc( - resource.TestCheckResourceAttr( - "outscale_load_balancer_ssl_certificate.test", "ssl_certificate.load_balancer_port", "80"), - ), - }, - }, - }) -} - -func testAccOutscaleOAPISSLCertificateConfig(r int, fName string) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-lbu-%d" - listeners { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - -} - -resource "outscale_server_certificate" "test_cert" { - server_certificate_name = "terraform-test-cert-%d" - server_certificate_body = "${file("%s")}" - private_key = < Date: Thu, 26 Nov 2020 19:20:39 +0100 Subject: [PATCH 164/218] remove another unused test Signed-off-by: Matthias Gatto --- ...e_outscale_load_balancer_listeners_test.go | 64 ------------------- 1 file changed, 64 deletions(-) delete mode 100644 outscale/resource_outscale_load_balancer_listeners_test.go diff --git a/outscale/resource_outscale_load_balancer_listeners_test.go b/outscale/resource_outscale_load_balancer_listeners_test.go deleted file mode 100644 index ea74eebb7..000000000 --- a/outscale/resource_outscale_load_balancer_listeners_test.go +++ /dev/null @@ -1,64 +0,0 @@ -package outscale - -import ( - "fmt" - oscgo "github.com/outscale/osc-sdk-go/v2" - "testing" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPILBUUpdate_Listener(t *testing.T) { - var conf oscgo.LoadBalancer - r := acctest.RandIntRange(0, 10) - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer_listeners.bar", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccOutscaleOAPILBUListenersConfig(r), - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleOAPILBUExists("outscale_load_balancer_listeners.bar", &conf), - testAccCheckOutscaleOAPILBUAttributes(&conf), - resource.TestCheckResourceAttr( - "outscale_load_balancer_listeners.bar", "listener.0.backend_port", "9000"), - ), - }, - }, - }) -} - -func testAccOutscaleOAPILBUListenersConfig(r int) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "lb" { - subregion_names = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-lbu-%d" - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - tag { - bar = "baz" - } - -} - -resource "outscale_load_balancer_listeners" "bar" { - load_balancer_name = "${outscale_load_balancer.lb.id}" - listener { - backend_port = 9000 - backend_protocol = "HTTP" - load_balancer_port = 9000 - load_balancer_protocol = "HTTP" - } -} -`, r) -} From 7fdc147f30aefb91b651274044de3005f7c4366d Mon Sep 17 00:00:00 2001 From: "meriem.zouari" Date: Fri, 27 Nov 2020 08:19:14 +0000 Subject: [PATCH 165/218] LBU resources examples --- examples/LBU_resources_examples.tf | 251 +++++++++++++++++++++++++++++ 1 file changed, 251 insertions(+) create mode 100644 examples/LBU_resources_examples.tf diff --git a/examples/LBU_resources_examples.tf b/examples/LBU_resources_examples.tf new file mode 100644 index 000000000..1e7a95c34 --- /dev/null +++ b/examples/LBU_resources_examples.tf @@ -0,0 +1,251 @@ +#---Public LBU------------------------------------------------------------------ +resource "outscale_load_balancer" "public_lbu-01" { + load_balancer_name = "lbu-01" + subregion_names = ["${var.region}a"] + listeners { + backend_port = 80 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 80 + } + listeners { + backend_port = 1024 + backend_protocol = "TCP" + load_balancer_protocol = "TCP" + load_balancer_port = 1024 + } + tags { + key = "name" + value = "public_lbu-01" + } +} +#-------------------------------------------------------------------------------- + +#---Private LBU------------------------------------------------------------------ +resource "outscale_net" "Net-01" { + ip_range = "10.0.0.0/16" +} + +resource "outscale_route_table" "Route_Table-01" { + net_id = outscale_net.Net-01.net_id +} + +resource "outscale_security_group" "SG-1" { + description = "test group" + security_group_name = "sg1-terraform-lbu-test" + net_id = outscale_net.Net-01.net_id +} + +resource "outscale_security_group" "SG-2" { + description = "test group-2" + security_group_name = "sg2-terraform-lbu-test" + net_id = outscale_net.Net-01.net_id +} +resource "outscale_subnet" "Subnet-1" { + net_id = outscale_net.Net-01.net_id + ip_range = "10.0.0.0/24" +} + +resource "outscale_load_balancer" "internal_lbu" { + load_balancer_name = "lbu-internal" + subnets = [outscale_subnet.Subnet-1.subnet_id] + security_groups = [outscale_security_group.SG-1.id, outscale_security_group.SG-2.id] + load_balancer_type = "internal" + listeners { + backend_port = 80 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 80 + } + tags { + key = "name" + value = "internal_lbu" + } +} +#---------------------------------------------------------------------------- + +#---LBU Policies------------------------------------------------------------- +resource "outscale_load_balancer" "public_lbu-02" { + load_balancer_name = "lbu-02" + subregion_names = ["${var.region}a"] + listeners { + backend_port = 80 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 80 + } + tags { + key = "project" + value = "terraform" + } +} + +resource "outscale_load_balancer_policy" "policy-1" { + load_balancer_name = outscale_load_balancer.public_lbu-02.load_balancer_name + policy_name = "lbu-policy-1" + policy_type = "load_balancer" +} + +resource "outscale_load_balancer_policy" "policy-2" { + load_balancer_name = outscale_load_balancer.public_lbu-02.load_balancer_name + policy_name = "lbu-policy-2" + policy_type = "app" + cookie_name = "Cookie-2" +} + +#---------------------------------------------------------------------------- + +#---LBU Backend_vms--------------------------------------------------------- +resource "outscale_vm" "backend_vm" { + count = 2 + image_id = var.image_id + vm_type = var.vm_type + keypair_name = var.keypair_name +} + +resource "outscale_load_balancer" "public_lbu-03" { + load_balancer_name = "lbu-03" + subregion_names = ["${var.region}a"] + listeners { + backend_port = 80 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 80 + } +} + +resource "outscale_load_balancer_vms" "backend_vms" { + load_balancer_name = outscale_load_balancer.public_lbu-03.load_balancer_name + backend_vm_ids = [outscale_vm.backend_vm[0].vm_id,outscale_vm.backend_vm[1].vm_id] +} + +data "outscale_load_balancer_vm_health" "backend_vms_health" { + load_balancer_name = outscale_load_balancer.public_lbu-03.load_balancer_name + backend_vm_ids = [outscale_vm.backend_vm[0].vm_id,outscale_vm.backend_vm[1].vm_id] +depends_on = [outscale_load_balancer_vms.backend_vms] +} + +#---------------------------------------------------------------------------- + +#---LBU Update Attributes---------------------------------------------------- + +resource "outscale_load_balancer" "public_lbu-04" { + load_balancer_name = "lbu-04" + subregion_names = ["${var.region}a"] + listeners { + backend_port = 80 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 80 + } +} + +resource "outscale_load_balancer_attributes" "attributes-health_check" { + load_balancer_name = outscale_load_balancer.public_lbu-04.load_balancer_name + health_check { + healthy_threshold = 10 + check_interval = 30 + path = "/index.html" + port = 80 + protocol = "HTTP" + timeout = 5 + unhealthy_threshold = 5 + } +} + +resource "outscale_load_balancer_attributes" "attributes-access_log" { + load_balancer_name = outscale_load_balancer.public_lbu-04.load_balancer_name + access_log { + publication_interval = 5 + is_enabled = true + osu_bucket_name = "terraform-bucket" + osu_bucket_prefix = "access-logs" + } +} + +resource "outscale_load_balancer_attributes" "attributes-listener-policy" { + load_balancer_name = outscale_load_balancer.public_lbu-04.load_balancer_name + load_balancer_port = 80 + policy_names = ["lbu-policy-3"] +depends_on =[outscale_load_balancer_policy.policy-3] +} +resource "outscale_load_balancer_policy" "policy-3" { + load_balancer_name = outscale_load_balancer.public_lbu-04.load_balancer_name + policy_name = "lbu-policy-3" + policy_type = "load_balancer" +} + +#---------------------------------------------------------------------------- + +#---LBU datasource(s)-------------------------------------------------------- + +data "outscale_load_balancer" "public_lbu-01" { + filter { + name = "load_balancer_names" + values = ["lbu-01"] + } +depends_on = [outscale_load_balancer.public_lbu-01] +} + +data "outscale_load_balancers" "public_lbus" { + filter { + name = "load_balancer_names" + values = ["lbu-01","lbu-02"] + } +depends_on = [outscale_load_balancer.public_lbu-01,outscale_load_balancer.public_lbu-02] +} + +data "outscale_load_balancer_tags" "lbu_tags" { + load_balancer_names = ["lbu-01","lbu-02"] +depends_on = [outscale_load_balancer.public_lbu-01,outscale_load_balancer.public_lbu-02] +} + +#---------------------------------------------------------------------------- + +#---Listener Rules----------------------------------------------------------- +resource "outscale_load_balancer_listener_rule" "rule-1" { + listener { + load_balancer_name = outscale_load_balancer.public_lbu-03.load_balancer_name + load_balancer_port = 80 + } + + listener_rule { + action = "forward" + listener_rule_name = "listener-rule-1" + path_pattern = "*.abc.*.abc.*.com" + priority = 10 + } + vm_ids = [outscale_vm.backend_vm[0].vm_id] +} + +resource "outscale_load_balancer_listener_rule" "rule-2" { + listener { + load_balancer_name = outscale_load_balancer.public_lbu-03.load_balancer_name + load_balancer_port = 80 + } + + listener_rule { + action = "forward" + listener_rule_name = "listener-rule-2" + host_name_pattern = "*.abc.-.abc.*.com" + priority = 1 + } + vm_ids = [outscale_vm.backend_vm[1].vm_id] +} + +data "outscale_load_balancer_listener_rule" "listener_rule" { +filter { + name = "listener_rule_names" + values = ["listener-rule-2"] + } +depends_on =[outscale_load_balancer_listener_rule.rule-2] +} + +data "outscale_load_balancer_listener_rules" "listener_rules" { +filter { + name = "listener_rule_names" + values = ["listener-rule-2","listener-rule-1"] + } +depends_on =[outscale_load_balancer_listener_rule.rule-2,outscale_load_balancer_listener_rule.rule-1] +} +#---------------------------------------------------------------------------- From 4d456e067d163471f08c9b0a51ef53c2cf554e23 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 10:28:25 +0000 Subject: [PATCH 166/218] fix TPD-1939 Signed-off-by: Thiery Ouattara --- outscale/data_source_outscale_access_keys.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/data_source_outscale_access_keys.go b/outscale/data_source_outscale_access_keys.go index b27b73ada..95ff31773 100644 --- a/outscale/data_source_outscale_access_keys.go +++ b/outscale/data_source_outscale_access_keys.go @@ -126,7 +126,7 @@ func flattenAccessKeys(accessKeys []oscgo.AccessKey) []map[string]interface{} { "access_key_id": ak.GetAccessKeyId(), "creation_date": ak.GetCreationDate(), "last_modification_date": ak.GetLastModificationDate(), - "state": ak.GetLastModificationDate(), + "state": ak.GetState(), } } return accessKeysMap From a14f8107c9c994ea45224db90482c689bfa72d23 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 11:26:18 +0000 Subject: [PATCH 167/218] rename file TPD-1915 Signed-off-by: Thiery Ouattara --- ...ce_outscale_vms_state.go => data_source_outscale_vm_states.go} | 0 ...e_vms_state_test.go => data_source_outscale_vm_states_test.go} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename outscale/{data_source_outscale_vms_state.go => data_source_outscale_vm_states.go} (100%) rename outscale/{data_source_outscale_vms_state_test.go => data_source_outscale_vm_states_test.go} (100%) diff --git a/outscale/data_source_outscale_vms_state.go b/outscale/data_source_outscale_vm_states.go similarity index 100% rename from outscale/data_source_outscale_vms_state.go rename to outscale/data_source_outscale_vm_states.go diff --git a/outscale/data_source_outscale_vms_state_test.go b/outscale/data_source_outscale_vm_states_test.go similarity index 100% rename from outscale/data_source_outscale_vms_state_test.go rename to outscale/data_source_outscale_vm_states_test.go From a517c8a9852a4f2be132600044e86c12837663cd Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 12:18:39 +0100 Subject: [PATCH 168/218] access_log default Signed-off-by: Matthias Gatto --- outscale/resource_outscale_load_balancer_attributes.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/resource_outscale_load_balancer_attributes.go b/outscale/resource_outscale_load_balancer_attributes.go index c367e48d8..9cdf3d66f 100644 --- a/outscale/resource_outscale_load_balancer_attributes.go +++ b/outscale/resource_outscale_load_balancer_attributes.go @@ -53,7 +53,7 @@ func resourceOutscaleOAPILoadBalancerAttributes() *schema.Resource { Type: schema.TypeInt, Optional: true, ForceNew: true, - Computed: true, + Default: 60, }, }, }, From 272a20a5540a8fbcc74fe92e619c5a45f02178f9 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 13:19:49 +0000 Subject: [PATCH 169/218] rename listener_rule Signed-off-by: Thiery Ouattara --- ...s_rule.go => resource_outscale_load_balancer_listener_rule.go} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename outscale/{resource_outscale_load_balancer_listeners_rule.go => resource_outscale_load_balancer_listener_rule.go} (100%) diff --git a/outscale/resource_outscale_load_balancer_listeners_rule.go b/outscale/resource_outscale_load_balancer_listener_rule.go similarity index 100% rename from outscale/resource_outscale_load_balancer_listeners_rule.go rename to outscale/resource_outscale_load_balancer_listener_rule.go From 52ada99f870cd6c1ad921cc8e4767d55c3ab0734 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 14:36:49 +0100 Subject: [PATCH 170/218] remove unused data source Signed-off-by: Matthias Gatto --- ...urce_outscale_load_balancer_access_logs.go | 76 ------------- ...outscale_load_balancer_access_logs_test.go | 68 ------------ ...ource_outscale_load_balancer_attributes.go | 93 ---------------- ..._outscale_load_balancer_attributes_test.go | 64 ----------- ...rce_outscale_load_balancer_health_check.go | 86 --------------- ...utscale_load_balancer_health_check_test.go | 59 ---------- ...cale_load_balancer_listener_description.go | 68 ------------ ...load_balancer_listener_description_test.go | 52 --------- ...ale_load_balancer_listener_descriptions.go | 55 --------- ...oad_balancer_listener_descriptions_test.go | 52 --------- outscale/provider.go | 104 +++++++++--------- 11 files changed, 49 insertions(+), 728 deletions(-) delete mode 100644 outscale/data_source_outscale_load_balancer_access_logs.go delete mode 100644 outscale/data_source_outscale_load_balancer_access_logs_test.go delete mode 100644 outscale/data_source_outscale_load_balancer_attributes.go delete mode 100644 outscale/data_source_outscale_load_balancer_attributes_test.go delete mode 100644 outscale/data_source_outscale_load_balancer_health_check.go delete mode 100644 outscale/data_source_outscale_load_balancer_health_check_test.go delete mode 100644 outscale/data_source_outscale_load_balancer_listener_description.go delete mode 100644 outscale/data_source_outscale_load_balancer_listener_description_test.go delete mode 100644 outscale/data_source_outscale_load_balancer_listener_descriptions.go delete mode 100644 outscale/data_source_outscale_load_balancer_listener_descriptions_test.go diff --git a/outscale/data_source_outscale_load_balancer_access_logs.go b/outscale/data_source_outscale_load_balancer_access_logs.go deleted file mode 100644 index 7daa3af59..000000000 --- a/outscale/data_source_outscale_load_balancer_access_logs.go +++ /dev/null @@ -1,76 +0,0 @@ -package outscale - -import ( - "fmt" - - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func dataSourceOutscaleLoadBalancerAccessLogs() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleLoadBalancerAccessLogsRead, - Schema: getDataSourceSchemas(attrLBAccessLogsSchema()), - } -} - -func attrLBAccessLogsSchema() map[string]*schema.Schema { - return map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeInt, - Computed: true, - }, - "is_enabled": { - Type: schema.TypeBool, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - ForceNew: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - } -} - -func dataSourceOutscaleLoadBalancerAccessLogsRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - resp, elbName, err := readLbs(conn, d) - if err != nil { - return err - } - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", *elbName) - } - - lb := (lbs)[0] - - if lb.AccessLog == nil { - return fmt.Errorf("NO Attributes FOUND") - } - - //utils.PrintToJSON(resp, "RESPONSE =>") - - a := lb.AccessLog - - d.Set("publication_interval", a.PublicationInterval) - d.Set("is_enabled", a.IsEnabled) - d.Set("osu_bucket_name", a.OsuBucketName) - d.Set("osu_bucket_prefix", a.OsuBucketPrefix) - - d.SetId(*elbName) - d.Set("request_id", resp.ResponseContext.RequestId) - - return nil -} diff --git a/outscale/data_source_outscale_load_balancer_access_logs_test.go b/outscale/data_source_outscale_load_balancer_access_logs_test.go deleted file mode 100644 index 42f5bac05..000000000 --- a/outscale/data_source_outscale_load_balancer_access_logs_test.go +++ /dev/null @@ -1,68 +0,0 @@ -package outscale - -import ( - "fmt" - "testing" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/terraform" -) - -func TestAccOutscaleLoadBalancerAccessLogs_basic(t *testing.T) { - resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - Steps: []resource.TestStep{ - { - Config: testAccDSOutscaleLBUDSAccessLogsConfig, - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleLBUDSAccessLogsExists("data.outscale_load_balancer_access_logs.test"), - resource.TestCheckResourceAttr( - "data.outscale_load_balancer_access_logs.test", "enabled", "false"), - )}, - }, - }) -} - -func testAccCheckOutscaleLBUDSAccessLogsExists(n string) resource.TestCheckFunc { - return func(s *terraform.State) error { - rs, ok := s.RootModule().Resources[n] - if !ok { - return fmt.Errorf("Not found: %s", n) - } - - if rs.Primary.ID == "" { - return fmt.Errorf("No LBU Attr ID is set") - } - - return nil - } -} - -const testAccDSOutscaleLBUDSAccessLogsConfig = ` -resource "outscale_load_balancer" "bar" { - availability_zones = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-ds" - listeners { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - -} - -resource "outscale_load_balancer_attributes" "bar2" { - is_enabled = "false" - osu_bucket_name = "donustestbucket" - load_balancer_name = "${outscale_load_balancer.bar.id}" -} - -data "outscale_load_balancer_access_logs" "test" { - load_balancer_name = "${outscale_load_balancer.bar.id}" -} -` diff --git a/outscale/data_source_outscale_load_balancer_attributes.go b/outscale/data_source_outscale_load_balancer_attributes.go deleted file mode 100644 index 86f89435a..000000000 --- a/outscale/data_source_outscale_load_balancer_attributes.go +++ /dev/null @@ -1,93 +0,0 @@ -package outscale - -import ( - "fmt" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func dataSourceOutscaleOAPILoadBalancerAttr() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerAttrRead, - Schema: getDataSourceSchemas(lbAttrAttributes()), - } -} - -func lbAttrAttributes() map[string]*schema.Schema { - return map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "load_balancer_attributes": { - Type: schema.TypeList, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "access_log": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: map[string]*schema.Schema{ - "publication_interval": { - Type: schema.TypeString, - Computed: true, - }, - "is_enabled": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_name": { - Type: schema.TypeString, - Computed: true, - }, - "osu_bucket_prefix": { - Type: schema.TypeString, - Computed: true, - }, - }, - }, - }, - }, - }, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - } -} - -func dataSourceOutscaleOAPILoadBalancerAttrRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - resp, elbName, err := readLbs(conn, d) - if err != nil { - return err - } - - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", *elbName) - } - - lb := (lbs)[0] - - a := lb.AccessLog - - ld := make([]map[string]interface{}, 1) - acc := make(map[string]interface{}) - - acc["publication_interval"] = a.PublicationInterval - acc["is_enabled"] = a.IsEnabled - acc["osu_bucket_name"] = a.OsuBucketName - acc["osu_bucket_prefix"] = a.OsuBucketPrefix - - ld[0] = map[string]interface{}{"access_log": acc} - - d.Set("request_id", resp.ResponseContext.RequestId) - d.SetId(resource.UniqueId()) - - return d.Set("load_balancer_attributes", ld) -} diff --git a/outscale/data_source_outscale_load_balancer_attributes_test.go b/outscale/data_source_outscale_load_balancer_attributes_test.go deleted file mode 100644 index a65b0e65a..000000000 --- a/outscale/data_source_outscale_load_balancer_attributes_test.go +++ /dev/null @@ -1,64 +0,0 @@ -package outscale - -import ( - "fmt" - "testing" - - oscgo "github.com/outscale/osc-sdk-go/v2" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPIDSLBUAttr_basic(t *testing.T) { - t.Skip() - - r := acctest.RandIntRange(0, 10) - - var conf oscgo.LoadBalancer - - resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - IDRefreshName: "outscale_load_balancer.bar", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccDSOutscaleOAPILBUAttrConfig(r), - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - resource.TestCheckResourceAttr("data.outscale_load_balancer_attributes.test", "load_balancer_attributes.0.access_log.is_enabled", "false"), - )}, - }, - }) -} - -func testAccDSOutscaleOAPILBUAttrConfig(r int) string { - return fmt.Sprintf(` - resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-%d" - - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - } - - resource "outscale_load_balancer_attributes" "bar2" { - is_enabled = "false" - osu_bucket_name = "donustestbucket" - load_balancer_name = "${outscale_load_balancer.bar.id}" - } - - data "outscale_load_balancer_attributes" "test" { - load_balancer_name = "${outscale_load_balancer.bar.id}" - } - `, r) -} diff --git a/outscale/data_source_outscale_load_balancer_health_check.go b/outscale/data_source_outscale_load_balancer_health_check.go deleted file mode 100644 index a362d7186..000000000 --- a/outscale/data_source_outscale_load_balancer_health_check.go +++ /dev/null @@ -1,86 +0,0 @@ -package outscale - -import ( - "fmt" - - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func dataSourceOutscaleOAPILoadBalancerHealthCheck() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerHealthCheckRead, - Schema: getDataSourceSchemas( - map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "healthy_threshold": { - Type: schema.TypeInt, - Computed: true, - }, - "unhealthy_threshold": { - Type: schema.TypeInt, - Computed: true, - }, - "path": { - Type: schema.TypeString, - Computed: true, - }, - "check_interval": { - Type: schema.TypeInt, - Computed: true, - }, - "timeout": { - Type: schema.TypeInt, - Computed: true, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }), - } -} - -func dataSourceOutscaleOAPILoadBalancerHealthCheckRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - resp, elbName, err := readLbs(conn, d) - if err != nil { - return err - } - - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", *elbName) - } - - lb := (lbs)[0] - - if lb.AccessLog == nil { - return fmt.Errorf("NO Attributes FOUND") - } - - h := int32(0) - i := int32(0) - t := "" - ti := int32(0) - u := int32(0) - - h = lb.HealthCheck.HealthyThreshold - i = lb.HealthCheck.CheckInterval - t = *lb.HealthCheck.Path - ti = lb.HealthCheck.Timeout - u = lb.HealthCheck.UnhealthyThreshold - - d.Set("healthy_threshold", h) - d.Set("check_interval", i) - d.Set("path", t) - d.Set("timeout", ti) - d.Set("unhealthy_threshold", u) - - d.Set("request_id", resp.ResponseContext.RequestId) - d.SetId(*lb.LoadBalancerName) - - return nil -} diff --git a/outscale/data_source_outscale_load_balancer_health_check_test.go b/outscale/data_source_outscale_load_balancer_health_check_test.go deleted file mode 100644 index 70bc90272..000000000 --- a/outscale/data_source_outscale_load_balancer_health_check_test.go +++ /dev/null @@ -1,59 +0,0 @@ -package outscale - -import ( - "fmt" - "testing" - - oscgo "github.com/outscale/osc-sdk-go/v2" - - "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPIDSLBUH_basic(t *testing.T) { - var conf oscgo.LoadBalancer - rs := acctest.RandString(5) - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer.bar", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: getTestAccDSOutscaleOAPILBUHConfig(rs), - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - resource.TestCheckResourceAttrSet( - "data.outscale_load_balancer_health_check.test", "healthy_threshold"), - resource.TestCheckResourceAttrSet( - "data.outscale_load_balancer_health_check.test", "check_interval"), - )}, - }, - }) -} -func getTestAccDSOutscaleOAPILBUHConfig(r string) string { - return fmt.Sprintf(` - resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb-%s" - - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - } - - data "outscale_load_balancer_health_check" "test" { - load_balancer_name = "${outscale_load_balancer.bar.id}" - } - `, r) -} diff --git a/outscale/data_source_outscale_load_balancer_listener_description.go b/outscale/data_source_outscale_load_balancer_listener_description.go deleted file mode 100644 index f2fb9e4c9..000000000 --- a/outscale/data_source_outscale_load_balancer_listener_description.go +++ /dev/null @@ -1,68 +0,0 @@ -package outscale - -import ( - "fmt" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func attrLBListenerDesc() map[string]*schema.Schema { - return map[string]*schema.Schema{ - "load_balancer_name": { - Type: schema.TypeString, - Required: true, - }, - "listener": { - Type: schema.TypeMap, - Computed: true, - Elem: &schema.Resource{ - Schema: lb_listener_schema(true), - }, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - } -} - -func dataSourceOutscaleOAPILoadBalancerLD() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerRead, - Schema: getDataSourceSchemas(attrLBListenerDesc()), - } -} - -func dataSourceOutscaleOAPILoadBalancerLDRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - resp, elbName, err := readLbs(conn, d) - if err != nil { - return err - } - lbs := *resp.LoadBalancers - if len(lbs) != 1 { - return fmt.Errorf("Unable to find LBU: %s", *elbName) - } - - lb := (lbs)[0] - - v := (*lb.Listeners)[0] - - l := make(map[string]interface{}) - l["backend_port"] = v.BackendPort - l["backend_protocol"] = v.BackendProtocol - l["load_balancer_port"] = v.LoadBalancerPort - l["load_balancer_protocol"] = v.LoadBalancerProtocol - l["server_certificate_id"] = v.ServerCertificateId - - if err := d.Set("listener", l); err != nil { - return err - } - - d.Set("request_id", resp.ResponseContext.RequestId) - d.SetId(resource.UniqueId()) - - return d.Set("policy_name", flattenStringList(v.PolicyNames)) -} diff --git a/outscale/data_source_outscale_load_balancer_listener_description_test.go b/outscale/data_source_outscale_load_balancer_listener_description_test.go deleted file mode 100644 index e15e28bbd..000000000 --- a/outscale/data_source_outscale_load_balancer_listener_description_test.go +++ /dev/null @@ -1,52 +0,0 @@ -package outscale - -import ( - "testing" - - oscgo "github.com/outscale/osc-sdk-go/v2" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPIDSLBUListenerDesc_basic(t *testing.T) { - var conf oscgo.LoadBalancer - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer.bar", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccDSOutscaleOAPILBUListenerDescConfig, - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - resource.TestCheckResourceAttr("data.outscale_load_balancer_listener_description.test", "listener.backend_port", "8000"), - )}, - }, - }) -} - -const testAccDSOutscaleOAPILBUListenerDescConfig = ` - resource "outscale_load_balancer" "bar" { - subregion_name = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb" - - listeners { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - } - - data "outscale_load_balancer_listener_description" "test" { - load_balancer_name = "${outscale_load_balancer.bar.id}" - } -` diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions.go b/outscale/data_source_outscale_load_balancer_listener_descriptions.go deleted file mode 100644 index 60a873fea..000000000 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions.go +++ /dev/null @@ -1,55 +0,0 @@ -package outscale - -import ( - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" - "github.com/hashicorp/terraform-plugin-sdk/helper/schema" -) - -func dataSourceOutscaleOAPILoadBalancerLDs() *schema.Resource { - return &schema.Resource{ - Read: dataSourceOutscaleOAPILoadBalancerLDsRead, - - Schema: getDataSourceSchemas( - map[string]*schema.Schema{ - "load_balancer_names": { - Type: schema.TypeList, - Required: true, - Elem: &schema.Schema{Type: schema.TypeString}, - }, - "listeners": { - Type: schema.TypeSet, - Computed: true, - Elem: &schema.Resource{ - Schema: lb_listener_schema(true), - }, - }, - "request_id": { - Type: schema.TypeString, - Computed: true, - }, - }), - } -} - -func dataSourceOutscaleOAPILoadBalancerLDsRead(d *schema.ResourceData, meta interface{}) error { - conn := meta.(*OutscaleClient).OSCAPI - - lb, resp, err := readLbs0(conn, d) - if err != nil { - return err - } - - if lb.Listeners != nil { - if err := d.Set("listeners", flattenOAPIListeners(lb.Listeners)); err != nil { - return err - } - } else { - if err := d.Set("listeners", make([]map[string]interface{}, 0)); err != nil { - return err - } - } - d.Set("request_id", resp.ResponseContext.RequestId) - d.SetId(resource.UniqueId()) - - return nil -} diff --git a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go b/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go deleted file mode 100644 index 22a919bbd..000000000 --- a/outscale/data_source_outscale_load_balancer_listener_descriptions_test.go +++ /dev/null @@ -1,52 +0,0 @@ -package outscale - -import ( - "testing" - - oscgo "github.com/outscale/osc-sdk-go/v2" - - "github.com/hashicorp/terraform-plugin-sdk/helper/resource" -) - -func TestAccOutscaleOAPIDSLBUListenerDescs_basic(t *testing.T) { - var conf oscgo.LoadBalancer - - resource.Test(t, resource.TestCase{ - PreCheck: func() { - testAccPreCheck(t) - }, - IDRefreshName: "outscale_load_balancer.bar", - Providers: testAccProviders, - CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, - Steps: []resource.TestStep{ - { - Config: testAccDSOutscaleOAPILBUListenerDescsConfig, - Check: resource.ComposeTestCheckFunc( - testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - resource.TestCheckResourceAttr("data.outscale_load_balancer_listener_descriptions.test", "listener_descriptions.0.listener.0.backend_port", "8000"), - )}, - }, - }) -} - -const testAccDSOutscaleOAPILBUListenerDescsConfig = ` - resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] - load_balancer_name = "foobar-terraform-elb" - - listener { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } - - tag { - bar = "baz" - } - } - - data "outscale_load_balancer_listener_descriptions" "test" { - load_balancer_names = ["${outscale_load_balancer.bar.id}"] - } -` diff --git a/outscale/provider.go b/outscale/provider.go index 21cddbed0..3f088651a 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -82,61 +82,55 @@ func Provider() terraform.ResourceProvider { "outscale_load_balancer_listener_rule": resourceOutscaleLoadBalancerListenerRule(), }, DataSourcesMap: map[string]*schema.Resource{ - "outscale_vm": dataSourceOutscaleOAPIVM(), - "outscale_vms": datasourceOutscaleOApiVMS(), - "outscale_security_group": dataSourceOutscaleOAPISecurityGroup(), - "outscale_security_groups": dataSourceOutscaleOAPISecurityGroups(), - "outscale_image": dataSourceOutscaleOAPIImage(), - "outscale_images": dataSourceOutscaleOAPIImages(), - "outscale_tag": dataSourceOutscaleOAPITag(), - "outscale_tags": dataSourceOutscaleOAPITags(), - "outscale_public_ip": dataSourceOutscaleOAPIPublicIP(), - "outscale_public_ips": dataSourceOutscaleOAPIPublicIPS(), - "outscale_volume": datasourceOutscaleOAPIVolume(), - "outscale_volumes": datasourceOutscaleOAPIVolumes(), - "outscale_nat_service": dataSourceOutscaleOAPINatService(), - "outscale_nat_services": dataSourceOutscaleOAPINatServices(), - "outscale_keypair": datasourceOutscaleOAPIKeyPair(), - "outscale_keypairs": datasourceOutscaleOAPIKeyPairs(), - "outscale_vm_state": dataSourceOutscaleOAPIVMState(), - "outscale_vm_states": dataSourceOutscaleOAPIVMStates(), - "outscale_internet_service": datasourceOutscaleOAPIInternetService(), - "outscale_internet_services": datasourceOutscaleOAPIInternetServices(), - "outscale_subnet": dataSourceOutscaleOAPISubnet(), - "outscale_subnets": dataSourceOutscaleOAPISubnets(), - "outscale_net": dataSourceOutscaleOAPIVpc(), - "outscale_nets": dataSourceOutscaleOAPIVpcs(), - "outscale_net_attributes": dataSourceOutscaleOAPIVpcAttr(), - "outscale_route_table": dataSourceOutscaleOAPIRouteTable(), - "outscale_route_tables": dataSourceOutscaleOAPIRouteTables(), - "outscale_snapshot": dataSourceOutscaleOAPISnapshot(), - "outscale_snapshots": dataSourceOutscaleOAPISnapshots(), - "outscale_net_peering": dataSourceOutscaleOAPILinPeeringConnection(), - "outscale_net_peerings": dataSourceOutscaleOAPILinPeeringsConnection(), - "outscale_nics": dataSourceOutscaleOAPINics(), - "outscale_nic": dataSourceOutscaleOAPINic(), - "outscale_client_gateway": dataSourceOutscaleClientGateway(), - "outscale_client_gateways": dataSourceOutscaleClientGateways(), - "outscale_virtual_gateway": dataSourceOutscaleOAPIVirtualGateway(), - "outscale_virtual_gateways": dataSourceOutscaleOAPIVirtualGateways(), - "outscale_vpn_connection": dataSourceOutscaleVPNConnection(), - "outscale_vpn_connections": dataSourceOutscaleVPNConnections(), - "outscale_access_key": dataSourceOutscaleAccessKey(), - "outscale_access_keys": dataSourceOutscaleAccessKeys(), - "outscale_dhcp_option": dataSourceOutscaleDHCPOption(), - "outscale_dhcp_options": dataSourceOutscaleDHCPOptions(), - "outscale_load_balancer": dataSourceOutscaleOAPILoadBalancer(), - "outscale_load_balancer_access_logs": dataSourceOutscaleLoadBalancerAccessLogs(), - "outscale_load_balancer_attributes": dataSourceOutscaleOAPILoadBalancerAttr(), - "outscale_load_balancer_health_check": dataSourceOutscaleOAPILoadBalancerHealthCheck(), - "outscale_load_balancer_listener_description": dataSourceOutscaleOAPILoadBalancerLD(), - "outscale_load_balancer_listener_descriptions": dataSourceOutscaleOAPILoadBalancerLDs(), - "outscale_load_balancer_listener_rule": dataSourceOutscaleOAPILoadBalancerLDRule(), - "outscale_load_balancer_listener_rules": dataSourceOutscaleOAPILoadBalancerLDRules(), - "outscale_load_balancer_tags": dataSourceOutscaleOAPILBUTags(), - "outscale_load_balancer_vms": dataSourceOutscaleLoadBalancerVms(), - "outscale_load_balancer_vm_health": dataSourceOutscaleLoadBalancerVmsHeals(), - "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), + "outscale_vm": dataSourceOutscaleOAPIVM(), + "outscale_vms": datasourceOutscaleOApiVMS(), + "outscale_security_group": dataSourceOutscaleOAPISecurityGroup(), + "outscale_security_groups": dataSourceOutscaleOAPISecurityGroups(), + "outscale_image": dataSourceOutscaleOAPIImage(), + "outscale_images": dataSourceOutscaleOAPIImages(), + "outscale_tag": dataSourceOutscaleOAPITag(), + "outscale_tags": dataSourceOutscaleOAPITags(), + "outscale_public_ip": dataSourceOutscaleOAPIPublicIP(), + "outscale_public_ips": dataSourceOutscaleOAPIPublicIPS(), + "outscale_volume": datasourceOutscaleOAPIVolume(), + "outscale_volumes": datasourceOutscaleOAPIVolumes(), + "outscale_nat_service": dataSourceOutscaleOAPINatService(), + "outscale_nat_services": dataSourceOutscaleOAPINatServices(), + "outscale_keypair": datasourceOutscaleOAPIKeyPair(), + "outscale_keypairs": datasourceOutscaleOAPIKeyPairs(), + "outscale_vm_state": dataSourceOutscaleOAPIVMState(), + "outscale_vm_states": dataSourceOutscaleOAPIVMStates(), + "outscale_internet_service": datasourceOutscaleOAPIInternetService(), + "outscale_internet_services": datasourceOutscaleOAPIInternetServices(), + "outscale_subnet": dataSourceOutscaleOAPISubnet(), + "outscale_subnets": dataSourceOutscaleOAPISubnets(), + "outscale_net": dataSourceOutscaleOAPIVpc(), + "outscale_nets": dataSourceOutscaleOAPIVpcs(), + "outscale_net_attributes": dataSourceOutscaleOAPIVpcAttr(), + "outscale_route_table": dataSourceOutscaleOAPIRouteTable(), + "outscale_route_tables": dataSourceOutscaleOAPIRouteTables(), + "outscale_snapshot": dataSourceOutscaleOAPISnapshot(), + "outscale_snapshots": dataSourceOutscaleOAPISnapshots(), + "outscale_net_peering": dataSourceOutscaleOAPILinPeeringConnection(), + "outscale_net_peerings": dataSourceOutscaleOAPILinPeeringsConnection(), + "outscale_nics": dataSourceOutscaleOAPINics(), + "outscale_nic": dataSourceOutscaleOAPINic(), + "outscale_client_gateway": dataSourceOutscaleClientGateway(), + "outscale_client_gateways": dataSourceOutscaleClientGateways(), + "outscale_virtual_gateway": dataSourceOutscaleOAPIVirtualGateway(), + "outscale_virtual_gateways": dataSourceOutscaleOAPIVirtualGateways(), + "outscale_vpn_connection": dataSourceOutscaleVPNConnection(), + "outscale_vpn_connections": dataSourceOutscaleVPNConnections(), + "outscale_access_key": dataSourceOutscaleAccessKey(), + "outscale_access_keys": dataSourceOutscaleAccessKeys(), + "outscale_dhcp_option": dataSourceOutscaleDHCPOption(), + "outscale_dhcp_options": dataSourceOutscaleDHCPOptions(), + "outscale_load_balancer": dataSourceOutscaleOAPILoadBalancer(), + "outscale_load_balancer_listener_rule": dataSourceOutscaleOAPILoadBalancerLDRule(), + "outscale_load_balancer_listener_rules": dataSourceOutscaleOAPILoadBalancerLDRules(), + "outscale_load_balancer_tags": dataSourceOutscaleOAPILBUTags(), + "outscale_load_balancer_vm_health": dataSourceOutscaleLoadBalancerVmsHeals(), + "outscale_load_balancers": dataSourceOutscaleOAPILoadBalancers(), }, ConfigureFunc: providerConfigureClient, From bb95b179707b8ae045616d71212f1e9b09f00519 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 14:28:33 +0000 Subject: [PATCH 171/218] fix testacc lbu_attributes Signed-off-by: Thiery Ouattara --- outscale/resource_outscale_load_balancer_attributes_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_attributes_test.go b/outscale/resource_outscale_load_balancer_attributes_test.go index 95f2b4845..d2e2299e4 100644 --- a/outscale/resource_outscale_load_balancer_attributes_test.go +++ b/outscale/resource_outscale_load_balancer_attributes_test.go @@ -60,13 +60,14 @@ resource "outscale_load_balancer" "bar" { } tags { - bar = "baz" + key = "test_baz" + value = "baz" } } resource "outscale_load_balancer_attributes" "bar2" { - "access_log" { + access_log { is_enabled = "false" osu_bucket_prefix = "donustestbucket" } From e91d68ca15774814a43e6f127795326d4f96fa80 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 14:58:52 +0000 Subject: [PATCH 172/218] fix lbu policy test Signed-off-by: Thiery Ouattara --- .../resource_outscale_load_balancer_policy_test.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index a1ea7bfac..de3fc33b2 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -130,7 +130,7 @@ func testAccAppCookieStickinessPolicyConfig(rName string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] listeners { backend_port = 8000 backend_protocol = "HTTP" @@ -140,6 +140,7 @@ resource "outscale_load_balancer" "lb" { } resource "outscale_load_balancer_policy" "foo" { + policy_type = "app" policy_name = "foo-policy" load_balancer_name = "${outscale_load_balancer.lb.id}" cookie_name = "MyAppCookie" @@ -151,7 +152,7 @@ func testAccAppCookieStickinessPolicyConfigUpdate(rName string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] listeners { backend_port = 8000 backend_protocol = "HTTP" @@ -160,7 +161,8 @@ resource "outscale_load_balancer" "lb" { } } -resource "outscale_load_balancer_cookiepolicy" "foo" { +resource "outscale_load_balancer_policy" "foo" { + policy_type = "app" policy_name = "foo-policy" load_balancer_name = "${outscale_load_balancer.lb.id}" cookie_name = "MyOtherAppCookie" @@ -172,7 +174,7 @@ func testAccAppCookieStickinessPolicyConfigDestroy(rName string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" - availability_zones = ["eu-west-2a"] + subregion_names = ["eu-west-2a"] listeners { backend_port = 8000 backend_protocol = "HTTP" From 6cebbf424fc4bf78e7d7171b6719e559d2c85a2b Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 16:43:06 +0100 Subject: [PATCH 173/218] fix: resource_outscale_load_balancer_test.go Signed-off-by: Matthias Gatto --- ...data_source_outscale_load_balancer_test.go | 7 +- .../resource_outscale_load_balancer_test.go | 66 ++++--------------- 2 files changed, 16 insertions(+), 57 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index 3466ea174..04bc58846 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -1,6 +1,8 @@ package outscale import ( + "fmt" + "os" "testing" oscgo "github.com/outscale/osc-sdk-go/v2" @@ -11,6 +13,8 @@ import ( func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { var conf oscgo.LoadBalancer + region := os.Getenv("OUTSCALE_REGION") + zone := fmt.Sprintf("%sa", region) resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) @@ -23,11 +27,10 @@ func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { Config: testAccDSOutscaleOAPILBUConfig, Check: resource.ComposeTestCheckFunc( testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - testAccCheckOutscaleOAPILBUAttributes(&conf), resource.TestCheckResourceAttr( "data.outscale_load_balancer.test", "sub_region_name.#", "1"), resource.TestCheckResourceAttr( - "data.outscale_load_balancer.test", "sub_region_name.0", "eu-west-2a"), + "data.outscale_load_balancer.test", "sub_region_name.0", zone), )}, }, }) diff --git a/outscale/resource_outscale_load_balancer_test.go b/outscale/resource_outscale_load_balancer_test.go index 9932a897c..05276b60e 100644 --- a/outscale/resource_outscale_load_balancer_test.go +++ b/outscale/resource_outscale_load_balancer_test.go @@ -3,8 +3,7 @@ package outscale import ( "context" "fmt" - "reflect" - "sort" + "os" "strings" "testing" "time" @@ -20,6 +19,8 @@ func TestAccOutscaleOAPILBUBasic(t *testing.T) { var conf oscgo.LoadBalancer r := acctest.RandIntRange(0, 10) + region := os.Getenv("OUTSCALE_REGION") + zone := fmt.Sprintf("%sa", region) resource.Test(t, resource.TestCase{ PreCheck: func() { @@ -33,19 +34,13 @@ func TestAccOutscaleOAPILBUBasic(t *testing.T) { Config: testAccOutscaleOAPILBUConfig(r), Check: resource.ComposeTestCheckFunc( testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), - testAccCheckOutscaleOAPILBUAttributes(&conf), resource.TestCheckResourceAttr( "outscale_load_balancer.bar", "subregion_names.#", "1"), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "subregion_names.0", "eu-west-2a"), + "outscale_load_balancer.bar", "subregion_names.0", zone), resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "listener.0.backend_port", "8000"), - resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "listener.0.backend_protocol", "HTTP"), - resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "listener.0.load_balancer_port", "80"), - resource.TestCheckResourceAttr( - "outscale_load_balancer.bar", "listener.0.load_balancer_protocol", "HTTP"), + "outscale_load_balancer.bar", + "listeners.#", "1"), )}, }, }) @@ -102,46 +97,6 @@ func testAccCheckOutscaleOAPILBUDestroy(s *terraform.State) error { return nil } -func testAccCheckOutscaleOAPILBUAttributes(conf *oscgo.LoadBalancer) resource.TestCheckFunc { - return func(s *terraform.State) error { - zones := []string{"eu-west-2a"} - azs := make([]string, 0, len(*conf.SubregionNames)) - for _, x := range *conf.SubregionNames { - azs = append(azs, x) - } - sort.StringSlice(azs).Sort() - if !reflect.DeepEqual(azs, zones) { - return fmt.Errorf("bad subregion_name") - } - - if *conf.DnsName == "" { - return fmt.Errorf("empty dns_name") - } - - return nil - } -} - -func testAccCheckOutscaleOAPILBUAttributesHealthCheck(conf *oscgo.LoadBalancer) resource.TestCheckFunc { - return func(s *terraform.State) error { - zones := []string{"eu-west-2a"} - azs := make([]string, 0, len(*conf.SubregionNames)) - for _, x := range *conf.SubregionNames { - azs = append(azs, x) - } - sort.StringSlice(azs).Sort() - if !reflect.DeepEqual(azs, zones) { - return fmt.Errorf("bad subregion_name") - } - - if *conf.DnsName == "" { - return fmt.Errorf("empty dns_name") - } - - return nil - } -} - func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resource.TestCheckFunc { return func(s *terraform.State) error { rs, ok := s.RootModule().Resources[n] @@ -203,7 +158,7 @@ func testAccCheckOutscaleOAPILBUExists(n string, res *oscgo.LoadBalancer) resour func testAccOutscaleOAPILBUConfig(r int) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] + subregion_names = ["%sa"] load_balancer_name = "foobar-terraform-elb-%d" listeners { backend_port = 8000 @@ -212,10 +167,11 @@ resource "outscale_load_balancer" "bar" { load_balancer_protocol = "HTTP" } - tag { - bar = "baz" + tags { + key = "name" + value = "baz" } } -`, r) +`, os.Getenv("OUTSCALE_REGION"), r) } From 822b85d639de2d0f13abb337cece16940b3a214e Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 16:53:43 +0100 Subject: [PATCH 174/218] fix data source lbu test Signed-off-by: Matthias Gatto --- ...data_source_outscale_load_balancer_test.go | 23 +++++++++++-------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_test.go b/outscale/data_source_outscale_load_balancer_test.go index 04bc58846..8eca9cf72 100644 --- a/outscale/data_source_outscale_load_balancer_test.go +++ b/outscale/data_source_outscale_load_balancer_test.go @@ -24,36 +24,39 @@ func TestAccOutscaleOAPIDSLBU_basic(t *testing.T) { CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, Steps: []resource.TestStep{ { - Config: testAccDSOutscaleOAPILBUConfig, + Config: testAccDSOutscaleOAPILBUConfig(zone), Check: resource.ComposeTestCheckFunc( testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), resource.TestCheckResourceAttr( - "data.outscale_load_balancer.test", "sub_region_name.#", "1"), + "data.outscale_load_balancer.test", "subregion_names.#", "1"), resource.TestCheckResourceAttr( - "data.outscale_load_balancer.test", "sub_region_name.0", zone), + "data.outscale_load_balancer.test", "subregion_names.0", zone), )}, }, }) } -const testAccDSOutscaleOAPILBUConfig = ` +func testAccDSOutscaleOAPILBUConfig(zone string) string { + return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] + subregion_names = ["%s"] load_balancer_name = "foobar-terraform-elb" - listener { + listeners { backend_port = 8000 backend_protocol = "HTTP" - load_balancer_protocol = 80 + load_balancer_port = 80 load_balancer_protocol = "HTTP" } - tag { - bar = "baz" + tags { + key = "name" + value = "baz" } } data "outscale_load_balancer" "test" { load_balancer_name = "${outscale_load_balancer.bar.id}" } -` +`, zone) +} From 1a080fbad81bda845996f648f67dedcdf92a9b3c Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 13 Nov 2020 09:20:33 +0000 Subject: [PATCH 175/218] apply fix x509 client certificate authentication Signed-off-by: Thiery Ouattara --- outscale/config.go | 13 ++++++++++++- outscale/provider.go | 14 ++++++++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/outscale/config.go b/outscale/config.go index 9ead7434c..d01befb5b 100644 --- a/outscale/config.go +++ b/outscale/config.go @@ -17,6 +17,8 @@ type Config struct { Region string TokenID string Endpoints map[string]interface{} + X509cert string + X509key string } //OutscaleClient client @@ -26,9 +28,18 @@ type OutscaleClient struct { // Client ... func (c *Config) Client() (*OutscaleClient, error) { + tlsconfig := &tls.Config{InsecureSkipVerify: false} + cert, err := tls.LoadX509KeyPair(c.X509cert, c.X509key) + if err == nil { + tlsconfig = &tls.Config{ + InsecureSkipVerify: false, + Certificates: []tls.Certificate{cert}, + } + } + skipClient := &http.Client{ Transport: &http.Transport{ - TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, + TLSClientConfig: tlsconfig, Proxy: http.ProxyFromEnvironment, }, } diff --git a/outscale/provider.go b/outscale/provider.go index 3f088651a..7ce5c7410 100644 --- a/outscale/provider.go +++ b/outscale/provider.go @@ -36,6 +36,18 @@ func Provider() terraform.ResourceProvider { Description: "The Region for API operations.", }, "endpoints": endpointsSchema(), + "x509_cert_path": { + Type: schema.TypeString, + Optional: true, + DefaultFunc: schema.EnvDefaultFunc("OUTSCALE_X509CERT", nil), + Description: "The path to your x509 cert", + }, + "x509_key_path": { + Type: schema.TypeString, + Optional: true, + DefaultFunc: schema.EnvDefaultFunc("OUTSCALE_X509KEY", nil), + Description: "The path to your x509 key", + }, }, ResourcesMap: map[string]*schema.Resource{ @@ -143,6 +155,8 @@ func providerConfigureClient(d *schema.ResourceData) (interface{}, error) { SecretKeyID: d.Get("secret_key_id").(string), Region: d.Get("region").(string), Endpoints: make(map[string]interface{}), + X509cert: d.Get("x509_cert_path").(string), + X509key: d.Get("x509_key_path").(string), } endpointsSet := d.Get("endpoints").(*schema.Set) From 288f9ef6e92b79b5ca09cb956e13fe0435c98b70 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 17:30:22 +0100 Subject: [PATCH 176/218] data_source_outscale_load_balancers.go Signed-off-by: Matthias Gatto --- .../data_source_outscale_load_balancer.go | 11 ++++++- .../data_source_outscale_load_balancers.go | 2 +- ...ata_source_outscale_load_balancers_test.go | 30 ++++++++++++------- 3 files changed, 30 insertions(+), 13 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer.go b/outscale/data_source_outscale_load_balancer.go index 64fb8ea69..71028f7a0 100644 --- a/outscale/data_source_outscale_load_balancer.go +++ b/outscale/data_source_outscale_load_balancer.go @@ -200,6 +200,10 @@ func buildOutscaleDataSourceLBFilters(set *schema.Set) *oscgo.FiltersLoadBalance } func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBalancersResponse, *string, error) { + return readLbs_(conn, d, schema.TypeString) +} + +func readLbs_(conn *oscgo.APIClient, d *schema.ResourceData, t schema.ValueType) (*oscgo.ReadLoadBalancersResponse, *string, error) { ename, nameOk := d.GetOk("load_balancer_name") filters, filtersOk := d.GetOk("filter") filter := new(oscgo.FiltersLoadBalancer) @@ -210,11 +214,16 @@ func readLbs(conn *oscgo.APIClient, d *schema.ResourceData) (*oscgo.ReadLoadBala if filtersOk { filter = buildOutscaleDataSourceLBFilters(filters.(*schema.Set)) - } else { + } else if t == schema.TypeString { elbName := ename.(string) filter = &oscgo.FiltersLoadBalancer{ LoadBalancerNames: &[]string{elbName}, } + } else { /* assuming typelist */ + filter = &oscgo.FiltersLoadBalancer{ + LoadBalancerNames: expandStringList(ename.([]interface{})), + } + } elbName := (*filter.LoadBalancerNames)[0] diff --git a/outscale/data_source_outscale_load_balancers.go b/outscale/data_source_outscale_load_balancers.go index b1245a5cc..250619197 100644 --- a/outscale/data_source_outscale_load_balancers.go +++ b/outscale/data_source_outscale_load_balancers.go @@ -193,7 +193,7 @@ func dataSourceOutscaleOAPILoadBalancers() *schema.Resource { func dataSourceOutscaleOAPILoadBalancersRead(d *schema.ResourceData, meta interface{}) error { conn := meta.(*OutscaleClient).OSCAPI - resp, _, err := readLbs(conn, d) + resp, _, err := readLbs_(conn, d, schema.TypeList) if err != nil { return err } diff --git a/outscale/data_source_outscale_load_balancers_test.go b/outscale/data_source_outscale_load_balancers_test.go index d6f3ee5f8..46ace47e6 100644 --- a/outscale/data_source_outscale_load_balancers_test.go +++ b/outscale/data_source_outscale_load_balancers_test.go @@ -1,12 +1,17 @@ package outscale import ( + "fmt" + "os" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" ) func TestAccOutscaleOAPIDSLBSU_basic(t *testing.T) { + region := os.Getenv("OUTSCALE_REGION") + zone := fmt.Sprintf("%sa", region) + resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) @@ -16,34 +21,37 @@ func TestAccOutscaleOAPIDSLBSU_basic(t *testing.T) { CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, Steps: []resource.TestStep{ { - Config: testAccDSOutscaleOAPILBsUConfig, + Config: testAccDSOutscaleOAPILBsUConfig(zone), Check: resource.ComposeTestCheckFunc( - resource.TestCheckResourceAttr("data.outscale_load_balancers.test", "load_balancer_descriptions_member.#", "1"), + resource.TestCheckResourceAttr("data.outscale_load_balancers.test", "load_balancer.#", "1"), )}, }, }) } -const testAccDSOutscaleOAPILBsUConfig = ` +func testAccDSOutscaleOAPILBsUConfig(zone string) string { + return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] + subregion_names = ["%s"] load_balancer_name = "foobar-terraform-elb" - listeners_member { - instance_port = 8000 - instance_protocol = "HTTP" + listeners { + backend_port = 8000 + backend_protocol = "HTTP" load_balancer_port = 80 // Protocol should be case insensitive - protocol = "HTTP" + load_balancer_protocol = "HTTP" } - tag { - bar = "baz" + tags { + key = "name" + value = "baz" } } data "outscale_load_balancers" "test" { load_balancer_name = ["${outscale_load_balancer.bar.id}"] } -` +`, zone) +} From beb6f1a457d06b0bf74d91b4c4fcbc28f2e714a3 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 17:44:58 +0100 Subject: [PATCH 177/218] data_source_outscale_load_balancer_tags_test.go Signed-off-by: Matthias Gatto --- ...source_outscale_load_balancer_tags_test.go | 28 ++++++++----------- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/outscale/data_source_outscale_load_balancer_tags_test.go b/outscale/data_source_outscale_load_balancer_tags_test.go index 59b60acbf..e3b116d2d 100644 --- a/outscale/data_source_outscale_load_balancer_tags_test.go +++ b/outscale/data_source_outscale_load_balancer_tags_test.go @@ -2,6 +2,7 @@ package outscale import ( "fmt" + "os" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" @@ -11,6 +12,8 @@ import ( func TestAccOutscaleOAPIDSLoadBalancerTags_basic(t *testing.T) { r := acctest.RandString(4) + region := os.Getenv("OUTSCALE_REGION") + zone := fmt.Sprintf("%sa", region) resource.Test(t, resource.TestCase{ PreCheck: func() { @@ -19,11 +22,11 @@ func TestAccOutscaleOAPIDSLoadBalancerTags_basic(t *testing.T) { Providers: testAccProviders, Steps: []resource.TestStep{ { - Config: getTestAccDSODSutscaleOAPILBUDSTagsConfig(r), + Config: getTestAccDSODSutscaleOAPILBUDSTagsConfig(r, zone), Check: resource.ComposeTestCheckFunc( testAccCheckODSutscaleOAPILBUDSTagsExists("data.outscale_load_balancer_tags.testds"), resource.TestCheckResourceAttr( - "data.outscale_load_balancer_tags.testds", "tag.#", "1"), + "data.outscale_load_balancer_tags.testds", "tags.#", "1"), )}, }, }) @@ -44,10 +47,10 @@ func testAccCheckODSutscaleOAPILBUDSTagsExists(n string) resource.TestCheckFunc } } -func getTestAccDSODSutscaleOAPILBUDSTagsConfig(r string) string { +func getTestAccDSODSutscaleOAPILBUDSTagsConfig(r string, zone string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - subregion_names = ["eu-west-2a"] + subregion_names = ["%s"] load_balancer_name = "foobar-terraform-elb-%s" listeners { @@ -57,22 +60,15 @@ func getTestAccDSODSutscaleOAPILBUDSTagsConfig(r string) string { load_balancer_protocol = "HTTP" } - tag { - bar = "baz" + tags { + key = "name" + value = "baz" } } - resource "outscale_load_balancer_tags" "tags" { - load_balancer_name = ["${outscale_load_balancer.bar.id}"] - - tag = [{ - key = "bar2" - value = "baz2" - }] - } data "outscale_load_balancer_tags" "testds" { - load_balancer_name = ["${outscale_load_balancer.bar.id}"] + load_balancer_names = ["${outscale_load_balancer.bar.id}"] } - `, r) + `, zone, r) } From 22cd626faa4384376b1f19762e662c15838439f1 Mon Sep 17 00:00:00 2001 From: Thiery Ouattara Date: Fri, 27 Nov 2020 16:58:08 +0000 Subject: [PATCH 178/218] fix load_balancer_vms_test Signed-off-by: Thiery Ouattara --- ...esource_outscale_load_balancer_vms_test.go | 27 ++++++++++++------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_vms_test.go b/outscale/resource_outscale_load_balancer_vms_test.go index fc6fbb66b..9a87f0711 100644 --- a/outscale/resource_outscale_load_balancer_vms_test.go +++ b/outscale/resource_outscale_load_balancer_vms_test.go @@ -2,6 +2,7 @@ package outscale import ( "fmt" + "os" "testing" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -12,11 +13,16 @@ import ( func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { var conf oscgo.LoadBalancer + omi := os.Getenv("OUTSCALE_IMAGEID") + region := os.Getenv("OUTSCALE_REGION") testCheckInstanceAttached := func(count int) resource.TestCheckFunc { return func(*terraform.State) error { - if len(*conf.BackendVmIds) != count { - return fmt.Errorf("backend_vm_ids count does not match") + if conf.BackendVmIds != nil { + if len(*conf.BackendVmIds) != count { + return fmt.Errorf("backend_vm_ids count does not match") + } + return nil } return nil } @@ -29,7 +35,7 @@ func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { CheckDestroy: testAccCheckOutscaleOAPILBUDestroy, Steps: []resource.TestStep{ { - Config: testAccOutscaleOAPILBUAttachmentConfig1, + Config: testAccOutscaleOAPILBUAttachmentConfig1(omi, region), Check: resource.ComposeTestCheckFunc( testAccCheckOutscaleOAPILBUExists("outscale_load_balancer.bar", &conf), testCheckInstanceAttached(1), @@ -40,11 +46,11 @@ func TestAccOutscaleOAPILBUAttachment_basic(t *testing.T) { } // add one attachment -const testAccOutscaleOAPILBUAttachmentConfig1 = ` +func testAccOutscaleOAPILBUAttachmentConfig1(omi, region string) string { + return fmt.Sprintf(` resource "outscale_load_balancer" "bar" { - load_balancer_name = "load-test" - - availability_zones = ["eu-west-2a"] + load_balancer_name = "load-test12" + subregion_names = ["%sa"] listeners { backend_port = 8000 backend_protocol = "HTTP" @@ -54,12 +60,13 @@ resource "outscale_load_balancer" "bar" { } resource "outscale_vm" "foo1" { - image_id = "ami-8a6a0120" - type = "t2.micro" + image_id = "%s" + vm_type = "tinav4.c1r1p1" } resource "outscale_load_balancer_vms" "foo1" { load_balancer_name = "${outscale_load_balancer.bar.id}" backend_vm_ids = ["${outscale_vm.foo1.id}"] } -` +`, region, omi) +} From 88c6fde48454fe81312dc41cde794d2699b50411 Mon Sep 17 00:00:00 2001 From: Matthias Gatto Date: Fri, 27 Nov 2020 18:18:19 +0100 Subject: [PATCH 179/218] resource_outscale_load_balancer_policy_test.go Signed-off-by: Matthias Gatto --- ...urce_outscale_load_balancer_policy_test.go | 92 +++---------------- 1 file changed, 11 insertions(+), 81 deletions(-) diff --git a/outscale/resource_outscale_load_balancer_policy_test.go b/outscale/resource_outscale_load_balancer_policy_test.go index de3fc33b2..3aae9f68d 100644 --- a/outscale/resource_outscale_load_balancer_policy_test.go +++ b/outscale/resource_outscale_load_balancer_policy_test.go @@ -1,13 +1,9 @@ package outscale import ( - "context" "fmt" - "strings" + "os" "testing" - "time" - - oscgo "github.com/outscale/osc-sdk-go/v2" "github.com/hashicorp/terraform-plugin-sdk/helper/acctest" "github.com/hashicorp/terraform-plugin-sdk/helper/resource" @@ -16,6 +12,8 @@ import ( func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) + region := os.Getenv("OUTSCALE_REGION") + zone := fmt.Sprintf("%sa", region) resource.Test(t, resource.TestCase{ PreCheck: func() { testAccPreCheck(t) }, @@ -23,7 +21,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, Steps: []resource.TestStep{ { - Config: testAccAppCookieStickinessPolicyConfig(lbName), + Config: testAccAppCookieStickinessPolicyConfig(lbName, zone), Check: resource.ComposeTestCheckFunc( testAccCheckAppCookieStickinessPolicy( "outscale_load_balancer.lb", @@ -32,7 +30,7 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { ), }, { - Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName), + Config: testAccAppCookieStickinessPolicyConfigUpdate(lbName, zone), Check: resource.ComposeTestCheckFunc( testAccCheckAppCookieStickinessPolicy( "outscale_load_balancer.lb", @@ -44,59 +42,6 @@ func TestAccOutscaleAppCookieStickinessPolicy_basic(t *testing.T) { }) } -func TestAccOutscaleAppCookieStickinessPolicy_missingLB(t *testing.T) { - lbName := fmt.Sprintf("tf-test-lb-%s", acctest.RandString(5)) - - // check that we can destroy the policy if the LB is missing - removeLB := func() { - conn := testAccProvider.Meta().(*OutscaleClient).OSCAPI - - request := oscgo.DeleteLoadBalancerRequest{ - LoadBalancerName: lbName, - } - - var err error - err = resource.Retry(5*time.Minute, func() *resource.RetryError { - _, _, err = conn.LoadBalancerApi.DeleteLoadBalancer( - context.Background()).DeleteLoadBalancerRequest(request).Execute() - - if err != nil { - if strings.Contains(fmt.Sprint(err), "Throttling") { - return resource.RetryableError( - fmt.Errorf("[WARN] Error creating ELB Listener with SSL Cert, retrying: %s", err)) - } - return resource.NonRetryableError(err) - } - return nil - }) - - if err != nil { - t.Fatalf("Error deleting ELB: %s", err) - } - } - - resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckAppCookieStickinessPolicyDestroy, - Steps: []resource.TestStep{ - { - Config: testAccAppCookieStickinessPolicyConfig(lbName), - Check: resource.ComposeTestCheckFunc( - testAccCheckAppCookieStickinessPolicy( - "outscale_load_balancer.lb", - "outscale_load_balancer_cookiepolicy.foo", - ), - ), - }, - { - PreConfig: removeLB, - Config: testAccAppCookieStickinessPolicyConfigDestroy(lbName), - }, - }, - }) -} - func testAccCheckAppCookieStickinessPolicyDestroy(s *terraform.State) error { for _, rs := range s.RootModule().Resources { @@ -126,11 +71,11 @@ func testAccCheckAppCookieStickinessPolicy(elbResource string, policyResource st } } -func testAccAppCookieStickinessPolicyConfig(rName string) string { +func testAccAppCookieStickinessPolicyConfig(rName string, zone string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" - subregion_names = ["eu-west-2a"] + subregion_names = ["%s"] listeners { backend_port = 8000 backend_protocol = "HTTP" @@ -144,15 +89,15 @@ resource "outscale_load_balancer_policy" "foo" { policy_name = "foo-policy" load_balancer_name = "${outscale_load_balancer.lb.id}" cookie_name = "MyAppCookie" -}`, rName) +}`, rName, zone) } // Change the cookie_name to "MyOtherAppCookie". -func testAccAppCookieStickinessPolicyConfigUpdate(rName string) string { +func testAccAppCookieStickinessPolicyConfigUpdate(rName string, zone string) string { return fmt.Sprintf(` resource "outscale_load_balancer" "lb" { load_balancer_name = "%s" - subregion_names = ["eu-west-2a"] + subregion_names = ["%s"] listeners { backend_port = 8000 backend_protocol = "HTTP" @@ -166,20 +111,5 @@ resource "outscale_load_balancer_policy" "foo" { policy_name = "foo-policy" load_balancer_name = "${outscale_load_balancer.lb.id}" cookie_name = "MyOtherAppCookie" -}`, rName) -} - -// attempt to destroy the policy, but we'll delete the LB in the PreConfig -func testAccAppCookieStickinessPolicyConfigDestroy(rName string) string { - return fmt.Sprintf(` -resource "outscale_load_balancer" "lb" { - load_balancer_name = "%s" - subregion_names = ["eu-west-2a"] - listeners { - backend_port = 8000 - backend_protocol = "HTTP" - load_balancer_port = 80 - load_balancer_protocol = "HTTP" - } -}`, rName) +}`, rName, zone) } From 1b7e5376bd493b1c4ee96c6adbbca2139ad62eb6 Mon Sep 17 00:00:00 2001 From: Dorine Germain Date: Tue, 28 Jul 2020 08:50:15 +0200 Subject: [PATCH 180/218] DOC-2491: Improve endpoints description in index --- outscale/.DS_Store | Bin 6148 -> 22532 bytes website/docs/index.html.markdown | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/outscale/.DS_Store b/outscale/.DS_Store index 5008ddfcf53c02e82d7eee2e57c38e5672ef89f6..5ea2557c05d3b509286c1bef1cee73be49478895 100644 GIT binary patch literal 22532 zcmeHP$&M695Y1wn83QtsErD4Z%re-3&Ba3EGD29wHzZ%U4KU!D5wmF)mfKt`akbryAf;VXDRprC9`D|Z-}622+Kn?6-oN3!7uTn>neL_8w2@ZR*1)gZ6CWA_yU-xo za1Y*Jrw6c|wBLG~OAld9+Hw;%ox}G_`OJFv9KYoi_w)HHX+Ev~w6r>Re`)nTB*Goi zbpX8lC%^E&>?J^2hm_h!nla`ea}mE=0m3XKvuzL46C9r<1F1Tk(!{ht+6T0wMM!;Z zEV;j?^x3t(-0JTgI9H1>7Sl3XKA+iJ!e3j^Yc4H7vo)Ms$G3}MWCNe8_=c>Kp-od$ zv`A@sD%^rvdNxS=(K667@QE_Oz8kN}{q?c^Y#C@7Xc>6R0P{l!Zysm5$L;!OQua~=F{q18(zvy3@1-UuBojseH-;b;fR+Lf^)x~yhxCH4CFsGG zCZ8iGKLM)`yXy^p>);jY>Vt^PdK`H<{el>Mnsa7e#nJ0MTpdwY4%Qp(nU;Z;fe(j) z3uwv|Dmtz^GPdWf%*)J}rbXsGA6P9OVI@~#eLE&BH|KGzqfjr53AM4}QD~ROhURL? z@ruGd5y0)QVH8bF>bMGME)r6U%l1Pzg=ByI; z91V@G%$G!oM6-?JYQ;GjrB%caY&_deWbd`GQzUkqaD2_^;gZQ?0nccjBZEKhx+C<6 zj9Pj*wsa1Ywvn7gMlBwe%Ug~pi5l~B&MnqE(AbYGqF*sbe>wk1l$f7eD6UpHt|VT} z&n-OL&yls2f5iOU#&I=cUQ&pW4BPXPUM+6*6!1bN|9Ci#Y^K=mS0a*5k094&hCZfR z9?Jk60X6X<+a2SZQr%WF{uD1UzA4}2JF_9%9pk%}>$aRRrdl3BSj(#j+@DK+7BO}) zxF`bjQF^>#%;tCbAr+?GQ#k%Tn(8g6l%ol zJyg?zzxK$^4;kBmKk%#!W+3)XAcfAE|tH%6Bzk-cU%9yuK63wh_5{ zE^HL@dCk?Z`4afN(k3$FBiFjEcp_6$kI2|r%69FMJzAnfW(FjRX$$5Ar9&jMYU!>P z*?*-Lkq7l z5Yc-VgdHMT*GKcUr1wfKBjXSs*NzrMywWo=8#)Zn)s&vDkdFrHr^i?iZ-}0~e+jEa zqK7g$!$ogoJ!!~iZc%NH^jSOQyX-KY6jCHd)<{lG%q*aIisUXzH+_jx_uUfgM{+m75T;1!1Eq@|M^1A)FhSec^ zfCoS|*J#Mk#I)e&(7;u$&e;P5>U*pIx&Oaxf3LTW@9M_bQQVZ>m)&1gHLR3nz7Tw0 zf?c>riGJ98S9xD1cY+PO58J?{os=#g@BQCq)MP)Fyq+uMb)>cF$w^_svU@j}3A|Ns zcZVNG8WU2x@5Z8CAJdHk#@yMtn8km6-eZ2 zT2HdiGc$^0qcj857#zd{_YB%;;1wOG^4m$F#{;Pm`xn-VFW12W%nKpuG(3i zMA@%|CzaV^P|`9D7nKL2k Date: Fri, 6 Nov 2020 09:40:38 +0100 Subject: [PATCH 181/218] DOC-2623: fix nat_service link --- website/docs/r/nat_service.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/r/nat_service.html.markdown b/website/docs/r/nat_service.html.markdown index e597ef620..460fee035 100644 --- a/website/docs/r/nat_service.html.markdown +++ b/website/docs/r/nat_service.html.markdown @@ -9,7 +9,7 @@ description: |- # outscale_nat_service Resource Manages a NAT service. -For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+NAT+Devices). +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+NAT+Gateways). For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-natservice). ## Example Usage From 0eaedf0e48daaf53a6313e193f079c57b3a58c00 Mon Sep 17 00:00:00 2001 From: Dorine Germain Date: Fri, 6 Nov 2020 10:19:25 +0100 Subject: [PATCH 182/218] DOC-2613: fix attribute in outscale_route example --- website/docs/r/route.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/r/route.html.markdown b/website/docs/r/route.html.markdown index b30e92953..23fe3a85d 100644 --- a/website/docs/r/route.html.markdown +++ b/website/docs/r/route.html.markdown @@ -25,7 +25,7 @@ For more information on this resource actions, see the [API documentation](https #} resource "outscale_route" "route01" { - gateway_id = outscale_internet_service.internet_service01.id + gateway_id = outscale_internet_service.internet_service01.internet_service_id destination_ip_range = "20.0.0.0/16" route_table_id = outscale_route_table.route_table01.route_table_id } From 9babc94602795bdeecb210b071de655ca8d72cbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Wed, 18 Nov 2020 14:14:53 +0100 Subject: [PATCH 183/218] DOC-2323/2596: Fix website display issues --- website/docs/index.html.markdown | 2 +- .../docs/r/security_group_rule.html.markdown | 66 +++++++++---------- 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index 11873adfd..371644a70 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -41,7 +41,7 @@ The 3DS OUTSCALE provider supports different ways of providing credentials for a ### Static credentials -!> **Warning**: Hard-coding credentials into any Terraform configuration is not recommended, and risks secret leakage should this file ever be committed to a public version control system. +!> **Warning:** Hard-coding credentials into any Terraform configuration is not recommended, and risks secret leakage should this file ever be committed to a public version control system. You can provide your credentials by specifying the `access_key_id` and `secret_key_id` attributes in the provider block: diff --git a/website/docs/r/security_group_rule.html.markdown b/website/docs/r/security_group_rule.html.markdown index bbf3a0aed..be42c1aa2 100644 --- a/website/docs/r/security_group_rule.html.markdown +++ b/website/docs/r/security_group_rule.html.markdown @@ -64,32 +64,32 @@ resource "outscale_security_group_rule" "security_group_rule02" The following arguments are supported: -* `flow` - (Required) The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. -* `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. -* `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. -* `ip_range` - (Optional) The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). -* `rules` - (Optional) Information about the security group rule to create. - * `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - (Optional) One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). +* `flow` - (Required) The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. +* `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. +* `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. +* `ip_range` - (Optional) The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). +* `rules` - (Optional) Information about the security group rule to create. + * `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - (Optional) One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). * `security_groups_members` - (Optional) Information about one or more members of a security group. * `account_id` - (Optional) The account ID of a user. * `security_group_id` - (Required) The ID of the security group. * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. - * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. -* `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. -* `security_group_id` - (Required) The ID of the security group for which you want to create a rule. -* `security_group_name_to_link` - (Optional) The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. + * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. +* `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. +* `security_group_id` - (Required) The ID of the security group for which you want to create a rule. +* `security_group_name_to_link` - (Optional) The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. ## Attribute Reference The following attributes are exported: -* `security_group` - Information about the security group. - * `account_id` - The account ID of a user that has been granted permission. - * `description` - The description of the security group. +* `security_group` - Information about the security group. + * `account_id` - The account ID of a user that has been granted permission. + * `description` - The description of the security group. * `inbound_rules` - The inbound rules associated with the security group. * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. @@ -98,21 +98,21 @@ The following attributes are exported: * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. * `security_group_name` - (Public Cloud only) The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. - * `net_id` - The ID of the Net for the security group. - * `outbound_rules` - The outbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. - * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. - * `tags` - One or more tags associated with the security group. - * `key` - The key of the tag, with a minimum of 1 character. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `net_id` - The ID of the Net for the security group. + * `outbound_rules` - The outbound rules associated with the security group. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - (Public Cloud only) The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `security_group_id` - The ID of the security group. + * `security_group_name` - (Public Cloud only) The name of the security group. + * `tags` - One or more tags associated with the security group. + * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. From ea37e8c724b1a5acdae39bd65417b84c67a4123b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Thu, 19 Nov 2020 15:27:49 +0100 Subject: [PATCH 184/218] DOC-2596: Add Terraform 0.13 note --- website/docs/index.html.markdown | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index 371644a70..a1fb6f429 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -7,13 +7,15 @@ description: |- # 3DS OUTSCALE Provider -The 3DS OUTSCALE provider is used to manage 3DS OUTSCALE Cloud resources. -Use the navigation to the left to read about the available resources. -For more information on our resources, see the [User Guide](https://wiki.outscale.net/display/EN#). +The 3DS OUTSCALE provider is used to manage 3DS OUTSCALE Cloud resources. +Use the navigation to the left to read about the available resources. For more information on our resources, see the [User Guide](https://wiki.outscale.net/display/EN#). -The provider is based on our 3DS OUTSCALE API. For more information, see [APIs Reference](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference) and the [API Documentation](https://docs.outscale.com/api#3ds-outscale-api). +The provider is based on our 3DS OUTSCALE API. For more information, see [APIs Reference](https://wiki.outscale.net/display/EN/3DS+OUTSCALE+APIs+Reference) and the [API Documentation](https://docs.outscale.com/api#3ds-outscale-api). + +The provider needs to be configured with the proper credentials before it can be used. + +-> **Note:** The 3DS OUTSCALE provider is compatible with Terraform 0.13. For more information on provider requirements, see our [README](https://github.com/outscale-dev/terraform-provider-outscale#using-the-provider) and the [Terraform documentation](https://www.terraform.io/docs/configuration/provider-requirements.html#v0-12-compatible-provider-requirements). -The provider needs to be configured with the proper credentials before it can be used. ## Example From 5982e8b75d8be889e7fb3f732abca1e59c246b24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Fri, 20 Nov 2020 11:50:19 +0100 Subject: [PATCH 185/218] DOC-2664: Add Client Certificate config --- website/docs/index.html.markdown | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index a1fb6f429..a5214dcd5 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -21,12 +21,14 @@ The provider needs to be configured with the proper credentials before it can be ```hcl provider "outscale" { - access_key_id = "123456789ABCDEFGHIJK" - secret_key_id = "ABCDEFGHIJKLMNOPQRSTU1234567891011121314" - region = "cn-southeast-1" + access_key_id = var.access_key_id + secret_key_id = var.secret_key_id + region = "cn-southeast-1" endpoints { api = "https://api.cn-southeast-1.outscale.hk/api/v1" } + x509_cert_path = "/tmp/client-certificate.pem" + x509_key_path = "/tmp/key.pem" } ``` @@ -53,7 +55,7 @@ Example: provider "outscale" { access_key_id = "myaccesskey" secret_key_id = "mysecretkey" - region = "regionname" + region = "eu-west-2" } ``` @@ -72,7 +74,10 @@ Usage: ```bash $ export OUTSCALE_ACCESSKEYID="myaccesskey" $ export OUTSCALE_SECRETKEYID="mysecretkey" -$ export OUTSCALE_REGION="regionname" +$ export OUTSCALE_REGION="cloudgouv-eu-west-1" +$ export OUTSCALE_X509CERT="~/certificate/certificate.crt" +$ export OUTSCALE_X509KEY="~/certificate/certificate.key" + $ terraform plan ``` @@ -86,4 +91,8 @@ In addition to [generic provider arguments](https://www.terraform.io/docs/config * `region` - (Optional) The Region that will be used as default value for all resources. It can also be sourced from the `OUTSCALE_REGION` [environment variable](#environment-variables). For more information on available Regions, see [Regions Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). -* `endpoints` - (Optional) The custom endpoint that will be used as default value for all resources. For more information on available endpoints, see [Endpoints Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). \ No newline at end of file +* `endpoints` - (Optional) The custom endpoint that will be used as default value for all resources. For more information on available endpoints, see [Endpoints Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). + +* `x509_cert_path` - (Optional) The x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509CERT` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Acess Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). + +* `x509_key_path` - (Optional) The private key of the x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509KEY` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Acess Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). \ No newline at end of file From 220dd016097b1bed5958e78d4e0d43de4c5eb4f2 Mon Sep 17 00:00:00 2001 From: Dorine Germain Date: Tue, 24 Nov 2020 14:19:08 +0100 Subject: [PATCH 186/218] DOC-2667: fix public IP import --- website/docs/r/public_ip.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/r/public_ip.html.markdown b/website/docs/r/public_ip.html.markdown index 65fa19b4c..26c9edd2d 100644 --- a/website/docs/r/public_ip.html.markdown +++ b/website/docs/r/public_ip.html.markdown @@ -52,6 +52,6 @@ A public IP can be imported using its ID. For example: ``` -$ terraform import outscale_public_ip.ImportedPublicIp 111.11.111.11 +$ terraform import outscale_public_ip.ImportedPublicIp eipalloc-12345678 ``` \ No newline at end of file From f014ed3167756e7bad4ebe1a990b546a1d2dd99c Mon Sep 17 00:00:00 2001 From: "margaux.haccard" Date: Wed, 25 Nov 2020 15:35:49 +0100 Subject: [PATCH 187/218] DOC-2323: Fix SG rule parameter indentation --- website/docs/r/security_group_rule.html.markdown | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/website/docs/r/security_group_rule.html.markdown b/website/docs/r/security_group_rule.html.markdown index be42c1aa2..c48148227 100644 --- a/website/docs/r/security_group_rule.html.markdown +++ b/website/docs/r/security_group_rule.html.markdown @@ -73,9 +73,9 @@ The following arguments are supported: * `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. * `ip_ranges` - (Optional) One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). * `security_groups_members` - (Optional) Information about one or more members of a security group. - * `account_id` - (Optional) The account ID of a user. - * `security_group_id` - (Required) The ID of the security group. - * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. + * `account_id` - (Optional) The account ID of a user. + * `security_group_id` - (Required) The ID of the security group. + * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. From 1fea76c511ea14c7b77c1452c1a2cf20f0551f51 Mon Sep 17 00:00:00 2001 From: Rosalie Chadelat Date: Thu, 26 Nov 2020 09:09:15 +0100 Subject: [PATCH 188/218] DOC-2493 --- website/docs/d/vm_states.html.markdown | 51 ++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 website/docs/d/vm_states.html.markdown diff --git a/website/docs/d/vm_states.html.markdown b/website/docs/d/vm_states.html.markdown new file mode 100644 index 000000000..9b04884a4 --- /dev/null +++ b/website/docs/d/vm_states.html.markdown @@ -0,0 +1,51 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_vm_state" +sidebar_current: "outscale-vm-state" +description: |- + [Provides information about VM states.] +--- + +# outscale_vm_states Data Source + +Provides information about VM states. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Instance+Lifecycle). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#readvmsstate). + +## Example Usage + +```hcl + +data "outscale_vm_states" "vm_states01" { + filter { + name = "vm_ids" + values = ["i-12345678", "i-12345679"] + } +} + + +``` + +## Argument Reference + +The following arguments are supported: + +* `all_vms` - (Optional) If `true`, includes the status of all VMs. By default or if set to `false`, only includes the status of running VMs. +* `filter` - One or more filters. + * `subregion_names` - (Optional) The names of the Subregions of the VMs. + * `vm_ids` - (Optional) One or more IDs of VMs. + * `vm_states` - (Optional) The states of the VMs (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). + +## Attribute Reference + +The following attributes are exported: + +* `vm_states` - Information about one or more VM states. + * `maintenance_events` - One or more scheduled events associated with the VM. + * `code` - The code of the event (`system-reboot` \| `system-maintenance`). + * `description` - The description of the event. + * `not_after` - The latest scheduled end time for the event. + * `not_before` - The earliest scheduled start time for the event. + * `subregion_name` - The name of the Subregion of the VM. + * `vm_id` - The ID of the VM. + * `vm_state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). From c74951ba8b28d158fef8466717384419c62f46d4 Mon Sep 17 00:00:00 2001 From: "margaux.haccard" Date: Thu, 26 Nov 2020 10:06:55 +0100 Subject: [PATCH 189/218] DOC-2323: Fix SG rule parameter indentation --- .../docs/r/security_group_rule.html.markdown | 92 +++++++++---------- 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/website/docs/r/security_group_rule.html.markdown b/website/docs/r/security_group_rule.html.markdown index c48148227..585f18405 100644 --- a/website/docs/r/security_group_rule.html.markdown +++ b/website/docs/r/security_group_rule.html.markdown @@ -64,55 +64,55 @@ resource "outscale_security_group_rule" "security_group_rule02" The following arguments are supported: -* `flow` - (Required) The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. -* `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. -* `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. -* `ip_range` - (Optional) The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). -* `rules` - (Optional) Information about the security group rule to create. - * `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - (Optional) One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - (Optional) Information about one or more members of a security group. - * `account_id` - (Optional) The account ID of a user. - * `security_group_id` - (Required) The ID of the security group. - * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. - * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. -* `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. -* `security_group_id` - (Required) The ID of the security group for which you want to create a rule. -* `security_group_name_to_link` - (Optional) The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. +* `flow` - (Required) The direction of the flow: `Inbound` or `Outbound`. You can specify `Outbound` for Nets only. +* `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. +* `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. +* `ip_range` - (Optional) The IP range for the security group rule, in CIDR notation (for example, 10.0.0.0/16). +* `rules` - (Optional) Information about the security group rule to create. + * `from_port_range` - (Optional) The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - (Optional) The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - (Optional) One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - (Optional) Information about one or more members of a security group. + * `account_id` - (Optional) The account ID of a user. + * `security_group_id` - (Required) The ID of the security group. + * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. + * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. +* `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. +* `security_group_id` - (Required) The ID of the security group for which you want to create a rule. +* `security_group_name_to_link` - (Optional) The ID of the source security group. If you are in the Public Cloud, you can also specify the name of the source security group. * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. ## Attribute Reference The following attributes are exported: -* `security_group` - Information about the security group. - * `account_id` - The account ID of a user that has been granted permission. - * `description` - The description of the security group. - * `inbound_rules` - The inbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. - * `net_id` - The ID of the Net for the security group. - * `outbound_rules` - The outbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. - * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. - * `tags` - One or more tags associated with the security group. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. +* `security_group` - Information about the security group. + * `account_id` - The account ID of a user that has been granted permission. + * `description` - The description of the security group. + * `inbound_rules` - The inbound rules associated with the security group. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - (Public Cloud only) The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `net_id` - The ID of the Net for the security group. + * `outbound_rules` - The outbound rules associated with the security group. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - (Public Cloud only) The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `security_group_id` - The ID of the security group. + * `security_group_name` - (Public Cloud only) The name of the security group. + * `tags` - One or more tags associated with the security group. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. From c96000aaeafcd059a0c06e8583b16f2680dd6bcc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Thu, 26 Nov 2020 12:20:53 +0100 Subject: [PATCH 190/218] DOC-2664: Improve Certificate descriptions --- website/docs/index.html.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index a5214dcd5..bb7ef4f37 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -93,6 +93,6 @@ In addition to [generic provider arguments](https://www.terraform.io/docs/config * `endpoints` - (Optional) The custom endpoint that will be used as default value for all resources. For more information on available endpoints, see [Endpoints Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). -* `x509_cert_path` - (Optional) The x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509CERT` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Acess Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). +* `x509_cert_path` - (Optional) The path to the x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509CERT` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Access Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). -* `x509_key_path` - (Optional) The private key of the x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509KEY` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Acess Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). \ No newline at end of file +* `x509_key_path` - (Optional) The path to the private key of the x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509KEY` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Access Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). \ No newline at end of file From 82a7167b4b38faabb12071b83f90f1cbeda5e038 Mon Sep 17 00:00:00 2001 From: "rosalie.chadelat" Date: Fri, 27 Nov 2020 10:06:56 +0000 Subject: [PATCH 191/218] DOC-2556 --- website/docs/d/load_balancer.html.markdown | 80 ++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 website/docs/d/load_balancer.html.markdown diff --git a/website/docs/d/load_balancer.html.markdown b/website/docs/d/load_balancer.html.markdown new file mode 100644 index 000000000..48a372020 --- /dev/null +++ b/website/docs/d/load_balancer.html.markdown @@ -0,0 +1,80 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer" +sidebar_current: "outscale-load-balancer" +description: |- + [Provides information about a specific load balancer.] +--- + +# outscale_load_balancer Data Source + +Provides information about a specific load balancer. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-loadbalancer). + +## Example Usage + +```hcl +data "outscale_load_balancer" "load_balancer01" { +filter { + name = "load_balancer_names" + values = "load_balancer01" + } +} +``` + +## Argument Reference + +The following arguments are supported: + +* `filter` - A combination of a filter name and one or more filter values. You can specify this argument for as many filter names as you need. The filter name can be any of the following: + * `load_balancer_names` - (Optional) The names of the load balancers. + +## Attribute Reference + +The following attributes are exported: + +* `load_balancers` - Information about one or more load balancers. + * `access_log` - Information about access logs. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. + * `dns_name` - The DNS name of the load balancer. + * `health_check` - Information about the health check configuration. + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `listeners` - The listeners for the load balancer. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. + * `load_balancer_name` - The name of the load balancer. + * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. + * `policy_name` - The name of the stickiness policy. + * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
+If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
+If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + * `net_id` - The ID of the Net for the load balancer. + * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
+To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. + * `subnets` - The IDs of the Subnets for the load balancer. + * `subregion_names` - One or more names of Subregions for the load balancer. + * `tags` - One or more tags associated with the load balancer. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. + From 82cc85ecdc8592c0b9e2f6f4ceacbbfaf06e8ec2 Mon Sep 17 00:00:00 2001 From: "rosalie.chadelat" Date: Fri, 27 Nov 2020 10:09:31 +0000 Subject: [PATCH 192/218] DOC-2556: Create Load Balancer Doc Uploaded data source load_balancers.html.markdown --- website/docs/d/load_balancers.html.markdown | 80 +++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 website/docs/d/load_balancers.html.markdown diff --git a/website/docs/d/load_balancers.html.markdown b/website/docs/d/load_balancers.html.markdown new file mode 100644 index 000000000..0e658a3f3 --- /dev/null +++ b/website/docs/d/load_balancers.html.markdown @@ -0,0 +1,80 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer" +sidebar_current: "outscale-load-balancer" +description: |- + [Provides information about load balancers.] +--- + +# outscale_load_balancer Data Source + +Provides information about load balancers. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-loadbalancer). + +## Example Usage + +```hcl +data "outscale_load_balancers" "load_balancers01" { +filter { + name = "load_balancer_names" + values = ["load_balancer01","load_balancer02"] + } +} +``` + +## Argument Reference + +The following arguments are supported: + +* `filter` - A combination of a filter name and one or more filter values. You can specify this argument for as many filter names as you need. The filter name can be any of the following: + * `load_balancer_names` - (Optional) The names of the load balancers. + +## Attribute Reference + +The following attributes are exported: + +* `load_balancers` - Information about one or more load balancers. + * `access_log` - Information about access logs. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. + * `dns_name` - The DNS name of the load balancer. + * `health_check` - Information about the health check configuration. + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `listeners` - The listeners for the load balancer. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. + * `load_balancer_name` - The name of the load balancer. + * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. + * `policy_name` - The name of the stickiness policy. + * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
+If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
+If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + * `net_id` - The ID of the Net for the load balancer. + * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
+To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. + * `subnets` - The IDs of the Subnets for the load balancer. + * `subregion_names` - One or more names of Subregions for the load balancer. + * `tags` - One or more tags associated with the load balancer. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. + From 287032149dc130d1aa68f474f31ddaf4bb887061 Mon Sep 17 00:00:00 2001 From: "rosalie.chadelat" Date: Fri, 27 Nov 2020 10:10:25 +0000 Subject: [PATCH 193/218] DOC-2556: Create Load Balancer Doc Uploaded resource load_balancer.html.markdown --- website/docs/r/load_balancer.html.markdown | 219 +++++++++++++++++++++ 1 file changed, 219 insertions(+) create mode 100644 website/docs/r/load_balancer.html.markdown diff --git a/website/docs/r/load_balancer.html.markdown b/website/docs/r/load_balancer.html.markdown new file mode 100644 index 000000000..c8c2b05b9 --- /dev/null +++ b/website/docs/r/load_balancer.html.markdown @@ -0,0 +1,219 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer" +sidebar_current: "outscale-load-balancer" +description: |- + [Manages a load balancer.] +--- + +# outscale_load_balancer Resource + +Manages a load balancer. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-loadbalancer). + +## Example Usage + +```hcl +# Create a load balancer in the public Cloud + +resource "outscale_load_balancer" "load_balancer01" { + load_balancer_name = "terraform-public-load-balancer" + subregion_names = ["${var.region}a"] + listeners { + backend_port = 8080 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 8080 + } + tags { + key = "name" + value = "terraform-public-load-balancer" + } +} + +# Create a load balancer in a Net + +#resource "outscale_net" "net01" { +# ip_range = "10.0.0.0/16" +#} + +#resource "outscale_subnet" "subnet01" { +# net_id = outscale_net.net01.net_id +# ip_range = "10.0.0.0/24" +# tags { +# key = "Name" +# value = "terraform-subnet-for-internal-load-balancer" +# } +#} + +#resource "outscale_security_group" "security_group01" { +# description = "Terraform security group for internal load balancer" +# security_group_name = "terraform-security-group-for-internal-load-balancer" +# net_id = outscale_net.net01.net_id +# tags { +# key = "Name" +# value = "terraform-security-group-for-internal-load-balancer" +# } +#} + +resource "outscale_load_balancer" "load_balancer02" { + load_balancer_name = "terraform-private-load-balancer" + listeners { + backend_port = 80 + backend_protocol = "TCP" + load_balancer_protocol = "TCP" + load_balancer_port = 80 + } + subnets = [outscale_subnet.subnet01.subnet_id] + security_groups = [outscale_security_group.security_group01.security_group_id] + load_balancer_type = "internal" + tags { + key = "name" + value = "terraform-private-load-balancer" + } +} + +# Create an internet-facing load balancer in a Net + +#resource "outscale_net" "net02" { +# ip_range = "10.0.0.0/16" +#} + +#resource "outscale_subnet" "subnet02" { +# net_id = outscale_net.net02.net_id +# ip_range = "10.0.0.0/24" +# tags { +# key = "Name" +# value = "terraform-security-group-for-load-balancer" +# } +#} + +#resource "outscale_internet_service" "internet_service01" { +# depends_on = "outscale_net.net02" +#} + +#resource "outscale_internet_service_link" "internet_service_link01" { +# internet_service_id = outscale_internet_service.internet_service01.internet_service_id +# net_id = outscale_net.net02.net_id +#} + +#resource "outscale_route" "route01" { +# gateway_id = outscale_internet_service.internet_service01.id +# destination_ip_range = "10.0.0.0/0" +# route_table_id = outscale_route_table.route_table01.route_table_id +#} + +#resource "outscale_route_table" "route_table01" { +# net_id = outscale_net.net02.net_id +# tags { +# key = "name" +# value = "terraform-route-table-for-load-balancer" +# } +#} + +#resource "outscale_route_table_link" "route_table_link01" { +# route_table_id = outscale_route_table.route_table01.route_table_id +# subnet_id = outscale_subnet.subnet02.subnet_id +#} + +resource "outscale_load_balancer" "load_balancer03" { + load_balancer_name = "terraform-internet-facing-private-load-balancer" + listeners { + backend_port = 80 + backend_protocol = "TCP" + load_balancer_protocol = "TCP" + load_balancer_port = 80 + } + listeners { + backend_port = 8080 + backend_protocol = "HTTP" + load_balancer_protocol = "HTTP" + load_balancer_port = 8080 + } + subnets = [outscale_subnet.subnet02.subnet_id] + load_balancer_type = "internet-facing" + tags { + key = "name" + value = "terraform-internet-facing-private-load-balancer" + } + depends_on = [outscale_route.route01,outscale_route_table_link.route_table_link01] +} +``` + +## Argument Reference + +The following arguments are supported: + +* `listeners` - (Required) One or more listeners to create. + * `backend_port` - (Optional) The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - (Optional) The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - (Optional) The port on which the load balancer is listening (between `1` and `65535`, both included). + * `load_balancer_protocol` - (Optional) The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `server_certificate_id` - (Optional) The ID of the server certificate. +* `load_balancer_name` - (Required) The unique name of the load balancer (32 alphanumeric or hyphen characters maximum, but cannot start or end with a hyphen). +* `load_balancer_type` - (Optional) The type of load balancer: `internet-facing` or `internal`. Use this parameter only for load balancers in a Net. +* `security_groups` - (Optional) (Net only) One or more IDs of security groups you want to assign to the load balancer. If not specified, the default security group of the Net is assigned to the load balancer. +* `subnets` - (Optional) One or more IDs of Subnets in your Net that you want to attach to the load balancer. +* `subregion_names` - (Optional) One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `LoadBalancerType` parameter. +* `tags` - (Optional) One or more tags assigned to the load balancer. + * `key` - (Optional) The key of the tag, with a minimum of 1 character. + * `value` - (Optional) The value of the tag, between 0 and 255 characters. + +## Attribute Reference + +The following attributes are exported: + +* `load_balancer` - Information about the load balancer. + * `access_log` - Information about access logs. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. + * `dns_name` - The DNS name of the load balancer. + * `health_check` - Information about the health check configuration. + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `listeners` - The listeners for the load balancer. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. + * `load_balancer_name` - The name of the load balancer. + * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. + * `policy_name` - The name of the stickiness policy. + * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
+If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
+If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + * `net_id` - The ID of the Net for the load balancer. + * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
+To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. + * `subnets` - The IDs of the Subnets for the load balancer. + * `subregion_names` - One or more names of Subregions for the load balancer. + * `tags` - One or more tags associated with the load balancer. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. + +## Import + +A load balancer can be imported using its name. For example: + +``` + +$ terraform import outscale_load_balancer.ImportedLbu Name-of-the-Lbu + +``` \ No newline at end of file From 57f6a5111e62a7ee24ec340757e88defc63cf22f Mon Sep 17 00:00:00 2001 From: Rosalie Chadelat Date: Fri, 27 Nov 2020 13:37:24 +0100 Subject: [PATCH 194/218] DOC-2493: Rename datasource vms_state to vm_states --- website/docs/d/vm_states.html.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/docs/d/vm_states.html.markdown b/website/docs/d/vm_states.html.markdown index 9b04884a4..900ddb338 100644 --- a/website/docs/d/vm_states.html.markdown +++ b/website/docs/d/vm_states.html.markdown @@ -1,7 +1,7 @@ --- layout: "outscale" -page_title: "3DS OUTSCALE: outscale_vm_state" -sidebar_current: "outscale-vm-state" +page_title: "3DS OUTSCALE: outscale_vm_states" +sidebar_current: "outscale-vm-states" description: |- [Provides information about VM states.] --- From 30160380ba18ecd95b469ec6f1a0fbcd07ffedd2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Fri, 27 Nov 2020 13:41:20 +0100 Subject: [PATCH 195/218] DOC-2596: Improve Terraform 0.13 note --- website/docs/index.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index bb7ef4f37..e3c490fc8 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -14,7 +14,7 @@ The provider is based on our 3DS OUTSCALE API. For more information, see [APIs R The provider needs to be configured with the proper credentials before it can be used. --> **Note:** The 3DS OUTSCALE provider is compatible with Terraform 0.13. For more information on provider requirements, see our [README](https://github.com/outscale-dev/terraform-provider-outscale#using-the-provider) and the [Terraform documentation](https://www.terraform.io/docs/configuration/provider-requirements.html#v0-12-compatible-provider-requirements). +-> **Note:** Since the release of Terraform 0.13, provider declaration has changed. For more information, see our [README](https://github.com/outscale-dev/terraform-provider-outscale#using-the-provider) and the [Terraform documentation](https://www.terraform.io/docs/configuration/provider-requirements.html). ## Example From 79d50b3572151ce4cb6ade5400b7dfbefa4bf6d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Fri, 27 Nov 2020 13:43:47 +0100 Subject: [PATCH 196/218] DOC-2679: Simplify endpoint path --- website/docs/index.html.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/docs/index.html.markdown b/website/docs/index.html.markdown index e3c490fc8..959ca575f 100644 --- a/website/docs/index.html.markdown +++ b/website/docs/index.html.markdown @@ -25,7 +25,7 @@ provider "outscale" { secret_key_id = var.secret_key_id region = "cn-southeast-1" endpoints { - api = "https://api.cn-southeast-1.outscale.hk/api/v1" + api = "api.cn-southeast-1.outscale.hk" } x509_cert_path = "/tmp/client-certificate.pem" x509_key_path = "/tmp/key.pem" @@ -91,7 +91,7 @@ In addition to [generic provider arguments](https://www.terraform.io/docs/config * `region` - (Optional) The Region that will be used as default value for all resources. It can also be sourced from the `OUTSCALE_REGION` [environment variable](#environment-variables). For more information on available Regions, see [Regions Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). -* `endpoints` - (Optional) The custom endpoint that will be used as default value for all resources. For more information on available endpoints, see [Endpoints Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). +* `endpoints` - (Optional) The shortened custom endpoint that will be used as default value for all resources. For more information on available endpoints, see [Endpoints Reference](https://wiki.outscale.net/display/EN/Regions%2C+Endpoints+and+Availability+Zones+Reference). * `x509_cert_path` - (Optional) The path to the x509 Client Certificate. It can also be sourced from the `OUTSCALE_X509CERT` [environment variable](#environment-variables). For more information on the use of those certificates, see [About API Access Rules](https://wiki.outscale.net/display/EN/About+API+Access+Rules). From 156b64954c1ffe491075e0c7fe994f5b7c1ac120 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Fri, 27 Nov 2020 14:34:39 +0100 Subject: [PATCH 197/218] DOC-2561: Add load balancer policy doc --- .../docs/r/load_balancer_policy.html.markdown | 115 ++++++++++++++++++ 1 file changed, 115 insertions(+) create mode 100644 website/docs/r/load_balancer_policy.html.markdown diff --git a/website/docs/r/load_balancer_policy.html.markdown b/website/docs/r/load_balancer_policy.html.markdown new file mode 100644 index 000000000..b92a8b3fd --- /dev/null +++ b/website/docs/r/load_balancer_policy.html.markdown @@ -0,0 +1,115 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_policy" +sidebar_current: "outscale-load-balancer-policy" +description: |- + [Manages a load balancer policy.] +--- + +# outscale_load_balancer_policy Resource + +Manages a load balancer policy. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-loadbalancerpolicy). + +## Example Usage + +```hcl +# Create a load balancer policy based on browser + +#resource "outscale_load_balancer" "load_balancer01" { +# load_balancer_name = "terraform-load-balancer-for-browser-policy" +# subregion_names = ["eu-west-2a"] +# listeners { +# backend_port = 8080 +# backend_protocol = "HTTP" +# load_balancer_port = 8080 +# load_balancer_protocol = "HTTP" +# } +#} + +resource "outscale_load_balancer_policy" "load_balancer_policy01" { + load_balancer_name = "terraform-load-balancer-for-browser-policy" + policy_name = "terraform-load-balancer-browser-policy" + policy_type = "load_balancer" +} + +# Create a load balancer policy based on application cookie + +#resource "outscale_load_balancer" "load_balancer02" { +# load_balancer_name = "terraform-load-balancer-for-app-policy" +# subregion_names = ["${var.region}b"] +# listeners { +# load_balancer_port = 80 +# load_balancer_protocol = "TCP" +# backend_port = 80 +# backend_protocol = "TCP" +# } +#} + +resource "outscale_load_balancer_policy" "load_balancer_policy02" { + load_balancer_name = outscale_load_balancer.load_balancer02.load_balancer_name + policy_name = "terraform-load-balancer-app-policy" + policy_type = "app" + cookie_name = "cookie01" + depends_on = [outscale_load_balancer.load_balancer02] +} +``` + +## Argument Reference + +The following arguments are supported: + +* `cookie_name` - (Optional) The name of the application cookie used for stickiness. This parameter is required if you create a stickiness policy based on an application-generated cookie. +* `load_balancer_name` - (Required) The name of the load balancer for which you want to create a policy. +* `policy_name` - (Required) The name of the policy. This name must be unique and consist of alphanumeric characters and dashes (-). +* `policy_type` - (Required) The type of stickiness policy you want to create: `app` or `load_balancer`. + +## Attribute Reference + +The following attributes are exported: + +* `load_balancer` - Information about the load balancer. + * `access_log` - Information about access logs. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. + * `dns_name` - The DNS name of the load balancer. + * `health_check` - Information about the health check configuration. + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `listeners` - The listeners for the load balancer. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. + * `load_balancer_name` - The name of the load balancer. + * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. + * `policy_name` - The name of the stickiness policy. + * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
+If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
+If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + * `net_id` - The ID of the Net for the load balancer. + * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
+To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. + * `subnets` - The IDs of the Subnets for the load balancer. + * `subregion_names` - One or more names of Subregions for the load balancer. + * `tags` - One or more tags associated with the load balancer. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. + From ffa521cfbc3a21d7a41efcbdee7f638de2c6a20d Mon Sep 17 00:00:00 2001 From: "margaux.haccard" Date: Fri, 27 Nov 2020 15:23:17 +0100 Subject: [PATCH 198/218] DOC-2558: Create Load Balancer VM Doc --- .../docs/r/load_balancer_vms.html.markdown | 63 +++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 website/docs/r/load_balancer_vms.html.markdown diff --git a/website/docs/r/load_balancer_vms.html.markdown b/website/docs/r/load_balancer_vms.html.markdown new file mode 100644 index 000000000..da9187bba --- /dev/null +++ b/website/docs/r/load_balancer_vms.html.markdown @@ -0,0 +1,63 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_vms" +sidebar_current: "outscale-load-balancer-vms" +description: |- + [Manages a load balancer VM.] +--- + +# outscale_load_balancer_vms Resource + +Manages a load balancer VM. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#registervmsinloadbalancer). + +## Example Usage + +```hcl +#resource "outscale_vm" "outscale_vm01" { +# image_id = "ami-12345678" +# vm_type = "t2.small" +# keypair_name = var.keypair_name +#} + +#resource "outscale_vm" "outscale_vm_02" { +# image_id = var.image_id +# vm_type = var.vm_type +# keypair_name = var.keypair_name +#} + +#resource "outscale_load_balancer" "load_balancer01" { +# load_balancer_name = "load-balancer-for-backend-vms" +# subregion_names = ["${var.region}a"] +# listeners { +# backend_port = 80 +# backend_protocol = "TCP" +# load_balancer_protocol = "TCP" +# load_balancer_port = 80 +# } +# tags { +# key = "name" +# value = "outscale_load_balancer01" +# } +#} + +resource "outscale_load_balancer_vms" "outscale_load_balancer_vms01" { + load_balancer_name = load-balancer-for-backend-vms + backend_vm_ids = [outscale_vm.outscale_vm01.vm_id,outscale_vm.outscale_vm_02.vm_id] +} +``` + +## Argument Reference + +The following arguments are supported: + +* `backend_vm_ids` - (Required) One or more IDs of back-end VMs.
+Specifying the same ID several times has no effect as each back-end VM has equal weight. +* `load_balancer_name` - (Required) The name of the load balancer. + +## Attribute Reference + +No attribute is exported. + + From ba6114208bc3a3617d06754bc78959b1b3e86d18 Mon Sep 17 00:00:00 2001 From: Rosalie Chadelat Date: Fri, 27 Nov 2020 15:30:24 +0100 Subject: [PATCH 199/218] DOC-2556: modified indent to display 3 levels --- website/docs/d/load_balancer.html.markdown | 50 +++++++++++----------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/website/docs/d/load_balancer.html.markdown b/website/docs/d/load_balancer.html.markdown index 48a372020..1e80cb9f6 100644 --- a/website/docs/d/load_balancer.html.markdown +++ b/website/docs/d/load_balancer.html.markdown @@ -36,33 +36,33 @@ The following attributes are exported: * `load_balancers` - Information about one or more load balancers. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. - * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). - * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. - * `cookie_name` - The name of the application cookie used for stickiness. - * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. * `dns_name` - The DNS name of the load balancer. * `health_check` - Information about the health check configuration. - * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). - * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - * `path` - The path for HTTP or HTTPS requests. - * `port` - The port number (between `1` and `65535`, both included). - * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). * `listeners` - The listeners for the load balancer. - * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). - * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). - * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. - * `server_certificate_id` - The ID of the server certificate. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. * `load_balancer_name` - The name of the load balancer. * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. - * `policy_name` - The name of the stickiness policy. + * `policy_name` - The name of the stickiness policy. * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. @@ -70,11 +70,11 @@ If `LoadBalancerType` is `internal`, the load balancer has a public DNS name tha * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. - * `security_group_account_id` - The account ID of the owner of the security group. - * `security_group_name` - The name of the security group. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. * `subnets` - The IDs of the Subnets for the load balancer. * `subregion_names` - One or more names of Subregions for the load balancer. * `tags` - One or more tags associated with the load balancer. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. From c520195162b9755c4b256e1bcf9a4858ac91df77 Mon Sep 17 00:00:00 2001 From: Rosalie Chadelat Date: Fri, 27 Nov 2020 15:50:15 +0100 Subject: [PATCH 200/218] DOC-2557: corrected indent --- website/docs/r/load_balancer.html.markdown | 48 +++++++++++----------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/website/docs/r/load_balancer.html.markdown b/website/docs/r/load_balancer.html.markdown index c8c2b05b9..ae7bc7bdd 100644 --- a/website/docs/r/load_balancer.html.markdown +++ b/website/docs/r/load_balancer.html.markdown @@ -166,33 +166,33 @@ The following attributes are exported: * `load_balancer` - Information about the load balancer. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. - * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. - * `cookie_name` - The name of the application cookie used for stickiness. - * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. * `dns_name` - The DNS name of the load balancer. * `health_check` - Information about the health check configuration. - * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). - * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - * `path` - The path for HTTP or HTTPS requests. - * `port` - The port number (between `1` and `65535`, both included). - * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). * `listeners` - The listeners for the load balancer. - * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). - * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). - * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. - * `server_certificate_id` - The ID of the server certificate. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. * `load_balancer_name` - The name of the load balancer. * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. - * `policy_name` - The name of the stickiness policy. + * `policy_name` - The name of the stickiness policy. * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. @@ -200,13 +200,13 @@ If `LoadBalancerType` is `internal`, the load balancer has a public DNS name tha * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. - * `security_group_account_id` - The account ID of the owner of the security group. - * `security_group_name` - The name of the security group. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. * `subnets` - The IDs of the Subnets for the load balancer. * `subregion_names` - One or more names of Subregions for the load balancer. * `tags` - One or more tags associated with the load balancer. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import From 71dcb74d9aa53bbbb338a263a6e520883a9ee661 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Mon, 30 Nov 2020 13:02:20 +0100 Subject: [PATCH 201/218] DOC-2674: Update parameter descriptions --- website/docs/d/client_gateway.html.markdown | 2 +- website/docs/d/client_gateways.html.markdown | 2 +- website/docs/d/nic.html.markdown | 2 +- website/docs/d/nics.html.markdown | 2 +- website/docs/d/security_group.html.markdown | 6 +++--- website/docs/d/security_groups.html.markdown | 6 +++--- website/docs/d/vm.html.markdown | 8 ++++---- website/docs/d/vms.html.markdown | 8 ++++---- website/docs/d/volume.html.markdown | 4 ++-- website/docs/d/volumes.html.markdown | 4 ++-- website/docs/r/client_gateway.html.markdown | 4 ++-- website/docs/r/nic.html.markdown | 2 +- website/docs/r/security_group.html.markdown | 8 ++++---- website/docs/r/security_group_rule.html.markdown | 8 ++++---- website/docs/r/vm.html.markdown | 10 +++++----- website/docs/r/volume.html.markdown | 2 +- 16 files changed, 39 insertions(+), 39 deletions(-) diff --git a/website/docs/d/client_gateway.html.markdown b/website/docs/d/client_gateway.html.markdown index bbe01989e..4bb0df4a4 100644 --- a/website/docs/d/client_gateway.html.markdown +++ b/website/docs/d/client_gateway.html.markdown @@ -41,7 +41,7 @@ The following arguments are supported: The following attributes are exported: -* `bgp_asn` - An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. +* `bgp_asn` - An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. * `client_gateway_id` - The ID of the client gateway. * `connection_type` - The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). * `public_ip` - The public IPv4 address of the client gateway (must be a fixed address into a NATed network). diff --git a/website/docs/d/client_gateways.html.markdown b/website/docs/d/client_gateways.html.markdown index 2ad3a7ccb..b919e710c 100644 --- a/website/docs/d/client_gateways.html.markdown +++ b/website/docs/d/client_gateways.html.markdown @@ -42,7 +42,7 @@ The following arguments are supported: The following attributes are exported: * `client_gateways` - Information about one or more client gateways. - * `bgp_asn` - An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. + * `bgp_asn` - An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. * `client_gateway_id` - The ID of the client gateway. * `connection_type` - The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). * `public_ip` - The public IPv4 address of the client gateway (must be a fixed address into a NATed network). diff --git a/website/docs/d/nic.html.markdown b/website/docs/d/nic.html.markdown index 3dd566758..6a6c3e5b3 100644 --- a/website/docs/d/nic.html.markdown +++ b/website/docs/d/nic.html.markdown @@ -74,7 +74,7 @@ The following attributes are exported: * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. diff --git a/website/docs/d/nics.html.markdown b/website/docs/d/nics.html.markdown index 56aa9c884..8ea2dcbfa 100644 --- a/website/docs/d/nics.html.markdown +++ b/website/docs/d/nics.html.markdown @@ -74,7 +74,7 @@ The following attributes are exported: * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. diff --git a/website/docs/d/security_group.html.markdown b/website/docs/d/security_group.html.markdown index 137f11e7b..92689a764 100644 --- a/website/docs/d/security_group.html.markdown +++ b/website/docs/d/security_group.html.markdown @@ -52,7 +52,7 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. @@ -63,11 +63,11 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/security_groups.html.markdown b/website/docs/d/security_groups.html.markdown index dd30e4163..f9d60b4d4 100644 --- a/website/docs/d/security_groups.html.markdown +++ b/website/docs/d/security_groups.html.markdown @@ -52,7 +52,7 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. @@ -63,11 +63,11 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/vm.html.markdown b/website/docs/d/vm.html.markdown index ddb199282..e2f0e51b0 100644 --- a/website/docs/d/vm.html.markdown +++ b/website/docs/d/vm.html.markdown @@ -58,7 +58,7 @@ The following attributes are exported: * `keypair_name` - The name of the keypair used when launching the VM. * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. - * `nics` - The network interface cards (NICs) the VMs are attached to. + * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. * `account_id` - The account ID of the owner of the NIC. * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. @@ -85,11 +85,11 @@ The following attributes are exported: * `private_ip` - The private IP address. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. - * `performance` - The performance of the VM (`standard` \| `high` \| `highest`). + * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. * `subregion_name` - The name of the Subregion. * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). @@ -103,7 +103,7 @@ The following attributes are exported: * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. diff --git a/website/docs/d/vms.html.markdown b/website/docs/d/vms.html.markdown index 44fe38f2f..1bcffebec 100644 --- a/website/docs/d/vms.html.markdown +++ b/website/docs/d/vms.html.markdown @@ -58,7 +58,7 @@ The following attributes are exported: * `keypair_name` - The name of the keypair used when launching the VM. * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. - * `nics` - The network interface cards (NICs) the VMs are attached to. + * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. * `account_id` - The account ID of the owner of the NIC. * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. @@ -85,11 +85,11 @@ The following attributes are exported: * `private_ip` - The private IP address. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. - * `performance` - The performance of the VM (`standard` \| `high` \| `highest`). + * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. * `subregion_name` - The name of the Subregion. * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). @@ -103,7 +103,7 @@ The following attributes are exported: * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. diff --git a/website/docs/d/volume.html.markdown b/website/docs/d/volume.html.markdown index b53926c07..472e30638 100644 --- a/website/docs/d/volume.html.markdown +++ b/website/docs/d/volume.html.markdown @@ -44,7 +44,7 @@ The following arguments are supported: * `tags` - (Optional) The key/value combination of the tags associated with the volumes, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}. * `volume_ids` - (Optional) The IDs of the volumes. * `volume_sizes` - (Optional) The sizes of the volumes, in gibibytes (GiB). - * `volume_states` - (Optional) The states of the volumes (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). + * `volume_states` - (Optional) The states of the volumes (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `volume_types` - (Optional) The types of the volumes (`standard` \| `gp2` \| `io1`). ## Attribute Reference @@ -63,7 +63,7 @@ The following attributes are exported: * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. - * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). + * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. * `key` - The key of the tag, with a minimum of 1 character. diff --git a/website/docs/d/volumes.html.markdown b/website/docs/d/volumes.html.markdown index 3e0da1991..e34397c3f 100644 --- a/website/docs/d/volumes.html.markdown +++ b/website/docs/d/volumes.html.markdown @@ -44,7 +44,7 @@ The following arguments are supported: * `tags` - (Optional) The key/value combination of the tags associated with the volumes, in the following format: "Filters":{"Tags":["TAGKEY=TAGVALUE"]}. * `volume_ids` - (Optional) The IDs of the volumes. * `volume_sizes` - (Optional) The sizes of the volumes, in gibibytes (GiB). - * `volume_states` - (Optional) The states of the volumes (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). + * `volume_states` - (Optional) The states of the volumes (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `volume_types` - (Optional) The types of the volumes (`standard` \| `gp2` \| `io1`). ## Attribute Reference @@ -63,7 +63,7 @@ The following attributes are exported: * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. - * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). + * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. * `key` - The key of the tag, with a minimum of 1 character. diff --git a/website/docs/r/client_gateway.html.markdown b/website/docs/r/client_gateway.html.markdown index c8c8bfb3f..e185edcb9 100644 --- a/website/docs/r/client_gateway.html.markdown +++ b/website/docs/r/client_gateway.html.markdown @@ -30,7 +30,7 @@ resource "outscale_client_gateway" "client_gateway01" { The following arguments are supported: -* `bgp_asn` - (Required) An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. The integer must be within the [0;4294967295] range. By default, 65000. +* `bgp_asn` - (Required) An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. * `connection_type` - (Required) The communication protocol used to establish tunnel with your client gateway (only `ipsec.1` is supported). * `public_ip` - (Required) The public fixed IPv4 address of your client gateway. * `tags` - One or more tags to add to this resource. @@ -42,7 +42,7 @@ The following arguments are supported: The following attributes are exported: * `client_gateway` - Information about the client gateway. - * `bgp_asn` - An unsigned 32-bits Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find out the path to your client gateway through the Internet network. + * `bgp_asn` - An Autonomous System Number (ASN) used by the Border Gateway Protocol (BGP) to find the path to your client gateway through the Internet. * `client_gateway_id` - The ID of the client gateway. * `connection_type` - The type of communication tunnel used by the client gateway (only `ipsec.1` is supported). * `public_ip` - The public IPv4 address of the client gateway (must be a fixed address into a NATed network). diff --git a/website/docs/r/nic.html.markdown b/website/docs/r/nic.html.markdown index 7d4c89aa2..24dd679b4 100644 --- a/website/docs/r/nic.html.markdown +++ b/website/docs/r/nic.html.markdown @@ -86,7 +86,7 @@ The following attributes are exported: * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. diff --git a/website/docs/r/security_group.html.markdown b/website/docs/r/security_group.html.markdown index abe7ee445..7bdfffafe 100644 --- a/website/docs/r/security_group.html.markdown +++ b/website/docs/r/security_group.html.markdown @@ -35,7 +35,7 @@ The following arguments are supported: * `description` - (Required) A description for the security group, with a maximum length of 255 [ASCII printable characters](https://en.wikipedia.org/wiki/ASCII#Printable_characters). * `net_id` - (Optional) The ID of the Net for the security group. -* `security_group_name` - (Required) (Public Cloud only) The name of the security group.
+* `security_group_name` - (Required) The name of the security group.
This name must not start with `sg-`.
This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed. * `tags` - One or more tags to add to this resource. @@ -56,7 +56,7 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. @@ -67,11 +67,11 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/r/security_group_rule.html.markdown b/website/docs/r/security_group_rule.html.markdown index 585f18405..c4b5aa187 100644 --- a/website/docs/r/security_group_rule.html.markdown +++ b/website/docs/r/security_group_rule.html.markdown @@ -75,7 +75,7 @@ The following arguments are supported: * `security_groups_members` - (Optional) Information about one or more members of a security group. * `account_id` - (Optional) The account ID of a user. * `security_group_id` - (Required) The ID of the security group. - * `security_group_name` - (Optional) (Public Cloud only) The name of the security group. + * `security_group_name` - (Optional) The name of the security group. * `service_ids` - (Optional) One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - (Optional) The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_account_id_to_link` - (Optional) The account ID of the owner of the security group for which you want to create a rule. @@ -97,7 +97,7 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. @@ -108,11 +108,11 @@ The following attributes are exported: * `security_groups_members` - Information about one or more members of a security group. * `account_id` - The account ID of a user. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/r/vm.html.markdown b/website/docs/r/vm.html.markdown index 61eedecf7..46aad045d 100644 --- a/website/docs/r/vm.html.markdown +++ b/website/docs/r/vm.html.markdown @@ -186,7 +186,7 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `secondary_private_ip_count` - (Optional) The number of secondary private IP addresses, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP address in the `private_ips` parameter. * `security_group_ids` - (Optional) One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM. * `subnet_id` - (Optional) The ID of the Subnet for the NIC, if you create a NIC when creating a VM. -* `performance` - (Optional) The performance of the VM (`standard` \| `high` \| `highest`). +* `performance` - (Optional) The performance of the VM (`medium` \| `high` \| `highest`). * `placement_subregion_name` - (Optional) The name of the Subregion where the VM is placed. * `placement_tenancy` - (Optional) The tenancy of the VM (`default` | `dedicated`). * `private_ips` - (Optional) One or more private IP addresses of the VM. @@ -223,7 +223,7 @@ The following attributes are exported: * `keypair_name` - The name of the keypair used when launching the VM. * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. - * `nics` - The network interface cards (NICs) the VMs are attached to. + * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. * `account_id` - The account ID of the owner of the NIC. * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. @@ -250,11 +250,11 @@ The following attributes are exported: * `private_ip` - The private IP address. * `security_groups` - One or more IDs of security groups for the NIC. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. - * `performance` - The performance of the VM (`standard` \| `high` \| `highest`). + * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. * `subregion_name` - The name of the Subregion. * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). @@ -268,7 +268,7 @@ The following attributes are exported: * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. * `security_group_id` - The ID of the security group. - * `security_group_name` - (Public Cloud only) The name of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. diff --git a/website/docs/r/volume.html.markdown b/website/docs/r/volume.html.markdown index d22a0b35e..598e9c9c7 100644 --- a/website/docs/r/volume.html.markdown +++ b/website/docs/r/volume.html.markdown @@ -56,7 +56,7 @@ The following attributes are exported: * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. - * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `deleting` \| `error`). + * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. * `key` - The key of the tag, with a minimum of 1 character. From cc1d0d1935117077a5f720c6df043cf172811971 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Tran?= Date: Mon, 30 Nov 2020 14:05:44 +0100 Subject: [PATCH 202/218] DOC-2560: Create Load Balancer Listener Rule Doc --- .../load_balancer_listener_rule.html.markdown | 46 ++++++++ ...load_balancer_listener_rules.html.markdown | 46 ++++++++ .../load_balancer_listener_rule.html.markdown | 106 ++++++++++++++++++ 3 files changed, 198 insertions(+) create mode 100644 website/docs/d/load_balancer_listener_rule.html.markdown create mode 100644 website/docs/d/load_balancer_listener_rules.html.markdown create mode 100644 website/docs/r/load_balancer_listener_rule.html.markdown diff --git a/website/docs/d/load_balancer_listener_rule.html.markdown b/website/docs/d/load_balancer_listener_rule.html.markdown new file mode 100644 index 000000000..44a2a9f4b --- /dev/null +++ b/website/docs/d/load_balancer_listener_rule.html.markdown @@ -0,0 +1,46 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_listener_rule" +sidebar_current: "outscale-load-balancer-listener-rule" +description: |- + [Provides information about a specific load balancer listener rule.] +--- + +# outscale_load_balancer_listener_rule Data Source + +Provides information about a specific load balancer listener rule. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-listener). + +## Example Usage + +```hcl +data "outscale_load_balancer_listener_rule" "rule01" { + filter { + name = "listener_rule_names" + values = ["terraform-listener-rule02"] + } +} +``` + +## Argument Reference + +The following arguments are supported: + +* `filter` - A combination of a filter name and one or more filter values. You can specify this argument for as many filter names as you need. The filter name can be any of the following: + * `listener_rule_names` - (Optional) The names of the listener rules. + +## Attribute Reference + +The following attributes are exported: + +* `listener_rules` - The list of the rules to describe. + * `action` - The type of action for the rule (always `forward`). + * `host_name_pattern` - A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + * `listener_id` - The ID of the listener. + * `listener_rule_id` - The ID of the listener rule. + * `listener_rule_name` - A human-readable name for the listener rule. + * `path_pattern` - A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. + * `priority` - The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. + * `vm_ids` - The IDs of the backend VMs. + diff --git a/website/docs/d/load_balancer_listener_rules.html.markdown b/website/docs/d/load_balancer_listener_rules.html.markdown new file mode 100644 index 000000000..1fcd7a866 --- /dev/null +++ b/website/docs/d/load_balancer_listener_rules.html.markdown @@ -0,0 +1,46 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_listener_rule" +sidebar_current: "outscale-load-balancer-listener-rule" +description: |- + [Provides information about load balancer listener rules.] +--- + +# outscale_load_balancer_listener_rule Data Source + +Provides information about load balancer listener rules. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-listener). + +## Example Usage + +```hcl +data "outscale_load_balancer_listener_rules" "rules01" { + filter { + name = "listener_rule_names" + values = ["terraform-listener-rule02","terraform-listener-rule01"] + } +} +``` + +## Argument Reference + +The following arguments are supported: + +* `filter` - A combination of a filter name and one or more filter values. You can specify this argument for as many filter names as you need. The filter name can be any of the following: + * `listener_rule_names` - (Optional) The names of the listener rules. + +## Attribute Reference + +The following attributes are exported: + +* `listener_rules` - The list of the rules to describe. + * `action` - The type of action for the rule (always `forward`). + * `host_name_pattern` - A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + * `listener_id` - The ID of the listener. + * `listener_rule_id` - The ID of the listener rule. + * `listener_rule_name` - A human-readable name for the listener rule. + * `path_pattern` - A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. + * `priority` - The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. + * `vm_ids` - The IDs of the backend VMs. + diff --git a/website/docs/r/load_balancer_listener_rule.html.markdown b/website/docs/r/load_balancer_listener_rule.html.markdown new file mode 100644 index 000000000..886387184 --- /dev/null +++ b/website/docs/r/load_balancer_listener_rule.html.markdown @@ -0,0 +1,106 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_listener_rule" +sidebar_current: "outscale-load-balancer-listener-rule" +description: |- + [Manages a load balancer listener rule.] +--- + +# outscale_load_balancer_listener_rule Resource + +Manages a load balancer listener rule. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#3ds-outscale-api-listener). + +## Example Usage + +```hcl +#resource "outscale_vm" "vm01" { +# image_id = var.image_id +# vm_type = var.vm_type +# keypair_name = var.keypair_name +#} + +#resource "outscale_load_balancer" "load_balancer01" { +# load_balancer_name = "terraform-public-load-balancer" +# subregion_names = ["${var.region}a"] +# listeners { +# backend_port = 80 +# backend_protocol = "TCP" +# load_balancer_protocol = "TCP" +# load_balancer_port = 80 +# } +# tags { +# key = "name" +# value = "terraform-public-load-balancer" +# } +#} + +#resource "outscale_load_balancer_vms" "outscale_load_balancer_vms01" { +# load_balancer_name = outscale_load_balancer.load_balancer01.id +# backend_vm_ids = [outscale_vm.vm01.vm_id] +#} + +# Create a listener rule based on path pattern + +resource "outscale_load_balancer_listener_rule" "rule01" { + listener { + load_balancer_name = outscale_load_balancer.load_balancer01.id + load_balancer_port = 80 + } + listener_rule { + action = "forward" + listener_rule_name = "terraform-listener-rule01" + path_pattern = "*.abc.*.abc.*.com" + priority = 10 + } + vm_ids = [outscale_vm.vm01.vm_id] +} + +# Create a listener rule based on host pattern + +resource "outscale_load_balancer_listener_rule" "rule02" { + listener { + load_balancer_name = outscale_load_balancer.load_balancer01.id + load_balancer_port = 80 + } + listener_rule { + action = "forward" + listener_rule_name = "terraform-listener-rule02" + host_name_pattern = "*.abc.-.abc.*.com" + priority = 1 + } + vm_ids = [outscale_vm.vm01.vm_id] +} +``` + +## Argument Reference + +The following arguments are supported: + +* `listener_rule` - Information about the listener rule. + * `action` - (Optional) The type of action for the rule (always `forward`). + * `host_name_pattern` - (Optional) A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + * `listener_rule_id` - (Optional) The ID of the listener. + * `listener_rule_name` - (Optional) A human-readable name for the listener rule. + * `path_pattern` - (Optional) A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. + * `priority` - (Optional) The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. +* `listener` - Information about the load balancer. + * `load_balancer_name` - (Optional) The name of the load balancer to which the listener is attached. + * `load_balancer_port` - (Optional) The port of load balancer on which the load balancer is listening (between `1` and `65535` both included). +* `vm_ids` - (Required) The IDs of the backend VMs. + +## Attribute Reference + +The following attributes are exported: + +* `listener_rule` - Information about the listener rule. + * `action` - The type of action for the rule (always `forward`). + * `host_name_pattern` - A host-name pattern for the rule, with a maximum length of 128 characters. This host-name pattern supports maximum three wildcards, and must not contain any special characters except [-.?]. + * `listener_id` - The ID of the listener. + * `listener_rule_id` - The ID of the listener rule. + * `listener_rule_name` - A human-readable name for the listener rule. + * `path_pattern` - A path pattern for the rule, with a maximum length of 128 characters. This path pattern supports maximum three wildcards, and must not contain any special characters except [_-.$/~"'@:+?]. + * `priority` - The priority level of the listener rule, between `1` and `19999` both included. Each rule must have a unique priority level. Otherwise, an error is returned. + * `vm_ids` - The IDs of the backend VMs. + From 8763b3c99c453379856a5911b66468745e099f4f Mon Sep 17 00:00:00 2001 From: "margaux.haccard" Date: Mon, 30 Nov 2020 14:22:27 +0100 Subject: [PATCH 203/218] DOC-2558: Create Load Balancer VM Doc --- website/docs/r/load_balancer_vms.html.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/docs/r/load_balancer_vms.html.markdown b/website/docs/r/load_balancer_vms.html.markdown index da9187bba..c7e670ebd 100644 --- a/website/docs/r/load_balancer_vms.html.markdown +++ b/website/docs/r/load_balancer_vms.html.markdown @@ -3,12 +3,12 @@ layout: "outscale" page_title: "3DS OUTSCALE: outscale_load_balancer_vms" sidebar_current: "outscale-load-balancer-vms" description: |- - [Manages a load balancer VM.] + [Manages load balancer VMs.] --- # outscale_load_balancer_vms Resource -Manages a load balancer VM. +Manages load balancer VMs. For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#registervmsinloadbalancer). From 362f308ef92f2c72cf0c4c0b9d5ef8d011392ee2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Tran?= Date: Mon, 30 Nov 2020 15:15:33 +0100 Subject: [PATCH 204/218] DOC-2681: Fix indents in older files --- website/docs/d/client_gateways.html.markdown | 4 +- website/docs/d/dhcp_options.html.markdown | 4 +- website/docs/d/image.html.markdown | 28 +++--- website/docs/d/images.html.markdown | 28 +++--- website/docs/d/internet_service.html.markdown | 4 +- .../docs/d/internet_services.html.markdown | 4 +- website/docs/d/load_balancers.html.markdown | 48 +++++----- website/docs/d/nat_service.html.markdown | 8 +- website/docs/d/nat_services.html.markdown | 8 +- website/docs/d/net.html.markdown | 4 +- website/docs/d/net_peering.html.markdown | 20 ++-- website/docs/d/net_peerings.html.markdown | 20 ++-- website/docs/d/nets.html.markdown | 4 +- website/docs/d/nic.html.markdown | 48 +++++----- website/docs/d/nics.html.markdown | 48 +++++----- website/docs/d/public_ip.html.markdown | 4 +- website/docs/d/public_ips.html.markdown | 4 +- website/docs/d/route_table.html.markdown | 36 +++---- website/docs/d/route_tables.html.markdown | 36 +++---- website/docs/d/security_group.html.markdown | 40 ++++---- website/docs/d/security_groups.html.markdown | 40 ++++---- website/docs/d/snapshot.html.markdown | 8 +- website/docs/d/snapshots.html.markdown | 8 +- website/docs/d/subnet.html.markdown | 4 +- website/docs/d/subnets.html.markdown | 4 +- website/docs/d/virtual_gateways.html.markdown | 8 +- website/docs/d/vm.html.markdown | 78 +++++++-------- website/docs/d/vm_state.html.markdown | 8 +- website/docs/d/vm_states.html.markdown | 8 +- website/docs/d/vms.html.markdown | 78 +++++++-------- website/docs/d/volume.html.markdown | 14 +-- website/docs/d/volumes.html.markdown | 14 +-- website/docs/d/vpn_connections.html.markdown | 10 +- website/docs/r/client_gateway.html.markdown | 4 +- website/docs/r/dhcp_option.html.markdown | 4 +- website/docs/r/image.html.markdown | 42 ++++---- website/docs/r/internet_service.html.markdown | 8 +- .../docs/r/load_balancer_policy.html.markdown | 48 +++++----- website/docs/r/nat_service.html.markdown | 12 +-- website/docs/r/net.html.markdown | 8 +- website/docs/r/net_peering.html.markdown | 24 ++--- .../r/net_peering_acceptation.html.markdown | 20 ++-- website/docs/r/nic.html.markdown | 52 +++++----- website/docs/r/public_ip.html.markdown | 8 +- website/docs/r/route.html.markdown | 36 +++---- website/docs/r/route_table.html.markdown | 40 ++++---- website/docs/r/security_group.html.markdown | 44 ++++----- website/docs/r/snapshot.html.markdown | 12 +-- website/docs/r/subnet.html.markdown | 8 +- website/docs/r/virtual_gateway.html.markdown | 8 +- ...al_gateway_route_propagation.html.markdown | 36 +++---- website/docs/r/vm.html.markdown | 96 +++++++++---------- website/docs/r/volume.html.markdown | 18 ++-- website/docs/r/vpn_connection.html.markdown | 10 +- 54 files changed, 610 insertions(+), 610 deletions(-) diff --git a/website/docs/d/client_gateways.html.markdown b/website/docs/d/client_gateways.html.markdown index b919e710c..25d4398c1 100644 --- a/website/docs/d/client_gateways.html.markdown +++ b/website/docs/d/client_gateways.html.markdown @@ -48,6 +48,6 @@ The following attributes are exported: * `public_ip` - The public IPv4 address of the client gateway (must be a fixed address into a NATed network). * `state` - The state of the client gateway (`pending` \| `available` \| `deleting` \| `deleted`). * `tags` - One or more tags associated with the client gateway. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/dhcp_options.html.markdown b/website/docs/d/dhcp_options.html.markdown index 9b8788d02..8633b66db 100644 --- a/website/docs/d/dhcp_options.html.markdown +++ b/website/docs/d/dhcp_options.html.markdown @@ -49,6 +49,6 @@ The following attributes are exported: * `domain_name_servers` - One or more IP addresses for the domain name servers. * `ntp_servers` - One or more IP addresses for the NTP servers. * `tags` - One or more tags associated with the DHCP options set. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/image.html.markdown b/website/docs/d/image.html.markdown index 16499e018..1d97d06d1 100644 --- a/website/docs/d/image.html.markdown +++ b/website/docs/d/image.html.markdown @@ -62,17 +62,17 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the OMI. * `architecture` - The architecture of the OMI (by default, `i386`). * `block_device_mappings` - One or more block device mappings. - * `bsu` - Information about the BSU volume to create. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - * `snapshot_id` - The ID of the snapshot used to create the volume. - * `volume_size` - The size of the volume, in gibibytes (GiB).
+ * `bsu` - Information about the BSU volume to create. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + * `snapshot_id` - The ID of the snapshot used to create the volume. + * `volume_size` - The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
+ * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). - * `device_name` - The name of the device. - * `virtual_device_name` - The name of the virtual device (ephemeralN). + * `device_name` - The name of the device. + * `virtual_device_name` - The name of the virtual device (ephemeralN). * `creation_date` - The date and time at which the OMI was created. * `description` - The description of the OMI. * `file_location` - The location where the OMI file is stored on Object Storage Unit (OSU). @@ -80,15 +80,15 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `image_name` - The name of the OMI. * `image_type` - The type of the OMI. * `permissions_to_launch` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `product_codes` - The product code associated with the OMI (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). * `root_device_name` - The name of the root device. * `root_device_type` - The type of root device used by the OMI (always `bsu`). * `state` - The state of the OMI (`pending` \| `available` \| `failed`). * `state_comment` - Information about the change of state. - * `state_code` - The code of the change of state. - * `state_message` - A message explaining the change of state. + * `state_code` - The code of the change of state. + * `state_message` - A message explaining the change of state. * `tags` - One or more tags associated with the OMI. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/images.html.markdown b/website/docs/d/images.html.markdown index 603d17751..96e38f851 100644 --- a/website/docs/d/images.html.markdown +++ b/website/docs/d/images.html.markdown @@ -62,17 +62,17 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the OMI. * `architecture` - The architecture of the OMI (by default, `i386`). * `block_device_mappings` - One or more block device mappings. - * `bsu` - Information about the BSU volume to create. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - * `snapshot_id` - The ID of the snapshot used to create the volume. - * `volume_size` - The size of the volume, in gibibytes (GiB).
+ * `bsu` - Information about the BSU volume to create. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + * `snapshot_id` - The ID of the snapshot used to create the volume. + * `volume_size` - The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
+ * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). - * `device_name` - The name of the device. - * `virtual_device_name` - The name of the virtual device (ephemeralN). + * `device_name` - The name of the device. + * `virtual_device_name` - The name of the virtual device (ephemeralN). * `creation_date` - The date and time at which the OMI was created. * `description` - The description of the OMI. * `file_location` - The location where the OMI file is stored on Object Storage Unit (OSU). @@ -80,15 +80,15 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `image_name` - The name of the OMI. * `image_type` - The type of the OMI. * `permissions_to_launch` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `product_codes` - The product code associated with the OMI (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). * `root_device_name` - The name of the root device. * `root_device_type` - The type of root device used by the OMI (always `bsu`). * `state` - The state of the OMI (`pending` \| `available` \| `failed`). * `state_comment` - Information about the change of state. - * `state_code` - The code of the change of state. - * `state_message` - A message explaining the change of state. + * `state_code` - The code of the change of state. + * `state_message` - A message explaining the change of state. * `tags` - One or more tags associated with the OMI. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/internet_service.html.markdown b/website/docs/d/internet_service.html.markdown index 3e21e6be4..8419eaa5a 100644 --- a/website/docs/d/internet_service.html.markdown +++ b/website/docs/d/internet_service.html.markdown @@ -45,5 +45,5 @@ The following attributes are exported: * `net_id` - The ID of the Net attached to the Internet service. * `state` - The state of the attachment of the Net to the Internet service (always `available`). * `tags` - One or more tags associated with the Internet service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/internet_services.html.markdown b/website/docs/d/internet_services.html.markdown index 65a99d0df..8b764656b 100644 --- a/website/docs/d/internet_services.html.markdown +++ b/website/docs/d/internet_services.html.markdown @@ -45,5 +45,5 @@ The following attributes are exported: * `net_id` - The ID of the Net attached to the Internet service. * `state` - The state of the attachment of the Net to the Internet service (always `available`). * `tags` - One or more tags associated with the Internet service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/load_balancers.html.markdown b/website/docs/d/load_balancers.html.markdown index 0e658a3f3..6f644cc4e 100644 --- a/website/docs/d/load_balancers.html.markdown +++ b/website/docs/d/load_balancers.html.markdown @@ -36,33 +36,33 @@ The following attributes are exported: * `load_balancers` - Information about one or more load balancers. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. - * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. - * `cookie_name` - The name of the application cookie used for stickiness. - * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. * `dns_name` - The DNS name of the load balancer. * `health_check` - Information about the health check configuration. - * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). - * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - * `path` - The path for HTTP or HTTPS requests. - * `port` - The port number (between `1` and `65535`, both included). - * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). * `listeners` - The listeners for the load balancer. - * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). - * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). - * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. - * `server_certificate_id` - The ID of the server certificate. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. * `load_balancer_name` - The name of the load balancer. * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. - * `policy_name` - The name of the stickiness policy. + * `policy_name` - The name of the stickiness policy. * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. @@ -70,11 +70,11 @@ If `LoadBalancerType` is `internal`, the load balancer has a public DNS name tha * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. - * `security_group_account_id` - The account ID of the owner of the security group. - * `security_group_name` - The name of the security group. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. * `subnets` - The IDs of the Subnets for the load balancer. * `subregion_names` - One or more names of Subregions for the load balancer. * `tags` - One or more tags associated with the load balancer. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/nat_service.html.markdown b/website/docs/d/nat_service.html.markdown index 4cae0308e..e95b774e4 100644 --- a/website/docs/d/nat_service.html.markdown +++ b/website/docs/d/nat_service.html.markdown @@ -47,10 +47,10 @@ The following attributes are exported: * `nat_service_id` - The ID of the NAT service. * `net_id` - The ID of the Net in which the NAT service is. * `public_ips` - Information about the External IP address or addresses (EIPs) associated with the NAT service. - * `public_ip` - The External IP address (EIP) associated with the NAT service. - * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. + * `public_ip` - The External IP address (EIP) associated with the NAT service. + * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `state` - The state of the NAT service (`pending` \| `available` \| `deleting` \| `deleted`). * `subnet_id` - The ID of the Subnet in which the NAT service is. * `tags` - One or more tags associated with the NAT service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/nat_services.html.markdown b/website/docs/d/nat_services.html.markdown index 4bc4f57bf..25b2f51c5 100644 --- a/website/docs/d/nat_services.html.markdown +++ b/website/docs/d/nat_services.html.markdown @@ -47,10 +47,10 @@ The following attributes are exported: * `nat_service_id` - The ID of the NAT service. * `net_id` - The ID of the Net in which the NAT service is. * `public_ips` - Information about the External IP address or addresses (EIPs) associated with the NAT service. - * `public_ip` - The External IP address (EIP) associated with the NAT service. - * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. + * `public_ip` - The External IP address (EIP) associated with the NAT service. + * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `state` - The state of the NAT service (`pending` \| `available` \| `deleting` \| `deleted`). * `subnet_id` - The ID of the Subnet in which the NAT service is. * `tags` - One or more tags associated with the NAT service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/net.html.markdown b/website/docs/d/net.html.markdown index dfe5328ec..496c42ed3 100644 --- a/website/docs/d/net.html.markdown +++ b/website/docs/d/net.html.markdown @@ -49,6 +49,6 @@ The following attributes are exported: * `net_id` - The ID of the Net. * `state` - The state of the Net (`pending` \| `available`). * `tags` - One or more tags associated with the Net. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `tenancy` - The VM tenancy in a Net. diff --git a/website/docs/d/net_peering.html.markdown b/website/docs/d/net_peering.html.markdown index 42bbb487e..94e9bbdab 100644 --- a/website/docs/d/net_peering.html.markdown +++ b/website/docs/d/net_peering.html.markdown @@ -50,17 +50,17 @@ The following attributes are exported: * `net_peerings` - Information about one or more Net peering connections. * `accepter_net` - Information about the accepter Net. - * `account_id` - The account ID of the owner of the accepter Net. - * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the accepter Net. + * `account_id` - The account ID of the owner of the accepter Net. + * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the accepter Net. * `net_peering_id` - The ID of the Net peering connection. * `source_net` - Information about the source Net. - * `account_id` - The account ID of the owner of the source Net. - * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the source Net. + * `account_id` - The account ID of the owner of the source Net. + * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the source Net. * `state` - Information about the state of the Net peering connection. - * `message` - Additional information about the state of the Net peering connection. - * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). + * `message` - Additional information about the state of the Net peering connection. + * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). * `tags` - One or more tags associated with the Net peering connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/net_peerings.html.markdown b/website/docs/d/net_peerings.html.markdown index d9785c347..0cd1951f5 100644 --- a/website/docs/d/net_peerings.html.markdown +++ b/website/docs/d/net_peerings.html.markdown @@ -50,17 +50,17 @@ The following attributes are exported: * `net_peerings` - Information about one or more Net peering connections. * `accepter_net` - Information about the accepter Net. - * `account_id` - The account ID of the owner of the accepter Net. - * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the accepter Net. + * `account_id` - The account ID of the owner of the accepter Net. + * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the accepter Net. * `net_peering_id` - The ID of the Net peering connection. * `source_net` - Information about the source Net. - * `account_id` - The account ID of the owner of the source Net. - * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the source Net. + * `account_id` - The account ID of the owner of the source Net. + * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the source Net. * `state` - Information about the state of the Net peering connection. - * `message` - Additional information about the state of the Net peering connection. - * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). + * `message` - Additional information about the state of the Net peering connection. + * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). * `tags` - One or more tags associated with the Net peering connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/nets.html.markdown b/website/docs/d/nets.html.markdown index acf9baed1..36cb1187a 100644 --- a/website/docs/d/nets.html.markdown +++ b/website/docs/d/nets.html.markdown @@ -49,6 +49,6 @@ The following attributes are exported: * `net_id` - The ID of the Net. * `state` - The state of the Net (`pending` \| `available`). * `tags` - One or more tags associated with the Net. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `tenancy` - The VM tenancy in a Net. diff --git a/website/docs/d/nic.html.markdown b/website/docs/d/nic.html.markdown index 6a6c3e5b3..282f29f6e 100644 --- a/website/docs/d/nic.html.markdown +++ b/website/docs/d/nic.html.markdown @@ -46,38 +46,38 @@ The following attributes are exported: * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. * `link_nic` - Information about the NIC attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of the VM. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of the VM. * `link_public_ip` - Information about the EIP association. - * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `public_ip_id` - The allocation ID of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. - * `link_public_ip` - Information about the EIP association. * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. * `public_dns_name` - The name of the public DNS. * `public_ip` - The External IP address (EIP) associated with the NIC. * `public_ip_account_id` - The account ID of the owner of the EIP. * `public_ip_id` - The allocation ID of the EIP. - * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address of the NIC. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. + * `private_dns_name` - The name of the private DNS. + * `private_ips` - The private IP addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP association. + * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_ip_id` - The allocation ID of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. * `tags` - One or more tags associated with the NIC. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/nics.html.markdown b/website/docs/d/nics.html.markdown index 8ea2dcbfa..27f651f8d 100644 --- a/website/docs/d/nics.html.markdown +++ b/website/docs/d/nics.html.markdown @@ -46,38 +46,38 @@ The following attributes are exported: * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. * `link_nic` - Information about the NIC attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of the VM. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of the VM. * `link_public_ip` - Information about the EIP association. - * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `public_ip_id` - The allocation ID of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. - * `link_public_ip` - Information about the EIP association. * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. * `public_dns_name` - The name of the public DNS. * `public_ip` - The External IP address (EIP) associated with the NIC. * `public_ip_account_id` - The account ID of the owner of the EIP. * `public_ip_id` - The allocation ID of the EIP. - * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address of the NIC. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. + * `private_dns_name` - The name of the private DNS. + * `private_ips` - The private IP addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP association. + * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_ip_id` - The allocation ID of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. * `tags` - One or more tags associated with the NIC. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/public_ip.html.markdown b/website/docs/d/public_ip.html.markdown index 8ee83b69d..8d4c3f6c0 100644 --- a/website/docs/d/public_ip.html.markdown +++ b/website/docs/d/public_ip.html.markdown @@ -55,6 +55,6 @@ The following attributes are exported: * `public_ip` - The External IP address (EIP) associated with the NAT service. * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `tags` - One or more tags associated with the EIP. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `vm_id` - The ID of the VM the External IP (EIP) is associated with (if any). diff --git a/website/docs/d/public_ips.html.markdown b/website/docs/d/public_ips.html.markdown index eaa912254..0b2bfffe3 100644 --- a/website/docs/d/public_ips.html.markdown +++ b/website/docs/d/public_ips.html.markdown @@ -55,6 +55,6 @@ The following attributes are exported: * `public_ip` - The External IP address (EIP) associated with the NAT service. * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `tags` - One or more tags associated with the EIP. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `vm_id` - The ID of the VM the External IP (EIP) is associated with (if any). diff --git a/website/docs/d/route_table.html.markdown b/website/docs/d/route_table.html.markdown index 6780f9671..f01afa11d 100644 --- a/website/docs/d/route_table.html.markdown +++ b/website/docs/d/route_table.html.markdown @@ -52,26 +52,26 @@ The following attributes are exported: * `route_tables` - Information about one or more route tables. * `link_route_tables` - One or more associations between the route table and Subnets. - * `link_route_table_id` - The ID of the association between the route table and the Subnet. - * `main` - If `true`, the route table is the main one. - * `route_table_id` - The ID of the route table. - * `subnet_id` - The ID of the Subnet. + * `link_route_table_id` - The ID of the association between the route table and the Subnet. + * `main` - If `true`, the route table is the main one. + * `route_table_id` - The ID of the route table. + * `subnet_id` - The ID of the Subnet. * `net_id` - The ID of the Net for the route table. * `route_propagating_virtual_gateways` - Information about virtual gateways propagating routes. - * `virtual_gateway_id` - The ID of the virtual gateway. + * `virtual_gateway_id` - The ID of the virtual gateway. * `route_table_id` - The ID of the route table. * `routes` - One or more routes in the route table. - * `creation_method` - The method used to create the route. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `destination_service_id` - The ID of the 3DS OUTSCALE service. - * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. - * `nat_service_id` - The ID of a NAT service attached to the Net. - * `net_access_point_id` - The ID of the Net access point. - * `net_peering_id` - The ID of the Net peering connection. - * `nic_id` - The ID of the NIC. - * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of a VM specified in a route in the table. + * `creation_method` - The method used to create the route. + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `destination_service_id` - The ID of the 3DS OUTSCALE service. + * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. + * `nat_service_id` - The ID of a NAT service attached to the Net. + * `net_access_point_id` - The ID of the Net access point. + * `net_peering_id` - The ID of the Net peering connection. + * `nic_id` - The ID of the NIC. + * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of a VM specified in a route in the table. * `tags` - One or more tags associated with the route table. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/route_tables.html.markdown b/website/docs/d/route_tables.html.markdown index 1677dcb90..1fff4e3f4 100644 --- a/website/docs/d/route_tables.html.markdown +++ b/website/docs/d/route_tables.html.markdown @@ -52,26 +52,26 @@ The following attributes are exported: * `route_tables` - Information about one or more route tables. * `link_route_tables` - One or more associations between the route table and Subnets. - * `link_route_table_id` - The ID of the association between the route table and the Subnet. - * `main` - If `true`, the route table is the main one. - * `route_table_id` - The ID of the route table. - * `subnet_id` - The ID of the Subnet. + * `link_route_table_id` - The ID of the association between the route table and the Subnet. + * `main` - If `true`, the route table is the main one. + * `route_table_id` - The ID of the route table. + * `subnet_id` - The ID of the Subnet. * `net_id` - The ID of the Net for the route table. * `route_propagating_virtual_gateways` - Information about virtual gateways propagating routes. - * `virtual_gateway_id` - The ID of the virtual gateway. + * `virtual_gateway_id` - The ID of the virtual gateway. * `route_table_id` - The ID of the route table. * `routes` - One or more routes in the route table. - * `creation_method` - The method used to create the route. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `destination_service_id` - The ID of the 3DS OUTSCALE service. - * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. - * `nat_service_id` - The ID of a NAT service attached to the Net. - * `net_access_point_id` - The ID of the Net access point. - * `net_peering_id` - The ID of the Net peering connection. - * `nic_id` - The ID of the NIC. - * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of a VM specified in a route in the table. + * `creation_method` - The method used to create the route. + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `destination_service_id` - The ID of the 3DS OUTSCALE service. + * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. + * `nat_service_id` - The ID of a NAT service attached to the Net. + * `net_access_point_id` - The ID of the Net access point. + * `net_peering_id` - The ID of the Net peering connection. + * `nic_id` - The ID of the NIC. + * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of a VM specified in a route in the table. * `tags` - One or more tags associated with the route table. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/security_group.html.markdown b/website/docs/d/security_group.html.markdown index 92689a764..813049c08 100644 --- a/website/docs/d/security_group.html.markdown +++ b/website/docs/d/security_group.html.markdown @@ -46,28 +46,28 @@ The following attributes are exported: * `account_id` - The account ID of a user that has been granted permission. * `description` - The description of the security group. * `inbound_rules` - The inbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. * `outbound_rules` - The outbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/security_groups.html.markdown b/website/docs/d/security_groups.html.markdown index f9d60b4d4..44f47292b 100644 --- a/website/docs/d/security_groups.html.markdown +++ b/website/docs/d/security_groups.html.markdown @@ -46,28 +46,28 @@ The following attributes are exported: * `account_id` - The account ID of a user that has been granted permission. * `description` - The description of the security group. * `inbound_rules` - The inbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. * `outbound_rules` - The outbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/snapshot.html.markdown b/website/docs/d/snapshot.html.markdown index cd8efb7cd..acaff57c1 100644 --- a/website/docs/d/snapshot.html.markdown +++ b/website/docs/d/snapshot.html.markdown @@ -54,13 +54,13 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the snapshot. * `description` - The description of the snapshot. * `permissions_to_create_volume` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `progress` - The progress of the snapshot, as a percentage. * `snapshot_id` - The ID of the snapshot. * `state` - The state of the snapshot (`in-queue` \| `completed` \| `error`). * `tags` - One or more tags associated with the snapshot. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume used to create the snapshot. * `volume_size` - The size of the volume used to create the snapshot, in gibibytes (GiB). diff --git a/website/docs/d/snapshots.html.markdown b/website/docs/d/snapshots.html.markdown index 7a38ae09a..77fb07abb 100644 --- a/website/docs/d/snapshots.html.markdown +++ b/website/docs/d/snapshots.html.markdown @@ -54,13 +54,13 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the snapshot. * `description` - The description of the snapshot. * `permissions_to_create_volume` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `progress` - The progress of the snapshot, as a percentage. * `snapshot_id` - The ID of the snapshot. * `state` - The state of the snapshot (`in-queue` \| `completed` \| `error`). * `tags` - One or more tags associated with the snapshot. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume used to create the snapshot. * `volume_size` - The size of the volume used to create the snapshot, in gibibytes (GiB). diff --git a/website/docs/d/subnet.html.markdown b/website/docs/d/subnet.html.markdown index c1419ebc7..55cce1a1e 100644 --- a/website/docs/d/subnet.html.markdown +++ b/website/docs/d/subnet.html.markdown @@ -51,5 +51,5 @@ The following attributes are exported: * `subnet_id` - The ID of the Subnet. * `subregion_name` - The name of the Subregion in which the Subnet is located. * `tags` - One or more tags associated with the Subnet. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/subnets.html.markdown b/website/docs/d/subnets.html.markdown index 8a21e536a..8f7e29ae9 100644 --- a/website/docs/d/subnets.html.markdown +++ b/website/docs/d/subnets.html.markdown @@ -51,5 +51,5 @@ The following attributes are exported: * `subnet_id` - The ID of the Subnet. * `subregion_name` - The name of the Subregion in which the Subnet is located. * `tags` - One or more tags associated with the Subnet. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/d/virtual_gateways.html.markdown b/website/docs/d/virtual_gateways.html.markdown index 285a4066e..b4cb654c5 100644 --- a/website/docs/d/virtual_gateways.html.markdown +++ b/website/docs/d/virtual_gateways.html.markdown @@ -44,11 +44,11 @@ The following attributes are exported: * `virtual_gateways` - Information about one or more virtual gateways. * `connection_type` - The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). * `net_to_virtual_gateway_links` - The Net to which the virtual gateway is attached. - * `net_id` - The ID of the Net to which the virtual gateway is attached. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). + * `net_id` - The ID of the Net to which the virtual gateway is attached. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). * `state` - The state of the virtual gateway (`pending` \| `available` \| `deleting` \| `deleted`). * `tags` - One or more tags associated with the virtual gateway. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `virtual_gateway_id` - The ID of the virtual gateway. diff --git a/website/docs/d/vm.html.markdown b/website/docs/d/vm.html.markdown index e2f0e51b0..0f2a68a7d 100644 --- a/website/docs/d/vm.html.markdown +++ b/website/docs/d/vm.html.markdown @@ -43,12 +43,12 @@ The following attributes are exported: * `vms` - Information about one or more VMs. * `architecture` - The architecture of the VM (`i386` \| `x86_64`). * `block_device_mappings_created` - The block device mapping of the VM. - * `bsu` - Information about the created BSU volume. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `link_date` - The time and date of attachment of the volume to the VM. - * `state` - The state of the volume. - * `volume_id` - The ID of the volume. - * `device_name` - The name of the device. + * `bsu` - Information about the created BSU volume. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `link_date` - The time and date of attachment of the volume to the VM. + * `state` - The state of the volume. + * `volume_id` - The ID of the volume. + * `device_name` - The name of the device. * `bsu_optimized` - If `true`, the VM is optimized for BSU I/O. * `client_token` - The idempotency token provided when launching the VM. * `deletion_protection` - If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. @@ -59,40 +59,40 @@ The following attributes are exported: * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. - * `account_id` - The account ID of the owner of the NIC. - * `description` - The description of the NIC. - * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - * `link_nic` - Information about the network interface card (NIC). - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP address or addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `account_id` - The account ID of the owner of the NIC. + * `description` - The description of the NIC. + * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + * `link_nic` - Information about the network interface card (NIC). + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address. - * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). - * `subnet_id` - The ID of the Subnet for the NIC. + * `private_ips` - The private IP address or addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP associated with the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address. + * `security_groups` - One or more IDs of security groups for the NIC. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). + * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. - * `subregion_name` - The name of the Subregion. - * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). + * `subregion_name` - The name of the Subregion. + * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). * `private_dns_name` - The name of the private DNS. * `private_ip` - The primary private IP address of the VM. * `product_codes` - The product code associated with the OMI used to create the VM (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). @@ -102,14 +102,14 @@ The following attributes are exported: * `root_device_name` - The name of the root device for the VM (for example, /dev/vda1). * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. * `tags` - One or more tags associated with the VM. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `user_data` - The Base64-encoded MIME user data. * `vm_id` - The ID of the VM. * `vm_initiated_shutdown_behavior` - The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. diff --git a/website/docs/d/vm_state.html.markdown b/website/docs/d/vm_state.html.markdown index 96bc25d8b..e72611cec 100644 --- a/website/docs/d/vm_state.html.markdown +++ b/website/docs/d/vm_state.html.markdown @@ -42,10 +42,10 @@ The following attributes are exported: * `vm_states` - Information about one or more VM states. * `maintenance_events` - One or more scheduled events associated with the VM. - * `code` - The code of the event (`system-reboot` \| `system-maintenance`). - * `description` - The description of the event. - * `not_after` - The latest scheduled end time for the event. - * `not_before` - The earliest scheduled start time for the event. + * `code` - The code of the event (`system-reboot` \| `system-maintenance`). + * `description` - The description of the event. + * `not_after` - The latest scheduled end time for the event. + * `not_before` - The earliest scheduled start time for the event. * `subregion_name` - The name of the Subregion of the VM. * `vm_id` - The ID of the VM. * `vm_state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). diff --git a/website/docs/d/vm_states.html.markdown b/website/docs/d/vm_states.html.markdown index 900ddb338..4d20ad49f 100644 --- a/website/docs/d/vm_states.html.markdown +++ b/website/docs/d/vm_states.html.markdown @@ -42,10 +42,10 @@ The following attributes are exported: * `vm_states` - Information about one or more VM states. * `maintenance_events` - One or more scheduled events associated with the VM. - * `code` - The code of the event (`system-reboot` \| `system-maintenance`). - * `description` - The description of the event. - * `not_after` - The latest scheduled end time for the event. - * `not_before` - The earliest scheduled start time for the event. + * `code` - The code of the event (`system-reboot` \| `system-maintenance`). + * `description` - The description of the event. + * `not_after` - The latest scheduled end time for the event. + * `not_before` - The earliest scheduled start time for the event. * `subregion_name` - The name of the Subregion of the VM. * `vm_id` - The ID of the VM. * `vm_state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). diff --git a/website/docs/d/vms.html.markdown b/website/docs/d/vms.html.markdown index 1bcffebec..6af8efa1a 100644 --- a/website/docs/d/vms.html.markdown +++ b/website/docs/d/vms.html.markdown @@ -43,12 +43,12 @@ The following attributes are exported: * `vms` - Information about one or more VMs. * `architecture` - The architecture of the VM (`i386` \| `x86_64`). * `block_device_mappings_created` - The block device mapping of the VM. - * `bsu` - Information about the created BSU volume. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `link_date` - The time and date of attachment of the volume to the VM. - * `state` - The state of the volume. - * `volume_id` - The ID of the volume. - * `device_name` - The name of the device. + * `bsu` - Information about the created BSU volume. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `link_date` - The time and date of attachment of the volume to the VM. + * `state` - The state of the volume. + * `volume_id` - The ID of the volume. + * `device_name` - The name of the device. * `bsu_optimized` - If `true`, the VM is optimized for BSU I/O. * `client_token` - The idempotency token provided when launching the VM. * `deletion_protection` - If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. @@ -59,40 +59,40 @@ The following attributes are exported: * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. - * `account_id` - The account ID of the owner of the NIC. - * `description` - The description of the NIC. - * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - * `link_nic` - Information about the network interface card (NIC). - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP address or addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `account_id` - The account ID of the owner of the NIC. + * `description` - The description of the NIC. + * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + * `link_nic` - Information about the network interface card (NIC). + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address. - * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). - * `subnet_id` - The ID of the Subnet for the NIC. + * `private_ips` - The private IP address or addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP associated with the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address. + * `security_groups` - One or more IDs of security groups for the NIC. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). + * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. - * `subregion_name` - The name of the Subregion. - * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). + * `subregion_name` - The name of the Subregion. + * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). * `private_dns_name` - The name of the private DNS. * `private_ip` - The primary private IP address of the VM. * `product_codes` - The product code associated with the OMI used to create the VM (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). @@ -102,14 +102,14 @@ The following attributes are exported: * `root_device_name` - The name of the root device for the VM (for example, /dev/vda1). * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. * `tags` - One or more tags associated with the VM. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `user_data` - The Base64-encoded MIME user data. * `vm_id` - The ID of the VM. * `vm_initiated_shutdown_behavior` - The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. diff --git a/website/docs/d/volume.html.markdown b/website/docs/d/volume.html.markdown index 472e30638..8690c0bd4 100644 --- a/website/docs/d/volume.html.markdown +++ b/website/docs/d/volume.html.markdown @@ -56,17 +56,17 @@ The following attributes are exported: For `io1` volumes, the number of provisioned IOPS. For `gp2` volumes, the baseline performance of the volume. * `linked_volumes` - Information about your volume attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_name` - The name of the device. - * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). - * `vm_id` - The ID of the VM. - * `volume_id` - The ID of the volume. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_name` - The name of the device. + * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). + * `vm_id` - The ID of the VM. + * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume. * `volume_type` - The type of the volume (`standard` \| `gp2` \| `io1`). diff --git a/website/docs/d/volumes.html.markdown b/website/docs/d/volumes.html.markdown index e34397c3f..b79fc85cf 100644 --- a/website/docs/d/volumes.html.markdown +++ b/website/docs/d/volumes.html.markdown @@ -56,17 +56,17 @@ The following attributes are exported: For `io1` volumes, the number of provisioned IOPS. For `gp2` volumes, the baseline performance of the volume. * `linked_volumes` - Information about your volume attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_name` - The name of the device. - * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). - * `vm_id` - The ID of the VM. - * `volume_id` - The ID of the volume. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_name` - The name of the device. + * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). + * `vm_id` - The ID of the VM. + * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume. * `volume_type` - The type of the volume (`standard` \| `gp2` \| `io1`). diff --git a/website/docs/d/vpn_connections.html.markdown b/website/docs/d/vpn_connections.html.markdown index cd96d761e..aeced4a91 100644 --- a/website/docs/d/vpn_connections.html.markdown +++ b/website/docs/d/vpn_connections.html.markdown @@ -46,14 +46,14 @@ The following attributes are exported: * `client_gateway_id` - The ID of the client gateway used on the client end of the connection. * `connection_type` - The type of VPN connection (always `ipsec.1`). * `routes` - Information about one or more static routes associated with the VPN connection, if any. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `route_type` - The type of route (always `static`). - * `state` - The current state of the static route (`pending` \| `available` \| `deleting` \| `deleted`). + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `route_type` - The type of route (always `static`). + * `state` - The current state of the static route (`pending` \| `available` \| `deleting` \| `deleted`). * `state` - The state of the VPN connection (`pending` \| `available` \| `deleting` \| `deleted`). * `static_routes_only` - If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](https://docs.outscale.com/api#createvpnconnectionroute) and [DeleteVpnConnectionRoute](https://docs.outscale.com/api#deletevpnconnectionroute). * `tags` - One or more tags associated with the VPN connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `virtual_gateway_id` - The ID of the virtual gateway used on the 3DS OUTSCALE end of the connection. * `vpn_connection_id` - The ID of the VPN connection. diff --git a/website/docs/r/client_gateway.html.markdown b/website/docs/r/client_gateway.html.markdown index e185edcb9..24a0da533 100644 --- a/website/docs/r/client_gateway.html.markdown +++ b/website/docs/r/client_gateway.html.markdown @@ -48,8 +48,8 @@ The following attributes are exported: * `public_ip` - The public IPv4 address of the client gateway (must be a fixed address into a NATed network). * `state` - The state of the client gateway (`pending` \| `available` \| `deleting` \| `deleted`). * `tags` - One or more tags associated with the client gateway. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/dhcp_option.html.markdown b/website/docs/r/dhcp_option.html.markdown index 0eab23ad4..e2c2c2931 100644 --- a/website/docs/r/dhcp_option.html.markdown +++ b/website/docs/r/dhcp_option.html.markdown @@ -57,8 +57,8 @@ The following attributes are exported: * `domain_name_servers` - One or more IP addresses for the domain name servers. * `ntp_servers` - One or more IP addresses for the NTP servers. * `tags` - One or more tags associated with the DHCP options set. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/image.html.markdown b/website/docs/r/image.html.markdown index a8760cdd3..353ee2184 100644 --- a/website/docs/r/image.html.markdown +++ b/website/docs/r/image.html.markdown @@ -52,13 +52,13 @@ The following arguments are supported: * `architecture` - (Optional) The architecture of the OMI (by default, `i386`). * `block_device_mappings` - (Optional) One or more block device mappings. * `bsu` - Information about the BSU volume to create. - * `delete_on_vm_deletion` - (Optional) Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `iops` - (Optional) The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - * `snapshot_id` - (Optional) The ID of the snapshot used to create the volume. - * `volume_size` - (Optional) The size of the volume, in gibibytes (GiB).
+ * `delete_on_vm_deletion` - (Optional) Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `iops` - (Optional) The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + * `snapshot_id` - (Optional) The ID of the snapshot used to create the volume. + * `volume_size` - (Optional) The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - * `volume_type` - (Optional) The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
+ * `volume_type` - (Optional) The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). * `device_name` - (Optional) The name of the device. * `virtual_device_name` - (Optional) The name of the virtual device (ephemeralN). @@ -72,8 +72,8 @@ Constraints: 3-128 alphanumeric characters, underscores (_), spaces ( ), parenth * `source_region_name` - (Optional) The name of the source Region, which must be the same as the Region of your account. * `vm_id` - (Optional) The ID of the VM from which you want to create the OMI. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -84,17 +84,17 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the OMI. * `architecture` - The architecture of the OMI (by default, `i386`). * `block_device_mappings` - One or more block device mappings. - * `bsu` - Information about the BSU volume to create. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - * `snapshot_id` - The ID of the snapshot used to create the volume. - * `volume_size` - The size of the volume, in gibibytes (GiB).
+ * `bsu` - Information about the BSU volume to create. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `iops` - The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + * `snapshot_id` - The ID of the snapshot used to create the volume. + * `volume_size` - The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
+ * `volume_type` - The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). - * `device_name` - The name of the device. - * `virtual_device_name` - The name of the virtual device (ephemeralN). + * `device_name` - The name of the device. + * `virtual_device_name` - The name of the virtual device (ephemeralN). * `creation_date` - The date and time at which the OMI was created. * `description` - The description of the OMI. * `file_location` - The location where the OMI file is stored on Object Storage Unit (OSU). @@ -102,18 +102,18 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `image_name` - The name of the OMI. * `image_type` - The type of the OMI. * `permissions_to_launch` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `product_codes` - The product code associated with the OMI (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). * `root_device_name` - The name of the root device. * `root_device_type` - The type of root device used by the OMI (always `bsu`). * `state` - The state of the OMI (`pending` \| `available` \| `failed`). * `state_comment` - Information about the change of state. - * `state_code` - The code of the change of state. - * `state_message` - A message explaining the change of state. + * `state_code` - The code of the change of state. + * `state_message` - A message explaining the change of state. * `tags` - One or more tags associated with the OMI. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/internet_service.html.markdown b/website/docs/r/internet_service.html.markdown index a8cc5f331..2d6af2b97 100644 --- a/website/docs/r/internet_service.html.markdown +++ b/website/docs/r/internet_service.html.markdown @@ -27,8 +27,8 @@ resource "outscale_internet_service" "internet_service01" { The following arguments are supported: * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -39,8 +39,8 @@ The following attributes are exported: * `net_id` - The ID of the Net attached to the Internet service. * `state` - The state of the attachment of the Net to the Internet service (always `available`). * `tags` - One or more tags associated with the Internet service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/load_balancer_policy.html.markdown b/website/docs/r/load_balancer_policy.html.markdown index b92a8b3fd..eac0fedd4 100644 --- a/website/docs/r/load_balancer_policy.html.markdown +++ b/website/docs/r/load_balancer_policy.html.markdown @@ -71,33 +71,33 @@ The following attributes are exported: * `load_balancer` - Information about the load balancer. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. - * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. - * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. - * `cookie_name` - The name of the application cookie used for stickiness. - * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. * `dns_name` - The DNS name of the load balancer. * `health_check` - Information about the health check configuration. - * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). - * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - * `path` - The path for HTTP or HTTPS requests. - * `port` - The port number (between `1` and `65535`, both included). - * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). * `listeners` - The listeners for the load balancer. - * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). - * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). - * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. - * `server_certificate_id` - The ID of the server certificate. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. * `load_balancer_name` - The name of the load balancer. * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. - * `policy_name` - The name of the stickiness policy. + * `policy_name` - The name of the stickiness policy. * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. @@ -105,11 +105,11 @@ If `LoadBalancerType` is `internal`, the load balancer has a public DNS name tha * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. - * `security_group_account_id` - The account ID of the owner of the security group. - * `security_group_name` - The name of the security group. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. * `subnets` - The IDs of the Subnets for the load balancer. * `subregion_names` - One or more names of Subregions for the load balancer. * `tags` - One or more tags associated with the load balancer. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/r/nat_service.html.markdown b/website/docs/r/nat_service.html.markdown index 460fee035..ec58bf187 100644 --- a/website/docs/r/nat_service.html.markdown +++ b/website/docs/r/nat_service.html.markdown @@ -43,8 +43,8 @@ The following arguments are supported: * `public_ip_id` - (Required) The allocation ID of the EIP to associate with the NAT service. If the EIP is already associated with another resource, you must first disassociate it. * `subnet_id` - (Required) The ID of the Subnet in which you want to create the NAT service. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -54,13 +54,13 @@ The following attributes are exported: * `nat_service_id` - The ID of the NAT service. * `net_id` - The ID of the Net in which the NAT service is. * `public_ips` - Information about the External IP address or addresses (EIPs) associated with the NAT service. - * `public_ip` - The External IP address (EIP) associated with the NAT service. - * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. + * `public_ip` - The External IP address (EIP) associated with the NAT service. + * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `state` - The state of the NAT service (`pending` \| `available` \| `deleting` \| `deleted`). * `subnet_id` - The ID of the Subnet in which the NAT service is. * `tags` - One or more tags associated with the NAT service. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/net.html.markdown b/website/docs/r/net.html.markdown index d0d15e8fd..0de28329b 100644 --- a/website/docs/r/net.html.markdown +++ b/website/docs/r/net.html.markdown @@ -75,8 +75,8 @@ The following arguments are supported: * `ip_range` - (Required) The IP range for the Net, in CIDR notation (for example, 10.0.0.0/16). * `tenancy` - (Optional) The tenancy options for the VMs (`default` if a VM created in a Net can be launched with any tenancy, `dedicated` if it can be launched with dedicated tenancy VMs running on single-tenant hardware). * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -88,8 +88,8 @@ The following attributes are exported: * `net_id` - The ID of the Net. * `state` - The state of the Net (`pending` \| `available`). * `tags` - One or more tags associated with the Net. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `tenancy` - The VM tenancy in a Net. ## Import diff --git a/website/docs/r/net_peering.html.markdown b/website/docs/r/net_peering.html.markdown index 328d6c3d5..051bff8fa 100644 --- a/website/docs/r/net_peering.html.markdown +++ b/website/docs/r/net_peering.html.markdown @@ -39,8 +39,8 @@ The following arguments are supported: * `accepter_net_id` - (Required) The ID of the Net you want to connect with. * `source_net_id` - (Required) The ID of the Net you send the peering request from. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -48,20 +48,20 @@ The following attributes are exported: * `net_peering` - Information about the Net peering connection. * `accepter_net` - Information about the accepter Net. - * `account_id` - The account ID of the owner of the accepter Net. - * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the accepter Net. + * `account_id` - The account ID of the owner of the accepter Net. + * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the accepter Net. * `net_peering_id` - The ID of the Net peering connection. * `source_net` - Information about the source Net. - * `account_id` - The account ID of the owner of the source Net. - * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the source Net. + * `account_id` - The account ID of the owner of the source Net. + * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the source Net. * `state` - Information about the state of the Net peering connection. - * `message` - Additional information about the state of the Net peering connection. - * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). + * `message` - Additional information about the state of the Net peering connection. + * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). * `tags` - One or more tags associated with the Net peering connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/net_peering_acceptation.html.markdown b/website/docs/r/net_peering_acceptation.html.markdown index 30b885db8..7bf068078 100644 --- a/website/docs/r/net_peering_acceptation.html.markdown +++ b/website/docs/r/net_peering_acceptation.html.markdown @@ -35,17 +35,17 @@ The following attributes are exported: * `net_peering` - Information about the Net peering connection. * `accepter_net` - Information about the accepter Net. - * `account_id` - The account ID of the owner of the accepter Net. - * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the accepter Net. + * `account_id` - The account ID of the owner of the accepter Net. + * `ip_range` - The IP range for the accepter Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the accepter Net. * `net_peering_id` - The ID of the Net peering connection. * `source_net` - Information about the source Net. - * `account_id` - The account ID of the owner of the source Net. - * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). - * `net_id` - The ID of the source Net. + * `account_id` - The account ID of the owner of the source Net. + * `ip_range` - The IP range for the source Net, in CIDR notation (for example, 10.0.0.0/16). + * `net_id` - The ID of the source Net. * `state` - Information about the state of the Net peering connection. - * `message` - Additional information about the state of the Net peering connection. - * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). + * `message` - Additional information about the state of the Net peering connection. + * `name` - The state of the Net peering connection (`pending-acceptance` \| `active` \| `rejected` \| `failed` \| `expired` \| `deleted`). * `tags` - One or more tags associated with the Net peering connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/r/nic.html.markdown b/website/docs/r/nic.html.markdown index 24dd679b4..c11e9667d 100644 --- a/website/docs/r/nic.html.markdown +++ b/website/docs/r/nic.html.markdown @@ -46,8 +46,8 @@ The following arguments are supported: * `security_group_ids` - (Optional) One or more IDs of security groups for the NIC. * `subnet_id` - (Required) The ID of the Subnet in which you want to create the NIC. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -58,41 +58,41 @@ The following attributes are exported: * `description` - The description of the NIC. * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. * `link_nic` - Information about the NIC attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of the VM. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of the VM. * `link_public_ip` - Information about the EIP association. - * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `public_ip_id` - The allocation ID of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. - * `link_public_ip` - Information about the EIP association. * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. * `public_dns_name` - The name of the public DNS. * `public_ip` - The External IP address (EIP) associated with the NIC. * `public_ip_account_id` - The account ID of the owner of the EIP. * `public_ip_id` - The allocation ID of the EIP. - * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address of the NIC. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. + * `private_dns_name` - The name of the private DNS. + * `private_ips` - The private IP addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP association. + * `link_public_ip_id` - (Required in a Net) The ID representing the association of the EIP with the VM or the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_ip_id` - The allocation ID of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address of the NIC. * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). * `subnet_id` - The ID of the Subnet. * `subregion_name` - The Subregion in which the NIC is located. * `tags` - One or more tags associated with the NIC. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/public_ip.html.markdown b/website/docs/r/public_ip.html.markdown index 26c9edd2d..b981f05c7 100644 --- a/website/docs/r/public_ip.html.markdown +++ b/website/docs/r/public_ip.html.markdown @@ -27,8 +27,8 @@ resource "outscale_public_ip" "public_ip01" { The following arguments are supported: * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -42,8 +42,8 @@ The following attributes are exported: * `public_ip` - The External IP address (EIP) associated with the NAT service. * `public_ip_id` - The allocation ID of the EIP associated with the NAT service. * `tags` - One or more tags associated with the EIP. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `vm_id` - The ID of the VM the External IP (EIP) is associated with (if any). ## Import diff --git a/website/docs/r/route.html.markdown b/website/docs/r/route.html.markdown index 23fe3a85d..876db2093 100644 --- a/website/docs/r/route.html.markdown +++ b/website/docs/r/route.html.markdown @@ -51,29 +51,29 @@ The following attributes are exported: * `route_table` - Information about the route table. * `link_route_tables` - One or more associations between the route table and Subnets. - * `link_route_table_id` - The ID of the association between the route table and the Subnet. - * `main` - If `true`, the route table is the main one. - * `route_table_id` - The ID of the route table. - * `subnet_id` - The ID of the Subnet. + * `link_route_table_id` - The ID of the association between the route table and the Subnet. + * `main` - If `true`, the route table is the main one. + * `route_table_id` - The ID of the route table. + * `subnet_id` - The ID of the Subnet. * `net_id` - The ID of the Net for the route table. * `route_propagating_virtual_gateways` - Information about virtual gateways propagating routes. - * `virtual_gateway_id` - The ID of the virtual gateway. + * `virtual_gateway_id` - The ID of the virtual gateway. * `route_table_id` - The ID of the route table. * `routes` - One or more routes in the route table. - * `creation_method` - The method used to create the route. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `destination_service_id` - The ID of the 3DS OUTSCALE service. - * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. - * `nat_service_id` - The ID of a NAT service attached to the Net. - * `net_access_point_id` - The ID of the Net access point. - * `net_peering_id` - The ID of the Net peering connection. - * `nic_id` - The ID of the NIC. - * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of a VM specified in a route in the table. + * `creation_method` - The method used to create the route. + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `destination_service_id` - The ID of the 3DS OUTSCALE service. + * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. + * `nat_service_id` - The ID of a NAT service attached to the Net. + * `net_access_point_id` - The ID of the Net access point. + * `net_peering_id` - The ID of the Net peering connection. + * `nic_id` - The ID of the NIC. + * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of a VM specified in a route in the table. * `tags` - One or more tags associated with the route table. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/route_table.html.markdown b/website/docs/r/route_table.html.markdown index 4fde97d08..b9ef101b0 100644 --- a/website/docs/r/route_table.html.markdown +++ b/website/docs/r/route_table.html.markdown @@ -33,8 +33,8 @@ The following arguments are supported: * `net_id` - (Required) The ID of the Net for which you want to create a route table. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -42,29 +42,29 @@ The following attributes are exported: * `route_table` - Information about the route table. * `link_route_tables` - One or more associations between the route table and Subnets. - * `link_route_table_id` - The ID of the association between the route table and the Subnet. - * `main` - If `true`, the route table is the main one. - * `route_table_id` - The ID of the route table. - * `subnet_id` - The ID of the Subnet. + * `link_route_table_id` - The ID of the association between the route table and the Subnet. + * `main` - If `true`, the route table is the main one. + * `route_table_id` - The ID of the route table. + * `subnet_id` - The ID of the Subnet. * `net_id` - The ID of the Net for the route table. * `route_propagating_virtual_gateways` - Information about virtual gateways propagating routes. - * `virtual_gateway_id` - The ID of the virtual gateway. + * `virtual_gateway_id` - The ID of the virtual gateway. * `route_table_id` - The ID of the route table. * `routes` - One or more routes in the route table. - * `creation_method` - The method used to create the route. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `destination_service_id` - The ID of the 3DS OUTSCALE service. - * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. - * `nat_service_id` - The ID of a NAT service attached to the Net. - * `net_access_point_id` - The ID of the Net access point. - * `net_peering_id` - The ID of the Net peering connection. - * `nic_id` - The ID of the NIC. - * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of a VM specified in a route in the table. + * `creation_method` - The method used to create the route. + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `destination_service_id` - The ID of the 3DS OUTSCALE service. + * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. + * `nat_service_id` - The ID of a NAT service attached to the Net. + * `net_access_point_id` - The ID of the Net access point. + * `net_peering_id` - The ID of the Net peering connection. + * `nic_id` - The ID of the NIC. + * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of a VM specified in a route in the table. * `tags` - One or more tags associated with the route table. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/security_group.html.markdown b/website/docs/r/security_group.html.markdown index 7bdfffafe..f15af2ef1 100644 --- a/website/docs/r/security_group.html.markdown +++ b/website/docs/r/security_group.html.markdown @@ -39,8 +39,8 @@ The following arguments are supported: This name must not start with `sg-`.
This name must be unique and contain between 1 and 255 ASCII characters. Accented letters are not allowed. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -50,31 +50,31 @@ The following attributes are exported: * `account_id` - The account ID of a user that has been granted permission. * `description` - The description of the security group. * `inbound_rules` - The inbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `net_id` - The ID of the Net for the security group. * `outbound_rules` - The outbound rules associated with the security group. - * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. - * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. - * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). - * `security_groups_members` - Information about one or more members of a security group. - * `account_id` - The account ID of a user. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). - * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. + * `from_port_range` - The beginning of the port range for the TCP and UDP protocols, or an ICMP type number. + * `ip_protocol` - The IP protocol name (`tcp`, `udp`, `icmp`) or protocol number. By default, `-1`, which means all protocols. + * `ip_ranges` - One or more IP ranges for the security group rules, in CIDR notation (for example, 10.0.0.0/16). + * `security_groups_members` - Information about one or more members of a security group. + * `account_id` - The account ID of a user. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `service_ids` - One or more service IDs to allow traffic from a Net to access the corresponding 3DS OUTSCALE services. For more information, see [ReadNetAccessPointServices](https://docs.outscale.com/api#readnetaccesspointservices). + * `to_port_range` - The end of the port range for the TCP and UDP protocols, or an ICMP type number. * `security_group_id` - The ID of the security group. * `security_group_name` - The name of the security group. * `tags` - One or more tags associated with the security group. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/snapshot.html.markdown b/website/docs/r/snapshot.html.markdown index 37d9cff51..d4b43bb61 100644 --- a/website/docs/r/snapshot.html.markdown +++ b/website/docs/r/snapshot.html.markdown @@ -49,8 +49,8 @@ The following arguments are supported: * `source_snapshot_id` - (Optional) The ID of the snapshot you want to copy. * `volume_id` - (Optional) The ID of the volume you want to create a snapshot of. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -61,13 +61,13 @@ The following attributes are exported: * `account_id` - The account ID of the owner of the snapshot. * `description` - The description of the snapshot. * `permissions_to_create_volume` - Information about the users who have permissions for the resource. - * `account_ids` - The account ID of one or more users who have permissions for the resource. - * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. + * `account_ids` - The account ID of one or more users who have permissions for the resource. + * `global_permission` - If `true`, the resource is public. If `false`, the resource is private. * `progress` - The progress of the snapshot, as a percentage. * `snapshot_id` - The ID of the snapshot. * `state` - The state of the snapshot (`in-queue` \| `completed` \| `error`). * `tags` - One or more tags associated with the snapshot. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume used to create the snapshot. * `volume_size` - The size of the volume used to create the snapshot, in gibibytes (GiB). diff --git a/website/docs/r/subnet.html.markdown b/website/docs/r/subnet.html.markdown index 516154425..3e7b79f4f 100644 --- a/website/docs/r/subnet.html.markdown +++ b/website/docs/r/subnet.html.markdown @@ -36,8 +36,8 @@ The following arguments are supported: * `net_id` - (Required) The ID of the Net for which you want to create a Subnet. * `subregion_name` - (Optional) The name of the Subregion in which you want to create the Subnet. * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -52,8 +52,8 @@ The following attributes are exported: * `subnet_id` - The ID of the Subnet. * `subregion_name` - The name of the Subregion in which the Subnet is located. * `tags` - One or more tags associated with the Subnet. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import diff --git a/website/docs/r/virtual_gateway.html.markdown b/website/docs/r/virtual_gateway.html.markdown index 3f6dc1304..a9226838d 100644 --- a/website/docs/r/virtual_gateway.html.markdown +++ b/website/docs/r/virtual_gateway.html.markdown @@ -40,12 +40,12 @@ The following attributes are exported: * `virtual_gateway` - Information about the virtual gateway. * `connection_type` - The type of VPN connection supported by the virtual gateway (only `ipsec.1` is supported). * `net_to_virtual_gateway_links` - The Net to which the virtual gateway is attached. - * `net_id` - The ID of the Net to which the virtual gateway is attached. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). + * `net_id` - The ID of the Net to which the virtual gateway is attached. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). * `state` - The state of the virtual gateway (`pending` \| `available` \| `deleting` \| `deleted`). * `tags` - One or more tags associated with the virtual gateway. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `virtual_gateway_id` - The ID of the virtual gateway. ## Import diff --git a/website/docs/r/virtual_gateway_route_propagation.html.markdown b/website/docs/r/virtual_gateway_route_propagation.html.markdown index 89983fa02..afb902ed8 100644 --- a/website/docs/r/virtual_gateway_route_propagation.html.markdown +++ b/website/docs/r/virtual_gateway_route_propagation.html.markdown @@ -54,27 +54,27 @@ The following attributes are exported: * `route_table` - Information about the route table. * `link_route_tables` - One or more associations between the route table and Subnets. - * `link_route_table_id` - The ID of the association between the route table and the Subnet. - * `main` - If `true`, the route table is the main one. - * `route_table_id` - The ID of the route table. - * `subnet_id` - The ID of the Subnet. + * `link_route_table_id` - The ID of the association between the route table and the Subnet. + * `main` - If `true`, the route table is the main one. + * `route_table_id` - The ID of the route table. + * `subnet_id` - The ID of the Subnet. * `net_id` - The ID of the Net for the route table. * `route_propagating_virtual_gateways` - Information about virtual gateways propagating routes. - * `virtual_gateway_id` - The ID of the virtual gateway. + * `virtual_gateway_id` - The ID of the virtual gateway. * `route_table_id` - The ID of the route table. * `routes` - One or more routes in the route table. - * `creation_method` - The method used to create the route. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `destination_service_id` - The ID of the 3DS OUTSCALE service. - * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. - * `nat_service_id` - The ID of a NAT service attached to the Net. - * `net_access_point_id` - The ID of the Net access point. - * `net_peering_id` - The ID of the Net peering connection. - * `nic_id` - The ID of the NIC. - * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. - * `vm_account_id` - The account ID of the owner of the VM. - * `vm_id` - The ID of a VM specified in a route in the table. + * `creation_method` - The method used to create the route. + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `destination_service_id` - The ID of the 3DS OUTSCALE service. + * `gateway_id` - The ID of the Internet service or virtual gateway attached to the Net. + * `nat_service_id` - The ID of a NAT service attached to the Net. + * `net_access_point_id` - The ID of the Net access point. + * `net_peering_id` - The ID of the Net peering connection. + * `nic_id` - The ID of the NIC. + * `state` - The state of a route in the route table (`active` \| `blackhole`). The `blackhole` state indicates that the target of the route is not available. + * `vm_account_id` - The account ID of the owner of the VM. + * `vm_id` - The ID of a VM specified in a route in the table. * `tags` - One or more tags associated with the route table. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. diff --git a/website/docs/r/vm.html.markdown b/website/docs/r/vm.html.markdown index 46aad045d..3a4e947f7 100644 --- a/website/docs/r/vm.html.markdown +++ b/website/docs/r/vm.html.markdown @@ -156,13 +156,13 @@ The following arguments are supported: * `block_device_mappings` - (Optional) One or more block device mappings. * `bsu` - Information about the BSU volume to create. - * `delete_on_vm_deletion` - (Optional) Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `iops` - (Optional) The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. - * `snapshot_id` - (Optional) The ID of the snapshot used to create the volume. - * `volume_size` - (Optional) The size of the volume, in gibibytes (GiB).
+ * `delete_on_vm_deletion` - (Optional) Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `iops` - (Optional) The number of I/O operations per second (IOPS). This parameter must be specified only if you create an `io1` volume. The maximum number of IOPS allowed for `io1` volumes is `13000`. + * `snapshot_id` - (Optional) The ID of the snapshot used to create the volume. + * `volume_size` - (Optional) The size of the volume, in gibibytes (GiB).
If you specify a snapshot ID, the volume size must be at least equal to the snapshot size.
If you specify a snapshot ID but no volume size, the volume is created with a size similar to the snapshot one. - * `volume_type` - (Optional) The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
+ * `volume_type` - (Optional) The type of the volume (`standard` \| `io1` \| `gp2`). If not specified in the request, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). * `device_name` - (Optional) The name of the device. * `no_device` - (Optional) Removes the device which is included in the block device mapping of the OMI. @@ -181,8 +181,8 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `device_number` - (Optional) The index of the VM device for the NIC attachment (between 0 and 7, both included). This parameter is required if you create a NIC when creating the VM. * `nic_id` - (Optional) The ID of the NIC, if you are attaching an existing NIC when creating a VM. * `private_ips` - (Optional) One or more private IP addresses to assign to the NIC, if you create a NIC when creating a VM. Only one private IP address can be the primary private IP address. - * `is_primary` - (Optional) If `true`, the IP address is the primary private IP address of the NIC. - * `private_ip` - (Optional) The private IP address of the NIC. + * `is_primary` - (Optional) If `true`, the IP address is the primary private IP address of the NIC. + * `private_ip` - (Optional) The private IP address of the NIC. * `secondary_private_ip_count` - (Optional) The number of secondary private IP addresses, if you create a NIC when creating a VM. This parameter cannot be specified if you specified more than one private IP address in the `private_ips` parameter. * `security_group_ids` - (Optional) One or more IDs of security groups for the NIC, if you acreate a NIC when creating a VM. * `subnet_id` - (Optional) The ID of the Subnet for the NIC, if you create a NIC when creating a VM. @@ -198,8 +198,8 @@ For more information about volume types, see [Volume Types and IOPS](https://wik * `vm_type` - (Optional) The type of VM (`t2.small` by default).
For more information, see [Instance Types](https://wiki.outscale.net/display/EN/Instance+Types). * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -208,12 +208,12 @@ The following attributes are exported: * `vms` - Information about one or more created VMs. * `architecture` - The architecture of the VM (`i386` \| `x86_64`). * `block_device_mappings_created` - The block device mapping of the VM. - * `bsu` - Information about the created BSU volume. - * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. - * `link_date` - The time and date of attachment of the volume to the VM. - * `state` - The state of the volume. - * `volume_id` - The ID of the volume. - * `device_name` - The name of the device. + * `bsu` - Information about the created BSU volume. + * `delete_on_vm_deletion` - Set to `true` by default, which means that the volume is deleted when the VM is terminated. If set to `false`, the volume is not deleted when the VM is terminated. + * `link_date` - The time and date of attachment of the volume to the VM. + * `state` - The state of the volume. + * `volume_id` - The ID of the volume. + * `device_name` - The name of the device. * `bsu_optimized` - If `true`, the VM is optimized for BSU I/O. * `client_token` - The idempotency token provided when launching the VM. * `deletion_protection` - If `true`, you cannot terminate the VM using Cockpit, the CLI or the API. If `false`, you can. @@ -224,40 +224,40 @@ The following attributes are exported: * `launch_number` - The number for the VM when launching a group of several VMs (for example, 0, 1, 2, and so on). * `net_id` - The ID of the Net in which the VM is running. * `nics` - (Net only) The network interface cards (NICs) the VMs are attached to. - * `account_id` - The account ID of the owner of the NIC. - * `description` - The description of the NIC. - * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. - * `link_nic` - Information about the network interface card (NIC). - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). - * `link_nic_id` - The ID of the NIC to attach. - * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). - * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. - * `mac_address` - The Media Access Control (MAC) address of the NIC. - * `net_id` - The ID of the Net for the NIC. - * `nic_id` - The ID of the NIC. - * `private_dns_name` - The name of the private DNS. - * `private_ips` - The private IP address or addresses of the NIC. - * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `account_id` - The account ID of the owner of the NIC. + * `description` - The description of the NIC. + * `is_source_dest_checked` - (Net only) If `true`, the source/destination check is enabled. If `false`, it is disabled. This value must be `false` for a NAT VM to perform network address translation (NAT) in a Net. + * `link_nic` - Information about the network interface card (NIC). + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_number` - The device index for the NIC attachment (between 1 and 7, both included). + * `link_nic_id` - The ID of the NIC to attach. + * `state` - The state of the attachment (`attaching` \| `attached` \| `detaching` \| `detached`). * `link_public_ip` - Information about the EIP associated with the NIC. - * `public_dns_name` - The name of the public DNS. - * `public_ip` - The External IP address (EIP) associated with the NIC. - * `public_ip_account_id` - The account ID of the owner of the EIP. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `mac_address` - The Media Access Control (MAC) address of the NIC. + * `net_id` - The ID of the Net for the NIC. + * `nic_id` - The ID of the NIC. * `private_dns_name` - The name of the private DNS. - * `private_ip` - The private IP address. - * `security_groups` - One or more IDs of security groups for the NIC. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. - * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). - * `subnet_id` - The ID of the Subnet for the NIC. + * `private_ips` - The private IP address or addresses of the NIC. + * `is_primary` - If `true`, the IP address is the primary private IP address of the NIC. + * `link_public_ip` - Information about the EIP associated with the NIC. + * `public_dns_name` - The name of the public DNS. + * `public_ip` - The External IP address (EIP) associated with the NIC. + * `public_ip_account_id` - The account ID of the owner of the EIP. + * `private_dns_name` - The name of the private DNS. + * `private_ip` - The private IP address. + * `security_groups` - One or more IDs of security groups for the NIC. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. + * `state` - The state of the NIC (`available` \| `attaching` \| `in-use` \| `detaching`). + * `subnet_id` - The ID of the Subnet for the NIC. * `os_family` - Indicates the operating system (OS) of the VM. * `performance` - The performance of the VM (`medium` \| `high` \| `highest`). * `placement` - Information about the placement of the VM. - * `subregion_name` - The name of the Subregion. - * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). + * `subregion_name` - The name of the Subregion. + * `tenancy` - The tenancy of the VM (`default` \| `dedicated`). * `private_dns_name` - The name of the private DNS. * `private_ip` - The primary private IP address of the VM. * `product_codes` - The product code associated with the OMI used to create the VM (`0001` Linux/Unix \| `0002` Windows \| `0004` Linux/Oracle \| `0005` Windows 10). @@ -267,14 +267,14 @@ The following attributes are exported: * `root_device_name` - The name of the root device for the VM (for example, /dev/vda1). * `root_device_type` - The type of root device used by the VM (always `bsu`). * `security_groups` - One or more security groups associated with the VM. - * `security_group_id` - The ID of the security group. - * `security_group_name` - The name of the security group. + * `security_group_id` - The ID of the security group. + * `security_group_name` - The name of the security group. * `state` - The state of the VM (`pending` \| `running` \| `stopping` \| `stopped` \| `shutting-down` \| `terminated` \| `quarantine`). * `state_reason` - The reason explaining the current state of the VM. * `subnet_id` - The ID of the Subnet for the VM. * `tags` - One or more tags associated with the VM. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `user_data` - The Base64-encoded MIME user data. * `vm_id` - The ID of the VM. * `vm_initiated_shutdown_behavior` - The VM behavior when you stop it. By default or if set to `stop`, the VM stops. If set to `restart`, the VM stops then automatically restarts. If set to `terminate`, the VM stops and is deleted. diff --git a/website/docs/r/volume.html.markdown b/website/docs/r/volume.html.markdown index 598e9c9c7..e322efd27 100644 --- a/website/docs/r/volume.html.markdown +++ b/website/docs/r/volume.html.markdown @@ -37,8 +37,8 @@ The following arguments are supported: * `volume_type` - (Optional) The type of volume you want to create (`io1` \| `gp2` \| `standard`). If not specified, a `standard` volume is created.
For more information about volume types, see [Volume Types and IOPS](https://wiki.outscale.net/display/EN/About+Volumes#AboutVolumes-VolumeTypesVolumeTypesandIOPS). * `tags` - One or more tags to add to this resource. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Attribute Reference @@ -49,18 +49,18 @@ The following attributes are exported: For `io1` volumes, the number of provisioned IOPS. For `gp2` volumes, the baseline performance of the volume. * `linked_volumes` - Information about your volume attachment. - * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. - * `device_name` - The name of the device. - * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). - * `vm_id` - The ID of the VM. - * `volume_id` - The ID of the volume. + * `delete_on_vm_deletion` - If `true`, the volume is deleted when the VM is terminated. + * `device_name` - The name of the device. + * `state` - The state of the attachment of the volume (`attaching` \| `detaching` \| `attached` \| `detached`). + * `vm_id` - The ID of the VM. + * `volume_id` - The ID of the volume. * `size` - The size of the volume, in gibibytes (GiB). * `snapshot_id` - The snapshot from which the volume was created. * `state` - The state of the volume (`creating` \| `available` \| `in-use` \| `updating` \| `deleting` \| `error`). * `subregion_name` - The Subregion in which the volume was created. * `tags` - One or more tags associated with the volume. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `volume_id` - The ID of the volume. * `volume_type` - The type of the volume (`standard` \| `gp2` \| `io1`). diff --git a/website/docs/r/vpn_connection.html.markdown b/website/docs/r/vpn_connection.html.markdown index a8a4ef43f..13614f7d9 100644 --- a/website/docs/r/vpn_connection.html.markdown +++ b/website/docs/r/vpn_connection.html.markdown @@ -48,14 +48,14 @@ The following attributes are exported: * `client_gateway_id` - The ID of the client gateway used on the client end of the connection. * `connection_type` - The type of VPN connection (always `ipsec.1`). * `routes` - Information about one or more static routes associated with the VPN connection, if any. - * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). - * `route_type` - The type of route (always `static`). - * `state` - The current state of the static route (`pending` \| `available` \| `deleting` \| `deleted`). + * `destination_ip_range` - The IP range used for the destination match, in CIDR notation (for example, 10.0.0.0/24). + * `route_type` - The type of route (always `static`). + * `state` - The current state of the static route (`pending` \| `available` \| `deleting` \| `deleted`). * `state` - The state of the VPN connection (`pending` \| `available` \| `deleting` \| `deleted`). * `static_routes_only` - If `false`, the VPN connection uses dynamic routing with Border Gateway Protocol (BGP). If `true`, routing is controlled using static routes. For more information about how to create and delete static routes, see [CreateVpnConnectionRoute](https://docs.outscale.com/api#createvpnconnectionroute) and [DeleteVpnConnectionRoute](https://docs.outscale.com/api#deletevpnconnectionroute). * `tags` - One or more tags associated with the VPN connection. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. * `virtual_gateway_id` - The ID of the virtual gateway used on the 3DS OUTSCALE end of the connection. * `vpn_connection_id` - The ID of the VPN connection. From 2fe2ed2d3fcb33c1156dc52a64ec24c5405dc029 Mon Sep 17 00:00:00 2001 From: "margaux.haccard" Date: Mon, 30 Nov 2020 15:29:55 +0100 Subject: [PATCH 205/218] DOC-2524: Update ToC --- website/outscale.erb | 44 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 42 insertions(+), 2 deletions(-) diff --git a/website/outscale.erb b/website/outscale.erb index db58705e6..32ea41f07 100644 --- a/website/outscale.erb +++ b/website/outscale.erb @@ -55,6 +55,26 @@ keypairs +
  • + load_balancer_listener_rule +
  • + +
  • + load_balancer_listener_rules +
  • + +
  • + load_balancer_vm_health +
  • + +
  • + load_balancer +
  • + +
  • + load_balancers +
  • +
  • nat_service
  • @@ -144,11 +164,11 @@
  • - vm + vm_states
  • - vms_state + vm
  • @@ -209,6 +229,26 @@ keypair
  • +
  • + load_balancer_attributes +
  • + +
  • + load_balancer_listener_rule +
  • + +
  • + load_balancer_policy +
  • + +
  • + load_balancer_vms +
  • + +
  • + load_balancer +
  • +
  • nat_service
  • From b9a912d08aa046b3a1fbad7722f9b856250359e7 Mon Sep 17 00:00:00 2001 From: Dorine Germain Date: Mon, 30 Nov 2020 16:39:13 +0100 Subject: [PATCH 206/218] DOC-2557 Create Load Balancer Attributes Doc --- .../r/load_balancer_attributes.html.markdown | 173 ++++++++++++++++++ 1 file changed, 173 insertions(+) create mode 100644 website/docs/r/load_balancer_attributes.html.markdown diff --git a/website/docs/r/load_balancer_attributes.html.markdown b/website/docs/r/load_balancer_attributes.html.markdown new file mode 100644 index 000000000..6f5746cac --- /dev/null +++ b/website/docs/r/load_balancer_attributes.html.markdown @@ -0,0 +1,173 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_attributes" +sidebar_current: "outscale-load-balancer-attributes" +description: |- + [Manages a load balancer attribute.] +--- + +# outscale_load_balancer_attributes Resource + +Manages a load balancer attribute. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#updateloadbalancer). + +## Example Usage + +```hcl +#resource "outscale_load_balancer" "load_balancer01" { +# load_balancer_name = "terraform-load-balancer" +# subregion_names = ["eu-west-2a"] +# listeners { +# backend_port = 80 +# backend_protocol = "HTTP" +# load_balancer_protocol = "HTTP" +# load_balancer_port = 80 +# } +# listeners { +# backend_port = 8080 +# backend_protocol = "HTTPS" +# load_balancer_protocol = "HTTPS" +# load_balancer_port = 8080 +# server_certificate_id = "arn:aws:iam::012345678901:server-certificate/Cockpit/Certificate" +# } +# listeners { +# backend_port = 1024 +# backend_protocol = "TCP" +# load_balancer_protocol = "TCP" +# load_balancer_port = 1024 +# } +# tags { +# key = "name" +# value = "terraform-load-balancer" +# } +# tags { +# key = "platform" +# value = "eu-west-2" +# } +#} + +# Update health check + +resource "outscale_load_balancer_attributes" "attributes01" { + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + health_check { + healthy_threshold = 10 + check_interval = 30 + path = "/index.html" + port = 8080 + protocol = "HTTPS" + timeout = 5 + unhealthy_threshold = 5 + } +} + +# Update access log + +resource "outscale_load_balancer_attributes" "attributes02" { + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + access_log { + publication_interval = 5 + is_enabled = true + osu_bucket_name = "terraform-access-logs" + osu_bucket_prefix = "access-logs-01234" + } +} + +# Update policies + +resource "outscale_load_balancer_attributes" "attributes03" { + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + load_balancer_port = 80 + policy_names = ["policy-name-01"] +} + +# Update SSL certificate + +resource "outscale_load_balancer_attributes" "attributes04" { + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + load_balancer_port = 8080 + server_certificate_id = "arn:aws:iam::012345678901:server-certificate/Service/Name,Certificate" +} + +``` + +## Argument Reference + +The following arguments are supported: + +* `access_log` - Information about access logs. + * `is_enabled` - (Optional) If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. + * `osu_bucket_name` - (Optional) The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - (Optional) The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - (Optional) The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). +* `health_check` - Information about the health check configuration. + * `check_interval` - (Optional) The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - (Optional) The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - (Optional) The path for HTTP or HTTPS requests. + * `port` - (Optional) The port number (between `1` and `65535`, both included). + * `protocol` - (Optional) The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - (Optional) The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - (Optional) The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). +* `load_balancer_name` - (Required) The name of the load balancer. +* `load_balancer_port` - (Optional) The port on which the load balancer is listening (between `1` and `65535`, both included). +* `policy_names` - (Optional) The list of policy names (must contain all the policies to be enabled). +* `server_certificate_id` - (Optional) The Outscale Resource Name (ORN) of the SSL certificate. + +## Attribute Reference + +The following attributes are exported: + +* `load_balancer` - Information about the load balancer. + * `access_log` - Information about access logs. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. + * `dns_name` - The DNS name of the load balancer. + * `health_check` - Information about the health check configuration. + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `listeners` - The listeners for the load balancer. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. + * `load_balancer_name` - The name of the load balancer. + * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. + * `policy_name` - The name of the stickiness policy. + * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
    +If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
    +If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. + * `net_id` - The ID of the Net for the load balancer. + * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. + * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
    +To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. + * `subnets` - The IDs of the Subnets for the load balancer. + * `subregion_names` - One or more names of Subregions for the load balancer. + * `tags` - One or more tags associated with the load balancer. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. + +## Import + +A load balancer attribute can be imported using the name of the load balancer. For example: + +``` + +$ terraform import outscale_attributes.ImportedLbuAttributes Name-of-the-Lbu + +``` \ No newline at end of file From 4e5cc988c9da05641f66a0417ccf865140082d63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Mon, 30 Nov 2020 16:41:37 +0100 Subject: [PATCH 207/218] DOC-2678: Add load balancer VM health --- .../d/load_balancer_vm_health.html.markdown | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 website/docs/d/load_balancer_vm_health.html.markdown diff --git a/website/docs/d/load_balancer_vm_health.html.markdown b/website/docs/d/load_balancer_vm_health.html.markdown new file mode 100644 index 000000000..ce6acdf55 --- /dev/null +++ b/website/docs/d/load_balancer_vm_health.html.markdown @@ -0,0 +1,41 @@ +--- +layout: "outscale" +page_title: "3DS OUTSCALE: outscale_load_balancer_vm_health" +sidebar_current: "outscale-load-balancer-vm-health" +description: |- + [Provides information about VM health of a specific load balancer.] +--- + +# outscale_load_balancer_vm_health Data Source + +Provides information about VM health of a specific load balancer. +For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). +For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#readvmshealth). + +## Example Usage + +```hcl +data "outscale_load_balancer_vm_health" "load_balancer_vm_health01" { + load_balancer_name = "load_balancer01" + backend_vm_ids = ["i-12345678","i-87654321"] +} +``` + +## Argument Reference + +The following arguments are supported: + +* `backend_vm_ids` - (Optional) One or more IDs of back-end VMs. +* `load_balancer_name` - (Required) The name of the load balancer. + +## Attribute Reference + +The following attributes are exported: + +* `backend_vm_health` - Information about the health of one or more back-end VMs. + * `description` - The description of the state of the back-end VM. + * `state` - The state of the back-end VM (`InService` \| `OutOfService` \| `Unknown`). + * `state_reason` - Information about the cause of `OutOfService` VMs.
    +Specifically, whether the cause is Elastic Load Balancing or the VM (`ELB` \| `Instance` \| `N/A`). + * `vm_id` - The ID of the back-end VM. + From ac353adb18fb14a41524c2b7992e481ed8955250 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Mon, 30 Nov 2020 16:49:06 +0100 Subject: [PATCH 208/218] DOC-2524: Fix CamelCase to snake_case --- website/docs/d/load_balancer.html.markdown | 2 +- website/docs/d/load_balancers.html.markdown | 2 +- website/docs/r/load_balancer.html.markdown | 4 ++-- website/docs/r/load_balancer_policy.html.markdown | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/website/docs/d/load_balancer.html.markdown b/website/docs/d/load_balancer.html.markdown index 1e80cb9f6..4938a95c3 100644 --- a/website/docs/d/load_balancer.html.markdown +++ b/website/docs/d/load_balancer.html.markdown @@ -36,7 +36,7 @@ The following attributes are exported: * `load_balancers` - Information about one or more load balancers. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). diff --git a/website/docs/d/load_balancers.html.markdown b/website/docs/d/load_balancers.html.markdown index 6f644cc4e..5c98f07ee 100644 --- a/website/docs/d/load_balancers.html.markdown +++ b/website/docs/d/load_balancers.html.markdown @@ -36,7 +36,7 @@ The following attributes are exported: * `load_balancers` - Information about one or more load balancers. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). diff --git a/website/docs/r/load_balancer.html.markdown b/website/docs/r/load_balancer.html.markdown index ae7bc7bdd..e88075b32 100644 --- a/website/docs/r/load_balancer.html.markdown +++ b/website/docs/r/load_balancer.html.markdown @@ -155,7 +155,7 @@ The following arguments are supported: * `load_balancer_type` - (Optional) The type of load balancer: `internet-facing` or `internal`. Use this parameter only for load balancers in a Net. * `security_groups` - (Optional) (Net only) One or more IDs of security groups you want to assign to the load balancer. If not specified, the default security group of the Net is assigned to the load balancer. * `subnets` - (Optional) One or more IDs of Subnets in your Net that you want to attach to the load balancer. -* `subregion_names` - (Optional) One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `LoadBalancerType` parameter. +* `subregion_names` - (Optional) One or more names of Subregions (currently, only one Subregion is supported). This parameter is not required if you create a load balancer in a Net. To create an internal load balancer, use the `load_balancer_type` parameter. * `tags` - (Optional) One or more tags assigned to the load balancer. * `key` - (Optional) The key of the tag, with a minimum of 1 character. * `value` - (Optional) The value of the tag, between 0 and 255 characters. @@ -166,7 +166,7 @@ The following attributes are exported: * `load_balancer` - Information about the load balancer. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). diff --git a/website/docs/r/load_balancer_policy.html.markdown b/website/docs/r/load_balancer_policy.html.markdown index eac0fedd4..74df8bac7 100644 --- a/website/docs/r/load_balancer_policy.html.markdown +++ b/website/docs/r/load_balancer_policy.html.markdown @@ -71,7 +71,7 @@ The following attributes are exported: * `load_balancer` - Information about the load balancer. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `OsuBucketName` parameter is required. + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). From 7eea979e49514343cd32b64f9c55ec8a48e1c0b0 Mon Sep 17 00:00:00 2001 From: "lea.renou" Date: Mon, 30 Nov 2020 16:05:10 +0000 Subject: [PATCH 209/218] DOC-2524: Delete hidden file --- outscale/.DS_Store | Bin 22532 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 outscale/.DS_Store diff --git a/outscale/.DS_Store b/outscale/.DS_Store deleted file mode 100644 index 5ea2557c05d3b509286c1bef1cee73be49478895..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 22532 zcmeHP$&M695Y1wn83QtsErD4Z%re-3&Ba3EGD29wHzZ%U4KU!D5wmF)mfKt`akbryAf;VXDRprC9`D|Z-}622+Kn?6-oN3!7uTn>neL_8w2@ZR*1)gZ6CWA_yU-xo za1Y*Jrw6c|wBLG~OAld9+Hw;%ox}G_`OJFv9KYoi_w)HHX+Ev~w6r>Re`)nTB*Goi zbpX8lC%^E&>?J^2hm_h!nla`ea}mE=0m3XKvuzL46C9r<1F1Tk(!{ht+6T0wMM!;Z zEV;j?^x3t(-0JTgI9H1>7Sl3XKA+iJ!e3j^Yc4H7vo)Ms$G3}MWCNe8_=c>Kp-od$ zv`A@sD%^rvdNxS=(K667@QE_Oz8kN}{q?c^Y#C@7Xc>6R0P{l!Zysm5$L;!OQua~=F{q18(zvy3@1-UuBojseH-;b;fR+Lf^)x~yhxCH4CFsGG zCZ8iGKLM)`yXy^p>);jY>Vt^PdK`H<{el>Mnsa7e#nJ0MTpdwY4%Qp(nU;Z;fe(j) z3uwv|Dmtz^GPdWf%*)J}rbXsGA6P9OVI@~#eLE&BH|KGzqfjr53AM4}QD~ROhURL? z@ruGd5y0)QVH8bF>bMGME)r6U%l1Pzg=ByI; z91V@G%$G!oM6-?JYQ;GjrB%caY&_deWbd`GQzUkqaD2_^;gZQ?0nccjBZEKhx+C<6 zj9Pj*wsa1Ywvn7gMlBwe%Ug~pi5l~B&MnqE(AbYGqF*sbe>wk1l$f7eD6UpHt|VT} z&n-OL&yls2f5iOU#&I=cUQ&pW4BPXPUM+6*6!1bN|9Ci#Y^K=mS0a*5k094&hCZfR z9?Jk60X6X<+a2SZQr%WF{uD1UzA4}2JF_9%9pk%}>$aRRrdl3BSj(#j+@DK+7BO}) zxF`bjQF^>#%;tCbAr+?GQ#k%Tn(8g6l%ol zJyg?zzxK$^4;kBmKk%#!W+3)XAcfAE|tH%6Bzk-cU%9yuK63wh_5{ zE^HL@dCk?Z`4afN(k3$FBiFjEcp_6$kI2|r%69FMJzAnfW(FjRX$$5Ar9&jMYU!>P z*?*-Lkq7l z5Yc-VgdHMT*GKcUr1wfKBjXSs*NzrMywWo=8#)Zn)s&vDkdFrHr^i?iZ-}0~e+jEa zqK7g$!$ogoJ!!~iZc%NH^jSOQyX-KY6jCHd)<{lG%q*aIisUXzH+_jx_uUfgM{+m75T;1!1Eq@|M^1A)FhSec^ zfCoS|*J#Mk#I)e&(7;u$&e;P5>U*pIx&Oaxf3LTW@9M_bQQVZ>m)&1gHLR3nz7Tw0 zf?c>riGJ98S9xD1cY+PO58J?{os=#g@BQCq)MP)Fyq+uMb)>cF$w^_svU@j}3A|Ns zcZVNG8WU2x@5Z8CAJdHk#@yMtn8km6-eZ2 zT2HdiGc$^0qcj857#zd{_YB%;;1wOG^4m$F#{;Pm`xn-VFW12W%nKpuG(3i zMA@%|CzaV^P|`9D7nKL2k Date: Mon, 30 Nov 2020 17:17:18 +0100 Subject: [PATCH 210/218] DOC-2524: Fix plural --- website/docs/d/load_balancer_listener_rules.html.markdown | 6 +++--- website/docs/d/load_balancers.html.markdown | 6 +++--- website/docs/r/load_balancer_attributes.html.markdown | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/website/docs/d/load_balancer_listener_rules.html.markdown b/website/docs/d/load_balancer_listener_rules.html.markdown index 1fcd7a866..bdb24923f 100644 --- a/website/docs/d/load_balancer_listener_rules.html.markdown +++ b/website/docs/d/load_balancer_listener_rules.html.markdown @@ -1,12 +1,12 @@ --- layout: "outscale" -page_title: "3DS OUTSCALE: outscale_load_balancer_listener_rule" -sidebar_current: "outscale-load-balancer-listener-rule" +page_title: "3DS OUTSCALE: outscale_load_balancer_listener_rules" +sidebar_current: "outscale-load-balancer-listener-rules" description: |- [Provides information about load balancer listener rules.] --- -# outscale_load_balancer_listener_rule Data Source +# outscale_load_balancer_listener_rules Data Source Provides information about load balancer listener rules. For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). diff --git a/website/docs/d/load_balancers.html.markdown b/website/docs/d/load_balancers.html.markdown index 5c98f07ee..d274d997f 100644 --- a/website/docs/d/load_balancers.html.markdown +++ b/website/docs/d/load_balancers.html.markdown @@ -1,12 +1,12 @@ --- layout: "outscale" -page_title: "3DS OUTSCALE: outscale_load_balancer" -sidebar_current: "outscale-load-balancer" +page_title: "3DS OUTSCALE: outscale_load_balancers" +sidebar_current: "outscale-load-balancers" description: |- [Provides information about load balancers.] --- -# outscale_load_balancer Data Source +# outscale_load_balancers Data Source Provides information about load balancers. For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). diff --git a/website/docs/r/load_balancer_attributes.html.markdown b/website/docs/r/load_balancer_attributes.html.markdown index 6f5746cac..01cd42f2a 100644 --- a/website/docs/r/load_balancer_attributes.html.markdown +++ b/website/docs/r/load_balancer_attributes.html.markdown @@ -3,12 +3,12 @@ layout: "outscale" page_title: "3DS OUTSCALE: outscale_load_balancer_attributes" sidebar_current: "outscale-load-balancer-attributes" description: |- - [Manages a load balancer attribute.] + [Manages load balancer attributes.] --- # outscale_load_balancer_attributes Resource -Manages a load balancer attribute. +Manages load balancer attributes. For more information on this resource, see the [User Guide](https://wiki.outscale.net/display/EN/About+Load+Balancers). For more information on this resource actions, see the [API documentation](https://docs.outscale.com/api#updateloadbalancer). From eb498d2077bec429544ddf3a8224b17fdba43ab6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Tran?= Date: Mon, 30 Nov 2020 17:32:03 +0100 Subject: [PATCH 211/218] DOC-2681: Fix Load Balancer Attributes Doc --- .../r/load_balancer_attributes.html.markdown | 48 +++++++++---------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/website/docs/r/load_balancer_attributes.html.markdown b/website/docs/r/load_balancer_attributes.html.markdown index 01cd42f2a..4371cf510 100644 --- a/website/docs/r/load_balancer_attributes.html.markdown +++ b/website/docs/r/load_balancer_attributes.html.markdown @@ -120,33 +120,33 @@ The following attributes are exported: * `load_balancer` - Information about the load balancer. * `access_log` - Information about access logs. - * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. - * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. - * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). - * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). + * `is_enabled` - If `true`, access logs are enabled for your load balancer. If `false`, they are not. If you set this to `true` in your request, the `osu_bucket_name` parameter is required. + * `osu_bucket_name` - The name of the Object Storage Unit (OSU) bucket for the access logs. + * `osu_bucket_prefix` - The path to the folder of the access logs in your Object Storage Unit (OSU) bucket (by default, the `root` level of your bucket). + * `publication_interval` - The time interval for the publication of access logs in the Object Storage Unit (OSU) bucket, in minutes. This value can be either 5 or 60 (by default, 60). * `application_sticky_cookie_policies` - The stickiness policies defined for the load balancer. - * `cookie_name` - The name of the application cookie used for stickiness. - * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. + * `cookie_name` - The name of the application cookie used for stickiness. + * `policy_name` - The mnemonic name for the policy being created. The name must be unique within a set of policies for this load balancer. * `backend_vm_ids` - One or more IDs of back-end VMs for the load balancer. * `dns_name` - The DNS name of the load balancer. * `health_check` - Information about the health check configuration. - * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). - * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). - * `path` - The path for HTTP or HTTPS requests. - * `port` - The port number (between `1` and `65535`, both included). - * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). - * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). + * `check_interval` - The number of seconds between two pings (between `5` and `600` both included). + * `healthy_threshold` - The number of consecutive successful pings before considering the VM as healthy (between `2` and `10` both included). + * `path` - The path for HTTP or HTTPS requests. + * `port` - The port number (between `1` and `65535`, both included). + * `protocol` - The protocol for the URL of the VM (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `timeout` - The maximum waiting time for a response before considering the VM as unhealthy, in seconds (between `2` and `60` both included). + * `unhealthy_threshold` - The number of consecutive failed pings before considering the VM as unhealthy (between `2` and `10` both included). * `listeners` - The listeners for the load balancer. - * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). - * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). - * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). - * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. - * `server_certificate_id` - The ID of the server certificate. + * `backend_port` - The port on which the back-end VM is listening (between `1` and `65535`, both included). + * `backend_protocol` - The protocol for routing traffic to back-end VMs (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `load_balancer_port` - The port on which the load balancer is listening (between 1 and `65535`, both included). + * `load_balancer_protocol` - The routing protocol (`HTTP` \| `HTTPS` \| `TCP` \| `SSL` \| `UDP`). + * `policy_names` - The names of the policies. If there are no policies enabled, the list is empty. + * `server_certificate_id` - The ID of the server certificate. * `load_balancer_name` - The name of the load balancer. * `load_balancer_sticky_cookie_policies` - The policies defined for the load balancer. - * `policy_name` - The name of the stickiness policy. + * `policy_name` - The name of the stickiness policy. * `load_balancer_type` - The type of load balancer. Valid only for load balancers in a Net.
    If `LoadBalancerType` is `internet-facing`, the load balancer has a public DNS name that resolves to a public IP address.
    If `LoadBalancerType` is `internal`, the load balancer has a public DNS name that resolves to a private IP address. @@ -154,13 +154,13 @@ If `LoadBalancerType` is `internal`, the load balancer has a public DNS name tha * `security_groups` - One or more IDs of security groups for the load balancers. Valid only for load balancers in a Net. * `source_security_group` - Information about the source security group of the load balancer, which you can use as part of your inbound rules for your registered VMs.
    To only allow traffic from load balancers, add a security group rule that specifies this source security group as the inbound source. - * `security_group_account_id` - The account ID of the owner of the security group. - * `security_group_name` - The name of the security group. + * `security_group_account_id` - The account ID of the owner of the security group. + * `security_group_name` - The name of the security group. * `subnets` - The IDs of the Subnets for the load balancer. * `subregion_names` - One or more names of Subregions for the load balancer. * `tags` - One or more tags associated with the load balancer. - * `key` - The key of the tag, with a minimum of 1 character. - * `value` - The value of the tag, between 0 and 255 characters. + * `key` - The key of the tag, with a minimum of 1 character. + * `value` - The value of the tag, between 0 and 255 characters. ## Import From 394b47cbdabdfa4b4ddf504d37a8b0ce7e270e09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Mon, 30 Nov 2020 17:50:16 +0100 Subject: [PATCH 212/218] DOC-2557: Improve example --- website/docs/r/load_balancer_attributes.html.markdown | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/website/docs/r/load_balancer_attributes.html.markdown b/website/docs/r/load_balancer_attributes.html.markdown index 4371cf510..28d029f42 100644 --- a/website/docs/r/load_balancer_attributes.html.markdown +++ b/website/docs/r/load_balancer_attributes.html.markdown @@ -29,7 +29,7 @@ For more information on this resource actions, see the [API documentation](https # backend_protocol = "HTTPS" # load_balancer_protocol = "HTTPS" # load_balancer_port = 8080 -# server_certificate_id = "arn:aws:iam::012345678901:server-certificate/Cockpit/Certificate" +# server_certificate_id = "arn:aws:iam::012345678910:server-certificate/MyCertificates/Certificate" # } # listeners { # backend_port = 1024 @@ -50,7 +50,7 @@ For more information on this resource actions, see the [API documentation](https # Update health check resource "outscale_load_balancer_attributes" "attributes01" { - load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id health_check { healthy_threshold = 10 check_interval = 30 @@ -65,9 +65,9 @@ resource "outscale_load_balancer_attributes" "attributes01" { # Update access log resource "outscale_load_balancer_attributes" "attributes02" { - load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id + load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id access_log { - publication_interval = 5 + publication_interval = 5 is_enabled = true osu_bucket_name = "terraform-access-logs" osu_bucket_prefix = "access-logs-01234" @@ -87,7 +87,7 @@ resource "outscale_load_balancer_attributes" "attributes03" { resource "outscale_load_balancer_attributes" "attributes04" { load_balancer_name = outscale_load_balancer.load_balancer01.load_balancer_id load_balancer_port = 8080 - server_certificate_id = "arn:aws:iam::012345678901:server-certificate/Service/Name,Certificate" + server_certificate_id = "arn:aws:iam::012345678910:server-certificate/MyCertificates/Certificate" } ``` From b24c63400de1933fe7c62cb6569d87c80e97e0b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9a=20Renou?= Date: Mon, 30 Nov 2020 18:11:36 +0100 Subject: [PATCH 213/218] DOC-2557: Delete attribute import --- website/docs/r/load_balancer_attributes.html.markdown | 9 --------- 1 file changed, 9 deletions(-) diff --git a/website/docs/r/load_balancer_attributes.html.markdown b/website/docs/r/load_balancer_attributes.html.markdown index 28d029f42..b754cbca1 100644 --- a/website/docs/r/load_balancer_attributes.html.markdown +++ b/website/docs/r/load_balancer_attributes.html.markdown @@ -162,12 +162,3 @@ To only allow traffic from load balancers, add a security group rule that specif * `key` - The key of the tag, with a minimum of 1 character. * `value` - The value of the tag, between 0 and 255 characters. -## Import - -A load balancer attribute can be imported using the name of the load balancer. For example: - -``` - -$ terraform import outscale_attributes.ImportedLbuAttributes Name-of-the-Lbu - -``` \ No newline at end of file From 28980b9b0e5650c10e1fec7db169e4f2f3e0bbcc Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Mon, 30 Nov 2020 19:03:26 +0000 Subject: [PATCH 214/218] Added new GO SDK, LBU resources & datasources and x509 client authentication support --- README.md | 36 +++++++++++++++++++++++++++++++----- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index e25d45105..8a13d8599 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ terraform { required_providers { outscale = { source = "outscale-dev/outscale" - version = "0.1.1" + version = "0.2.0" } } } @@ -49,6 +49,32 @@ $ set HTTPS_PROXY=http://192.168.1.24:3128 ``` +x509 client authentication, if any +---------------------------------- + +Add the following lines in the Terraform configuration to define certificate location: + +```sh +terraform { + required_version = ">= 0.13" + required_providers { + outscale = { + source = "hashicorp/outscale" + version = "0.2.0" + } + } +} +provider "outscale" { + access_key_id = var.access_key_id + secret_key_id = var.secret_key_id + region = var.region + x509_cert_path = "certificate/client_ca.crt" + x509_key_path = "certificate/client_ca.key" +} +``` + + + Building The Provider --------------------- @@ -57,23 +83,23 @@ Clone repository to: `$GOPATH/src/github.com/terraform-providers/terraform-provi ```sh $ mkdir -p $GOPATH/src/github.com/terraform-providers; cd $GOPATH/src/github.com/terraform-providers -$ git clone --branch v0.1.1 https://github.com/outscale-dev/terraform-provider-outscale +$ git clone --branch v0.2.0 https://github.com/outscale-dev/terraform-provider-outscale ``` Enter the provider directory and build the provider ```sh $ cd $GOPATH/src/github.com/terraform-providers/terraform-provider-outscale -$ go build -o terraform-provider-outscale_v0.1.1 +$ go build -o terraform-provider-outscale_v0.2.0 ``` Using the provider ---------------------- 1. Download and install [Terraform](https://www.terraform.io/downloads.html) -2. Move the plugin to the repository ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.1.0/linux_amd64/. +2. Move the plugin to the repository ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.2.0/linux_amd64/. ```shell - $ mv terraform-provider-outscale_v0.1.1 ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.1.0/linux_amd64/. + $ mv terraform-provider-outscale_v0.2.0 ~/.terraform/plugins/registry.terraform.io/outscale-dev/outscale/0.2.0/linux_amd64/. ``` 3. Execute `terraform init` From dcded18efeae61495b9ed7f7d3405900ae1ddde7 Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Mon, 30 Nov 2020 19:29:37 +0000 Subject: [PATCH 215/218] Added new GO SDK, LBU resources & datasources and x509 client authentication support --- CHANGELOG.md | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 299135618..489572d0c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,83 @@ +0.2.0 (November 30, 2020) +======================== + +FEATURES: +--------- + +* New Data Source: outscale_load_balancer +* New Data Source: outscale_load_balancer_listener_rule +* New Data Source: outscale_load_balancer_listener_rules +* New Data Source: outscale_load_balancer_tags +* New Data Source: outscale_load_balancer_vm_health +* New Data Source: outscale_load_balancer_vms +* New Data Source: outscale_load_balancers +* New Data Source: outscale_vms_states is replaced by outscale_vm_state + +* New Resource: outscale_load_balancer +* New Resource: outscale_load_balancer_attributes +* New Resource: outscale_load_balancer_listener_rule +* New Resource: outscale_load_balancer_policy +* New Resource: outscale_load_balancer_vms + +BUG FIXES: +---------- + +* oAPI outscale_load_balancer resource is using fcu type call (TPD-1739) +* Add "outscale_load_balancer" datasource and datasources (TPD-1906) +* Wrong attributes for "outscale_load_balancer_vms" resource (TPD-1907) +* "image_id" should be mandatory in "outscale_vm" resource (TPD-1911) +* terraform crash when client gateway and vpn resources cannot be found (TPD-1914) +* Change "outscale_vms_state" datasource name to "outscale_vm_states" (TPD-1915) +* Issue with listeners on "outscale_load_balancer" (TPD-1916) +* Wrong attributes for "outscale_load_balancer" resource (TPD-1917) +* "outscale_load_balancer" resource: terraform destroy fails for private LBU (TPD-1918) +* "outscale_load_balancer" resource: issue when creating a load balancer with multiple securtiy groups (TPD-1919) +* "outscale_load_balancer_listeners" resource: "server_certificate_id" is not sent in the request (TPD-1920) +* "outscale_load_balancer_listeners" resource: missing attributes in the state (TPD-1921) +* Issue when creating a load balancer policy (TPD-1922) +* Add "outscale_load_balancer_listener_rule" resource and datasource(s) (TPD-1925) +* "outscale_load_balancer_vm_health" datasource(s) (TPD-1926) +* Regressions on "refactor-osc-client" branch (TPD-1927) +* Missing Health check attributes in "outscale_load_balancer" resource (TPD-1928) +* Terraform crashes when creating "outscale_load_balancer_ssl_certificate" resource (TPD-1930) +* "outscale_load_balancer_tags" datasources are not supported (TPD-1931) +* Migrate all LBU attributes modifications to "outscale_load_balancer_attributes" (TPD-1932) +* Issue on terraform refresh/destroy when using "outscale_nic" and "outscale_nic_private_ip" (TPD-1933) +* Regression on ""outscale_vpn_connection"" on "refactor-osc-client" branch (TPD-1934) +* x509 client certificate authentication (TPD-1936) + + +NOTES: +------ + +**WARNING:** When creating access keys, the secret key is stored in the Terraform state. For security reasons, it is strongly recommended to create access keys using the API instead of the Terraform resource. For more information on how to create access keys using the API, see our [official API documentation](https://docs.outscale.com/api#3ds-outscale-api-accesskey). + +It is recommended to set tags inside the resources rather than using outscale_tag. + + +0.1.2-beta (unpublished) +======================== + +BUG FIXES: +---------- + +* x509 client authentication support (TPD-1936) + + +0.1.1 (October 02, 2020) +======================== + +BUG FIXES: +---------- + +* Support proxy for Outscale Terraform provider (TPD-1924) + + +0.1.0 (August 07, 2020) +======================== + +NOTES: Rename of the previous release + 0.1.1 (October 02, 2020) ======================== From 1050e3d81a50feefdcfd6c644edde3b61d55806b Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Tue, 1 Dec 2020 09:16:20 +0000 Subject: [PATCH 216/218] Added new GO SDK, LBU resources & datasources and x509 client authentication support --- README.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8a13d8599..987dc5acd 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ terraform { required_version = ">= 0.13" required_providers { outscale = { - source = "hashicorp/outscale" + source = "outscale-dev/outscale" version = "0.2.0" } } @@ -73,8 +73,12 @@ provider "outscale" { } ``` +or set the following environment variables: - +```sh +export OUTSCALE_X509CERT=~/.terraform.d/plugins/certificate/client_ca.crt +export OUTSCALE_X509KEY=~/.terraform.d/plugins/certificate/client_ca.key +``` Building The Provider --------------------- From dd952c781827ebf465d03a60c472677d0cb843cc Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Tue, 1 Dec 2020 09:23:33 +0000 Subject: [PATCH 217/218] Added new GO SDK, LBU resources & datasources and x509 client authentication support --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 987dc5acd..b7f3a65b7 100644 --- a/README.md +++ b/README.md @@ -68,16 +68,16 @@ provider "outscale" { access_key_id = var.access_key_id secret_key_id = var.secret_key_id region = var.region - x509_cert_path = "certificate/client_ca.crt" - x509_key_path = "certificate/client_ca.key" + x509_cert_path = "/myrepository/certificate/client_ca.crt" + x509_key_path = "/myrepository/certificate/client_ca.key" } ``` or set the following environment variables: ```sh -export OUTSCALE_X509CERT=~/.terraform.d/plugins/certificate/client_ca.crt -export OUTSCALE_X509KEY=~/.terraform.d/plugins/certificate/client_ca.key +export OUTSCALE_X509CERT=/myrepository/certificate/client_ca.crt +export OUTSCALE_X509KEY=/myrepository/certificate/client_ca.key ``` Building The Provider From 564178fc535bd803b8344e9b2fcada2a95e2b72a Mon Sep 17 00:00:00 2001 From: "jean-francois.latour" Date: Tue, 1 Dec 2020 09:50:18 +0000 Subject: [PATCH 218/218] Added new GO SDK, LBU resources & datasources and x509 client authentication support --- CHANGELOG.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 489572d0c..29af65fa2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,9 +9,9 @@ FEATURES: * New Data Source: outscale_load_balancer_listener_rules * New Data Source: outscale_load_balancer_tags * New Data Source: outscale_load_balancer_vm_health -* New Data Source: outscale_load_balancer_vms * New Data Source: outscale_load_balancers -* New Data Source: outscale_vms_states is replaced by outscale_vm_state + +* Changed Data Source: outscale_vms_states is replaced by outscale_vm_state * New Resource: outscale_load_balancer * New Resource: outscale_load_balancer_attributes @@ -19,6 +19,7 @@ FEATURES: * New Resource: outscale_load_balancer_policy * New Resource: outscale_load_balancer_vms + BUG FIXES: ---------- @@ -45,6 +46,16 @@ BUG FIXES: * Issue on terraform refresh/destroy when using "outscale_nic" and "outscale_nic_private_ip" (TPD-1933) * Regression on ""outscale_vpn_connection"" on "refactor-osc-client" branch (TPD-1934) * x509 client certificate authentication (TPD-1936) +* Issue with custom endpoints (TPD-1938) +* Regression on "outscale_access_keys" datasource on develop-oapi (TPD-1939) +* Issue when deactivating LBU access logs (TPD-1940) + + +KNOWN INCOMPATIBILITIES: +------------------------ + +* outscale_load_balancer datasource: When applying the same configuration file twice in a row (with non change), terraform asks fo the user confirmation to read the datasource again (TPD-1942). +* outscale_load_balancer_listener_rule: The resource cannot be imported correctly because of listener block (TPD-1941). NOTES: